You are not logged in.
Trying to build openloco but after it builds the executable it tries to link it and fails doing so. (with this error)
mold: fatal: /home/Felipe/.cache/yay/openloco/src/OpenLoco-25.01/distribution/linux/ld_script_i386.xc:10: OUTPUT_ARCH(i386)
^ unknown linker script token
collect2: error: ld returned 1 exit statusThe PKGBUILD has set options=(!lto), I have also tried setting !lto on makepkg.conf and it STILL tries to link it.
There's another couple of packages I have that disable linking and they build as expected.
How do I get this to build correctly?
As explained below, it was an issue with mold not being compatible.
Last edited by Megarock90 (2025-02-15 22:56:43)
Offline
every binary needs to be linked, else you can't use it.
!lto just disables link time optimization.
Last edited by BS86 (2025-02-15 20:02:59)
Offline
What if you disable setting mold as the linker? As mold does not support OUTPUT_ARCH.
Offline
Yeah, as it turns out mold was the issue.
Is there an option to force the use of ld/lld on a PKGBUILD?
Offline
Is there an option to force the use of ld/lld on a PKGBUILD?
No changing the linker or one of the other build tools requires setting the environment variable or whatever other mechanism the build system uses.
Offline