Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rec use meson to create dist file #15076

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

omoerbeek
Copy link
Member

@omoerbeek omoerbeek commented Jan 22, 2025

Short description

Draft as I need to double check the differences between the the autotool generated tarball and meson generated tarball.

meson dist -C yourbuilddir --formats bztar gets you the tarball.

Meson dist uses a partial checkout of the tree for subprojects (as rec is), so symlinks into the parent are dangling. There is a dist script to fix those.

To bootstrap, a few symlinks are replaced in git by actual files, as the project clause needs them before the dist script is run.

Next, after the dist dir is created, we replace the remaining symlinks into the rest of the tree by the actual files using some tar magic in the dist script.

I checked the produced tarbal can be used to build both using meson and autotools.

version.sh script from meson docs: https://mesonbuild.com/Creating-releases.html#cement-a-version-obtained-from-vcs

Checklist

I have:

  • read the CONTRIBUTING.md document
  • compiled this code
  • tested this code
  • included documentation (including possible behaviour changes)
  • documented the code
  • added or modified regression test(s)
  • added or modified unit test(s)

@omoerbeek omoerbeek changed the title Rec meson dist Rec use meson to create dist file Jan 22, 2025
@omoerbeek omoerbeek marked this pull request as draft January 22, 2025 14:19
@omoerbeek omoerbeek added the rec label Jan 22, 2025
@coveralls
Copy link

coveralls commented Jan 22, 2025

Pull Request Test Coverage Report for Build 12911942143

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 20 unchanged lines in 8 files lost coverage.
  • Overall coverage increased (+0.03%) to 64.707%

Files with Coverage Reduction New Missed Lines %
pdns/recursordist/syncres.cc 1 80.13%
pdns/misc.cc 1 62.71%
pdns/dnsdistdist/dnsdist-tcp.cc 1 75.79%
pdns/pollmplexer.cc 1 83.66%
pdns/tsigverifier.cc 3 77.22%
modules/gpgsqlbackend/spgsql.cc 3 67.7%
pdns/recursordist/test-syncres_cc1.cc 5 89.87%
pdns/signingpipe.cc 5 84.99%
Totals Coverage Status
Change from base Build 12905504248: 0.03%
Covered Lines: 127816
Relevant Lines: 166432

💛 - Coveralls

@omoerbeek
Copy link
Member Author

omoerbeek commented Jan 22, 2025

Dir compare shows that the meson tarball has some extra files.
autotrools show a few generated files extra that are currenlty missing in the meson tarball.
I marked them to stand out

The question is if we want to have these file sin the meson tarball as well. They would require ragel and python as abuild dep. I'd say include in tarball for ragel and nope for python generated files.

Only in meson: .gitignore
Only in meson: Caddyfile
Only in meson: README.md
Only in meson: autom4te.cache
Only in meson/build-aux: gen-version
*** Only in autotools: dnslabeltext.cc
Only in meson: docs
Only in autotools: effective_tld_names.dat
Only in meson: examples
Only in meson/ext/arc4random: .gitignore
Only in meson/ext/arc4random: meson.build
Only in meson/ext/json11: .gitignore
Only in meson/ext/json11: meson.build
Only in meson/ext/luawrapper: meson.build
Only in meson/ext/probds: .gitignore
Only in meson/ext/probds: meson.build
Only in meson/ext/protozero: CHANGELOG.md
Only in meson/ext/protozero: LICENSE.from_folly
Only in meson/ext/protozero: LICENSE.md
Only in meson/ext/protozero: meson.build
Only in meson/ext/yahttp: .gitignore
Only in meson/ext/yahttp: meson.build
Only in meson/ext/yahttp/yahttp: meson.build
Only in meson/m4: pdns_enable_p11kit.m4
Only in meson/m4: pdns_with_gnutls.m4
Only in meson: make-ext-symlinks.py
Only in meson: meson
Only in meson: meson-dist-script.sh
Only in meson: meson.build
Only in meson: meson_options.txt
Only in meson: recursor-lsan.supp
Only in meson: recursor-tsan.supp
Only in meson/settings: .gitignore
*** Only in autotools/settings: cxxsettings-generated.cc
Only in meson/settings: meson.build
Only in meson/settings/rust: .gitignore
Only in meson/settings/rust: build_settings
Only in meson/settings/rust: meson.build
*** Only in autotools/settings/rust/src: lib.rs
Only in meson: version.sh

@eli-schwartz
Copy link
Contributor

Dir compare shows that the meson tarball has some extra files.

gitignore files can be excluded pretty easily: #15078

@@ -0,0 +1,28 @@
#!/bin/sh -e

echo Runnig meson-dist-script
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
echo Runnig meson-dist-script
echo Running meson-dist-script

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants