Fixes builds for Linux

openvr-qml-windows
dsc 3 years ago
parent 54694ccaa5
commit 0da4b5b8db

@ -5,9 +5,11 @@ set(CMAKE_AUTOUIC ON)
# pthread # pthread
find_package(Threads REQUIRED) find_package(Threads REQUIRED)
# PNG if(QML)
find_package(ZLIB REQUIRED) # PNG
find_package(PNG REQUIRED) find_package(ZLIB REQUIRED)
find_package(PNG REQUIRED)
endif()
# Compile these source files (.h/.cpp) # Compile these source files (.h/.cpp)
file(GLOB SOURCE_FILES file(GLOB SOURCE_FILES
@ -61,7 +63,10 @@ add_subdirectory(libwalletqt)
add_subdirectory(model) add_subdirectory(model)
add_subdirectory(utils) add_subdirectory(utils)
add_subdirectory(openpgp) add_subdirectory(openpgp)
add_subdirectory(QR-Code-scanner)
if(WITH_SCANNER)
add_subdirectory(QR-Code-scanner)
endif()
qt5_add_resources(RESOURCES assets.qrc) qt5_add_resources(RESOURCES assets.qrc)
@ -262,12 +267,11 @@ target_link_libraries(wowlet PUBLIC
openpgp openpgp
Threads::Threads Threads::Threads
${QRENCODE_LIBRARY} ${QRENCODE_LIBRARY}
qrdecoder
) )
# Link scanner # Link scanner
if(WITH_SCANNER) if(WITH_SCANNER)
target_link_libraries(wowlet PUBLIC qrscanner) target_link_libraries(wowlet PUBLIC qrdecoder qrscanner)
if(LINUX AND NOT ANDROID) if(LINUX AND NOT ANDROID)
target_link_libraries(wowlet PUBLIC target_link_libraries(wowlet PUBLIC
jpeg jpeg
@ -309,8 +313,8 @@ if(STATIC)
Qt5::QSvgIconPlugin Qt5::QSvgIconPlugin
Qt5::QSvgPlugin) Qt5::QSvgPlugin)
if(UNIX AND NOT APPLE) if(UNIX AND NOT APPLE)
target_link_libraries(wowlet target_link_libraries(wowlet PUBLIC
Qt5::QXcbIntegrationPlugin) Qt5::QXcbIntegrationPlugin)
endif() endif()
endif() endif()

Loading…
Cancel
Save