aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/cyclonedds
diff options
context:
space:
mode:
authorEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
committerEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
commit54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch)
treed915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/cyclonedds
move to own git serverHEADmaster
Diffstat (limited to 'vcpkg/ports/cyclonedds')
-rw-r--r--vcpkg/ports/cyclonedds/enable-security.patch13
-rw-r--r--vcpkg/ports/cyclonedds/idlc-generate.patch35
-rw-r--r--vcpkg/ports/cyclonedds/portfile.cmake51
-rw-r--r--vcpkg/ports/cyclonedds/usage4
-rw-r--r--vcpkg/ports/cyclonedds/vcpkg.json88
5 files changed, 191 insertions, 0 deletions
diff --git a/vcpkg/ports/cyclonedds/enable-security.patch b/vcpkg/ports/cyclonedds/enable-security.patch
new file mode 100644
index 0000000..a414272
--- /dev/null
+++ b/vcpkg/ports/cyclonedds/enable-security.patch
@@ -0,0 +1,13 @@
+diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt
+index 148fb3f2..c9c4d96c 100644
+--- a/src/core/CMakeLists.txt
++++ b/src/core/CMakeLists.txt
+@@ -43,7 +43,7 @@ endif()
+
+ # Support the OMG DDS Security within ddsc adds quite a bit of code.
+ if(ENABLE_SECURITY)
+- target_link_libraries(ddsc PRIVATE security_core)
++ target_link_libraries(ddsc PRIVATE $<BUILD_INTERFACE:security_core>)
+ target_include_directories(
+ ddsc PUBLIC
+ $<BUILD_INTERFACE:$<TARGET_PROPERTY:security_api,INTERFACE_INCLUDE_DIRECTORIES>>)
diff --git a/vcpkg/ports/cyclonedds/idlc-generate.patch b/vcpkg/ports/cyclonedds/idlc-generate.patch
new file mode 100644
index 0000000..5c9715e
--- /dev/null
+++ b/vcpkg/ports/cyclonedds/idlc-generate.patch
@@ -0,0 +1,35 @@
+diff --git a/cmake/Modules/Generate.cmake b/cmake/Modules/Generate.cmake
+index 0ed67d63..9037fe05 100644
+--- a/cmake/Modules/Generate.cmake
++++ b/cmake/Modules/Generate.cmake
+@@ -157,11 +157,25 @@ function(IDLC_GENERATE_GENERIC)
+ endforeach()
+
+ list(APPEND _outputs ${_file_outputs})
+- add_custom_command(
+- OUTPUT ${_file_outputs}
+- COMMAND ${_idlc_executable}
+- ARGS ${_language} ${IDLC_ARGS} ${IDLC_INCLUDE_DIRS} ${_file}
+- DEPENDS ${_files} ${_depends})
++ if(APPLE)
++ add_custom_command(
++ OUTPUT ${_file_outputs}
++ COMMAND ${CMAKE_COMMAND}
++ ARGS -E env "DYLD_LIBRARY_PATH=$<TARGET_FILE_DIR:${_idlc_executable}>/../../lib" $<TARGET_FILE:${_idlc_executable}> ${_language} ${IDLC_ARGS} ${IDLC_INCLUDE_DIRS} ${_file}
++ DEPENDS ${_files} ${_depends})
++ elseif(UNIX)
++ add_custom_command(
++ OUTPUT ${_file_outputs}
++ COMMAND ${CMAKE_COMMAND}
++ ARGS -E env "LD_LIBRARY_PATH=$<TARGET_FILE_DIR:${_idlc_executable}>/../../lib" $<TARGET_FILE:${_idlc_executable}> ${_language} ${IDLC_ARGS} ${IDLC_INCLUDE_DIRS} ${_file}
++ DEPENDS ${_files} ${_depends})
++ else()
++ add_custom_command(
++ OUTPUT ${_file_outputs}
++ COMMAND ${_idlc_executable}
++ ARGS ${_language} ${IDLC_ARGS} ${IDLC_INCLUDE_DIRS} ${_file}
++ DEPENDS ${_files} ${_depends})
++ endif()
+ endforeach()
+
+ add_custom_target("${_target}_generate" DEPENDS "${_outputs}")
diff --git a/vcpkg/ports/cyclonedds/portfile.cmake b/vcpkg/ports/cyclonedds/portfile.cmake
new file mode 100644
index 0000000..ac81d03
--- /dev/null
+++ b/vcpkg/ports/cyclonedds/portfile.cmake
@@ -0,0 +1,51 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO eclipse-cyclonedds/cyclonedds
+ REF "${VERSION}"
+ SHA512 de63a7207c36ff1b185b1a108d697d37675078ac15c34a940429b619b048593056dd8c4c920fb708235b972f94536452973eb40a8e66da1d57cb9b9b03005f30
+ HEAD_REF master
+ PATCHES
+ enable-security.patch
+ idlc-generate.patch
+)
+
+vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
+ FEATURES
+ "ddsperf" BUILD_DDSPERF
+ "deadline-missed" ENABLE_DEADLINE_MISSED
+ "ipv6" ENABLE_IPV6
+ "idlc" BUILD_IDLC
+ "lifespan" ENABLE_LIFESPAN
+ "security" ENABLE_SECURITY
+ "shm" ENABLE_SHM
+ "source-specific-multicast" ENABLE_SOURCE_SPECIFIC_MULTICAST
+ "ssl" ENABLE_SSL
+ "topic-discovery" ENABLE_TOPIC_DISCOVERY
+ "type-discovery" ENABLE_TYPE_DISCOVERY
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS
+ ${FEATURE_OPTIONS}
+)
+
+vcpkg_cmake_install()
+vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/CycloneDDS")
+
+if(BUILD_IDLC)
+ vcpkg_copy_tools(TOOL_NAMES idlc AUTO_CLEAN)
+endif()
+
+if(BUILD_DDSPERF)
+ vcpkg_copy_tools(TOOL_NAMES ddsperf AUTO_CLEAN)
+endif()
+
+file(REMOVE_RECURSE
+ "${CURRENT_PACKAGES_DIR}/debug/include"
+ "${CURRENT_PACKAGES_DIR}/debug/share"
+)
+
+vcpkg_fixup_pkgconfig()
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
+file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
diff --git a/vcpkg/ports/cyclonedds/usage b/vcpkg/ports/cyclonedds/usage
new file mode 100644
index 0000000..dcc8c83
--- /dev/null
+++ b/vcpkg/ports/cyclonedds/usage
@@ -0,0 +1,4 @@
+cyclonedds provides CMake targets:
+
+ find_package(CycloneDDS CONFIG REQUIRED)
+ target_link_libraries(main PRIVATE CycloneDDS::ddsc)
diff --git a/vcpkg/ports/cyclonedds/vcpkg.json b/vcpkg/ports/cyclonedds/vcpkg.json
new file mode 100644
index 0000000..1f1875b
--- /dev/null
+++ b/vcpkg/ports/cyclonedds/vcpkg.json
@@ -0,0 +1,88 @@
+{
+ "name": "cyclonedds",
+ "version-semver": "0.10.5",
+ "description": "Eclipse Cyclone DDS is a very performant and robust open-source implementation of the OMG DDS specification",
+ "homepage": "https://cyclonedds.io",
+ "license": "EPL-2.0 OR BSD-3-Clause",
+ "supports": "!uwp & !(arm64 & windows)",
+ "dependencies": [
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ],
+ "default-features": [
+ "deadline-missed",
+ "ipv6",
+ "lifespan",
+ "security",
+ "source-specific-multicast",
+ "topic-discovery",
+ "type-discovery"
+ ],
+ "features": {
+ "ddsperf": {
+ "description": "Build ddsperf tool",
+ "dependencies": [
+ {
+ "name": "cyclonedds",
+ "host": true,
+ "default-features": false,
+ "features": [
+ "idlc"
+ ]
+ }
+ ]
+ },
+ "deadline-missed": {
+ "description": "Enable Deadline Missed QoS suppor"
+ },
+ "idlc": {
+ "description": "Build IDL preprocessor"
+ },
+ "ipv6": {
+ "description": "Enable ipv6 support"
+ },
+ "lifespan": {
+ "description": "Enable Lifespan QoS support"
+ },
+ "security": {
+ "description": "Enable OMG DDS Security support"
+ },
+ "shm": {
+ "description": "Enable shared memory support",
+ "supports": "!windows",
+ "dependencies": [
+ "iceoryx"
+ ]
+ },
+ "source-specific-multicast": {
+ "description": "Enable support for source-specific multicast"
+ },
+ "ssl": {
+ "description": "Enable OpenSSL support",
+ "dependencies": [
+ "openssl"
+ ]
+ },
+ "topic-discovery": {
+ "description": "Enable Topic Discovery support",
+ "dependencies": [
+ {
+ "name": "cyclonedds",
+ "default-features": false,
+ "features": [
+ "type-discovery"
+ ]
+ }
+ ]
+ },
+ "type-discovery": {
+ "description": "Enable Type Discovery support"
+ }
+ }
+}