Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Dec 20, 2024
1 parent a6e8afe commit dd286f3
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions units/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,10 @@ elseif(UNITS_BUILD_STATIC_LIBRARY)
if(CMAKE_CXX_STANDARD GREATER 16)
target_compile_definitions(units PRIVATE -DUNITS_CONSTEXPR_IF_SUPPORTED=1)
endif()
if(UNITS_INSTALL AND NOT UNITS_BINARY_ONLY_INSTALL AND NOT SKBUILD)
if(UNITS_INSTALL
AND NOT UNITS_BINARY_ONLY_INSTALL
AND NOT SKBUILD
)
install(TARGETS units ${UNITS_LIBRARY_EXPORT_COMMAND}
DESTINATION ${CMAKE_INSTALL_LIBDIR} # INCLUDES DESTINATION
# include/${PROJECT_NAME}
Expand All @@ -179,7 +182,10 @@ target_include_directories(
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)
target_compile_definitions(header_only INTERFACE UNITS_HEADER_ONLY)
if(UNITS_INSTALL AND NOT UNITS_BINARY_ONLY_ AND NOT SKBUILD)
if(UNITS_INSTALL
AND NOT UNITS_BINARY_ONLY_
AND NOT SKBUILD
)
install(TARGETS header_only ${UNITS_LIBRARY_EXPORT_COMMAND})
endif()
if(UNITS_NAMESPACE)
Expand All @@ -194,7 +200,10 @@ if(UNITS_BASE_TYPE)
endif()
add_library(${UNITS_LC_PROJECT_NAME}::header_only ALIAS header_only)

if(UNITS_INSTALL AND NOT UNITS_BINARY_ONLY_INSTALL AND NOT SKBUILD)
if(UNITS_INSTALL
AND NOT UNITS_BINARY_ONLY_INSTALL
AND NOT SKBUILD
)
install(FILES ${units_header_files}
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${UNITS_LC_PROJECT_NAME}
)
Expand Down

0 comments on commit dd286f3

Please sign in to comment.