File tree Expand file tree Collapse file tree 5 files changed +9
-19
lines changed
Expand file tree Collapse file tree 5 files changed +9
-19
lines changed Original file line number Diff line number Diff line change @@ -66,7 +66,7 @@ endif()
6666
6767target_compile_features (spt3g INTERFACE cxx_std_17 )
6868target_include_directories (spt3g INTERFACE ${Boost_INCLUDE_DIR} )
69- target_link_libraries (spt3g INTERFACE Threads::Threads ${Boost_LIBRARIES} )
69+ target_link_libraries (spt3g INTERFACE Threads::Threads Boost::python )
7070target_include_directories (spt3g INTERFACE $<INSTALL_INTERFACE :${SPT3G_INCLUDE_INSTALL_DIR} >)
7171
7272# Python bindings
Original file line number Diff line number Diff line change @@ -42,17 +42,7 @@ set(Boost_USE_STATIC_LIBS @Boost_USE_STATIC_LIBS@)
4242set (Boost_USE_MULTITHREADED @Boost_USE_MULTITHREADED@)
4343set (Boost_USE_STATIC_RUNTIME @Boost_USE_STATIC_RUNTIME@)
4444set (Boost_PYTHON_VERSION @Boost_PYTHON_VERSION@)
45- find_dependency (Boost COMPONENTS iostreams python REQUIRED )
46-
47- if (@FLAC_FOUND@)
48- find_dependency (FLAC MODULE )
49- endif ()
50- if (@NetCDF_FOUND@)
51- find_dependency (NetCDF MODULE )
52- endif ()
53- if (@OpenMP_FOUND@)
54- find_dependency (OpenMP )
55- endif ()
45+ find_dependency (Boost COMPONENTS python REQUIRED )
5646
5747include (FindPackageHandleStandardArgs )
5848find_package_handle_standard_args (Spt3g
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ add_spt3g_library(core SHARED
2222target_link_libraries (core PUBLIC spt3g )
2323
2424find_package (Filesystem REQUIRED )
25- target_link_libraries (core PUBLIC std::filesystem )
25+ target_link_libraries (core PRIVATE std::filesystem )
2626
2727# add python bindings
2828add_spt3g_module (core src/python.cxx )
@@ -37,10 +37,12 @@ target_include_directories(core PUBLIC
3737find_package (FLAC MODULE )
3838if (FLAC_FOUND)
3939 target_compile_definitions (core PRIVATE -DG3_HAS_FLAC )
40- target_link_libraries (core PUBLIC FLAC::FLAC )
41- set (FLAC_FOUND ${FLAC_FOUND} PARENT_SCOPE )
40+ target_link_libraries (core PRIVATE FLAC::FLAC )
4241endif ()
4342
43+ # Link Boost IOStreams
44+ target_link_libraries (core PRIVATE Boost::iostreams )
45+
4446# Link against BZIP2 library
4547if (NOT DEFINED WITH_BZIP2)
4648 set (WITH_BZIP2 TRUE CACHE BOOL "Enable bzip2 file compression" )
Original file line number Diff line number Diff line change @@ -17,9 +17,8 @@ target_link_libraries(dfmux PUBLIC core)
1717add_spt3g_module (dfmux src/python.cxx )
1818
1919if (NetCDF_FOUND AND HDF5_FOUND)
20- target_link_libraries (dfmux PUBLIC NetCDF::NetCDF )
20+ target_link_libraries (dfmux PRIVATE NetCDF::NetCDF )
2121 add_spt3g_program (bin/ledgerman.py ledgerman )
22- set (NetCDF_FOUND ${NetCDF_FOUND} PARENT_SCOPE )
2322endif ()
2423
2524link_python_dir ()
Original file line number Diff line number Diff line change @@ -22,8 +22,7 @@ target_link_libraries(maps PUBLIC core calibration)
2222
2323find_package (OpenMP )
2424if (OpenMP_FOUND)
25- target_link_libraries (maps PUBLIC OpenMP::OpenMP_CXX )
26- set (OpenMP_FOUND ${OpenMP_FOUND} PARENT_SCOPE )
25+ target_link_libraries (maps PRIVATE OpenMP::OpenMP_CXX )
2726endif ()
2827
2928add_spt3g_module (maps src/python.cxx )
You can’t perform that action at this time.
0 commit comments