From a9a6b98f058241aabd23b3d65497eebb5f33310a Mon Sep 17 00:00:00 2001 From: Rhys-T <108157737+Rhys-T@users.noreply.github.com> Date: Thu, 1 May 2025 23:38:33 -0400 Subject: [PATCH] sdcc: fix build on Darwin sdcc 4.5.0 massively rewrote sim/ucsim/Makefile.in, and lost the `.PHONY` rule in the process. As a result, on macOS (which uses a case-insensitive filesystem), the INSTALL file keeps the `install` target in the ucsim directory from running. Nothing else creates the `man` output, causing the entire build to fail. --- pkgs/by-name/sd/sdcc/package.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/pkgs/by-name/sd/sdcc/package.nix b/pkgs/by-name/sd/sdcc/package.nix index cc9e0512dcb4..82df34e70a2d 100644 --- a/pkgs/by-name/sd/sdcc/package.nix +++ b/pkgs/by-name/sd/sdcc/package.nix @@ -63,6 +63,16 @@ stdenv.mkDerivation (finalAttrs: { gputils ]; + # sdcc 4.5.0 massively rewrote sim/ucsim/Makefile.in, and lost the `.PHONY` + # rule in the process. As a result, on macOS (which uses a case-insensitive + # filesystem), the INSTALL file keeps the `install` target in the ucsim + # directory from running. Nothing else creates the `man` output, causing the + # entire build to fail. + + postPatch = '' + echo '.PHONY: install' >> sim/ucsim/Makefile.in + ''; + configureFlags = let excludedPorts =