Re: [MacPorts] #74106: giflib5 @5.2.2₃ does not build on PPC Leopard, Mac OS X 10.5.8, because of cc1: error: unrecognized command line option "-Wno-format-truncation"
MacPorts
noreply at macports.org
Thu Jul 16 01:51:31 UTC 2026
#74106: giflib5 @5.2.2₃ does not build on PPC Leopard, Mac OS X 10.5.8, because of
cc1: error: unrecognized command line option "-Wno-format-truncation"
------------------------+-------------------------
Reporter: ballapete | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.12.5
Resolution: | Keywords: ppc leopard
Port: giflib5 |
------------------------+-------------------------
Comment (by PotMJ):
I have verified a lightweight alternative patch that successfully compiles
`giflib5` natively on legacy setups (tested across both OS X 10.5.8 Intel
and OS X 10.11.6) without introducing heavy, problematic toolchain
dependencies like modern GCC. It successfully builds 4 arch +universal on
10.5.8.
The issue stems from a hardcoded modern warning flag (`-Wno-format-
truncation`) and standard Makefile architecture multi-flags crashing
baseline compilers during universal loops.
The attached updated `Portfile` fixes this cleanly by:
1. Adding a lightweight conditional block (`${os.major} < 16`) inside
`post-patch` to safely `reinplace` and strip out the unsupported flag.
2. Integrating `PortGroup muniversal 1.0` and updating the active build
arguments to cleanly separate and compile the individual architecture
slices.
This allows the library to compile entirely out-of-the-box using the
native system toolchains, keeping the dependency tree small and clean for
vintage systems.
--
Ticket URL: <https://trac.macports.org/ticket/74106#comment:4>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list