diff --git a/server/CMakeLists.txt b/server/CMakeLists.txt index 2b522ec..9043bff 100644 --- a/server/CMakeLists.txt +++ b/server/CMakeLists.txt @@ -289,7 +289,13 @@ target_link_libraries(TeaSpeakServer ) if (COMPILE_WEB_CLIENT) - target_link_libraries(TeaSpeakServer ${glib20_DIR}/lib/x86_64-linux-gnu/libffi.so.7 ${nice_DIR}/lib/libnice.so.10) + file(GLOB GLIB20_ARCHS ${glib20_DIR}/lib/*) + list(LENGTH GLIB20_ARCHS GLIB20_ARCHS_LENGTH) + if (NOT ${GLIB20_ARCHS_LENGTH} EQUAL 1) + message(FATAL_ERROR "Missing arch specific folder for glib2.0 in ${glib20_DIR}. Found ${GLIB20_ARCHS_LENGTH} directories, expected 1.") + endif () + list(GET GLIB20_ARCHS 0 GLIB20_ARCH_DIR) + target_link_libraries(TeaSpeakServer ${GLIB20_ARCH_DIR}/libffi.so.7 ${nice_DIR}/lib/libnice.so.10) endif () # include_directories(${LIBRARY_PATH}/boringssl/include/)