mirror of
https://github.com/jpd002/Play-.git
synced 2025-04-28 13:47:57 +03:00
qt: Allow compiling on Unix-likes without EVDEV
This is needed to compile on NetBSD, OpenBSD, illumos, etc. Signed-off-by: Nia Alarie <nia@NetBSD.org>
This commit is contained in:
parent
e70ee1608f
commit
478e490134
1 changed files with 9 additions and 4 deletions
|
@ -56,9 +56,11 @@ if(USE_GSH_VULKAN)
|
|||
endif()
|
||||
|
||||
if(TARGET_PLATFORM_UNIX)
|
||||
find_package(LIBEVDEV REQUIRED)
|
||||
list(APPEND PROJECT_LIBS ${LIBEVDEV_LIBRARY})
|
||||
list(APPEND DEFINITIONS_LIST HAS_LIBEVDEV=1)
|
||||
find_package(LIBEVDEV)
|
||||
if(LIBEVDEV_FOUND)
|
||||
list(APPEND PROJECT_LIBS ${LIBEVDEV_LIBRARY})
|
||||
list(APPEND DEFINITIONS_LIST HAS_LIBEVDEV=1)
|
||||
endif()
|
||||
|
||||
list(APPEND PROJECT_LIBS "-static-libgcc")
|
||||
list(APPEND PROJECT_LIBS "-static-libstdc++")
|
||||
|
@ -358,10 +360,13 @@ target_compile_definitions(Play PRIVATE ${DEFINITIONS_LIST})
|
|||
target_include_directories(Play PRIVATE
|
||||
./
|
||||
../../
|
||||
${LIBEVDEV_INCLUDE_DIR}
|
||||
${CMAKE_CURRENT_BINARY_DIR}
|
||||
)
|
||||
|
||||
if(LIBEVDEV_FOUND)
|
||||
target_include_directories(Play PRIVATE ${LIBEVDEV_INCLUDE_DIR})
|
||||
endif()
|
||||
|
||||
if(TARGET_PLATFORM_WIN32)
|
||||
find_program(WINDEPLOYQT_EXE windeployqt HINTS "${QT_BINARY_DIRECTORY}")
|
||||
add_custom_command(TARGET Play POST_BUILD
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue