diff options
author | Vadim Konovalov <vkonovalov@lucent.com> | 2005-06-12 10:09:11 -0400 |
---|---|---|
committer | H.Merijn Brand <h.m.brand@xs4all.nl> | 2005-06-12 09:54:07 +0000 |
commit | 595589fae4479595ffd0993d9a9d2e00eaaa1581 (patch) | |
tree | 5e03abd1ae5a81b9b8f12ad80418fa1362b074b1 /win32 | |
parent | bdd93743ce6a66a641e3c8f924cdb4f32d64381c (diff) | |
download | perl-595589fae4479595ffd0993d9a9d2e00eaaa1581.tar.gz |
improve static build for win32/Makefile
Message-Id: <1118599750.2732.2.camel@mdk10>
p4raw-id: //depot/perl@24806
Diffstat (limited to 'win32')
-rw-r--r-- | win32/Makefile | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/win32/Makefile b/win32/Makefile index aa254a782c..8ba95a5117 100644 --- a/win32/Makefile +++ b/win32/Makefile @@ -695,6 +695,9 @@ PERLDLL_OBJ = $(PERLDLL_OBJ) $(WIN32_OBJ) $(DLL_OBJ) SETARGV_OBJ = setargv$(o) !ENDIF +# specify static extensions here +STATIC_EXT = Cwd Compress/Zlib + DYNALOADER = $(EXTDIR)\DynaLoader\DynaLoader SOCKET = $(EXTDIR)\Socket\Socket FCNTL = $(EXTDIR)\Fcntl\Fcntl @@ -949,11 +952,13 @@ $(DLL_OBJ) : $(CORE_H) $(X2P_OBJ) : $(CORE_H) perldll.def : $(MINIPERL) $(CONFIGPM) ..\global.sym ..\pp.sym ..\makedef.pl + $(MINIPERL) -I..\lib buildext.pl --create-perllibst-h $(MINIPERL) -w ..\makedef.pl PLATFORM=win32 $(OPTIMIZE) $(DEFINES) $(BUILDOPT) \ CCTYPE=$(CCTYPE) > perldll.def -$(PERLDLL): perldll.def $(PERLDLL_OBJ) $(PERLDLL_RES) - $(LINK32) -dll -def:perldll.def -base:0x28000000 -out:$@ @<< +$(PERLDLL): perldll.def $(PERLDLL_OBJ) $(PERLDLL_RES) Extensions_static + $(MINIPERL) -I..\lib buildext.pl --list-static-libs > stat-exts.tmp + $(LINK32) -dll -def:perldll.def -base:0x28000000 -out:$@ @stat-exts.tmp @<< $(LINK_FLAGS) $(DELAYLOAD) $(LIBFILES) $(PERLDLL_OBJ) $(PERLDLL_RES) << $(XCOPY) $(PERLIMPLIB) $(COREDIR) @@ -1021,8 +1026,12 @@ $(EXTDIR)\DynaLoader\dl_win32.xs: dl_win32.xs #------------------------------------------------------------------------------- Extensions: buildext.pl $(PERLDEP) $(CONFIGPM) - $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) - $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext + $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) --dynamic + $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext --dynamic + +Extensions_static : buildext.pl + $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext --static + $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) --static Extensions_clean: -if exist $(MINIPERL) $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) clean @@ -1101,6 +1110,7 @@ distclean: realclean -del /f $(MINIPERL) $(PERLEXE) $(PERLDLL) $(GLOBEXE) \ $(PERLIMPLIB) ..\miniperl.lib $(MINIMOD) -del /f *.def *.map + -del /f stat-exts.tmp -del /f $(EXTENSION_DLL) -del /f $(EXTENSION_C) $(DYNALOADER).c $(ERRNO).pm -del /f $(EXTDIR)\DynaLoader\dl_win32.xs |