Skip to content

Commit

Permalink
Ports: Update bash to 5.1.8
Browse files Browse the repository at this point in the history
Also switches to using a sha256 signature check.
  • Loading branch information
Lubrsi authored and linusg committed Jul 29, 2021
1 parent e3b588a commit 9994480
Show file tree
Hide file tree
Showing 9 changed files with 58 additions and 60 deletions.
2 changes: 1 addition & 1 deletion Ports/AvailablePorts.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Please make sure to keep this list up to date when adding and updating ports. :^
| Port | Name | Version | Website |
|----------------------------------------|-----------------------------------------------------------------|--------------------------|--------------------------------------------------------------------------------|
| [`Another-World`](Another-World/) | Another World Bytecode Interpreter | | https://github.com/fabiensanglard/Another-World-Bytecode-Interpreter |
| [`bash`](bash/) | GNU Bash | 5.0 | https://www.gnu.org/software/bash/ |
| [`bash`](bash/) | GNU Bash | 5.1.8 | https://www.gnu.org/software/bash/ |
| [`bass`](bass/) | Beneath a Steel Sky | cd-1.2 | https://www.scummvm.org/games |
| [`bc`](bc/) | bc | 2.5.1 | https://github.com/gavinhoward/bc |
| [`binutils`](binutils/) | GNU Binutils | 2.37 | https://www.gnu.org/software/binutils/ |
Expand Down
9 changes: 3 additions & 6 deletions Ports/bash/package.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
#!/usr/bin/env -S bash ../.port_include.sh
port=bash
version=5.0
version=5.1.8
useconfigure=true
configopts="--disable-nls --without-bash-malloc"
files="https://ftpmirror.gnu.org/gnu/bash/bash-${version}.tar.gz bash-${version}.tar.gz
https://ftpmirror.gnu.org/gnu/bash/bash-${version}.tar.gz.sig bash-${version}.tar.gz.sig
https://ftpmirror.gnu.org/gnu/gnu-keyring.gpg gnu-keyring.gpg"
auth_type="sig"
auth_opts="--keyring ./gnu-keyring.gpg bash-${version}.tar.gz.sig"
files="https://ftpmirror.gnu.org/gnu/bash/bash-${version}.tar.gz bash-${version}.tar.gz 0cfb5c9bb1a29f800a97bd242d19511c997a1013815b805e0fdd32214113d6be"
auth_type="sha256"

build() {
run_replace_in_file "s/define GETCWD_BROKEN 1/undef GETCWD_BROKEN/" config.h
Expand Down
10 changes: 10 additions & 0 deletions Ports/bash/patches/config.sub.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
--- bash-5.1.8/support/config.sub 2020-11-18 19:40:12.000000000 +0000
+++ bash-5.1.8.serenity/support/config.sub 2021-07-29 15:33:03.347306019 +0100
@@ -1691,6 +1691,7 @@
# The portable systems comes first.
# Each alternative MUST end in a * to match a version number.
gnu* | android* | bsd* | mach* | minix* | genix* | ultrix* | irix* \
+ | serenity* \
| *vms* | esix* | aix* | cnk* | sunos | sunos[34]* \
| hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \
| sym* | plan9* | psp* | sim* | xray* | os68k* | v88r* \
13 changes: 0 additions & 13 deletions Ports/bash/patches/configure-system.patch

This file was deleted.

29 changes: 23 additions & 6 deletions Ports/bash/patches/disable-locale.patch
Original file line number Diff line number Diff line change
@@ -1,18 +1,35 @@
diff -Nru pristine/bash-5.0/locale.c bash-5.0/locale.c
+++ bash-5.0/locale.c 2019-05-21 02:18:05.843104487 +0200
--- bash-5.1.8/locale.c 2020-02-24 20:08:43.000000000 +0000
+++ bash-5.1.8.serenity/locale.c 2021-07-29 15:51:14.523146438 +0100
@@ -76,6 +76,7 @@
void
set_default_locale ()
{
+ return;
+ return;
#if defined (HAVE_SETLOCALE)
default_locale = setlocale (LC_ALL, "");
if (default_locale)
@@ -95,6 +96,7 @@
@@ -88,11 +89,11 @@

locale_mb_cur_max = MB_CUR_MAX;
locale_utf8locale = locale_isutf8 (default_locale);
-#if defined (HANDLE_MULTIBYTE)
- locale_shiftstates = mblen ((char *)NULL, 0);
-#else
- local_shiftstates = 0;
-#endif
+// #if defined (HANDLE_MULTIBYTE)
+// locale_shiftstates = mblen ((char *)NULL, 0);
+// #else
+// local_shiftstates = 0;
+// #endif
}

/* Set default values for LC_CTYPE, LC_COLLATE, LC_MESSAGES, LC_NUMERIC and
@@ -101,6 +102,7 @@
void
set_default_locale_vars ()
{
+ return;
+ return;
char *val;

#if defined (HAVE_SETLOCALE)
#if defined (HAVE_SETLOCALE)
13 changes: 0 additions & 13 deletions Ports/bash/patches/include-stdio.patch

This file was deleted.

10 changes: 10 additions & 0 deletions Ports/bash/patches/include-sys-select.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
--- bash-5.1.8.serenity/examples/loadables/accept.c 2020-03-18 12:58:36.000000000 +0000
+++ bash-5.1.8/examples/loadables/accept.c 2021-07-29 17:11:26.258287156 +0100
@@ -35,6 +35,7 @@
#include <sys/socket.h>
#include <arpa/inet.h>
#include <netinet/in.h>
+#include <sys/select.h>

#include "loadables.h"

11 changes: 11 additions & 0 deletions Ports/bash/patches/remove-conflicting-declaration-in-glob.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- bash-5.1.8.serenity/lib/glob/glob.c 2020-10-30 18:49:00.000000000 +0000
+++ bash-5.1.8/lib/glob/glob.c 2021-07-29 17:11:22.146328629 +0100
@@ -122,7 +122,7 @@
#else
# define dequote_pathname udequote_pathname
#endif
-static void dequote_pathname PARAMS((char *));
+//static void dequote_pathname PARAMS((char *));
static int glob_testdir PARAMS((char *, int));
static char **glob_dir_to_array PARAMS((char *, char **, int));

21 changes: 0 additions & 21 deletions Ports/bash/patches/remove-duplicate-declarations.patch

This file was deleted.

0 comments on commit 9994480

Please sign in to comment.