autotools to meson: policy?
tlaronde at kergis.com
tlaronde at kergis.com
Wed Jan 29 17:51:19 UTC 2025
On Wed, Jan 29, 2025 at 01:40:20PM +0100, Enrico Weigelt, metux IT consult wrote:
> On 14.12.24 08:06, tlaronde at kergis.com wrote:
> > I still liked to have a Xorg developers' expressed policy about these
> > points:
> >
> > - Has the meson framework to provide at least the configuration
> > flexibility provided by autotools, so that whoever is compiling Xorg
> > could, in the future, configure it the way it managed to do with
> > autotools?
>
> [speaking just for the Xserver and drivers]
>
> IMHO (for our cases) yes. But we maybe should upgrade to a newer
> version, where things can be a done a bit easier, esp. dependencies
> between config flags.
>
> There's still a lot cleanup work to be done here, anyways.
>
> > - What to do when python byte-compiling is involved?
>
> Do we have that case ?
>
Theoretically, python is interpreted, so byte-compiling should not be
necessary. But for the module concerned---xcbproto---autotools
byte-compiles by default (and this is wrong, since python is
interpreted but its byte format is not portable, meaning that
cross-compilation can simply not work and the byte-compilation should
be attempted, if any, at install time on the target).
What I have written for xcbproto allows to explicitely ask for
byte-compilation.
But python is a disease that should not be allowed to spread in the X
sources...
> > *: for this, I have chosen for xcbproto (I know: it depends on another
> > church) to provide POSIX.2 scripts to search for python and to
> > byte-compile, allowing to use the scripts also at install time and
> > allowing OSes not using python (and hence not using meson) to be able
> > to do things.
>
> Do we really need to do bytecode compilation here ?
>
> IMHO, most distros already have their own generic mechanism. As upstream
> we really can't know which bytecode / python engine types and versions
> are used on a particular distro/target, so IMHO we shouldn't care at
> all, instead just install the .py files and leave the rest to the distro.
>
This is worst than that: every distro has its own way to install
python modules, due to incompatibilities between versions.
Once more, for xcbproto I have written POSIX.2 shell scripts so that
any distribution could put the files where it wants it without relying
on Meson default handling that is unlikely to do what the distro
expects---if I'm not mistaken, the modules are even not compiled in
meson in NetBSD pkgsrc; so the python related features would not be
available. This is why I have programmed things outside meson, not
relying on optional features.
--
Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
http://www.kergis.com/
http://kertex.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89 250D 52B1 AE95 6006 F40C
More information about the xorg-devel
mailing list