diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2007-09-15 16:47:57 -0400 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-09-17 10:07:29 +0000 |
commit | 6d4b7d88eed49936ae16ecf02d5eb5b2cc716ea1 (patch) | |
tree | ebb471a724b48501acf4947245371ed9014bf1d8 /utils | |
parent | 2b3def87bfe260ad143467c9f351358fce35fd7b (diff) | |
download | perl-6d4b7d88eed49936ae16ecf02d5eb5b2cc716ea1.tar.gz |
Re: [PATCH] Cray XT4/Catamount build
Message-ID: <46EC7D3D.5010604@iki.fi>
p4raw-id: //depot/perl@31878
Diffstat (limited to 'utils')
-rw-r--r-- | utils/Makefile.SH (renamed from utils/Makefile) | 45 |
1 files changed, 44 insertions, 1 deletions
diff --git a/utils/Makefile b/utils/Makefile.SH index 3a96c9e8a0..42a274ccc5 100644 --- a/utils/Makefile +++ b/utils/Makefile.SH @@ -1,6 +1,40 @@ +case $PERL_CONFIG_SH in +'') + if test -f config.sh; then TOP=.; + elif test -f ../config.sh; then TOP=..; + elif test -f ../../config.sh; then TOP=../..; + elif test -f ../../../config.sh; then TOP=../../..; + elif test -f ../../../../config.sh; then TOP=../../../..; + else + echo "Can't find config.sh."; exit 1 + fi + . $TOP/config.sh + ;; +esac +: This forces SH files to create target in same directory as SH file. +: This is so that make depend always knows where to find SH derivatives. +case "$0" in +*/Makefile.SH) cd `expr X$0 : 'X\(.*\)/'` ;; +Makefile.SH) ;; +*) case `pwd` in + */utils) ;; + *) if test -d utils; then cd utils + else echo "Can't figure out where to write output."; exit 1 + fi;; + esac;; +esac + +echo "Extracting utils/Makefile (with variable substitutions)" +rm -f Makefile +cat >Makefile <<!GROK!THIS! PERL = ../miniperl REALPERL = ../perl +RUN = $run + +!GROK!THIS! + +cat >>Makefile <<'!NO!SUBS!' # Files to be built with variable substitution after miniperl is # available. Dependencies handled manually below (for now). @@ -12,7 +46,7 @@ plextractexe = ./c2ph ./config_data ./corelist ./cpan ./h2ph ./h2xs ./instmodsh all: $(plextract) $(plextract): - $(PERL) -I../lib $@.PL + $(RUN) $(PERL) -I../lib $@.PL c2ph: c2ph.PL ../config.sh @@ -74,3 +108,12 @@ distclean: clobber veryclean: distclean -rm -f *~ *.org +!NO!SUBS! +$eunicefix Makefile +case `pwd` in +*SH) + $rm -f ../Makefile + $ln Makefile ../Makefile + ;; +esac +rm -f $firstmakefile |