On Jul 4 10:28, Radek Barton via Cygwin-patches wrote: > Hello. > > > In terms of this patch here I'm a bit puzzled. It's nice that the > > "=/lib/w32api" is sufficent. I tested this locally on my fedora -> > > x86_64-pc-cygwin cross and it builds fine, too. > > > But why on earth is adding an unneeded dir to the search path > > breaking the build, if the correct "=/lib/w32api" path is part of the > >search path as well? Why does this not break the x86_64 build, even > > if that path neither exists for x86_64? > > This is not consistent with my observations (tested on the GitHub CI): > > `=/lib/w32api` breaks Fedora build
Oh, I'm sorry! Somehow I didn't notice the =lib vs. =usr/lib, I only saw a change in the directory order :( > `=/usr/lib/w32api` works > `/usr/x86_64-pc-cygwin/lib/w32api`, resp. `/usr/aarch64-pc-cygwin/lib/w32api` > does not change anything (builds pass whether it's present or not) > > For this reason, I'd suggest to that the original patch > https://sourceware.org/pipermail/cygwin-patches/2025q2/013892.html would be > the safest to merge. But in fact the =usr/lib should be sufficient as Jon pointed out. The native sysroot is /, the cross-build sysroot is either /usr/x86_64-pc-cygwin/sys-root/ or /usr/aarch64-pc-cygwin/sys-root. So the search dir is always $SYSROOT/usr/lib/w32api aka =usr/lib/w32api. I think your second patch is the way to go. > Radek > > PS: Thank you for your feedback, I'll be adding more information to the > commit messages. Thanks, Corinna