Commit 44fe0e77 authored by Ryan Pavlik's avatar Ryan Pavlik
Browse files

build: Handle Android NDK better.

parent 60cf946d
......@@ -68,6 +68,11 @@ else()
find_package(OpenGL)
endif()
find_library(RT_LIBRARY rt)
if(ANDROID)
find_library(ANDROID_LIBRARY android)
endif()
# This one is named differently because that's what CTest uses
option(BUILD_TESTING "Enable building of the test suite?" ON)
......
......@@ -49,7 +49,6 @@ target_include_directories(ipc_client PRIVATE
)
target_link_libraries(ipc_client PRIVATE
aux_util
rt
)
......@@ -76,12 +75,25 @@ target_include_directories(ipc_server PRIVATE
)
target_link_libraries(ipc_server PRIVATE
aux_util
rt
)
if(RT_LIBRARY)
target_link_libraries(ipc_client PRIVATE
${RT_LIBRARY}
)
target_link_libraries(ipc_server PRIVATE
${RT_LIBRARY}
)
endif()
if(XRT_HAVE_SYSTEMD)
target_include_directories(ipc_server PRIVATE
${SYSTEMD_INCLUDE_DIRS})
target_link_libraries(ipc_server PRIVATE
${SYSTEMD_LIBRARIES})
endif()
if(ANDROID)
target_link_libraries(ipc_server PUBLIC ${ANDROID_LIBRARY})
target_link_libraries(ipc_client PUBLIC ${ANDROID_LIBRARY})
endif()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment