diff --git a/Ports/AvailablePorts.md b/Ports/AvailablePorts.md index 5f5a0c2456..832f4fd46b 100644 --- a/Ports/AvailablePorts.md +++ b/Ports/AvailablePorts.md @@ -71,6 +71,7 @@ Please make sure to keep this list up to date when adding and updating ports. :^ | [`nesalizer`](nesalizer/) | Nesalizer | | https://github.com/SerenityOS/nesalizer | | [`ninja`](ninja/) | Ninja | 1.8.2 | https://ninja-build.org/ | | [`npth`](npth/) | New GNU Portable Threads Library | 1.6 | https://gnupg.org/software/npth/index.html | +| [`ntbtls`](ntbtls/) | The Not Too Bad TLS Library | 0.2.0 | https://gnupg.org/software/ntbtls/index.html | | [`nyancat`](nyancat/) | Nyancat | | https://github.com/klange/nyancat | | [`openssh`](openssh/) | OpenSSH | 8.3-9ca7e9c | https://github.com/openssh/openssh-portable | | [`openssl`](openssl/) | OpenSSL | 1.0.2 | https://www.openssl.org/ | diff --git a/Ports/ntbtls/package.sh b/Ports/ntbtls/package.sh new file mode 100755 index 0000000000..833cd1d346 --- /dev/null +++ b/Ports/ntbtls/package.sh @@ -0,0 +1,14 @@ +#!/usr/bin/env -S bash ../.port_include.sh +port=ntbtls +version=0.2.0 +useconfigure=true +#configopts="--with-libgpg-error-prefix=${SERENITY_BUILD_DIR}/Root/usr/local" +files="https://gnupg.org/ftp/gcrypt/ntbtls/ntbtls-${version}.tar.bz2 ntbtls-${version}.tar.bz2" + +pre_configure() { + export ntbtls_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/ntbtls/patches/configure.patch b/Ports/ntbtls/patches/configure.patch new file mode 100644 index 0000000000..aa2b619c82 --- /dev/null +++ b/Ports/ntbtls/patches/configure.patch @@ -0,0 +1,12 @@ +diff -Naur ntbtls-0.2.0/build-aux/config.sub ntbtls-0.2.0.serenity/build-aux/config.sub +--- ntbtls-0.2.0/build-aux/config.sub 2016-07-13 19:10:49.000000000 +0200 ++++ ntbtls-0.2.0.serenity/build-aux/config.sub 2021-04-14 02:52:34.178672014 +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* \