Re: wget on i686 in core-updates

2023-04-17 Thread Andreas Enge
Am Sun, Apr 16, 2023 at 08:57:48PM +0200 schrieb Andreas Enge:
> As a stop-gap measure, I suggest to use a self-hosted tarball as in the
> attached commit. I have good hope that we will soon see a 1.23.4 release,
> see https://lists.gnu.org/archive/html/bug-wget/2023-04/msg2.html .

I just pushed the commit. There should be a new wget release this week:
https://lists.gnu.org/archive/html/bug-wget/2023-04/msg5.html
and then we can push the update. Having wget will enable us to see where
more work is needed on i686.

Andreas




Re: wget on i686 in core-updates

2023-04-16 Thread Andreas Enge
Am Sun, Apr 16, 2023 at 04:00:15PM +0200 schrieb Andreas Enge:
> HEAD of git solves the problem, I will try to propose a solution later.

Due to gnulib handled as a submodule, this turned out to be quite tricky
(for details, see the IRC logs with my discussion with jlicht).
The solution is to create a tarball after checking out the gnulib
submodule corresponding to the latest wget git commit and after running
./bootstrap.

As a stop-gap measure, I suggest to use a self-hosted tarball as in the
attached commit. I have good hope that we will soon see a 1.23.4 release,
see https://lists.gnu.org/archive/html/bug-wget/2023-04/msg2.html .

What do you think?

Andreas

>From 424ee72ffbdf9a79eee4dd4aac43404167e66083 Mon Sep 17 00:00:00 2001
From: Andreas Enge 
Date: Sun, 16 Apr 2023 20:52:35 +0200
Subject: [PATCH] gnu: wget: Update to 1.21.3.24.

This update to a non-release version fixes a build failure on i686-linux.

* gnu/packages/wget.scm (wget): Update to 1.21.3.24.
[origin]: Use a self-hosted tarball created from the latest git commit.
---
 gnu/packages/wget.scm | 9 +
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/wget.scm b/gnu/packages/wget.scm
index 083cf27212..17459344c0 100644
--- a/gnu/packages/wget.scm
+++ b/gnu/packages/wget.scm
@@ -46,15 +46,16 @@ (define-module (gnu packages wget)
 (define-public wget
   (package
 (name "wget")
-(version "1.21.3")
+(version "1.21.3.24")
 (source
  (origin
   (method url-fetch)
-  (uri (string-append "mirror://gnu/wget/wget-"
-  version ".tar.lz"))
+  ;;(uri (string-append "mirror://gnu/wget/wget-"
+  ;;version ".tar.lz"))
+  (uri "https://www.multiprecision.org/wget-1.21.3.24-2b723.tar.lz;)
   (sha256
(base32
-"19afmyr1i3zwdwr8wkyz8q6z5764ik3dm87as194g78l8xggplnv"
+"17ip94mvax83h0gh4905jqc64g5qf3vgxr3bj9gn02pijjm5lzbp"
 (build-system gnu-build-system)
 (inputs
  (list gnutls libidn2 libpsl))
-- 
2.39.2



Re: wget on i686 in core-updates

2023-04-15 Thread Andreas Enge
Hello,

Am Sat, Apr 15, 2023 at 06:25:52PM + schrieb Kaelyn:
> I tried to update the package definition to be able to build from git but it 
> became a much bigger rabbit hole than I have the energy for at the moment. I 
> also tried to cherry-pick the commit from the merge request without luck.

I just downloaded the commit, which is in uniform diff format and can serve
as a patch to be applied to the tarball. The result is attached, but it
does not work: The tests fail as before with the "file not found" messages.

But thanks for digging through the wget issues!

Andreas

>From 0991a0daf74c0a3754618f99b7a7cb812debfa1a Mon Sep 17 00:00:00 2001
From: Andreas Enge 
Date: Sat, 15 Apr 2023 22:52:39 +0200
Subject: [PATCH] gnu: wget: Add patch needed for i686.

* gnu/packages/patches/wget-hsts-portability.patch: New file.
* gnu/local.mk (dist_patch_DATA): Register patch.
* gnu/packages/wget.scm (wget)[origin]: Apply patch.
---
 gnu/local.mk  |   1 +
 .../patches/wget-hsts-portability.patch   | 223 ++
 gnu/packages/wget.scm |   4 +-
 3 files changed, 227 insertions(+), 1 deletion(-)
 create mode 100644 gnu/packages/patches/wget-hsts-portability.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 73756a8c49..8dd0c45cea 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -2021,6 +2021,7 @@ dist_patch_DATA = 
\
   %D%/packages/patches/webrtc-audio-processing-big-endian.patch\
   %D%/packages/patches/webrtc-for-telegram-desktop-fix-gcc12-cstdint.patch   \
   %D%/packages/patches/websocketpp-fix-for-cmake-3.15.patch\
+  %D%/packages/patches/wget-hsts-portability.patch  \
   %D%/packages/patches/wmctrl-64-fix.patch \
   %D%/packages/patches/wmfire-update-for-new-gdk-versions.patch\
   %D%/packages/patches/wordnet-CVE-2008-2149.patch \
diff --git a/gnu/packages/patches/wget-hsts-portability.patch 
b/gnu/packages/patches/wget-hsts-portability.patch
new file mode 100644
index 00..62dabd7fae
--- /dev/null
+++ b/gnu/packages/patches/wget-hsts-portability.patch
@@ -0,0 +1,223 @@
+From 9a3479a23c15cd7234a54296ae50c48f29c427ec Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Tim=20R=C3=BChsen?= 
+Date: Sun, 20 Mar 2022 12:18:20 +0100
+Subject: [PATCH] Fix HSTS portability by using int64_t instead of time_t.
+
+* src/hsts.c: Use int64_t instead of time_t.
+* src/http.c: Use int64_t for parsing Strict-Transport-Security.
+---
+ src/hsts.c | 41 -
+ src/hsts.h |  2 +-
+ src/http.c | 24 
+ 3 files changed, 33 insertions(+), 34 deletions(-)
+
+diff --git a/src/hsts.c b/src/hsts.c
+index 0a014401..72c5e936 100644
+--- a/src/hsts.c
 b/src/hsts.c
+@@ -61,8 +61,8 @@ struct hsts_kh {
+ };
+ 
+ struct hsts_kh_info {
+-  time_t created;
+-  time_t max_age;
++  int64_t created;
++  int64_t max_age;
+   bool include_subdomains;
+ };
+ 
+@@ -166,7 +166,7 @@ end:
+ static bool
+ hsts_new_entry_internal (hsts_store_t store,
+  const char *host, int port,
+- time_t created, time_t max_age,
++ int64_t created, int64_t max_age,
+  bool include_subdomains,
+  bool check_validity,
+  bool check_expired,
+@@ -216,21 +216,21 @@ bail:
+ static bool
+ hsts_add_entry (hsts_store_t store,
+ const char *host, int port,
+-time_t max_age, bool include_subdomains)
++int64_t max_age, bool include_subdomains)
+ {
+-  time_t t = time (NULL);
++  int64_t t = (int64_t) time (NULL);
+ 
+   /* It might happen time() returned -1 */
+-  return (t == (time_t)(-1) ?
++  return (t == -1) ?
+   false :
+-  hsts_new_entry_internal (store, host, port, t, max_age, 
include_subdomains, false, true, false));
++  hsts_new_entry_internal (store, host, port, t, max_age, 
include_subdomains, false, true, false);
+ }
+ 
+ /* Creates a new entry, unless an identical one already exists. */
+ static bool
+ hsts_new_entry (hsts_store_t store,
+ const char *host, int port,
+-time_t created, time_t max_age,
++int64_t created, int64_t max_age,
+ bool include_subdomains)
+ {
+   return hsts_new_entry_internal (store, host, port, created, max_age, 
include_subdomains, true, true, true);
+@@ -245,7 +245,7 @@ hsts_remove_entry (hsts_store_t store, struct hsts_kh *kh)
+ static bool
+ hsts_store_merge (hsts_store_t store,
+   const char *host, int port,
+-  time_t created, time_t max_age,
++  int64_t created, int64_t max_age,
+   bool include_subdomains)
+ {
+   enum hsts_kh_match match_type = NO_MATCH;
+@@ -276,11 +276,11 @@ hsts_read_database (hsts_store_t store, FILE *fp, bool 
merge_with_existing_entri
+