-
Notifications
You must be signed in to change notification settings - Fork 260
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* wip export targets Signed-off-by: Karsten Knese <[email protected]> * correct include dirs Signed-off-by: Karsten Knese <[email protected]> * relative include paths for vendor packages Signed-off-by: Karsten Knese <[email protected]> * cleanup rosbag2_test_common Signed-off-by: Karsten Knese <[email protected]> * cleanup shared_queues_vendor package Signed-off-by: Karsten Knese <[email protected]> * cleanup sqlite3 vendor package Signed-off-by: Karsten Knese <[email protected]> * cleanup zstd_vendor package Signed-off-by: Karsten Knese <[email protected]> * cleanup rosbag2_compression Signed-off-by: Karsten Knese <[email protected]> * touchups for isolated build Signed-off-by: Knese Karsten <[email protected]> * export typesupport Signed-off-by: Karsten Knese <[email protected]> * organize included dependencies Signed-off-by: Karsten Knese <[email protected]> * unknown import target for sqlite3 Signed-off-by: Karsten Knese <[email protected]> * try debugging windows Signed-off-by: Karsten Knese <[email protected]> * remove fatal error warning Signed-off-by: Karsten Knese <[email protected]> * limit amount of change Signed-off-by: Karsten Knese <[email protected]> * use CMAKE_INSTALL_PREFIX Signed-off-by: Karsten Knese <[email protected]> * fatal_error only when required Signed-off-by: Karsten Knese <[email protected]>
- Loading branch information
1 parent
f32a63c
commit ead6f74
Showing
10 changed files
with
128 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# Get package location hint from environment variable (if any) | ||
if(NOT zstd_ROOT_DIR AND DEFINED ENV{zstd_ROOT_DIR}) | ||
set(zstd_ROOT_DIR "$ENV{zstd_ROOT_DIR}" CACHE PATH | ||
"zstd base directory location (optional, used for nonstandard installation paths)") | ||
endif() | ||
|
||
# Search path for nonstandard package locations | ||
if(zstd_ROOT_DIR) | ||
set(zstd_INCLUDE_PATH PATHS "${zstd_ROOT_DIR}/include" NO_DEFAULT_PATH) | ||
set(zstd_LIBRARY_PATH PATHS "${zstd_ROOT_DIR}/lib" NO_DEFAULT_PATH) | ||
else() | ||
set(zstd_INCLUDE_PATH "") | ||
set(zstd_LIBRARY_PATH "") | ||
endif() | ||
|
||
# Find headers and libraries | ||
find_path(zstd_INCLUDE_DIR NAMES zstd.h PATH_SUFFIXES "zstd" ${zstd_INCLUDE_PATH}) | ||
find_library(zstd_LIBRARY NAMES zstd PATH_SUFFIXES "zstd" ${zstd_LIBRARY_PATH}) | ||
|
||
mark_as_advanced(zstd_INCLUDE_DIR zstd_LIBRARY) | ||
|
||
# Output variables generation | ||
include(FindPackageHandleStandardArgs) | ||
find_package_handle_standard_args(zstd DEFAULT_MSG zstd_LIBRARY zstd_INCLUDE_DIR) | ||
|
||
set(zstd_FOUND ${ZSTD_FOUND}) # Enforce case-correctness: Set appropriately cased variable... | ||
unset(ZSTD_FOUND) # ...and unset uppercase variable generated by find_package_handle_standard_args | ||
|
||
if(zstd_FOUND) | ||
set(zstd_INCLUDE_DIRS ${zstd_INCLUDE_DIR}) | ||
set(zstd_LIBRARIES ${zstd_LIBRARY}) | ||
|
||
if(NOT TARGET zstd::zstd) | ||
add_library(zstd::zstd UNKNOWN IMPORTED) | ||
set_property(TARGET zstd::zstd PROPERTY IMPORTED_LOCATION ${zstd_LIBRARY}) | ||
set_property(TARGET zstd::zstd PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${zstd_INCLUDE_DIR}) | ||
endif() | ||
list(APPEND zstd_TARGETS zstd::zstd) | ||
elseif(zstd_FIND_REQUIRED) | ||
message(FATAL_ERROR "Unable to find zstd") | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
list(INSERT CMAKE_MODULE_PATH 0 "${zstd_vendor_DIR}/Modules") |