too long lines were shrinked: scons -j4 ar=x86_64-pc-linux-gnu-ar allow_warnings=yes assertions=no build_examples=yes boost_bundled_enable=false boost_force_bundled=false cc=x86_64-pc-linux-gnu-gcc ccache=no ccflags=-O2 -pipe -march=native -fno-diagnostics-color coverage=no cxx=x86_64-pc-linux-gnu-g++ cxxflags=-O2 -pipe -march=n scons: Reading SConscript files ... scons: *** Path does not exist for variable 'icu': 'no' File "/var/tmp/portage/net-im/swift-4.0.3-r2/work/swift-swift-4.0.3/SConstruct", line 1, in <module> * ERROR: net-im/swift-4.0.3-r2::gentoo failed (compile phase): * escons failed. * * Call stack: ------------------------------------------------------------------- This is an unstable amd64 chroot image at a tinderbox (==build bot) name: 23.0_no_multilib_systemd-20250228-184508 UNMASKED: [ffmpeg] Requested by sam =media-video/ffmpeg-7* [go-1.24] Requested by WilliamH - maybe block bug 950018 <dev-lang/go-9999 The attached etc.portage.tar.xz has all details. ------------------------------------------------------------------- gcc-config -l: [1] x86_64-pc-linux-gnu-14 * clang version 19.1.7 llvm-config: 19.1.7 Python 3.12.9 go version go1.24.0 linux/amd64 [1] php8.2 [2] php8.3 * Available Ruby profiles: [1] ruby32 (with Rubygems) * Available Rust versions: [1] rust-bin-1.85.0 * The following VMs are available for generation-2: *) Eclipse Temurin JDK 21.0.6_p7 [openjdk-bin-21] 2) Eclipse Temurin JDK 8.442_p06 [openjdk-bin-8] Available Java Virtual Machines: [1] openjdk-bin-8 [2] openjdk-bin-21 system-vm HEAD of ::gentoo commit 1983d888d4447a22c3d0e4a05c9c0b05fc7f7738 Author: Repository mirror & CI <repomirrorci@gentoo.org> Date: Tue Mar 4 13:33:32 2025 +0000 2025-03-04 13:33:31 UTC emerge -qpvO =net-im/swift-4.0.3-r2 [ebuild N ] net-im/swift-4.0.3-r2 USE="icu idn lua -expat -test -zeroconf" LUA_SINGLE_TARGET="lua5-1 -luajit"
Created attachment 920209 [details] emerge-info.txt
Created attachment 920210 [details] emerge-history.txt
Created attachment 920211 [details] environment
Created attachment 920212 [details] etc.clang.tar.xz
Created attachment 920213 [details] etc.portage.tar.xz
Created attachment 920214 [details] logs.tar.xz
Created attachment 920215 [details] net-im:swift-4.0.3-r2:20250304-142251.log
Created attachment 920216 [details] qlist-info.txt.xz
Created attachment 920217 [details] temp.tar.xz
The build fails due to behaviour change in dev-build/scons-4.9.0 From: https://scons.org/scons-490-is-available.html FIXES PackageVariable now does what the documentation always said it does if the variable is used on the command line with one of the enabling string as the value: the variable's default value is produced (previously it always produced True in this case). I'm finding scons to be a bit opaque. By changing the net-im/swift-4.0.3 SConscript.boot from default "no" to default "search" for icu allows the package to be built with or without icu vars.Add(PackageVariable("icu", "ICU library location", "no")) vars.Add(PackageVariable("icu", "ICU library location", "search")) but I'm not sure that's the correct solution.
Thanks. Sounds reasonable for me.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=719db758e9f3ed8c96acb2df6ded739fab2b22bd commit 719db758e9f3ed8c96acb2df6ded739fab2b22bd Author: Conrad Kostecki <conikost@gentoo.org> AuthorDate: 2025-03-28 20:23:51 +0000 Commit: Conrad Kostecki <conikost@gentoo.org> CommitDate: 2025-03-28 20:24:58 +0000 net-im/swift: add fix for >=scons-4.9.0 Closes: https://bugs.gentoo.org/950584 Signed-off-by: Conrad Kostecki <conikost@gentoo.org> net-im/swift/files/swift-4.0.3-scons-4.9.0.patch | 11 +++++++++++ net-im/swift/swift-4.0.3-r2.ebuild | 3 ++- 2 files changed, 13 insertions(+), 1 deletion(-)
Created attachment 923206 [details, diff] fix build with scons-4.9.0 The patch just trivially changes the default in BuildTools/SCons/SConscript.boot
I'm not actually convinced that this isn't a bug in Scons ... I think the PackageVariable function's _converter might be missing an elif: def _converter(val: str | bool, default: str) -> str | bool: #<== trimmed ==> lval = val.lower() if lval in DISABLE_STRINGS: return False if lval in ENABLE_STRINGS: # Can't return the default if it is one of the enable/disable strings; # test code expects a bool. if default in ENABLE_STRINGS: return True else: return default return val looks to me that the `default` arg is a str, (was "no" is now "search") so when the cli gets 'icu=yes' it tests against ENABLE_STRINGS finds it and then tests `default` against ENABLE_STRINGS doesn't find it and returns `default` which is now a string (rather than bool). This then gets passed to the _validator which sees the str and not a bool and so tests it as a path. I suspect the above should have been: lval = val.lower() if lval in DISABLE_STRINGS: return False if lval in ENABLE_STRINGS: # Can't return the default if it is one of the enable/disable strings; # test code expects a bool. if default in ENABLE_STRINGS: return True elif default in DISABLE_STRINGS: return True else: return default return val waiting on response on discord from scons maintainers
gah typos lval = val.lower() if lval in DISABLE_STRINGS: return False if lval in ENABLE_STRINGS: # Can't return the default if it is one of the enable/disable strings; # test code expects a bool. if default in ENABLE_STRINGS: return True elif default in DISABLE_STRINGS: return False else: return default return val
Thanks for your further investigation. I will reopen here, until you have a response from upstream.
Bug was in dev-build/scons-4.9.0 - dev-build/scons-4.9.1 upstream bug: https://github.com/SCons/scons/issues/4702 closed in: https://github.com/SCons/scons/pull/4703 Fix should be in next release of dev-build/scons (4.9.2)
Thanks. I will drop patch when 4.9.2 becomes stable and available in tree.