Re: make dist using git archive

From: "Tristan Partin" <tristan(at)neon(dot)tech>
To: "Peter Eisentraut" <peter(at)eisentraut(dot)org>
Cc: "pgsql-hackers" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: make dist using git archive
Date: 2024-03-24 15:42:53
Message-ID: D023FU06R15U.1JPA37I8C46WP@neon.tech
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

3 comments left that are inconsequential. Feel free to ignore.

> +# Meson has its own distribution building command (meson dist), but we
> +# are not using that at this point. The main problem is that the way
> +# they have implemented it, it is not deterministic. Also, we want it
> +# to be equivalent to the "make" version for the time being. But the
> +# target name "dist" in meson is reserved for that reason, so we call
> +# the custom target "pgdist".

The second sentence is a run-on.

> +if bzip2.found()
> + tar_bz2 = custom_target('tar.bz2',
> + build_always_stale: true,
> + command: [git, '-C', '@SOURCE_ROOT@',
> + '-c', 'core.autocrlf=false',
> + '-c', 'tar.tar.bz2.command="' + bzip2.path() + '" -c',
> + 'archive',
> + '--format', 'tar.bz2',
> + '--prefix', distdir + '/',
> + '-o', join_paths(meson.build_root(), '@OUTPUT@'),
> + 'HEAD', '.'],
> + install: false,
> + output: distdir + '.tar.bz2',
> + )

You might find Meson's string formatting syntax creates a more readable
command string:

'tar(dot)tar(dot)bz2(dot)command=(at)0@ -c'.format(bzip2.path())

And then 'install: false' is the default if you feel like leaving it
out.

Otherwise, let's get this in!

--
Tristan Partin
Neon (https://neon.tech)

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Melanie Plageman 2024-03-24 16:32:46 Re: Combine Prune and Freeze records emitted by vacuum
Previous Message Tom Lane 2024-03-24 15:28:12 Re: Sync scan & regression tests