diff --git a/Ports/AvailablePorts.md b/Ports/AvailablePorts.md index bb00941d270..030f4ae1578 100644 --- a/Ports/AvailablePorts.md +++ b/Ports/AvailablePorts.md @@ -45,6 +45,7 @@ Please make sure to keep this list up to date when adding and updating ports. :^ | [`libexpat`](libexpat/) | Expat | 2.2.9 | https://libexpat.github.io/ | | [`libffi`](libffi/) | libffi | 3.3 | https://www.sourceware.org/libffi/ | | [`libiconv`](libiconv/) | GNU libiconv | 1.16 | https://www.gnu.org/software/libiconv/ | +| [`libksba`](libksba/) | libksba | 1.5.1 | https://gnupg.org/software/libksba/index.html | | [`libjpeg`](libjpeg/) | libjpeg | 9d | https://ijg.org/ | | [`libogg`](libogg/) | libogg | 1.3.4 | https://github.com/xiph/ogg | | [`libpng`](libpng/) | libpng | 1.6.37 | https://libpng.org/ | diff --git a/Ports/libksba/package.sh b/Ports/libksba/package.sh new file mode 100755 index 00000000000..9bce730e6ab --- /dev/null +++ b/Ports/libksba/package.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env -S bash ../.port_include.sh +port=libksba +version=1.5.1 +useconfigure=true +files="https://gnupg.org/ftp/gcrypt/libksba/libksba-${version}.tar.bz2 libksba-${version}.tar.bz2" + +pre_configure() { + export ksba_cv_gcc_has_f_visibility=no +} + +configure() { + run ./configure --host="${SERENITY_ARCH}-pc-serenity" --build="$($workdir/build-aux/config.guess)" $configopts +} diff --git a/Ports/libksba/patches/configure.patch b/Ports/libksba/patches/configure.patch new file mode 100644 index 00000000000..0dc619f7a88 --- /dev/null +++ b/Ports/libksba/patches/configure.patch @@ -0,0 +1,12 @@ +diff -Naur libksba-1.5.1/build-aux/config.sub libksba-1.5.1.serenity/build-aux/config.sub +--- libksba-1.5.1/build-aux/config.sub 2016-08-22 10:40:58.000000000 +0200 ++++ libksba-1.5.1.serenity/build-aux/config.sub 2021-04-14 02:31:15.924387614 +0200 +@@ -1381,7 +1381,7 @@ + # The portable systems comes first. + # Each alternative MUST END IN A *, to match a version number. + # -sysv* is not here because it comes later, after sysvr4. +- -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ ++ -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* | -serenity* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* | -plan9* \