On Fri, Apr 28, 2023 at 02:22:40PM +0200, Florian Weimer wrote:
Looking at
Information for RPM mingw64-zlib-1.2.13-2.fc38.noarch.rpm
<
https://koji.fedoraproject.org/koji/rpminfo?rpmID=33118048>
sysroot paths look like this:
/usr/x86_64-w64-mingw32/sys-root/mingw/bin/zlib1.dll
/usr/x86_64-w64-mingw32/sys-root/mingw/include/zconf.h
/usr/x86_64-w64-mingw32/sys-root/mingw/include/zlib.h
/usr/x86_64-w64-mingw32/sys-root/mingw/lib/libz.dll.a
/usr/x86_64-w64-mingw32/sys-root/mingw/lib/pkgconfig/zlib.pc
Is the /mingw/ part of the sysroot path, or is it within the sysroot?
Would I use --sysroot=/usr/x86_64-w64-mingw32/sys-root or
--sysroot=/usr/x86_64-w64-mingw32/sys-root/mingw to build against the
sysroot?
I assumed the latter, but now I wonder if /mingw in the sysroot is the
analogue of /usr in GNU/Linux sysroots.
Eventually, we want to produce some GNU/Linux sysroots. I picked
/usr/%{_arch}-redhat-linux/sys-root/fc%{fedora}
or (depending on the operating system)
/usr/%{_arch}-redhat-linux/sys-root/el%{rhel}
or (as the fallback)
/usr/%{_arch}-redhat-linux/sys-root/root
and we have /usr inside the sysroot, e.g. <stdio.h> is
/usr/x86_64-redhat-linux/sys-root/fc35/usr/include/stdio.h
in a Fedora 35 sysroot on x86-64 (although the Fedora 35 update with
this never actually went out). We essentially use the /mingw/ part as
an OS ABI version indicator, to make the different versions
co-installable.
Parallel install of different versions of mingw has never been
something we needed to consider. We only need parallel install
the different ABIs, which is handled by the higher level dir
in the path. So from that POV, I don't think mingw particularly
cares what semantics are attached to the 4th path component
'mingw'. As long as we don't have to change our paths currently
used in Fedora, I think it'd be OK for you to define the 4th
component as the OS version indicator.
With regards,
Daniel
--
|:
https://berrange.com -o-
https://www.flickr.com/photos/dberrange :|
|:
https://libvirt.org -o-
https://fstop138.berrange.com :|
|:
https://entangle-photo.org -o-
https://www.instagram.com/dberrange :|