File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed
Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -149,10 +149,16 @@ endif()
149149
150150include (GNUInstallDirs)
151151install (TARGETS openjph
152+ EXPORT openjph_targets
152153 ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
153154 RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
154155 LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} )
155156
157+ install (EXPORT openjph_targets
158+ FILE openjph_targets.cmake
159+ DESTINATION lib/cmake/openjph
160+ )
161+
156162install (DIRECTORY src/core/common/
157163 DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} /openjph
158164 FILES_MATCHING
Original file line number Diff line number Diff line change @@ -38,8 +38,8 @@ if(EMSCRIPTEN)
3838 add_library (openjph ${SOURCES} )
3939 add_library (openjphsimd ${SOURCES} ${CODESTREAM_WASM} ${CODING_WASM} ${TRANSFORM_WASM} )
4040
41- target_include_directories (openjph PUBLIC common)
42- target_include_directories (openjphsimd PUBLIC common)
41+ target_include_directories (openjph PUBLIC $<BUILD_INTERFACE: ${CMAKE_CURRENT_SOURCE_DIR} common> $<INSTALL_INTERFACE: include > )
42+ target_include_directories (openjphsimd PUBLIC $<BUILD_INTERFACE: ${CMAKE_CURRENT_SOURCE_DIR} common> $<INSTALL_INTERFACE: include > )
4343
4444 target_compile_options (openjphsimd PRIVATE -DOJPH_ENABLE_WASM_SIMD -msimd128)
4545
@@ -124,7 +124,7 @@ if (BUILD_SHARED_LIBS AND WIN32)
124124endif ()
125125
126126## include library version/name
127- target_include_directories (openjph PUBLIC common)
127+ target_include_directories (openjph PUBLIC $<BUILD_INTERFACE: ${CMAKE_CURRENT_SOURCE_DIR} / common> $<INSTALL_INTERFACE: include > )
128128target_compile_definitions (openjph PUBLIC _FILE_OFFSET_BITS=64)
129129
130130if (MSVC )
You can’t perform that action at this time.
0 commit comments