diff --git a/cmake/SuperBuild.cmake b/cmake/SuperBuild.cmake index b55bfb93..595bfb3b 100644 --- a/cmake/SuperBuild.cmake +++ b/cmake/SuperBuild.cmake @@ -152,7 +152,7 @@ if(BUILD_ZLIB) set(ZLIB_INCLUDE_DIRS ${ZLIB_ROOT}/include) set(ZLIB_LIBRARIES ${ZLIB_ROOT}/lib/zlibstatic.lib) set(ZLIB_LIBRARY_RELEASE ${ZLIB_ROOT}/lib/zlibstatic.lib) - elseif(WIN32) + else(WIN32) set(ZLIB_INCLUDE_DIRS ${ZLIB_ROOT}/include) set(ZLIB_LIBRARIES ${ZLIB_ROOT}/lib/libz.a) set(ZLIB_LIBRARY_RELEASE ${ZLIB_ROOT}/lib/libz.a) diff --git a/nglib/CMakeLists.txt b/nglib/CMakeLists.txt index aa9c101b..47eb6597 100644 --- a/nglib/CMakeLists.txt +++ b/nglib/CMakeLists.txt @@ -9,6 +9,8 @@ if(EMSCRIPTEN) target_compile_options(nglib PUBLIC $>) target_compile_definitions(nglib PUBLIC $) target_include_directories(nglib PUBLIC $) + target_include_directories(nglib PRIVATE $) + target_link_libraries(nglib PRIVATE ${ZLIB_LIBRARIES} $>) else(EMSCRIPTEN) target_link_libraries(nglib PUBLIC ngcore) target_link_libraries( nglib PRIVATE ${CMAKE_THREAD_LIBS_INIT} ${JPEG_LIBRARIES} ${MKL_LIBRARIES} ${ZLIB_LIBRARIES} occ_libs netgen_cgns )