diff options
author | Tim Schumacher <timschumi@gmx.de> | 2021-11-10 02:07:36 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-11-10 14:48:39 +0100 |
commit | 26a48f3516f4d26c81d3cf10c5c3dfe5a39528b1 (patch) | |
tree | 9202a7a615cddad59ceb13ef8d2ea9be69d347fe | |
parent | bd6c48f6ea5652be5087d9d879a45eb36b3a9a7d (diff) | |
download | serenity-26a48f3516f4d26c81d3cf10c5c3dfe5a39528b1.zip |
Ports: Use GNU patch instead of the OpenBSD version
The OpenBSD version is having some weird issues, so:
Reject OpenBSD, return to GNU.
-rw-r--r-- | Ports/AvailablePorts.md | 2 | ||||
-rwxr-xr-x | Ports/patch/package.sh | 6 | ||||
-rw-r--r-- | Ports/patch/patches/fix-config-sub.patch | 12 | ||||
-rw-r--r-- | Ports/patch/patches/remove-oversized-dirfd-cache.patch | 14 |
4 files changed, 30 insertions, 4 deletions
diff --git a/Ports/AvailablePorts.md b/Ports/AvailablePorts.md index 2d9de5f53b..c1effa8d1b 100644 --- a/Ports/AvailablePorts.md +++ b/Ports/AvailablePorts.md @@ -130,7 +130,7 @@ Please make sure to keep this list up to date when adding and updating ports. :^ | [`opentyrian-data`](opentyrian-data/) | OpenTyrian graphics and audio | 1.0.0 | https://camanis.net/tyrian/tyrian21.zip | | [`oksh`](oksh/) | oksh | 7.0 | https://github.com/ibara/oksh | | [`p7zip`](p7zip/) | p7zip | 17.04 | https://github.com/jinfeihan57/p7zip | -| [`patch`](patch/) | patch (OpenBSD) | 6.6 | https://github.com/ibara/libpuffy | +| [`patch`](patch/) | patch (GNU) | 2.7.6 | https://savannah.gnu.org/projects/patch/ | | [`pcre`](pcre/) | Perl-compatible Regular Expressions (PCRE) | 8.45 | https://www.pcre.org/ | | [`pcre2`](pcre2/) | Perl-compatible Regular Expressions (PCRE2) | 10.39 | https://www.pcre.org/ | | [`php`](php/) | PHP | 8.0.10 | https://www.php.net/ | diff --git a/Ports/patch/package.sh b/Ports/patch/package.sh index dc6ca91d15..a4964759ff 100755 --- a/Ports/patch/package.sh +++ b/Ports/patch/package.sh @@ -1,6 +1,6 @@ #!/usr/bin/env -S bash ../.port_include.sh port=patch -version=6.6 -files="https://github.com/ibara/libpuffy/releases/download/libpuffy-1.0/patch-${version}.tar.gz patch-${version}.tar.gz b82ba726d9bdb683534839673f0c845d4f97c8d08490fa53dbef502665fee637" +version=2.7.6 +useconfigure=true +files="https://ftp.gnu.org/gnu/patch/patch-${version}.tar.gz patch-${version}.tar.gz 8cf86e00ad3aaa6d26aca30640e86b0e3e1f395ed99f189b06d4c9f74bc58a4e" auth_type=sha256 -depends=("libpuffy") diff --git a/Ports/patch/patches/fix-config-sub.patch b/Ports/patch/patches/fix-config-sub.patch new file mode 100644 index 0000000000..bbea4431a7 --- /dev/null +++ b/Ports/patch/patches/fix-config-sub.patch @@ -0,0 +1,12 @@ +diff -ur a/build-aux/config.sub b/build-aux/config.sub +--- a/build-aux/config.sub 2018-02-03 13:41:53.000000000 +0100 ++++ b/build-aux/config.sub 2021-11-10 01:22:51.034188104 +0100 +@@ -1363,7 +1363,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* | -serenity* | -irix* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* | -plan9* \ diff --git a/Ports/patch/patches/remove-oversized-dirfd-cache.patch b/Ports/patch/patches/remove-oversized-dirfd-cache.patch new file mode 100644 index 0000000000..2789bbede0 --- /dev/null +++ b/Ports/patch/patches/remove-oversized-dirfd-cache.patch @@ -0,0 +1,14 @@ +diff -ur a/src/safe.c b/src/safe.c +--- a/src/safe.c 2018-02-03 13:41:49.000000000 +0100 ++++ b/src/safe.c 2021-11-10 02:05:04.152449983 +0100 +@@ -98,9 +98,7 @@ + { + struct rlimit nofile; + +- max_cached_fds = 8; +- if (getrlimit (RLIMIT_NOFILE, &nofile) == 0) +- max_cached_fds = MAX (nofile.rlim_cur / 4, max_cached_fds); ++ max_cached_fds = 64; + + cached_dirfds = hash_initialize (max_cached_fds, + NULL, |