diff --git a/CMakeLists.txt b/CMakeLists.txt index ca7c19b..8740ada 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -25,7 +25,7 @@ else() set(GUI_FOUND FALSE) endif(FLTK_FOUND) -if(MSVC) +if(MSVC OR APPLE) find_package(liblo) if(liblo_FOUND) set(LIBLO_FOUND TRUE) @@ -174,10 +174,10 @@ macro(maketestcpp fname) target_link_libraries(${fname} PRIVATE rtosc-cpp rtosc) #add_test(memcheck_${fname} valgrind --leak-check=full --show-reachable=yes --error-exitcode=1 ./${fname}) endmacro(maketestcpp) -if(WIN32) - set(RTOSC_LIBLO_LIBRARIES "liblo::liblo") -else() +if(PKG_CONFIG_FOUND) set(RTOSC_LIBLO_LIBRARIES "${LIBLO_LIBRARIES}") +else() + set(RTOSC_LIBLO_LIBRARIES "liblo::liblo") endif() maketest(rtosc-time)