Re: Tarball builds in the new world order
От | Peter Eisentraut |
---|---|
Тема | Re: Tarball builds in the new world order |
Дата | |
Msg-id | 0d0e3c52-9f17-43d0-8ab8-50f8dcf6084b@eisentraut.org обсуждение исходный текст |
Ответ на | Tarball builds in the new world order (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: Tarball builds in the new world order
|
Список | pgsql-hackers |
On 24.04.24 00:05, Tom Lane wrote: > It makes tarballs all right, but whatever commit ID you specify > is semi-ignored, and you get a tarball corresponding to HEAD > of master. (The PDFs come from the right version, though!) > > The reason for that is that the mk-one-release script does this > (shorn of not-relevant-here details): > > export BASE=/home/pgsql > export GIT_DIR=$BASE/postgresql.git > > mkdir pgsql > > # Export the selected git ref > git archive ${gitref} | tar xf - -C pgsql Where does ${gitref} come from? Why doesn't this line use git archive HEAD | ... ? > What I suggest is doing this in mk-one-release: > > -make dist > +make dist PG_COMMIT_HASH=${gitref} > > and changing the "make dist" rules to write $(PG_COMMIT_HASH) not > HEAD. The extra make variable will have no effect in the back > branches, while it should cause the right thing to happen with > the new implementation of "make dist". I suppose we could do something like that, but we'd also need to come up with a meson version. (Let's not use "hash" though, since other ways to commit specify a commit can be used.) > This change seems like a good thing anyway for anyone who's tempted > to use "make dist" manually, since they wouldn't necessarily want > to package HEAD either. A tin-foil-hat argument is that we might not want to encourage that, because for reproducibility, we need a known git commit and also a known implementation of make dist. If in the future someone uses the make dist implementation of PG19 to build a tarball for PG17, it might not come out the same way as using the make dist implementation of PG17.
В списке pgsql-hackers по дате отправления: