summaryrefslogtreecommitdiff
path: root/recipes/perl/perl-5.10.1/Makefile.SH.patch
blob: b707dfd7957c14ce6d0a7c762f6e8cea84596b11 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
Index: perl-5.10.1/Makefile.SH
===================================================================
--- perl-5.10.1.orig/Makefile.SH	2010-03-04 13:13:34.000000000 +0300
+++ perl-5.10.1/Makefile.SH	2010-03-04 13:14:45.000000000 +0300
@@ -134,7 +134,8 @@
 	        ldlibpth=''
 	        ;;
 	    *)
-		eval "ldlibpth=\"$ldlibpthname=`pwd`:\$$ldlibpthname\""
+# We compile in the library path in OE from cross-compile, so lets not do this
+#		eval "ldlibpth=\"$ldlibpthname=`pwd`:\$$ldlibpthname\""
 		;;
 	    esac
 	    # Strip off any trailing :'s
@@ -155,18 +156,7 @@
 	    # INSTALL file, under "Building a shared perl library".
 	    # If there is no pre-existing $libperl, we don't need
 	    # to do anything further.
-	    if test -f $archlib/CORE/$libperl; then
-		rm -f preload
-		cat <<'EOT' > preload
-#! /bin/sh
-lib=$1
-shift
-test -r $lib && export LD_PRELOAD="$lib $LD_PRELOAD"
-exec "$@"
-EOT
-		chmod 755 preload
-		ldlibpth="$ldlibpth `pwd`/preload `pwd`/$libperl"
-	    fi
+	    echo linux libraries overwritten by cross-compile patches
 	    ;;
 	os390)	test -f /bin/env && ldlibpth="/bin/env $ldlibpth"
 		;;
@@ -532,9 +522,19 @@
 .c.s:
 	$(CCCMDSRC) -S $*.c
 
-all: $(FIRSTMAKEFILE) miniperl$(EXE_EXT) miniperl $(generated_pods) $(private) $(unidatafiles) $(public) $(dynamic_ext) $(nonxs_ext) extras.make
-	@echo " ";
-	@echo "	Everything is up to date. Type '$(MAKE) test' to run test suite."
+#all: $(FIRSTMAKEFILE) miniperl$(EXE_EXT) miniperl $(generated_pods) $(private) $(unidatafiles) $(public) $(dynamic_ext) $(nonxs_ext) extras.make
+#	@echo " ";
+#	@echo "	Everything is up to date. Type '$(MAKE) test' to run test suite."
+
+all: $(FIRSTMAKEFILE) miniperl$(EXE_EXT) $(unidatafiles)
+
+more: $(generated_pods) $(private) $(public)
+
+more2: $(dynamic_ext)
+
+more3: $(nonxs_ext)
+
+more4: extras.make
 
 sperl$(OBJ_EXT): perl.c $(h)
 	$(RMS) sperl.c
@@ -554,10 +554,10 @@
 perl$(OBJ_EXT): git_version.h
 sperl$(OBJ_EXT): git_version.h
 
-translators:	miniperl$(EXE_EXT) $(CONFIGPM) FORCE
+translators: $(CONFIGPM) FORCE
 	@echo " "; echo "	Making x2p stuff"; cd x2p; $(LDLIBPTH) $(MAKE) all
 
-utilities:	miniperl$(EXE_EXT) $(CONFIGPM) $(plextract) lib/lib.pm FORCE
+utilities:  $(CONFIGPM) $(plextract) lib/lib.pm FORCE
 	@echo " "; echo "	Making utilities"; cd utils; $(LDLIBPTH) $(MAKE) all
 
 
@@ -730,7 +730,7 @@
 	true)
 		$spitshell >>$Makefile <<'!NO!SUBS!'
 	rm -f $@
-	$(LD) -o $@ $(SHRPLDFLAGS) $(obj) $(DYNALOADER) $(libs)
+	$(LD) -o $@ $(SHRPLDFLAGS) $(obj) $(DYNALOADER) $(libs) -Wl,-soname,libperl.so.5
 !NO!SUBS!
 		case "$osname" in
 		aix)
@@ -771,7 +771,8 @@
 	$(CC) -o miniperl$(EXE_EXT) $(CLDFLAGS) \
 	    $(mini_obj) \
 	    miniperlmain$(OBJ_EXT) opmini$(OBJ_EXT) perlmini$(OBJ_EXT) $(libs)
-	$(LDLIBPTH) $(RUN) ./miniperl$(HOST_EXE_EXT) -w -Ilib -MExporter -e '<?>' || $(MAKE) minitest
+	mv -f miniperl miniperl-target
+	ln -s hostperl miniperl
 !NO!SUBS!
 		;;
 	next4*)
@@ -779,7 +780,8 @@
 miniperl$(EXE_EXT): $& miniperlmain$(OBJ_EXT) $(mini_obj) perlmini$(OBJ_EXT) opmini$(OBJ_EXT)
 	$(CC) -o miniperl$(EXE_EXT) $(mini_obj) \
 	    miniperlmain$(OBJ_EXT) opmini$(OBJ_EXT) perlmini$(OBJ_EXT) $(libs)
-	$(LDLIBPTH) $(RUN) ./miniperl$(HOST_EXE_EXT) -w -Ilib -MExporter -e '<?>' || $(MAKE) minitest
+	mv -f miniperl miniperl-target
+	ln -s hostperl miniperl
 !NO!SUBS!
 		;;
 	darwin*)
@@ -801,7 +803,8 @@
 	$(CC) $(CLDFLAGS) $(NAMESPACEFLAGS) -o miniperl$(EXE_EXT) \
 	    $(mini_obj) \
 	    miniperlmain$(OBJ_EXT) opmini$(OBJ_EXT) perlmini$(OBJ_EXT) $(libs)
-	$(LDLIBPTH) $(RUN) ./miniperl$(HOST_EXE_EXT) -w -Ilib -MExporter -e '<?>' || $(MAKE) minitest
+	mv -f miniperl miniperl-target
+	ln -s hostperl miniperl
 !NO!SUBS!
 		;;
 	*)
@@ -811,7 +814,8 @@
 	$(LDLIBPTH) $(CC) $(CLDFLAGS) -o miniperl$(EXE_EXT) \
 	    $(mini_obj) \
 	    miniperlmain$(OBJ_EXT) opmini$(OBJ_EXT) perlmini$(OBJ_EXT) $(libs)
-	$(LDLIBPTH) $(RUN) ./miniperl$(HOST_EXE_EXT) -w -Ilib -MExporter -e '<?>' || $(MAKE) minitest
+	mv -f miniperl miniperl-target
+	ln -s hostperl miniperl
 !NO!SUBS!
 		;;
 	esac
@@ -979,55 +983,55 @@
 # We need to autosplit in two steps because VOS can't handle so many args
 #
 .PHONY: preplibrary
-preplibrary: miniperl$(EXE_EXT) $(CONFIGPM) lib/lib.pm $(PREPLIBRARY_LIBPERL)
+preplibrary: $(CONFIGPM) lib/lib.pm $(PREPLIBRARY_LIBPERL)
 	@sh ./makedir lib/auto
 	@echo "	AutoSplitting perl library"
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib -MAutoSplit -MFile::Find -e 'find ({no_chdir=>1, wanted => sub {autosplit_lib_modules($$_) if /\.pm$$/}}, "lib")'
 	$(MAKE) lib/re.pm
 
-$(CONFIGPM_FROM_CONFIG_SH) $(CONFIGPOD): config.sh miniperl$(EXE_EXT) configpm Porting/Glossary lib/Config_git.pl
+$(CONFIGPM_FROM_CONFIG_SH) $(CONFIGPOD): config.sh configpm Porting/Glossary lib/Config_git.pl
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib configpm
 
-lib/ExtUtils/Miniperl.pm: miniperlmain.c miniperl$(EXE_EXT) minimod.pl $(CONFIGPM)
+lib/ExtUtils/Miniperl.pm: miniperlmain.c minimod.pl $(CONFIGPM)
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) minimod.pl > lib/ExtUtils/Miniperl.pm
 
 lib/re.pm: ext/re/re.pm
 	@-rm -f $@
 	cp ext/re/re.pm lib/re.pm
 
-$(plextract):	miniperl$(EXE_EXT) $(CONFIGPM) x2p/s2p
+$(plextract): $(CONFIGPM) x2p/s2p
 	@-rm -f $@
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -I"`pwd`/lib" $@.PL
 
-x2p/s2p: miniperl$(EXE_EXT) $(CONFIGPM) x2p/s2p.PL
+x2p/s2p: $(CONFIGPM) x2p/s2p.PL
 	cd x2p; $(LDLIBPTH) $(MAKE) s2p
 
-lib/lib.pm:	miniperl$(EXE_EXT) $(CONFIGPM)
+lib/lib.pm: $(CONFIGPM)
 	@-rm -f $@
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib lib/lib_pm.PL
 
 unidatafiles $(unidatafiles): uni.data
 
-uni.data: miniperl$(EXE_EXT) $(CONFIGPM) lib/unicore/mktables
+uni.data: $(CONFIGPM) lib/unicore/mktables
 	cd lib/unicore && $(LDLIBPTH) $(RUN) ../../miniperl$(EXE_EXT) -I../../lib mktables -w
 	touch uni.data
 
 # perl$(EXE_EXT) and ext because buildtoc uses Text::Wrap uses re
 # But also this ensures that all extensions are built before we try to scan
 # them, which picks up Devel::PPPort's documentation.
-pod/perltoc.pod: $(perltoc_pod_prereqs) perl$(EXE_EXT) $(ext) pod/buildtoc
-	$(LDLIBPTH) $(RUN) ./perl$(EXE_EXT) -Ilib pod/buildtoc --build-toc -q
+pod/perltoc.pod: $(perltoc_pod_prereqs) $(ext) pod/buildtoc
+	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib pod/buildtoc --build-toc -q
 
-pod/perlapi.pod pod/perlintern.pod: miniperl$(EXE_EXT) autodoc.pl embed.fnc
+pod/perlapi.pod pod/perlintern.pod: autodoc.pl embed.fnc
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib autodoc.pl
 
-pod/perlmodlib.pod: miniperl$(EXE_EXT) pod/perlmodlib.PL MANIFEST
+pod/perlmodlib.pod: pod/perlmodlib.PL MANIFEST
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib pod/perlmodlib.PL -q
 
 pod/perldelta.pod: pod/perl5101delta.pod
 	$(LNS) perl5101delta.pod pod/perldelta.pod
 
-extra.pods: miniperl$(EXE_EXT)
+extra.pods:
 	-@test ! -f extra.pods || rm -f `cat extra.pods`
 	-@rm -f extra.pods
 	-@for x in `grep -l '^=[a-z]' README.* | grep -v README.vms` ; do \
@@ -1070,11 +1074,7 @@
 INSTALL_DEPENDENCE = all
 
 install.perl:	$(INSTALL_DEPENDENCE) installperl
-	$(LDLIBPTH) $(RUN) ./perl installperl --destdir=$(DESTDIR) $(INSTALLFLAGS) $(STRIPFLAGS)
-	-@test ! -s extras.lst || $(MAKE) extras.install
-
-install.man:	all installman
-	$(LDLIBPTH) $(RUN) ./perl installman --destdir=$(DESTDIR) $(INSTALLFLAGS)
+	./hostperl -Ifake_config_library -Ilib -MConfig installperl $(INSTALLFLAGS) $(STRIPFLAGS)
 
 # XXX Experimental. Hardwired values, but useful for testing.
 # Eventually Configure could ask for some of these values.
@@ -1171,16 +1171,16 @@
 #
 # DynaLoader may be needed for extensions that use Makefile.PL.
 
-$(DYNALOADER):	miniperl$(EXE_EXT) preplibrary FORCE
+$(DYNALOADER): preplibrary FORCE
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib make_ext.pl $@ MAKE=$(MAKE) LIBPERL_A=$(LIBPERL) LINKTYPE=static $(STATIC_LDFLAGS)
 
-d_dummy $(dynamic_ext):	miniperl$(EXE_EXT) preplibrary makeppport $(DYNALOADER) FORCE
+d_dummy $(dynamic_ext): preplibrary makeppport $(DYNALOADER) FORCE
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib make_ext.pl $@ MAKE=$(MAKE) LIBPERL_A=$(LIBPERL) LINKTYPE=dynamic
 
-s_dummy $(static_ext):	miniperl$(EXE_EXT) preplibrary makeppport $(DYNALOADER) FORCE
+s_dummy $(static_ext): preplibrary makeppport $(DYNALOADER) FORCE
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib make_ext.pl $@ MAKE=$(MAKE) LIBPERL_A=$(LIBPERL) LINKTYPE=static $(STATIC_LDFLAGS)
 
-n_dummy $(nonxs_ext):	miniperl$(EXE_EXT) preplibrary FORCE
+n_dummy $(nonxs_ext): preplibrary FORCE
 	$(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib make_ext.pl $@ MAKE=$(MAKE) LIBPERL_A=$(LIBPERL)
 !NO!SUBS!
 
@@ -1353,7 +1353,7 @@
 
 test_prep_pre: preplibrary utilities $(nonxs_ext)
 
-test_prep: test_prep_pre miniperl$(EXE_EXT) $(unidatafiles) perl$(EXE_EXT) $(dynamic_ext) $(TEST_PERL_DLL)
+test_prep: test_prep_pre $(unidatafiles) perl$(EXE_EXT) $(dynamic_ext) $(TEST_PERL_DLL)
 	PERL=./perl $(MAKE) _test_prep
 
 _test_tty:
@@ -1467,7 +1467,7 @@
 
 # Can't depend on lib/Config.pm because that might be where miniperl
 # is crashing.
-minitest: miniperl$(EXE_EXT) lib/re.pm minitest.prep
+minitest: lib/re.pm minitest.prep
 	- cd t && (rm -f perl$(EXE_EXT); $(LNS) ../miniperl$(EXE_EXT) perl$(EXE_EXT)) \
 		&& $(LDLIBPTH) $(RUN) ./perl TEST -minitest base/*.t comp/*.t cmd/*.t run/*.t io/*.t op/*.t uni/*.t </dev/tty