diff options
-rw-r--r-- | Makefile.SH | 5 | ||||
-rwxr-xr-x | configpm | 7 | ||||
-rw-r--r-- | make_patchnum.sh | 11 |
3 files changed, 14 insertions, 9 deletions
diff --git a/Makefile.SH b/Makefile.SH index 9bf115c661..c6bebe0c5d 100644 --- a/Makefile.SH +++ b/Makefile.SH @@ -541,7 +541,8 @@ sperl.i: perl.c $(h) .PHONY: all translators utilities make_patchnum make_patchnum: - sh $(shellflags) make_patchnum.sh + sh $(shellflags) make_patchnum.sh || $(MAKE) miniperl + git_version.h: stock_git_version.h cp stock_git_version.h git_version.h @@ -594,7 +595,7 @@ miniperlmain$(OBJ_EXT): miniperlmain.c patchlevel.h perlmain.c: miniperlmain.c config.sh $(FIRSTMAKEFILE) sh writemain $(DYNALOADER) $(static_ext) > perlmain.c -perlmain$(OBJ_EXT): perlmain.c +perlmain$(OBJ_EXT): perlmain.c git_version.h $(CCCMD) $(PLDLFLAGS) $*.c # The file ext.libs is a list of libraries that must be linked in @@ -548,8 +548,11 @@ foreach my $prefix (qw(libs libswanted)) { $heavy_txt .= "EOVIRTUAL\n"; $heavy_txt .= <<'ENDOFGIT'; -require 'Config_git.pl'; -$Config_SH_expanded .= $Config::Git_Data; +eval { + # do not have hairy conniptions if this isnt available + require 'Config_git.pl'; + $Config_SH_expanded .= $Config::Git_Data; +}; ENDOFGIT $heavy_txt .= $fetch_string; diff --git a/make_patchnum.sh b/make_patchnum.sh index e770f75e86..6c3ae65e9a 100644 --- a/make_patchnum.sh +++ b/make_patchnum.sh @@ -69,19 +69,19 @@ test -z "$commit_title" && commit_title='Commit id:' new_header=`cat <<EOFTEXT /*************************************************************************** -* WARNING: $header_file is automatically generated by make_patchnum.sh -* DO NOT EDIT DIRECTLY - edit make_patchnum.sh instead +* WARNING: $header_file is automatically generated by make_patchnum.sh +* DO NOT EDIT DIRECTLY - edit make_patchnum.sh instead ****************************************************************************/ #define PERL_PATCHNUM $describe $status -#define PERL_GIT_UNPUSHED_COMMITS $unpushed_commits +#define PERL_GIT_UNPUSHED_COMMITS $unpushed_commits /*leave-this-comment*/ EOFTEXT ` new_config=`cat <<EOFDATA ####################################################################### -# WARNING: $config_file is generated by make_patchnum.sh -# DO NOT EDIT DIRECTLY - edit make_patchnum.sh instead +# WARNING: $config_file is generated by make_patchnum.sh +# DO NOT EDIT DIRECTLY - edit make_patchnum.sh instead ####################################################################### \\$Config::Git_Data=<<'ENDOFGIT'; git_commit_id='$commit_id' @@ -98,6 +98,7 @@ if [ "$new_config" != "$existing_config" ] || [ "$existing_header" != "$new_head echo "Updating $header_file and $config_file" echo "$new_config" > $config_file echo "$new_header" > $header_file + exit 1 else echo "Reusing $header_file and $config_file" fi |