This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
pp_hot.c: Correct comment
[perl5.git] / Makefile.SH
index ee9ea47..a18dff0 100755 (executable)
@@ -443,9 +443,12 @@ xconfig.h: config_h.SH Cross/config-\$(CROSS_NAME).sh
        ;;
 esac
 
-SH='Makefile.SH cflags.SH config_h.SH makedepend.SH myconfig.SH runtests.SH pod/Makefile.SH'
-shextract=`echo $SH | sed -e s/\\\.SH//g -e s/_/./g`
+SH_to_target() {
+    echo $@ | sed -e s/\\\.SH//g -e s/_/./g
+}
 
+SH='Makefile.SH cflags.SH config_h.SH makedepend.SH myconfig.SH runtests.SH pod/Makefile.SH x2p/Makefile.SH'
+shextract=`SH_to_target $SH`
 
 ## In the following dollars and backticks do not need the extra backslash.
 $spitshell >>$Makefile <<!GROK!THIS!
@@ -1073,7 +1076,8 @@ pod/perltoc.pod: $(perltoc_pod_prereqs)  $(PERL_EXE) $(ext) pod/buildtoc
 
 pod/perlapi.pod: pod/perlintern.pod
 
-pod/perlintern.pod: $(MINIPERL_EXE) autodoc.pl embed.fnc
+# Depending on $(nonxs_ext) gets us Text::Wrap built
+pod/perlintern.pod: $(MINIPERL_EXE) autodoc.pl embed.fnc $(nonxs_ext)
        $(MINIPERL) autodoc.pl
 
 pod/perlmodlib.pod: $(MINIPERL_EXE) pod/perlmodlib.PL MANIFEST
@@ -1282,7 +1286,6 @@ _mopup:
        -@test -f vms/README_vms.pod && rm -f vms/README_vms.pod
        -rm -f perl.exp ext.libs $(generated_pods) uni.data opmini.o perlmini.o pod/roffitall
        -rm -f perl.export perl.dll perl.libexp perl.map perl.def
-       -rm -f perl.loadmap miniperl.loadmap perl.prelmap miniperl.prelmap
        -rm -f perl.third lib*.so.perl.third perl.3log t/perl.third t/perl.3log
        -rm -f perl.pixie lib*.so.perl.pixie lib*.so.Addrs
        -rm -f perl.Addrs perl.Counts t/perl.Addrs t/perl.Counts *perl.xok
@@ -1400,18 +1403,23 @@ MAKEDEPEND = Makefile makedepend
 
 $(FIRSTMAKEFILE):      README $(MAKEDEPEND)
        $(MAKE) depend MAKEDEPEND=
+!NO!SUBS!
+
+for f in $SH; do
+    file=`SH_to_target $f`
+    $spitshell >>$Makefile <<!GROK!THIS!
 
-config.h: config_h.SH config.sh
-       $(SHELL) config_h.SH
+$file: $f config.sh
+       \$(SHELL) $f
+!GROK!THIS!
+done
+
+$spitshell >>$Makefile <<'!NO!SUBS!'
 
 .PHONY: depend
 depend: makedepend
        sh ./makedepend MAKE=$(MAKE) cflags
 
-# Cannot postpone this until $firstmakefile is ready ;-)
-makedepend: makedepend.SH config.sh
-       sh ./makedepend.SH
-
 .PHONY: test check test_prep test_prep_nodll test_prep_pre \
        test_prep_reonly test_tty test-tty test_notty test-notty \
        utest ucheck test.utf8 check.utf8 test.torture torturetest \
@@ -1583,7 +1591,7 @@ noknack:  utilities
 nokfilenack:   utilities
        $(RUN_PERL) -Ilib utils/perlbug -nok -s '(UNINSTALLED)' -F perl.nok -A
 
-.PHONY: clist hlist shlist
+.PHONY: clist hlist
 
 clist: $(c)
        echo $(c) | tr ' ' $(TRNL) >.clist
@@ -1591,12 +1599,6 @@ clist:   $(c)
 hlist:  $(h)
        echo $(h) | tr ' ' $(TRNL) >.hlist
 
-shlist: $(sh)
-       echo $(sh) | tr ' ' $(TRNL) >.shlist
-
-Makefile: Makefile.SH ./config.sh
-       $(SHELL) Makefile.SH
-
 .PHONY: distcheck
 distcheck: FORCE
        perl '-MExtUtils::Manifest=&fullcheck' -e 'fullcheck()'