Skip to content

Commit

Permalink
Fixed pkgconfig files (mostly on Windows) (#37)
Browse files Browse the repository at this point in the history
automerged PR by conda-forge/automerge-action
  • Loading branch information
github-actions[bot] authored Sep 2, 2023
2 parents 4a2909e + 9930a8d commit e8eff43
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
23 changes: 23 additions & 0 deletions recipe/fix-zstd-pkgconfig.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
From c719428916b4d19e838f873b1a177b126a080d61 Mon Sep 17 00:00:00 2001
From: Thomas Klausner <[email protected]>
Date: Thu, 24 Aug 2023 14:07:50 +0200
Subject: [PATCH] Check for zstd_TARGET before using it in a regex.

Closes #404.
---
CMakeLists.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index b2e77241..b7bb7e3f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -349,7 +349,7 @@ endforeach()
STRING(CONCAT zlib_link_name "-l" ${ZLIB_LINK_LIBRARY_NAME})
string(REGEX REPLACE "-lBZip2::BZip2" "-lbz2" LIBS ${LIBS})
string(REGEX REPLACE "-lLibLZMA::LibLZMA" "-llzma" LIBS ${LIBS})
-if(ENABLE_ZSTD)
+if(zstd_TARGET)
string(REGEX REPLACE "-l${zstd_TARGET}" "-lzstd" LIBS ${LIBS})
endif()
string(REGEX REPLACE "-lOpenSSL::Crypto" "-lssl -lcrypto" LIBS ${LIBS})
3 changes: 2 additions & 1 deletion recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@ source:
sha256: {{ sha256 }}
patches:
- fix-bz2-pkgconfig-win.patch # [win]
- fix-zstd-pkgconfig.patch

build:
number: 0
number: 1
run_exports:
- {{ pin_subpackage(name, max_pin='x') }}

Expand Down

0 comments on commit e8eff43

Please sign in to comment.