Skip to content

Commit

Permalink
Rename utils library to avoid an overly generic libutils.so
Browse files Browse the repository at this point in the history
  • Loading branch information
tmadlener committed Apr 12, 2024
1 parent 792cefc commit 633b35e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
4 changes: 4 additions & 0 deletions cmake/EDM4HEPConfig.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,8 @@ include("${CMAKE_CURRENT_LIST_DIR}/EDM4HEPTargets.cmake")
# print the default "Found:" message and check library location
include(FindPackageHandleStandardArgs)
get_property(TEST_EDM4HEP_LIBRARY TARGET EDM4HEP::edm4hep PROPERTY LOCATION)

# For backwards compatibility and for slightly less typing
add_library(EDM4HEP::utils ALIAS EDM4HEP::edm4hepUtils)

find_package_handle_standard_args(EDM4HEP DEFAULT_MSG CMAKE_CURRENT_LIST_FILE TEST_EDM4HEP_LIBRARY)
9 changes: 4 additions & 5 deletions utils/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,9 @@ target_include_directories(kinematics
target_link_libraries(kinematics PUBLIC INTERFACE ROOT::Core)
target_compile_features(kinematics INTERFACE cxx_std_17)

add_library(utils INTERFACE)
add_library(EDM4HEP::utils ALIAS utils)
target_link_libraries(utils INTERFACE kinematics)

add_library(edm4hepUtils INTERFACE)
add_library(EDM4HEP::utils ALIAS edm4hepUtils)
target_link_libraries(edm4hepUtils INTERFACE kinematics)

set(sources src/dataframe.cc)
set(headers include/edm4hep/utils/dataframe.h)
Expand All @@ -26,7 +25,7 @@ target_link_libraries(edm4hepRDF PUBLIC edm4hep ROOT::Physics ROOT::ROOTVecOps)
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
PATTERN "CMakeLists.txt" EXCLUDE)

install(TARGETS utils kinematics edm4hepRDF
install(TARGETS edm4hepUtils kinematics edm4hepRDF
EXPORT EDM4HEPTargets
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" COMPONENT bin
RUNTIME DESTINATION "${CMAKE_INSTALL_LIBDIR}" COMPONENT shlib
Expand Down

0 comments on commit 633b35e

Please sign in to comment.