Monday, 8 December 2025

[netsurf-dev] Re: toolchains: branch jmb/sdk-update updated. a5187886ae92325c9859ac5efaefae0d851137b4

Hey John-Mark

In relation to the below, I was trying to update this to a newer GCC - you can see my attempt in chris/m68k-gcc15. Ultimately I gave up as it kept complaining about not being able to create binaries. In theory this compiler does work outside the NetSurf toolchain, but I'm not familiar enough with the workings of GCC to figure out what's wrong here.

There might be some of my NDK 3.2 updates on that branch which will need reverting. I'm holding off moving to that until after the next NetSurf release, as it's going to break 3.5/3.9 compatibility.

Chris


8 Dec 2025 01:19:41 NetSurf Browser Project <dmarc-noreply@freelists.org>:

Gitweb links:

...log http://git.netsurf-browser.org/toolchains.git/shortlog/a5187886ae92325c9859ac5efaefae0d851137b4
...commit http://git.netsurf-browser.org/toolchains.git/commit/a5187886ae92325c9859ac5efaefae0d851137b4
...tree http://git.netsurf-browser.org/toolchains.git/tree/a5187886ae92325c9859ac5efaefae0d851137b4

The branch, jmb/sdk-update has been updated
       via  a5187886ae92325c9859ac5efaefae0d851137b4 (commit)
       via  0ed58efcbe99982c34cd31623fbd3c49499b998d (commit)
       via  6cfb90abc9798bf4c6b29a30b0f58291cfaaf1b9 (commit)
       via  7e09c0d16f371bd95d982243a75612a855e83fb3 (commit)
       via  841d3230a29004935514443aa831f24e594ca57c (commit)
       via  2bffa4dc4e5bcc57e1fd996567dee292b40a1889 (commit)
      from  78390cc946b54c1e4b79fb0d6ff12638f1b3de40 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commitdiff http://git.netsurf-browser.org/toolchains.git/commit/?id=a5187886ae92325c9859ac5efaefae0d851137b4
commit a5187886ae92325c9859ac5efaefae0d851137b4
Author: John-Mark Bell <jmb@netsurf-browser.org>
Commit: John-Mark Bell <jmb@netsurf-browser.org>

    m68k-unknown-amigaos: disable fatal warnings in GCC14
   
    The sources being built here are ancient and give GCC14 a large
    amount of (reasonable) indigestion. It is intractable to patch
    these, so simply stop the fatal ones being fatal. Trying to build
    GCC 3.4.6 (or binutils 2.14) from source with any modern compiler
    is increasingly unlikely to work without copious warnings, at
    minimum.
   
    Thus, this entire toolchain is in need of updating to something
    more modern (if, indeed, such a thing exists).

diff --git a/m68k-unknown-amigaos/Makefile b/m68k-unknown-amigaos/Makefile
index c232f2b..437c309 100644
--- a/m68k-unknown-amigaos/Makefile
+++ b/m68k-unknown-amigaos/Makefile
@@ -154,7 +154,7 @@ $(BUILDSTEPS)/ndk.d: $(SOURCESDIR)/$(UPSTREAM_NDK_TARBALL) $(SOURCESDIR)/$(UPSTR
###

$(BUILDSTEPS)/bootstrap-compiler.d: $(BUILDSTEPS)/bison.d $(BUILDSTEPS)/srcdir-step3.d $(BUILDSTEPS)/binutils.d
-   cd $(BUILDDIR) && $(GCC_ENV_PARAMS) $(GCC_SRCDIR)/configure \
+   cd $(BUILDDIR) && $(GCC_ENV_PARAMS) CFLAGS="-Wno-implicit-int -Wno-implicit-function-declaration -Wno-incompatible-pointer-types" $(GCC_SRCDIR)/configure \
                --prefix=$(PREFIX) \
                --target=$(TARGET_NAME) \
                --disable-threads \
@@ -223,7 +223,7 @@ $(BUILDSTEPS)/$(UPSTREAM_BISON_TARBALL).d: $(BUILDSTEPS)/buildsteps.d $(SOURCESD
# Build a 32bit binary until this gets fixed
$(BUILDSTEPS)/binutils.d: $(BUILDSTEPS)/binutils-srcdir.d
    mkdir -p $(BUILDDIR)/binutils
-   cd $(BUILDDIR)/binutils && CFLAGS="-m32" LDFLAGS="-m32" $(BINUTILS_SRCDIR)/configure --prefix=$(PREFIX) --target=$(TARGET_NAME) --disable-nls --disable-werror
+   cd $(BUILDDIR)/binutils && CFLAGS="-m32 -Wno-implicit-int -Wno-implicit-function-declaration" LDFLAGS="-m32" $(BINUTILS_SRCDIR)/configure --prefix=$(PREFIX) --target=$(TARGET_NAME) --disable-nls --disable-werror
    cd $(BUILDDIR)/binutils && make
    cd $(BUILDDIR)/binutils && make install
    touch $@


commitdiff http://git.netsurf-browser.org/toolchains.git/commit/?id=0ed58efcbe99982c34cd31623fbd3c49499b998d
commit 0ed58efcbe99982c34cd31623fbd3c49499b998d
Author: John-Mark Bell <jmb@netsurf-browser.org>
Commit: John-Mark Bell <jmb@netsurf-browser.org>

    m68k-unknown-amigaos: pin a known-working binutils
   
    It turns out that the Makefile would just fetch whatever was at
    the top of the SVN branch, which is unfortunate. It also turns
    out that nothing happens if there's already a stamp file
    indicating that the sources have been obtained. Pin the revision
    last fetched by the CI worker (which dates from 2017, so is
    hardly modern) as that is known to work (and our patches apply
    to it).

diff --git a/m68k-unknown-amigaos/Makefile b/m68k-unknown-amigaos/Makefile
index a9c17d2..c232f2b 100644
--- a/m68k-unknown-amigaos/Makefile
+++ b/m68k-unknown-amigaos/Makefile
@@ -7,10 +7,11 @@ UPSTREAM_GCC_VERSION := 3.4.6
UPSTREAM_GCC_TARBALL := gcc-$(UPSTREAM_GCC_VERSION).tar.bz2
UPSTREAM_GCC_URI := http://ftp.gnu.org/gnu/gcc/gcc-$(UPSTREAM_GCC_VERSION)/$(UPSTREAM_GCC_TARBALL)

+UPSTREAM_BINUTILS_REVISION := 630
UPSTREAM_BINUTILS_VERSION := 2.14
# Not a tarball; so sue me
UPSTREAM_BINUTILS_TARBALL := binutils-$(UPSTREAM_BINUTILS_VERSION)
-UPSTREAM_BINUTILS_URI := http://svn.code.sf.net/p/adtools/code/branches/binutils/$(UPSTREAM_BINUTILS_VERSION)/
+UPSTREAM_BINUTILS_URI := http://svn.code.sf.net/p/adtools/code/branches/binutils/$(UPSTREAM_BINUTILS_VERSION)/@$(UPSTREAM_BINUTILS_REVISION)

UPSTREAM_GMP_VERSION := 4.3.2
UPSTREAM_GMP_TARBALL := gmp-$(UPSTREAM_GMP_VERSION).tar.bz2


commitdiff http://git.netsurf-browser.org/toolchains.git/commit/?id=6cfb90abc9798bf4c6b29a30b0f58291cfaaf1b9
commit 6cfb90abc9798bf4c6b29a30b0f58291cfaaf1b9
Author: John-Mark Bell <jmb@netsurf-browser.org>
Commit: John-Mark Bell <jmb@netsurf-browser.org>

    SDK/libcurl: refresh patches for m68k-unknown-amigaos

diff --git a/sdk/recipes/patches/libcurl/m68k-unknown-amigaos/lib.curl_setup.h.p b/sdk/recipes/patches/libcurl/m68k-unknown-amigaos/lib.curl_setup.h.p
index ba595ca..0e3a6d3 100644
--- a/sdk/recipes/patches/libcurl/m68k-unknown-amigaos/lib.curl_setup.h.p
+++ b/sdk/recipes/patches/libcurl/m68k-unknown-amigaos/lib.curl_setup.h.p
@@ -1,10 +1,10 @@
--- lib/curl_setup.h.orig  2017-10-10 15:19:45.611896396 +0100
+++ lib/curl_setup.h   2017-10-17 15:42:25.304921197 +0100
-@@ -314,7 +314,6 @@
+@@ -454,7 +454,6 @@
   * In clib2 arpa/inet.h warns that some prototypes may clash
   * with bsdsocket.library. This avoids the definition of those.
   */
-#  define __NO_NET_API