aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/libunwind
diff options
context:
space:
mode:
Diffstat (limited to 'vcpkg/ports/libunwind')
-rw-r--r--vcpkg/ports/libunwind/liblzma.diff30
-rw-r--r--vcpkg/ports/libunwind/portfile.cmake25
-rw-r--r--vcpkg/ports/libunwind/vcpkg.json11
3 files changed, 66 insertions, 0 deletions
diff --git a/vcpkg/ports/libunwind/liblzma.diff b/vcpkg/ports/libunwind/liblzma.diff
new file mode 100644
index 0000000..1dc8142
--- /dev/null
+++ b/vcpkg/ports/libunwind/liblzma.diff
@@ -0,0 +1,30 @@
+diff --git a/configure.ac b/configure.ac
+index 82caaa7..a17b7a1 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -443,9 +443,11 @@ AC_MSG_CHECKING([whether to support LZMA-compressed symbol tables])
+ AC_ARG_ENABLE(minidebuginfo,
+ AS_HELP_STRING([--enable-minidebuginfo], [Enables support for LZMA-compressed symbol tables]),, [enable_minidebuginfo=auto])
+ AC_MSG_RESULT([$enable_minidebuginfo])
++PKG_PROG_PKG_CONFIG
+ if test x$enable_minidebuginfo != xno; then
+- AC_CHECK_LIB([lzma], [lzma_mf_is_supported],
+- [LIBLZMA=-llzma
++ PKG_CHECK_MODULES([LZMA],[liblzma],
++ [LIBLZMA="$LZMA_LIBS"
++ CFLAGS="$CFLAGS $LZMA_CFLAGS"
+ AC_DEFINE([HAVE_LZMA], [1], [Define if you have liblzma])
+ enable_minidebuginfo=yes],
+ [if test x$enable_minidebuginfo = xyes; then
+diff --git a/src/unwind/libunwind.pc.in b/src/unwind/libunwind.pc.in
+index 9a65faf..bb351f7 100644
+--- a/src/unwind/libunwind.pc.in
++++ b/src/unwind/libunwind.pc.in
+@@ -7,5 +7,6 @@ Name: libunwind
+ Description: libunwind base library
+ Version: @VERSION@
+ Libs: -L${libdir} -lunwind
+-Libs.private: @LIBLZMA@ @LIBZ@
++Libs.private: @LIBZ@
++Requires.private: liblzma
+ Cflags: -I${includedir}
diff --git a/vcpkg/ports/libunwind/portfile.cmake b/vcpkg/ports/libunwind/portfile.cmake
new file mode 100644
index 0000000..4c3aa7b
--- /dev/null
+++ b/vcpkg/ports/libunwind/portfile.cmake
@@ -0,0 +1,25 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO "libunwind/libunwind"
+ REF "v${VERSION}"
+ HEAD_REF master
+ SHA512 0619716b2385375d618d84b1e9a75c42a7fa86d452c7c3168b4aa78c6bda629c8bb5e3a984a642277e9949c1b7dc39d5e21ae9d2670437182c7b797a14544cfa
+ PATCHES
+ liblzma.diff
+)
+
+vcpkg_find_acquire_program(PKGCONFIG)
+
+vcpkg_configure_make(
+ SOURCE_PATH "${SOURCE_PATH}"
+ AUTOCONFIG
+ OPTIONS
+ --disable-documentation
+ --disable-tests
+ --disable-zlibdebuginfo
+ --enable-minidebuginfo
+)
+vcpkg_install_make()
+vcpkg_fixup_pkgconfig()
+
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
diff --git a/vcpkg/ports/libunwind/vcpkg.json b/vcpkg/ports/libunwind/vcpkg.json
new file mode 100644
index 0000000..b8ee749
--- /dev/null
+++ b/vcpkg/ports/libunwind/vcpkg.json
@@ -0,0 +1,11 @@
+{
+ "name": "libunwind",
+ "version": "1.8.3",
+ "description": "Unix libray for portable stack unwinding",
+ "homepage": "https://www.nongnu.org/libunwind",
+ "license": "MIT",
+ "supports": "linux",
+ "dependencies": [
+ "liblzma"
+ ]
+}