develooper Front page | perl.perl5.porters | Postings from January 2009

Re: Minimal Perl git repostory

Thread Previous | Thread Next
Jerry D. Hedden
January 7, 2009 14:02
Re: Minimal Perl git repostory
Message ID:
On Wed, Jan 7, 2009 at 4:17 PM, Jerry D. Hedden <> wrote:
> demerphq wrote:
>> git pull # whatever, update git.
>> perl
>> git archive --format=zip HEAD > $zips/
>> zip $zips/ lib/ git_version.h
>> and $zips/ will contain a minimal archive that is buildable
>> with full details. If for some reason git_version.h is overwritten by
>> stock_git_version.h you can touch them before running make to ensure
>> they are more recent than perl.c. This is done using the zip format
>> becuase its easy to add files to it, I tried something similar with
>> tar -A and it didnt work. YMMV.
> This does not work.  Makefile does not respect git_version.h
> and lib/  They are overwritten regardless of
> their timestamps.

I used the following patch to get this to work:

--- perl-current/
+++ perl-current/
@@ -99,6 +99,9 @@
     return 0;

+# Don't overwrite existing files
+exit(0) if (-f 'git_version.h' && -f 'lib/');
 my $unpushed_commits = '/*no-op*/';
 my ($read, $branch, $snapshot_created, $commit_id, $describe)= ("") x 5;
 my ($changed, $extra_info, $commit_title, $new_patchnum, $status)= ("") x 5;

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About