Tíquete #48703

specenum generator: Meson integration

: 2023-09-23 06:02 Última Atualização: 2023-10-08 18:16

Relator:
Tipo:
Estado:
Fechado
Componente:
Marcos:
Prioridade:
5 - Medium
Gravidade:
5 - Medium
Resolução:
Fixed
Arquivo:
2

Details

Part of #48675. Follow-up to #48702. Call the new script automatically as part of the build to generate the headers.

This ticket is for the meson build only; see discussion below. Autotools is handled in #48806

Ticket History (3/10 Histories)

2023-09-23 06:02 Updated by: alienvalkyrie
  • New Ticket "specenum generator: Build system integration" created
2023-10-01 05:55 Updated by: cazfi
Comentário

Should this be further split to two; meson and autotools builds.

2023-10-01 16:59 Updated by: alienvalkyrie
Comentário

That would add complications; once the headers are generated automatically, we'd want to .gitignore them, but we can only do that once they're part of every build. Could still split it, but that would add a transitional period where they're auto-generated in one build, but still under version control.

2023-10-01 20:04 Updated by: cazfi
Comentário

Meson based build should place generated files to the builddir anyway, so I think we could do that (separately) first.

It's a bit shaky setup where meson build needs to use copy from builddir, despite another (possibly out-of-date) copy being in srcdir, but that's not much different from what we need to have in the future, and what we already have with generate_packets.py outputs. Even when files are not in the git repository, any autotools build (or unpacking from a tarball) places them there.

2023-10-03 03:48 Updated by: cazfi
  • Dono Update from (Nenhum) to alienvalkyrie
  • Marco Update from (Nenhum) to 3.3.0
Comentário

PoC, or, better-than-nothing implementation for meson attached. Assigning ticket to alienvalkyrie, as it's her call how to go forward.

2023-10-05 22:02 Updated by: alienvalkyrie
  • Resolução Update from Nenhum to Accepted
  • Details Updated
  • Summary Updated
Comentário

Figured it'll be worth it later to put in the time and effort now for a system that's easily extendable — I'm defining the custom targets in a loop, so each extra def file added in the future only needs one extra line a la 'extras_enums': ['extras_enums.def', 'extras_enums_gen.h'], rather than copy&pasting the whole thing and adding references in multiple places. We've got about forty files to migrate, so this'll pay off.

Also I decided that yeah, we'll do autotools in a separate ticket ~> #48806

2023-10-05 22:10 Updated by: alienvalkyrie
Comentário

NB: Patch depends on #48785 since it includes the enums for freeciv-manual. The patch file itself might also textually depend on other patches (or rather, lack thereof) for the context lines (specifically the end of the manual sources list, which is affected by some other pending patches), but git should handle that without problem when the actual commits are being merged.

2023-10-08 18:16 Updated by: alienvalkyrie
  • Estado Update from Aberto to Fechado
  • Resolução Update from Accepted to Fixed

Editar

You are not logged in. I you are not logged in, your comment will be treated as an anonymous post. » Login