From eaf7dbacede52be55329077c58ee7a8df14c39fb Mon Sep 17 00:00:00 2001 From: Beckett Normington Date: Fri, 25 Aug 2023 12:27:11 -0400 Subject: [PATCH] Ports/perl5: Remove unnecessary drand48 patch With `drand48` now in LibC, this patch is not needed. --- ...-Hardcode-random-in-place-of-drand48.patch | 56 ------------------- ...001-pp_sys-Avoid-redefining-h_errno.patch} | 0 ...n-lib-unicore-mktables-with-maketes.patch} | 0 ...eep.patch => 0003-Disable-nanosleep.patch} | 0 ...004-configure-Add-hint-for-serenity.patch} | 0 Ports/perl5/patches/ReadMe.md | 13 ++--- 6 files changed, 4 insertions(+), 65 deletions(-) delete mode 100644 Ports/perl5/patches/0001-configure-Hardcode-random-in-place-of-drand48.patch rename Ports/perl5/patches/{0002-pp_sys-Avoid-redefining-h_errno.patch => 0001-pp_sys-Avoid-redefining-h_errno.patch} (100%) rename Ports/perl5/patches/{0003-Makefile-Don-t-run-lib-unicore-mktables-with-maketes.patch => 0002-Makefile-Don-t-run-lib-unicore-mktables-with-maketes.patch} (100%) rename Ports/perl5/patches/{0004-Disable-nanosleep.patch => 0003-Disable-nanosleep.patch} (100%) rename Ports/perl5/patches/{0005-configure-Add-hint-for-serenity.patch => 0004-configure-Add-hint-for-serenity.patch} (100%) diff --git a/Ports/perl5/patches/0001-configure-Hardcode-random-in-place-of-drand48.patch b/Ports/perl5/patches/0001-configure-Hardcode-random-in-place-of-drand48.patch deleted file mode 100644 index 4252a222ac..0000000000 --- a/Ports/perl5/patches/0001-configure-Hardcode-random-in-place-of-drand48.patch +++ /dev/null @@ -1,56 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: Beckett Normington -Date: Tue, 25 Jul 2023 16:59:20 -0400 -Subject: [PATCH] configure: Hardcode `random()` in place of `drand48()` - ---- - cnf/configure_func.sh | 2 +- - cnf/configure_func_sel.sh | 8 +------- - cnf/configure_misc.sh | 2 +- - 3 files changed, 3 insertions(+), 9 deletions(-) - -diff --git a/cnf/configure_func.sh b/cnf/configure_func.sh -index 45e11341c0c3cc3563328e06aaafc0b7a50135b4..af7691a848e89b3d18a7dd531f9decf8915e485e 100644 ---- a/cnf/configure_func.sh -+++ b/cnf/configure_func.sh -@@ -54,7 +54,7 @@ checkfunc d_dirfd 'dirfd' "NULL" 'dirent.h sys/types.h' - checkfunc d_dladdr 'dladdr' 'NULL, NULL' 'dlfcn.h' - checkfunc d_dlerror 'dlerror' "" 'dlfcn.h' - checkfunc d_dlopen 'dlopen' "NULL,0" "dlfcn.h" --checkfunc d_drand48 'drand48' "" 'stdlib.h' -+# checkfunc d_drand48 'drand48' "" 'stdlib.h' - checkfunc d_dup2 'dup2' "0,0" 'unistd.h' - checkfunc d_dup3 'dup3' "0,0,0" 'fcntl.h unistd.h' - checkfunc d_duplocale 'duplocale' '0' 'locale.h' -diff --git a/cnf/configure_func_sel.sh b/cnf/configure_func_sel.sh -index 90d350d5451907ba219ad9c817d6ffb25a2178aa..37d433609dbd0289cd1591a60ba60c05ae275084 100644 ---- a/cnf/configure_func_sel.sh -+++ b/cnf/configure_func_sel.sh -@@ -53,13 +53,7 @@ fi - - mstart "Looking for a random number function" - log "d_drand=$d_drand48 d_random=$d_random d_rand=$d_rand" --if [ "$d_drand48" = 'define' ]; then -- define randfunc 'drand48' -- define seedfunc 'srand48' -- define randbits 48 -- define randseedtype 'long' -- result 'good, found drand48()' --elif [ "$d_random" = 'define' ]; then -+if [ "$d_random" = 'define' ]; then - define randfunc 'random' - define seedfunc 'srandom' - define randbits 31 -diff --git a/cnf/configure_misc.sh b/cnf/configure_misc.sh -index c5dca506ea72fa3693a2d825c0cceb287b26abd8..b2ba57282f7dcc6ea2e889704699ee399bf6a6d5 100644 ---- a/cnf/configure_misc.sh -+++ b/cnf/configure_misc.sh -@@ -108,7 +108,7 @@ define spitshell 'cat' - define d_Gconvert 'sprintf((b),"%.*g",(n),(x))' - define d_modfl_pow32_bug 'undef' - define direntrytype 'struct dirent' --define drand01 'drand48()' -+define drand01 'random()' - define fflushNULL 'define' - define fflushall 'undef' - define freetype 'void' diff --git a/Ports/perl5/patches/0002-pp_sys-Avoid-redefining-h_errno.patch b/Ports/perl5/patches/0001-pp_sys-Avoid-redefining-h_errno.patch similarity index 100% rename from Ports/perl5/patches/0002-pp_sys-Avoid-redefining-h_errno.patch rename to Ports/perl5/patches/0001-pp_sys-Avoid-redefining-h_errno.patch diff --git a/Ports/perl5/patches/0003-Makefile-Don-t-run-lib-unicore-mktables-with-maketes.patch b/Ports/perl5/patches/0002-Makefile-Don-t-run-lib-unicore-mktables-with-maketes.patch similarity index 100% rename from Ports/perl5/patches/0003-Makefile-Don-t-run-lib-unicore-mktables-with-maketes.patch rename to Ports/perl5/patches/0002-Makefile-Don-t-run-lib-unicore-mktables-with-maketes.patch diff --git a/Ports/perl5/patches/0004-Disable-nanosleep.patch b/Ports/perl5/patches/0003-Disable-nanosleep.patch similarity index 100% rename from Ports/perl5/patches/0004-Disable-nanosleep.patch rename to Ports/perl5/patches/0003-Disable-nanosleep.patch diff --git a/Ports/perl5/patches/0005-configure-Add-hint-for-serenity.patch b/Ports/perl5/patches/0004-configure-Add-hint-for-serenity.patch similarity index 100% rename from Ports/perl5/patches/0005-configure-Add-hint-for-serenity.patch rename to Ports/perl5/patches/0004-configure-Add-hint-for-serenity.patch diff --git a/Ports/perl5/patches/ReadMe.md b/Ports/perl5/patches/ReadMe.md index 21494ea2c8..a1912b635e 100755 --- a/Ports/perl5/patches/ReadMe.md +++ b/Ports/perl5/patches/ReadMe.md @@ -1,28 +1,23 @@ # Patches for perl5 on SerenityOS -## `0001-configure-Hardcode-random-in-place-of-drand48.patch` - -configure: Hardcode `random()` in place of `drand48()` - - -## `0002-pp_sys-Avoid-redefining-h_errno.patch` +## `0001-pp_sys-Avoid-redefining-h_errno.patch` pp_sys: Avoid redefining `h_errno` -## `0003-Makefile-Don-t-run-lib-unicore-mktables-with-maketes.patch` +## `0002-Makefile-Don-t-run-lib-unicore-mktables-with-maketes.patch` Makefile: Don't run `lib/unicore/mktables` with -maketest This argument causes the interpreter to hang and consume huge amounts of RAM. -## `0004-Disable-nanosleep.patch` +## `0003-Disable-nanosleep.patch` Disable nanosleep -## `0005-configure-Add-hint-for-serenity.patch` +## `0004-configure-Add-hint-for-serenity.patch` configure: Add hint for `serenity`