diff options
Diffstat (limited to 'vcpkg/ports/salome-configuration')
| -rw-r--r-- | vcpkg/ports/salome-configuration/cmake-4.patch | 14 | ||||
| -rw-r--r-- | vcpkg/ports/salome-configuration/portfile.cmake | 26 | ||||
| -rw-r--r-- | vcpkg/ports/salome-configuration/vcpkg.json | 16 |
3 files changed, 56 insertions, 0 deletions
diff --git a/vcpkg/ports/salome-configuration/cmake-4.patch b/vcpkg/ports/salome-configuration/cmake-4.patch new file mode 100644 index 0000000..d70aff6 --- /dev/null +++ b/vcpkg/ports/salome-configuration/cmake-4.patch @@ -0,0 +1,14 @@ +diff --git a/cmake/SalomeMacros.cmake b/cmake/SalomeMacros.cmake +index bb38859ee9..3b7662dcae 100644 +--- a/cmake/SalomeMacros.cmake ++++ b/cmake/SalomeMacros.cmake +@@ -23,9 +23,6 @@ + # Set-up global policies + #---------------------------------------------------------------------------- + CMAKE_POLICY(SET CMP0003 NEW) # Ensure proper linker behavior +-IF(WIN32) +- CMAKE_POLICY(SET CMP0020 OLD) # Disable automatic linking to qtmain.lib +-ENDIF(WIN32) + CMAKE_POLICY(SET CMP0053 NEW) # For correct Qt 5 detection procedure + IF(CMAKE_VERSION VERSION_GREATER_EQUAL 3.12) + CMAKE_POLICY(SET CMP0074 NEW) # Use ROOT variables when detecting packages diff --git a/vcpkg/ports/salome-configuration/portfile.cmake b/vcpkg/ports/salome-configuration/portfile.cmake new file mode 100644 index 0000000..ba9b417 --- /dev/null +++ b/vcpkg/ports/salome-configuration/portfile.cmake @@ -0,0 +1,26 @@ +string(REPLACE "." "_" UNDERSCORE_VERSION "${VERSION}")
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH_CONFIG
+ REPO SalomePlatform/configuration
+ REF "V${UNDERSCORE_VERSION}"
+ SHA512 e905a0f1e1105f5a630153036b80942032ccc07fad411d390e4da19d56561e224ac2ac681873b97d811d33ce4b0c9518ce3488b54414a42e011c39628d8e1673
+ HEAD_REF master
+ PATCHES
+ cmake-4.patch
+)
+
+file(COPY "${SOURCE_PATH_CONFIG}/" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
+
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH_CONFIG}/copyright/CEA_EDF.txt")
+
+file(WRITE "${CURRENT_PACKAGES_DIR}/share/${PORT}/vcpkg-port-config.cmake" [[set(SALOME_CONFIGURATION_ROOT_DIR "${CMAKE_CURRENT_LIST_DIR}")]])
+
+set(VCPKG_POLICY_EMPTY_PACKAGE enabled)
+
+file(READ "${CURRENT_PACKAGES_DIR}/share/${PORT}/cmake/SalomeMacros.cmake" contents)
+if(HDF5_WITH_PARALLEL)
+ string(PREPEND contents "set(SALOME_USE_MPI ON)\n")
+endif()
+string(REPLACE [[SET(CMAKE_PREFIX_PATH "${${_envvar}}")]] "" contents "${contents}")
+file(WRITE "${CURRENT_PACKAGES_DIR}/share/${PORT}/cmake/SalomeMacros.cmake" "${contents}")
diff --git a/vcpkg/ports/salome-configuration/vcpkg.json b/vcpkg/ports/salome-configuration/vcpkg.json new file mode 100644 index 0000000..393cc92 --- /dev/null +++ b/vcpkg/ports/salome-configuration/vcpkg.json @@ -0,0 +1,16 @@ +{ + "name": "salome-configuration", + "version": "9.10.0", + "port-version": 2, + "description": "Configuration files and other utilities for SALOME platform", + "homepage": "https://www.salome-platform.org", + "license": "LGPL-2.1-or-later", + "supports": "windows | linux", + "dependencies": [ + { + "$comment": "This is a dummy dependency to inject SALOME_USE_MPI depending on HDF5_WITH_PARALLEL", + "name": "hdf5", + "default-features": false + } + ] +} |