2 # Makefile to build perl on Windows NT using Microsoft NMAKE.
4 # Visual C++ 5.x (possibly other versions)
6 # This is set up to build a perl.exe that runs off a shared library
7 # (perl57.dll). Also makes individual DLLs for the XS extensions.
11 ## Make sure you read README.win32 *before* you mess with anything here!
15 ## Build configuration. Edit the values below to suit your needs.
19 # Set these to wherever you want "nmake install" to put your
23 INST_TOP = $(INST_DRV)\perl
26 # Comment this out if you DON'T want your perl installation to be versioned.
27 # This means that the new installation will overwrite any files from the
28 # old installation at the same INST_TOP location. Leaving it enabled is
29 # the safest route, as perl adds the extra version directory to all the
30 # locations it installs files to. If you disable it, an alternative
31 # versioned installation can be obtained by setting INST_TOP above to a
32 # path that includes an arbitrary version string.
37 # Comment this out if you DON'T want your perl installation to have
38 # architecture specific components. This means that architecture-
39 # specific files will be installed along with the architecture-neutral
40 # files. Leaving it enabled is safer and more flexible, in case you
41 # want to build multiple flavors of perl and install them together in
42 # the same location. Commenting it out gives you a simpler
43 # installation that is easier to understand for beginners.
45 #INST_ARCH = \$(ARCHNAME)
48 # uncomment to enable multiple interpreters. This is need for fork()
54 # Beginnings of interpreter cloning/threads; still very incomplete.
55 # This should be enabled to get the fork() emulation. This needs
61 # uncomment to enable the implicit "host" layer for all system calls
62 # made by perl. This needs USE_MULTI above. This is also needed to
68 # uncomment to enable the experimental PerlIO I/O subsystem.
72 # WARNING! This option is deprecated and will eventually go away (enable
73 # USE_ITHREADS instead).
75 # uncomment to enable threads-capabilities. This is incompatible with
76 # USE_ITHREADS, and is only here for people who may have come to rely
77 # on the experimental Thread support that was in 5.005.
79 #USE_5005THREADS = define
82 # WARNING! This option is deprecated and will eventually go away (enable
85 # uncomment next line if you want to use the PERL_OBJECT build option.
86 # DO NOT ENABLE unless you have legacy code that relies on the C++
87 # CPerlObj class that was available in 5.005. This cannot be enabled
88 # if you ask for USE_5005THREADS above.
93 # uncomment one of the following lines if you are using either
94 # Visual C++ 2.x or Visual C++ 6.x (aka Visual Studio 98)
100 # uncomment next line if you want debug version of perl (big,slow)
105 # uncomment to enable use of PerlCRT.DLL when using the Visual C compiler.
106 # It has patches that fix known bugs in older versions of MSVCRT.DLL.
107 # This currently requires VC 5.0 with Service Pack 3 or later.
108 # Get it from CPAN at http://www.perl.com/CPAN/authors/id/D/DO/DOUGL/
109 # and follow the directions in the package to install.
111 # Not recommended if you have VC 6.x and you're not running Windows 9x.
113 #USE_PERLCRT = define
116 # uncomment to enable linking with setargv.obj under the Visual C
117 # compiler. Setting this options enables perl to expand wildcards in
118 # arguments, but it may be harder to use alternate methods like
119 # File::DosGlob that are more powerful. This option is supported only with
122 #USE_SETARGV = define
125 # if you have the source for des_fcrypt(), uncomment this and make sure the
126 # file exists (see README.win32). File should be located in the same
127 # directory as this file.
129 #CRYPT_SRC = fcrypt.c
132 # if you didn't set CRYPT_SRC and if you have des_fcrypt() available in a
133 # library, uncomment this, and make sure the library exists (see README.win32)
134 # Specify the full pathname of the library.
136 #CRYPT_LIB = fcrypt.lib
139 # set this if you wish to use perl's malloc
140 # WARNING: Turning this on/off WILL break binary compatibility with extensions
141 # you may have compiled with/without it. Be prepared to recompile all
142 # extensions if you change the default. Currently, this cannot be enabled
143 # if you ask for USE_IMP_SYS above.
145 #PERL_MALLOC = define
148 # set the install locations of the compiler include/libraries
149 # Running VCVARS32.BAT is *required* when using Visual C.
150 # Some versions of Visual C don't define MSVCDIR in the environment,
151 # so you may have to set CCHOME explicitly (spaces in the path name should
156 CCINCDIR = $(CCHOME)\include
157 CCLIBDIR = $(CCHOME)\lib
160 # Additional compiler flags can be specified here.
164 # This should normally be disabled. Adding -DPERL_POLLUTE enables support
165 # for old symbols by default, at the expense of extreme pollution. You most
166 # probably just want to build modules that won't compile with
167 # perl Makefile.PL POLLUTE=1
168 # instead of enabling this. Please report such modules to the respective
171 #BUILDOPT = $(BUILDOPT) -DPERL_POLLUTE
174 # This should normally be disabled. Enabling it will disable the File::Glob
175 # implementation of CORE::glob.
177 #BUILDOPT = $(BUILDOPT) -DPERL_EXTERNAL_GLOB
180 # This should normally be disabled. Enabling it causes perl to read scripts
181 # in text mode (which is the 5.005 behavior) and will break ByteLoader.
182 #BUILDOPT = $(BUILDOPT) -DPERL_TEXTMODE_SCRIPTS
185 # specify semicolon-separated list of extra directories that modules will
186 # look for libraries (spaces in path names need not be quoted)
191 # set this to your email address (perl will guess a value from
192 # from your loginname and your hostname, which may not be right)
197 ## Build configuration ends.
200 ##################### CHANGE THESE ONLY IF YOU MUST #####################
202 !IF "$(CRYPT_SRC)$(CRYPT_LIB)" == ""
206 CRYPT_FLAG = -DHAVE_DES_FCRYPT
209 !IF "$(USE_OBJECT)" == "define"
211 USE_5005THREADS = undef
216 !IF "$(PERL_MALLOC)" == ""
220 !IF "$(USE_5005THREADS)" == ""
221 USE_5005THREADS = undef
224 !IF "$(USE_5005THREADS)" == "define"
228 !IF "$(USE_IMP_SYS)" == "define"
232 !IF "$(USE_MULTI)" == ""
236 !IF "$(USE_OBJECT)" == ""
240 !IF "$(USE_ITHREADS)" == ""
244 !IF "$(USE_IMP_SYS)" == ""
248 !IF "$(USE_PERLIO)" == ""
252 !IF "$(USE_PERLCRT)" == ""
256 !IF "$(USE_IMP_SYS)$(USE_MULTI)$(USE_5005THREADS)$(USE_OBJECT)" == "defineundefundefundef"
260 !IF "$(USE_ITHREADS)$(USE_MULTI)$(USE_OBJECT)" == "defineundefundef"
262 USE_5005THREADS = undef
265 !IF "$(USE_MULTI)$(USE_5005THREADS)$(USE_OBJECT)" != "undefundefundef"
266 BUILDOPT = $(BUILDOPT) -DPERL_IMPLICIT_CONTEXT
269 !IF "$(USE_IMP_SYS)" != "undef"
270 BUILDOPT = $(BUILDOPT) -DPERL_IMPLICIT_SYS
273 !IF "$(PROCESSOR_ARCHITECTURE)" == ""
274 PROCESSOR_ARCHITECTURE = x86
277 !IF "$(USE_OBJECT)" == "define"
278 ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-object
280 !IF "$(USE_5005THREADS)" == "define"
281 ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-thread
283 !IF "$(USE_MULTI)" == "define"
284 ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-multi
286 !IF "$(USE_PERLIO)" == "define"
287 ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-perlio
289 ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)
295 !IF "$(USE_PERLIO)" == "define"
296 BUILDOPT = $(BUILDOPT) -DUSE_PERLIO
299 !IF "$(USE_ITHREADS)" == "define"
300 ARCHNAME = $(ARCHNAME)-thread
303 # Visual Studio 98 specific
304 !IF "$(CCTYPE)" == "MSVC60"
306 # VC 6.0 can load the socket dll on demand. Makes the test suite
307 # run in about 10% less time.
308 DELAYLOAD = -DELAYLOAD:wsock32.dll -DELAYLOAD:shell32.dll delayimp.lib
311 ARCHDIR = ..\lib\$(ARCHNAME)
312 COREDIR = ..\lib\CORE
313 AUTODIR = ..\lib\auto
317 EXTUTILSDIR = $(LIBDIR)\ExtUtils
320 INST_SCRIPT = $(INST_TOP)$(INST_VER)\bin
321 INST_BIN = $(INST_SCRIPT)$(INST_ARCH)
322 INST_LIB = $(INST_TOP)$(INST_VER)\lib
323 INST_ARCHLIB = $(INST_LIB)$(INST_ARCH)
324 INST_COREDIR = $(INST_ARCHLIB)\CORE
325 INST_POD = $(INST_LIB)\pod
326 INST_HTML = $(INST_TOP)$(INST_VER)\html
329 # Programs to compile, build .lib files and link
334 LIB32 = $(LINK32) -lib
341 INCLUDES = -I$(COREDIR) -I.\include -I. -I..
342 #PCHFLAGS = -Fpc:\temp\vcmoduls.pch -YX
343 DEFINES = -DWIN32 -D_CONSOLE -DNO_STRICT $(CRYPT_FLAG)
344 LOCDEFS = -DPERLDLL -DPERL_CORE
348 !IF "$(USE_PERLCRT)" != "define"
357 !IF "$(CFG)" == "Debug"
358 ! IF "$(CCTYPE)" == "MSVC20"
359 OPTIMIZE = -Od -MD -Z7 -DDEBUGGING
361 OPTIMIZE = -Od -MD -Zi -DDEBUGGING
363 LINK_DBG = -debug -pdb:none
365 # -O1 yields smaller code, which turns out to be faster than -O2
366 #OPTIMIZE = -O2 -MD -DNDEBUG
367 OPTIMIZE = -O1 -MD -DNDEBUG
371 !IF "$(USE_OBJECT)" == "define"
372 OPTIMIZE = $(OPTIMIZE) $(CXX_FLAG)
373 BUILDOPT = $(BUILDOPT) -DPERL_OBJECT
376 !IF "$(USE_PERLCRT)" != "define"
377 BUILDOPT = $(BUILDOPT) -DPERL_MSVCRT_READFIX
380 LIBBASEFILES = $(CRYPT_LIB) \
381 oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib \
382 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib \
383 netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib \
384 version.lib odbc32.lib odbccp32.lib
386 # we add LIBC here, since we may be using PerlCRT.dll
387 LIBFILES = $(LIBBASEFILES) $(LIBC)
389 CFLAGS = -nologo -Gf -W3 $(INCLUDES) $(DEFINES) $(LOCDEFS) \
390 $(PCHFLAGS) $(OPTIMIZE)
391 LINK_FLAGS = -nologo -nodefaultlib $(LINK_DBG) \
392 -libpath:"$(INST_COREDIR)" \
393 -machine:$(PROCESSOR_ARCHITECTURE)
397 CFLAGS_O = $(CFLAGS) $(BUILDOPT)
399 #################### do not edit below this line #######################
400 ############# NO USER-SERVICEABLE PARTS BEYOND THIS POINT ##############
408 .SUFFIXES : .c $(o) .dll .lib .exe .rc .res
411 $(CC) -c -I$(<D) $(CFLAGS_O) $(OBJOUT_FLAG)$@ $<
417 $(LINK32) -dll -subsystem:windows -implib:$(*B).lib -def:$(*B).def \
418 -out:$@ $(LINK_FLAGS) $(LIBFILES) $< $(LIBPERL)
426 # makedef.pl must be updated if this changes, and this should normally
427 # only change when there is an incompatible revision of the public API.
428 # XXX so why did we change it from perl56 to perl57?
429 PERLIMPLIB = ..\perl57.lib
430 PERLDLL = ..\perl57.dll
432 MINIPERL = ..\miniperl.exe
434 PERLEXE = ..\perl.exe
435 WPERLEXE = ..\wperl.exe
436 GLOBEXE = ..\perlglob.exe
437 CONFIGPM = ..\lib\Config.pm
438 MINIMOD = ..\lib\ExtUtils\Miniperl.pm
441 # Nominate a target which causes extensions to be re-built
442 # This used to be $(PERLEXE), but at worst it is the .dll that they depend
443 # on and really only the interface - i.e. the .def file used to export symbols
445 PERLDEP = perldll.def
447 PL2BAT = bin\pl2bat.pl
448 GLOBBAT = bin\perlglob.bat
479 CFGSH_TMPL = config.vc
480 CFGH_TMPL = config_H.vc
482 XCOPY = xcopy /f /r /i /d
483 RCOPY = xcopy /f /r /i /e /d
487 DEL = bin\mdelete.bat
490 # filenames given to xsubpp must have forward slashes (since it puts
491 # full pathnames in #line strings)
492 XSUBPP = ..\$(MINIPERL) -I..\..\lib ..\$(EXTUTILSDIR)\xsubpp \
525 EXTRACORE_SRC = $(EXTRACORE_SRC) perllib.c
527 !IF "$(PERL_MALLOC)" == "define"
528 EXTRACORE_SRC = $(EXTRACORE_SRC) ..\malloc.c
531 !IF "$(USE_OBJECT)" != "define"
532 EXTRACORE_SRC = $(EXTRACORE_SRC) ..\perlio.c
540 !IF "$(CRYPT_SRC)" != ""
541 WIN32_SRC = $(WIN32_SRC) .\$(CRYPT_SRC)
544 DLL_SRC = $(DYNALOADER).c
590 .\include\sys\socket.h \
593 CORE_H = $(CORE_NOCFG_H) .\config.h
595 MICROCORE_OBJ = $(MICROCORE_SRC:.c=.obj)
596 CORE_OBJ = $(MICROCORE_OBJ) $(EXTRACORE_SRC:.c=.obj)
597 WIN32_OBJ = $(WIN32_SRC:.c=.obj)
598 MINICORE_OBJ = $(MICROCORE_OBJ:..\=.\mini\) \
599 $(MINIDIR)\miniperlmain$(o) \
600 $(MINIDIR)\perlio$(o)
601 MINIWIN32_OBJ = $(WIN32_OBJ:.\=.\mini\)
602 MINI_OBJ = $(MINICORE_OBJ) $(MINIWIN32_OBJ)
603 DLL_OBJ = $(DLL_SRC:.c=.obj)
604 X2P_OBJ = $(X2P_SRC:.c=.obj)
606 PERLDLL_OBJ = $(CORE_OBJ)
607 PERLEXE_OBJ = perlmain$(o)
609 PERLDLL_OBJ = $(PERLDLL_OBJ) $(WIN32_OBJ) $(DLL_OBJ)
610 #PERLEXE_OBJ = $(PERLEXE_OBJ) $(WIN32_OBJ) $(DLL_OBJ)
612 !IF "$(USE_SETARGV)" != ""
613 SETARGV_OBJ = setargv$(o)
616 DYNALOADER = $(EXTDIR)\DynaLoader\DynaLoader
617 SOCKET = $(EXTDIR)\Socket\Socket
618 FCNTL = $(EXTDIR)\Fcntl\Fcntl
619 OPCODE = $(EXTDIR)\Opcode\Opcode
620 SDBM_FILE = $(EXTDIR)\SDBM_File\SDBM_File
622 POSIX = $(EXTDIR)\POSIX\POSIX
623 ATTRS = $(EXTDIR)\attrs\attrs
624 THREAD = $(EXTDIR)\Thread\Thread
627 DUMPER = $(EXTDIR)\Data\Dumper\Dumper
628 ERRNO = $(EXTDIR)\Errno\Errno
629 PEEK = $(EXTDIR)\Devel\Peek\Peek
630 BYTELOADER = $(EXTDIR)\ByteLoader\ByteLoader
631 DPROF = $(EXTDIR)\Devel\DProf\DProf
632 GLOB = $(EXTDIR)\File\Glob\Glob
633 HOSTNAME = $(EXTDIR)\Sys\Hostname\Hostname
634 STORABLE = $(EXTDIR)\Storable\Storable
635 FILTER = $(EXTDIR)\Filter\Util\Call\Call
636 ENCODE = $(EXTDIR)\Encode\Encode
637 MD5 = $(EXTDIR)\Digest\MD5\MD5
638 PERLIOSCALAR = $(EXTDIR)\PerlIO\Scalar\Scalar
639 MIMEBASE64 = $(EXTDIR)\MIME\Base64\Base64
640 TIMEHIRES = $(EXTDIR)\Time\HiRes\HiRes
641 TIMEPIECE = $(EXTDIR)\Time\Piece\Piece
642 CWD = $(EXTDIR)\Cwd\Cwd
643 LISTUTIL = $(EXTDIR)\List\Util\Util
644 PERLIOVIA = $(EXTDIR)\PerlIO\Via\Via
645 XSTYPEMAP = $(EXTDIR)\XS\Typemap\Typemap
647 SOCKET_DLL = $(AUTODIR)\Socket\Socket.dll
648 FCNTL_DLL = $(AUTODIR)\Fcntl\Fcntl.dll
649 OPCODE_DLL = $(AUTODIR)\Opcode\Opcode.dll
650 SDBM_FILE_DLL = $(AUTODIR)\SDBM_File\SDBM_File.dll
651 IO_DLL = $(AUTODIR)\IO\IO.dll
652 POSIX_DLL = $(AUTODIR)\POSIX\POSIX.dll
653 ATTRS_DLL = $(AUTODIR)\attrs\attrs.dll
654 THREAD_DLL = $(AUTODIR)\Thread\Thread.dll
655 B_DLL = $(AUTODIR)\B\B.dll
656 DUMPER_DLL = $(AUTODIR)\Data\Dumper\Dumper.dll
657 PEEK_DLL = $(AUTODIR)\Devel\Peek\Peek.dll
658 RE_DLL = $(AUTODIR)\re\re.dll
659 BYTELOADER_DLL = $(AUTODIR)\ByteLoader\ByteLoader.dll
660 DPROF_DLL = $(AUTODIR)\Devel\DProf\DProf.dll
661 GLOB_DLL = $(AUTODIR)\File\Glob\Glob.dll
662 HOSTNAME_DLL = $(AUTODIR)\Sys\Hostname\Hostname.dll
663 STORABLE_DLL = $(AUTODIR)\Storable\Storable.dll
664 FILTER_DLL = $(AUTODIR)\Filter\Util\Call\Call.dll
665 ENCODE_DLL = $(AUTODIR)\Encode\Encode.dll
666 MD5_DLL = $(AUTODIR)\Digest\MD5\MD5.dll
667 PERLIOSCALAR_DLL= $(AUTODIR)\PerlIO\Scalar\Scalar.dll
668 MIMEBASE64_DLL = $(AUTODIR)\MIME\Base64\Base64.dll
669 TIMEHIRES_DLL = $(AUTODIR)\Time\HiRes\HiRes.dll
670 TIMEPIECE_DLL = $(AUTODIR)\Time\Piece\Piece.dll
671 CWD_DLL = $(AUTODIR)\Cwd\Cwd.dll
672 LISTUTIL_DLL = $(AUTODIR)\List\Util\Util.dll
673 PERLIOVIA_DLL = $(AUTODIR)\PerlIO\Via\Via.dll
674 XSTYPEMAP_DLL = $(AUTODIR)\XS\Typemap\Typemap.dll
727 $(PERLIOSCALAR_DLL) \
736 POD2HTML = $(PODDIR)\pod2html
737 POD2MAN = $(PODDIR)\pod2man
738 POD2LATEX = $(PODDIR)\pod2latex
739 POD2TEXT = $(PODDIR)\pod2text
742 "INST_DRV=$(INST_DRV)" \
743 "INST_TOP=$(INST_TOP)" \
744 "INST_VER=$(INST_VER)" \
745 "INST_ARCH=$(INST_ARCH)" \
746 "archname=$(ARCHNAME)" \
749 "ccflags=-nologo -Gf -W3 $(OPTIMIZE:"=\") $(DEFINES) $(BUILDOPT)" \
750 "cf_email=$(EMAIL)" \
751 "d_crypt=$(D_CRYPT)" \
752 "d_mymalloc=$(PERL_MALLOC)" \
754 "incpath=$(CCINCDIR:"=\")" \
755 "libperl=$(PERLIMPLIB:..\=)" \
756 "libpth=$(CCLIBDIR:"=\");$(EXTRALIBDIRS:"=\")" \
758 "make=$(MAKE_BARE)" \
759 "use5005threads=$(USE_5005THREADS)" \
760 "useithreads=$(USE_ITHREADS)" \
761 "usethreads=$(USE_5005THREADS)" \
762 "usemultiplicity=$(USE_MULTI)" \
763 "useperlio=$(USE_PERLIO)" \
764 "LINK_FLAGS=$(LINK_FLAGS:"=\")" \
765 "optimize=$(OPTIMIZE:"=\")"
771 all : .\config.h $(GLOBEXE) $(MINIMOD) $(CONFIGPM) $(PERLEXE) \
773 @echo Everything is up to date. '$(MAKE_BARE) test' to run test suite.
775 $(DYNALOADER)$(o) : $(DYNALOADER).c $(CORE_H) $(EXTDIR)\DynaLoader\dlutils.c
777 #------------------------------------------------------------
779 $(GLOBEXE) : perlglob$(o)
780 $(LINK32) $(LINK_FLAGS) $(LIBFILES) -out:$@ -subsystem:$(SUBSYS) \
781 perlglob$(o) setargv$(o)
783 perlglob$(o) : perlglob.c
785 config.w32 : $(CFGSH_TMPL)
786 copy $(CFGSH_TMPL) config.w32
788 .\config.h : $(CFGH_TMPL)
790 copy $(CFGH_TMPL) config.h
792 ..\config.sh : config.w32 $(MINIPERL) config_sh.PL
793 $(MINIPERL) -I..\lib config_sh.PL $(CFG_VARS) config.w32 > ..\config.sh
795 # this target is for when changes to the main config.sh happen
796 # edit config.{b,v,g}c and make this target once for each supported
797 # compiler (e.g. `nmake CCTYPE=BORLAND regen_config_h`)
799 perl config_sh.PL $(CFG_VARS) $(CFGSH_TMPL) > ..\config.sh
806 -perl -I..\lib config_h.PL "INST_VER=$(INST_VER)"
807 rename config.h $(CFGH_TMPL)
809 $(CONFIGPM) : $(MINIPERL) ..\config.sh config_h.PL ..\minimod.pl
813 if exist lib\* $(RCOPY) lib\*.* ..\lib\$(NULL)
814 $(XCOPY) ..\*.h $(COREDIR)\*.*
815 $(XCOPY) *.h $(COREDIR)\*.*
816 $(XCOPY) ..\ext\re\re.pm $(LIBDIR)\*.*
817 $(RCOPY) include $(COREDIR)\*.*
818 -$(MINIPERL) -I..\lib config_h.PL "INST_VER=$(INST_VER)"
819 if errorlevel 1 $(MAKE) /$(MAKEFLAGS) $(CONFIGPM)
821 $(MINIPERL) : $(MINIDIR) $(MINI_OBJ)
822 $(LINK32) -subsystem:console -out:$@ @<<
823 $(LINK_FLAGS) $(LIBFILES) $(MINI_OBJ)
827 if not exist "$(MINIDIR)" mkdir "$(MINIDIR)"
829 $(MINICORE_OBJ) : $(CORE_NOCFG_H)
830 $(CC) -c $(CFLAGS) -DPERL_EXTERNAL_GLOB $(OBJOUT_FLAG)$@ ..\$(*F).c
832 $(MINIWIN32_OBJ) : $(CORE_NOCFG_H)
833 $(CC) -c $(CFLAGS) $(OBJOUT_FLAG)$@ $(*F).c
835 # -DPERL_IMPLICIT_SYS needs C++ for perllib.c
836 # This is the only file that depends on perlhost.h, vmem.h, and vdir.h
837 !IF "$(USE_IMP_SYS)$(USE_OBJECT)" == "defineundef"
838 perllib$(o) : perllib.c .\perlhost.h .\vdir.h .\vmem.h
839 $(CC) -c -I. $(CFLAGS_O) $(CXX_FLAG) $(OBJOUT_FLAG)$@ perllib.c
842 # 1. we don't want to rebuild miniperl.exe when config.h changes
843 # 2. we don't want to rebuild miniperl.exe with non-default config.h
844 $(MINI_OBJ) : $(CORE_NOCFG_H)
846 $(WIN32_OBJ) : $(CORE_H)
847 $(CORE_OBJ) : $(CORE_H)
848 $(DLL_OBJ) : $(CORE_H)
849 $(X2P_OBJ) : $(CORE_H)
851 perldll.def : $(MINIPERL) $(CONFIGPM) ..\global.sym ..\pp.sym ..\makedef.pl
852 $(MINIPERL) -w ..\makedef.pl PLATFORM=win32 $(OPTIMIZE) $(DEFINES) $(BUILDOPT) \
853 CCTYPE=$(CCTYPE) > perldll.def
855 $(PERLDLL): perldll.def $(PERLDLL_OBJ) $(PERLDLL_RES)
856 $(LINK32) -dll -def:perldll.def -base:0x28000000 -out:$@ @<<
857 $(LINK_FLAGS) $(DELAYLOAD) $(LIBFILES) $(PERLDLL_OBJ) $(PERLDLL_RES)
859 $(XCOPY) $(PERLIMPLIB) $(COREDIR)
861 $(MINIMOD) : $(MINIPERL) ..\minimod.pl
863 miniperl minimod.pl > lib\ExtUtils\Miniperl.pm
866 ..\x2p\a2p$(o) : ..\x2p\a2p.c
867 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\a2p.c
869 ..\x2p\hash$(o) : ..\x2p\hash.c
870 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\hash.c
872 ..\x2p\str$(o) : ..\x2p\str.c
873 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\str.c
875 ..\x2p\util$(o) : ..\x2p\util.c
876 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\util.c
878 ..\x2p\walk$(o) : ..\x2p\walk.c
879 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\walk.c
881 $(X2P) : $(MINIPERL) $(X2P_OBJ)
882 $(MINIPERL) ..\x2p\find2perl.PL
883 $(MINIPERL) ..\x2p\s2p.PL
884 $(LINK32) -subsystem:console -out:$@ @<<
885 $(LINK_FLAGS) $(LIBFILES) $(X2P_OBJ)
888 perlmain.c : runperl.c
889 copy runperl.c perlmain.c
891 perlmain$(o) : perlmain.c
892 $(CC) $(CFLAGS_O) -UPERLDLL $(OBJOUT_FLAG)$@ -c perlmain.c
894 $(PERLEXE): $(PERLDLL) $(CONFIGPM) $(PERLEXE_OBJ) $(PERLEXE_RES)
895 $(LINK32) -subsystem:console -out:$@ -stack:0x1000000 $(LINK_FLAGS) \
896 $(LIBFILES) $(PERLEXE_OBJ) $(SETARGV_OBJ) $(PERLIMPLIB) $(PERLEXE_RES)
897 copy $(PERLEXE) $(WPERLEXE)
898 $(MINIPERL) -I..\lib bin\exetype.pl $(WPERLEXE) WINDOWS
900 $(MINIPERL) -I..\lib ..\splittree.pl "../LIB" $(AUTODIR)
902 $(DYNALOADER).c: $(MINIPERL) $(EXTDIR)\DynaLoader\dl_win32.xs $(CONFIGPM)
903 if not exist $(AUTODIR) mkdir $(AUTODIR)
905 ..\$(MINIPERL) -I..\..\lib $(*B)_pm.PL
906 ..\$(MINIPERL) -I..\..\lib XSLoader_pm.PL
908 $(XCOPY) $(EXTDIR)\$(*B)\$(*B).pm $(LIBDIR)\$(NULL)
909 $(XCOPY) $(EXTDIR)\$(*B)\XSLoader.pm $(LIBDIR)\$(NULL)
911 $(XSUBPP) dl_win32.xs > $(*B).c
914 $(EXTDIR)\DynaLoader\dl_win32.xs: dl_win32.xs
915 copy dl_win32.xs $(EXTDIR)\DynaLoader\dl_win32.xs
917 #----------------------------------------------------------------------------------
918 Extensions: buildext.pl $(PERLDEP) $(CONFIGPM)
919 $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR)
922 -if exist $(MINIPERL) $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) clean
924 #----------------------------------------------------------------------------------
927 $(PERLEXE) -I..\lib ..\installhtml --podroot=.. --htmldir=./html \
928 --podpath=pod:lib:ext:utils --htmlroot="file://$(INST_HTML::=|)" \
929 --libpod=perlfunc:perlguts:perlvar:perlrun:perlop --recurse
931 utils: $(PERLEXE) $(X2P)
933 $(MAKE) PERL=$(MINIPERL)
935 copy ..\README.aix .\perlaix.pod
936 copy ..\README.amiga .\perlamiga.pod
937 copy ..\README.bs2000 .\perlbs2000.pod
938 copy ..\README.cygwin .\perlcygwin.pod
939 copy ..\README.dos .\perldos.pod
940 copy ..\README.epoc .\perlepoc.pod
941 copy ..\README.hpux .\perlhpux.pod
942 copy ..\README.machten .\perlmachten.pod
943 copy ..\README.macos .\perlmacos.pod
944 copy ..\README.mpeix .\perlmpeix.pod
945 copy ..\README.os2 .\perlos2.pod
946 copy ..\README.os390 .\perlos390.pod
947 copy ..\README.solaris .\perlsolaris.pod
948 copy ..\README.vmesa .\perlvmesa.pod
949 copy ..\vms\perlvms.pod .\perlvms.pod
950 copy ..\README.vos .\perlvos.pod
951 copy ..\README.win32 .\perlwin32.pod
952 $(MAKE) -f ..\win32\pod.mak converters
956 $(PERLEXE) $(PL2BAT) $(UTILS)
959 -del /f $(MINIPERL) $(PERLEXE) $(PERLDLL) $(GLOBEXE) \
960 $(PERLIMPLIB) ..\miniperl.lib $(MINIMOD)
962 -del /f $(EXTENSION_DLL)
963 -del /f $(EXTENSION_C) $(DYNALOADER).c $(ERRNO).pm
964 -del /f $(EXTDIR)\DynaLoader\dl_win32.xs
965 -del /f $(LIBDIR)\.exists $(LIBDIR)\attrs.pm $(LIBDIR)\DynaLoader.pm
966 -del /f $(LIBDIR)\XSLoader.pm
967 -del /f $(LIBDIR)\Fcntl.pm $(LIBDIR)\IO.pm $(LIBDIR)\Opcode.pm
968 -del /f $(LIBDIR)\ops.pm $(LIBDIR)\Safe.pm $(LIBDIR)\Thread.pm
969 -del /f $(LIBDIR)\SDBM_File.pm $(LIBDIR)\Socket.pm $(LIBDIR)\POSIX.pm
970 -del /f $(LIBDIR)\B.pm $(LIBDIR)\O.pm $(LIBDIR)\re.pm
971 -del /f $(LIBDIR)\Data\Dumper.pm $(LIBDIR)\ByteLoader.pm
972 -del /f $(LIBDIR)\Devel\Peek.pm $(LIBDIR)\Devel\DProf.pm
973 -del /f $(LIBDIR)\File\Glob.pm
974 -del /f $(LIBDIR)\Storable.pm
975 -del /f $(LIBDIR)\Filter\Util\Call.pm
976 -del /f $(LIBDIR)\Digest\MD5.pm
977 -del /f $(LIBDIR)\PerlIO\Scalar.pm
978 -del /f $(LIBDIR)\PerlIO\Via.pm
979 -del /f $(LIBDIR)\MIME\Base64.pm
980 -del /f $(LIBDIR)\MIME\QuotedPrint.pm
981 -del /f $(LIBDIR)\List\Util.pm
982 -del /f $(LIBDIR)\Scalar\Util.pm
983 -del /f $(LIBDIR)\Time\HiRes.pm
984 -del /f $(LIBDIR)\Time\Piece.pm
985 -del /f $(LIBDIR)\Cwd.pm
986 -del /f $(LIBDIR)\XS\Typemap.pm
987 -if exist $(LIBDIR)\IO rmdir /s /q $(LIBDIR)\IO
988 -rmdir /s $(LIBDIR)\IO
989 -if exist $(LIBDIR)\Thread rmdir /s /q $(LIBDIR)\Thread
990 -rmdir /s $(LIBDIR)\Thread
991 -if exist $(LIBDIR)\B rmdir /s /q $(LIBDIR)\B
992 -rmdir /s $(LIBDIR)\B
993 -if exist $(LIBDIR)\Data rmdir /s /q $(LIBDIR)\Data
994 -rmdir /s $(LIBDIR)\Data
995 -if exist $(LIBDIR)\Filter\Util rmdir /s /q $(LIBDIR)\Filter\Util
996 -if exist $(LIBDIR)\Digest rmdir /s /q $(LIBDIR)\Digest
997 -rmdir /s $(LIBDIR)\Digest
998 -if exist $(LIBDIR)\MIME rmdir /s /q $(LIBDIR)\MIME
999 -rmdir /s $(LIBDIR)\MIME
1000 -if exist $(LIBDIR)\List rmdir /s /q $(LIBDIR)\List
1001 -rmdir /s $(LIBDIR)\List
1002 -if exist $(LIBDIR)\Scalar rmdir /s /q $(LIBDIR)\Scalar
1003 -rmdir /s $(LIBDIR)\Scalar
1004 -if exist $(LIBDIR)\XS rmdir /s /q $(LIBDIR)\XS
1005 -rmdir /s $(LIBDIR)\XS
1007 -del /f *.html *.bat checkpods \
1008 perlaix.pod perlamiga.pod perlbs2000.pod perlcygwin.pod \
1009 perldos.pod perlepoc.pod perlhpux.pod perlmachten.pod \
1010 perlmacos.pod perlmpeix.pod perlos2.pod perlos390.pod \
1011 perlsolaris.pod perlvmesa.pod perlvms.pod perlvos.pod \
1012 perlwin32.pod pod2html pod2latex pod2man pod2text pod2usage \
1013 podchecker podselect
1015 -del /f h2ph splain perlbug pl2pm c2ph h2xs perldoc dprofpp
1019 -del /f find2perl s2p
1022 -del /f ..\config.sh ..\splittree.pl perlmain.c dlutils.c config.h.new
1026 -del /s *.lib *.def *.map *.pdb *.bs Makefile *$(o) pm_to_blib
1028 -if exist $(AUTODIR) rmdir /s /q $(AUTODIR)
1029 -rmdir /s $(AUTODIR)
1030 -if exist $(COREDIR) rmdir /s /q $(COREDIR)
1031 -rmdir /s $(COREDIR)
1033 install : all installbare installhtml
1036 $(PERLEXE) ..\installperl
1037 if exist $(WPERLEXE) $(XCOPY) $(WPERLEXE) $(INST_BIN)\*.*
1038 $(XCOPY) $(GLOBEXE) $(INST_BIN)\*.*
1039 $(XCOPY) bin\*.bat $(INST_SCRIPT)\*.*
1042 $(RCOPY) html\*.* $(INST_HTML)\*.*
1044 inst_lib : $(CONFIGPM)
1045 copy splittree.pl ..
1046 $(MINIPERL) -I..\lib ..\splittree.pl "../LIB" $(AUTODIR)
1047 $(RCOPY) ..\lib $(INST_LIB)\*.*
1049 minitest : $(MINIPERL) $(GLOBEXE) $(CONFIGPM) utils
1050 $(XCOPY) $(MINIPERL) ..\t\perl.exe
1051 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
1055 $(MINIPERL) -I..\lib test base/*.t comp/*.t cmd/*.t io/*.t op/*.t pragma/*.t
1058 test-prep : all utils
1059 $(XCOPY) $(PERLEXE) ..\t\$(NULL)
1060 $(XCOPY) $(PERLDLL) ..\t\$(NULL)
1061 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
1065 $(PERLEXE) -I..\lib harness
1068 test-notty : test-prep
1069 set PERL_SKIP_TTY_TEST=1
1071 $(PERLEXE) -I..\lib harness
1074 test-wide : test-prep
1075 set HARNESS_PERL_SWITCHES=-C
1077 $(PERLEXE) -I..\lib harness
1080 test-wide-notty : test-prep
1081 set PERL_SKIP_TTY_TEST=1
1082 set HARNESS_PERL_SWITCHES=-C
1084 $(PERLEXE) -I..\lib harness
1087 clean : Extensions_clean
1088 -@$(DEL) miniperlmain$(o)
1089 -@$(DEL) $(MINIPERL)
1090 -@$(DEL) perlglob$(o)
1091 -@$(DEL) perlmain$(o)
1096 -@$(DEL) $(WPERLEXE)
1098 -@$(DEL) $(CORE_OBJ)
1099 -if exist $(MINIDIR) rmdir /s /q $(MINIDIR)
1100 -rmdir /s $(MINIDIR)
1101 -@$(DEL) $(WIN32_OBJ)
1104 -@$(DEL) ..\*$(o) ..\*.lib ..\*.exp *$(o) *.lib *.exp *.res
1105 -@$(DEL) ..\t\*.exe ..\t\*.dll ..\t\*.bat
1106 -@$(DEL) ..\x2p\*.exe ..\x2p\*.bat
1110 # Handy way to run perlbug -ok without having to install and run the
1111 # installed perlbug. We don't re-run the tests here - we trust the user.
1112 # Please *don't* use this unless all tests pass.
1113 # If you want to report test failures, use "nmake nok" instead.
1115 $(PERLEXE) -I..\lib ..\utils\perlbug -ok -s "(UNINSTALLED)"
1118 $(PERLEXE) -I..\lib ..\utils\perlbug -ok -s "(UNINSTALLED)" -F perl.ok
1121 $(PERLEXE) -I..\lib ..\utils\perlbug -nok -s "(UNINSTALLED)"
1124 $(PERLEXE) -I..\lib ..\utils\perlbug -nok -s "(UNINSTALLED)" -F perl.nok