Skip to content

Commit f4a3de5

Browse files
committed
cmake: Update library and target names for qrcodegen
qrcodegen is identified as such (without the "lib" prefix) and as the target "qrcodegencpp::qrcodegencpp" by the CMake package generated by obs-deps and the finders in obs-studio when using module fallback.
1 parent 2bfa1b4 commit f4a3de5

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

cmake/legacy.cmake

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@ find_qt(COMPONENTS Core Widgets Svg Network)
1818
find_package(nlohmann_json 3 REQUIRED)
1919

2020
# Find qrcodegencpp
21-
find_package(Libqrcodegencpp REQUIRED)
21+
set(CMAKE_FIND_PACKAGE_PREFER_CONFIG ON)
22+
find_package(qrcodegencpp REQUIRED)
23+
set(CMAKE_FIND_PACKAGE_PREFER_CONFIG OFF)
2224

2325
# Find WebSocket++
2426
find_package(Websocketpp 0.8 REQUIRED)
@@ -138,7 +140,7 @@ target_link_libraries(
138140
nlohmann_json::nlohmann_json
139141
Websocketpp::Websocketpp
140142
Asio::Asio
141-
Libqrcodegencpp::Libqrcodegencpp)
143+
qrcodegencpp::qrcodegencpp)
142144

143145
target_compile_features(obs-websocket PRIVATE cxx_std_17)
144146

0 commit comments

Comments
 (0)