Ticket #46495

Meson build from tarball uses premade ..._gen.h files

Date d'ouverture: 2023-01-09 13:38 Dernière mise à jour: 2023-02-21 23:40

Rapporteur:
Propriétaire:
Type:
État:
Atteints
Composant:
Priorité:
5 - moyen
Sévérité:
5 - moyen
Résolution:
Fixed
Fichier:
2

Détails

This is a bit of a problem also with git checkouts, but it occurred to me that release tarballs will be even more affected.

With git checkouts, if one does *only* meson based builds, there's no problem. The problems begin when one does both autotools and meson based builds from the same sources. Autotools builds generate some files to the source directory. Meson generates everything properly to the build directory, so it's not even overwriting autotools generated files. However, when both (potentially outdated) autotools generated version and meson generated version are available, meson may end up using autotools generated one from the source directory.

What makes tarball/release case worse than git checkout case is that those autotools generated files are already present in the tarball. So even if user never does autotools build themselves, meson build does not work properly (if some generated file should be regenerated, i.e. , one tries to build modified version)

Targeting to 3.1, but this isn't necessarily a beta1 blocker - meson based builds are experimental in 3.1, after all. Plan is to make official macOS builds from 3.1 with meson, though.

Ticket History (3/7 Histories)

2023-01-09 13:38 Updated by: cazfi
  • New Ticket "Meson build from tarball uses premade ..._gen.h files" created
2023-01-20 18:39 Updated by: cazfi
Commentaire

#42212 resolved the issue for the headers that have tolua_..._open(). Maybe similar solution would work for the rest?

2023-02-17 04:49 Updated by: cazfi
Commentaire

Reply To cazfi

#42212 resolved the issue for the headers that have tolua_..._open(). Maybe similar solution would work for the rest?

Alternatively we could make autotools build to generate those headers to a separate directory that would still be within "the source tree" in that it's distributed with freeciv, but which meson build would not look headers from.

I think that would be more robust solution, but also a lot more involved - so I guess that 3.1.0-beta1 should go by the #42212 route, even if as a temporary solution.

2023-02-17 05:17 Updated by: cazfi
  • Propriétaire Update from (Aucun) to cazfi
  • Résolution Update from Aucun to Accepted
2023-02-21 23:40 Updated by: cazfi
  • État Update from Ouvert to Atteints
  • Résolution Update from Accepted to Fixed

Modifier

Please login to add comment to this ticket » Connexion