aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/cblas
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/cblas
move to own git serverHEADmaster
Diffstat (limited to 'vcpkg/ports/cblas')
-rw-r--r--vcpkg/ports/cblas/cblas.pc.in8
-rw-r--r--vcpkg/ports/cblas/portfile.cmake24
-rw-r--r--vcpkg/ports/cblas/vcpkg.json24
3 files changed, 56 insertions, 0 deletions
diff --git a/vcpkg/ports/cblas/cblas.pc.in b/vcpkg/ports/cblas/cblas.pc.in
new file mode 100644
index 0000000..b73e7f6
--- /dev/null
+++ b/vcpkg/ports/cblas/cblas.pc.in
@@ -0,0 +1,8 @@
+prefix=${pcfiledir}/../..
+
+Name: CBLAS
+Description: Implementation of CBLAS
+Version:
+Requires: @requires@
+Libs: @libs@
+Cflags: @cflags@
diff --git a/vcpkg/ports/cblas/portfile.cmake b/vcpkg/ports/cblas/portfile.cmake
new file mode 100644
index 0000000..743b7f7
--- /dev/null
+++ b/vcpkg/ports/cblas/portfile.cmake
@@ -0,0 +1,24 @@
+SET(VCPKG_POLICY_EMPTY_PACKAGE enabled)
+
+# This block should be kept in sync with the port 'blas'
+if(VCPKG_TARGET_IS_OSX OR VCPKG_TARGET_IS_IOS)
+ # Use Apple's accelerate framework where available
+ set(BLA_VENDOR Apple)
+ set(requires "")
+ set(libs "-framework Accelerate")
+ set(cflags "-framework Accelerate")
+elseif(VCPKG_TARGET_IS_UWP
+ OR (VCPKG_TARGET_IS_WINDOWS AND VCPKG_TARGET_ARCHITECTURE MATCHES "arm")
+ OR NOT VCPKG_TARGET_IS_WINDOWS
+ OR NOT (VCPKG_LIBRARY_LINKAGE STREQUAL "static"))
+ set(BLA_VENDOR OpenBLAS)
+ set(requires openblas)
+else()
+ set(BLA_VENDOR Generic)
+ set(requires "cblas-reference")
+endif()
+
+configure_file("${CMAKE_CURRENT_LIST_DIR}/cblas.pc.in" "${CURRENT_PACKAGES_DIR}/lib/pkgconfig/cblas.pc" @ONLY)
+if(NOT VCPKG_BUILD_TYPE)
+ configure_file("${CMAKE_CURRENT_LIST_DIR}/cblas.pc.in" "${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/cblas.pc" @ONLY)
+endif()
diff --git a/vcpkg/ports/cblas/vcpkg.json b/vcpkg/ports/cblas/vcpkg.json
new file mode 100644
index 0000000..76d0078
--- /dev/null
+++ b/vcpkg/ports/cblas/vcpkg.json
@@ -0,0 +1,24 @@
+{
+ "$comment": "Keep the platform expressions in sync with the wrappers installed by the portfiles!",
+ "name": "cblas",
+ "version-date": "2024-03-19",
+ "description": "Metapackage for packages which provide CBLAS",
+ "license": null,
+ "dependencies": [
+ {
+ "name": "lapack-reference",
+ "features": [
+ "cblas"
+ ],
+ "platform": "!osx & !ios & !uwp & !(windows & arm) & windows & static"
+ },
+ {
+ "name": "openblas",
+ "platform": "!osx & !ios & (uwp | (windows & arm) | !windows | !static)"
+ },
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ }
+ ]
+}