This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Integrate:
[perl5.git] / win32 / Makefile
CommitLineData
caec3c99
NC
1#
2# Makefile to build perl on Windows NT using Microsoft NMAKE.
3# Supported compilers:
4# Visual C++ 2.0 through 6.0 (and possibly newer versions)
5# MS Platform SDK 64-bit compiler and tools **experimental**
6#
7# This is set up to build a perl.exe that runs off a shared library
8# (perl58.dll). Also makes individual DLLs for the XS extensions.
9#
10
11##
12## Make sure you read README.win32 *before* you mess with anything here!
13##
14
15##
16## Build configuration. Edit the values below to suit your needs.
17##
18
19#
20# Set these to wherever you want "nmake install" to put your
21# newly built perl.
22#
23INST_DRV = c:
24INST_TOP = $(INST_DRV)\perl
25
26#
27# Comment this out if you DON'T want your perl installation to be versioned.
28# This means that the new installation will overwrite any files from the
29# old installation at the same INST_TOP location. Leaving it enabled is
30# the safest route, as perl adds the extra version directory to all the
31# locations it installs files to. If you disable it, an alternative
32# versioned installation can be obtained by setting INST_TOP above to a
33# path that includes an arbitrary version string.
34#
41de044b 35#INST_VER = \5.8.4
caec3c99
NC
36
37#
38# Comment this out if you DON'T want your perl installation to have
39# architecture specific components. This means that architecture-
40# specific files will be installed along with the architecture-neutral
41# files. Leaving it enabled is safer and more flexible, in case you
42# want to build multiple flavors of perl and install them together in
43# the same location. Commenting it out gives you a simpler
44# installation that is easier to understand for beginners.
45#
46#INST_ARCH = \$(ARCHNAME)
47
48#
49# uncomment to enable multiple interpreters. This is need for fork()
50# emulation and for thread support.
51#
52USE_MULTI = define
53
54#
55# Beginnings of interpreter cloning/threads; now reasonably complete.
56# This should be enabled to get the fork() emulation. This needs
57# USE_MULTI as well.
58#
59USE_ITHREADS = define
60
61#
62# uncomment to enable the implicit "host" layer for all system calls
63# made by perl. This needs USE_MULTI above. This is also needed to
64# get fork().
65#
66USE_IMP_SYS = define
67
68#
69# Comment out next assign to disable perl's I/O subsystem and use compiler's
70# stdio for IO - depending on your compiler vendor and run time library you may
71# then get a number of fails from make test i.e. bugs - complain to them not us ;-).
72# You will also be unable to take full advantage of perl5.8's support for multiple
73# encodings and may see lower IO performance. You have been warned.
74USE_PERLIO = define
75
76#
77# Comment this out if you don't want to enable large file support for
78# some reason. Should normally only be changed to maintain compatibility
79# with an older release of perl.
80USE_LARGE_FILES = define
81
82#
83# WARNING! This option is deprecated and will eventually go away (enable
84# USE_ITHREADS instead).
85#
86# uncomment to enable threads-capabilities. This is incompatible with
87# USE_ITHREADS, and is only here for people who may have come to rely
88# on the experimental Thread support that was in 5.005.
89#
90#USE_5005THREADS = define
91
92#
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)
95#
96#CCTYPE = MSVC20
97CCTYPE = MSVC60
98
99#
100# uncomment next line if you want debug version of perl (big,slow)
101# If not enabled, we automatically try to use maximum optimization
102# with all compilers that are known to have a working optimizer.
103#
104#CFG = Debug
105
106#
107# uncomment to enable use of PerlCRT.DLL when using the Visual C compiler.
108# It has patches that fix known bugs in older versions of MSVCRT.DLL.
109# This currently requires VC 5.0 with Service Pack 3 or later.
110# Get it from CPAN at http://www.cpan.org/authors/id/D/DO/DOUGL/
111# and follow the directions in the package to install.
112#
113# Not recommended if you have VC 6.x and you're not running Windows 9x.
114#
115#USE_PERLCRT = define
116
117#
118# uncomment to enable linking with setargv.obj under the Visual C
119# compiler. Setting this options enables perl to expand wildcards in
120# arguments, but it may be harder to use alternate methods like
121# File::DosGlob that are more powerful. This option is supported only with
122# Visual C.
123#
124#USE_SETARGV = define
125
126#
127# if you want to have the crypt() builtin function implemented, leave this or
128# CRYPT_LIB uncommented. The fcrypt.c file named here contains a suitable
129# version of des_fcrypt().
130#
131CRYPT_SRC = fcrypt.c
132
133#
134# if you didn't set CRYPT_SRC and if you have des_fcrypt() available in a
135# library, uncomment this, and make sure the library exists (see README.win32)
136# Specify the full pathname of the library.
137#
138#CRYPT_LIB = fcrypt.lib
139
140#
141# set this if you wish to use perl's malloc
142# WARNING: Turning this on/off WILL break binary compatibility with extensions
143# you may have compiled with/without it. Be prepared to recompile all
144# extensions if you change the default. Currently, this cannot be enabled
145# if you ask for USE_IMP_SYS above.
146#
147#PERL_MALLOC = define
148
149#
150# set this to enable debugging mstats
151# This must be enabled to use the Devel::Peek::mstat() function. This cannot
152# be enabled without PERL_MALLOC as well.
153#
154#DEBUG_MSTATS = define
155
156#
157#
158# set the install locations of the compiler include/libraries
159# Running VCVARS32.BAT is *required* when using Visual C.
160# Some versions of Visual C don't define MSVCDIR in the environment,
161# so you may have to set CCHOME explicitly (spaces in the path name should
162# not be quoted)
163#
164#CCHOME = f:\msvc20
165CCHOME = $(MSVCDIR)
166CCINCDIR = $(CCHOME)\include
167CCLIBDIR = $(CCHOME)\lib
168
169#
170# Additional compiler flags can be specified here.
171#
172
173#
174# This should normally be disabled. Adding -DPERL_POLLUTE enables support
175# for old symbols by default, at the expense of extreme pollution. You most
176# probably just want to build modules that won't compile with
177# perl Makefile.PL POLLUTE=1
178# instead of enabling this. Please report such modules to the respective
179# authors.
180#
181#BUILDOPT = $(BUILDOPT) -DPERL_POLLUTE
182
183#
184# This should normally be disabled. Enabling it will disable the File::Glob
185# implementation of CORE::glob.
186#
187#BUILDOPT = $(BUILDOPT) -DPERL_EXTERNAL_GLOB
188
189#
190# This should normally be disabled. Enabling it causes perl to read scripts
191# in text mode (which is the 5.005 behavior) and will break ByteLoader.
192#BUILDOPT = $(BUILDOPT) -DPERL_TEXTMODE_SCRIPTS
193
194#
195# specify semicolon-separated list of extra directories that modules will
196# look for libraries (spaces in path names need not be quoted)
197#
198EXTRALIBDIRS =
199
200#
201# set this to your email address (perl will guess a value from
202# from your loginname and your hostname, which may not be right)
203#
204#EMAIL =
205
206##
207## Build configuration ends.
208##
209
210##################### CHANGE THESE ONLY IF YOU MUST #####################
211
212!IF "$(CRYPT_SRC)$(CRYPT_LIB)" == ""
213D_CRYPT = undef
214!ELSE
215D_CRYPT = define
216CRYPT_FLAG = -DHAVE_DES_FCRYPT
217!ENDIF
218
219!IF "$(PERL_MALLOC)" == ""
220PERL_MALLOC = undef
221DEBUG_MSTATS = undef
222!ENDIF
223
224!IF "$(DEBUG_MSTATS)" == ""
225DEBUG_MSTATS = undef
226!ENDIF
227
228!IF "$(DEBUG_MSTATS)" == "define"
229BUILDOPT = $(BUILDOPT) -DPERL_DEBUGGING_MSTATS
230!ENDIF
231
232!IF "$(USE_5005THREADS)" == ""
233USE_5005THREADS = undef
234!ENDIF
235
236!IF "$(USE_5005THREADS)" == "define"
237USE_ITHREADS = undef
238!ENDIF
239
240!IF "$(USE_IMP_SYS)" == "define"
241PERL_MALLOC = undef
242!ENDIF
243
244!IF "$(USE_MULTI)" == ""
245USE_MULTI = undef
246!ENDIF
247
248!IF "$(USE_ITHREADS)" == ""
249USE_ITHREADS = undef
250!ENDIF
251
252!IF "$(USE_IMP_SYS)" == ""
253USE_IMP_SYS = undef
254!ENDIF
255
256!IF "$(USE_PERLIO)" == ""
257USE_PERLIO = undef
258!ENDIF
259
260!IF "$(USE_LARGE_FILES)" == ""
261USE_LARGE_FILES = undef
262!ENDIF
263
264!IF "$(USE_PERLCRT)" == ""
265USE_PERLCRT = undef
266!ENDIF
267
268!IF "$(USE_IMP_SYS)$(USE_MULTI)$(USE_5005THREADS)" == "defineundefundef"
269USE_MULTI = define
270!ENDIF
271
272!IF "$(USE_ITHREADS)$(USE_MULTI)" == "defineundef"
273USE_MULTI = define
274USE_5005THREADS = undef
275!ENDIF
276
277!IF "$(USE_MULTI)$(USE_5005THREADS)" != "undefundef"
278BUILDOPT = $(BUILDOPT) -DPERL_IMPLICIT_CONTEXT
279!ENDIF
280
281!IF "$(USE_IMP_SYS)" != "undef"
282BUILDOPT = $(BUILDOPT) -DPERL_IMPLICIT_SYS
283!ENDIF
284
285!IF "$(PROCESSOR_ARCHITECTURE)" == ""
286PROCESSOR_ARCHITECTURE = x86
287!ENDIF
288
289!IF "$(WIN64)" == ""
290!IF "$(PROCESSOR_ARCHITEW6432)" != ""
291PROCESSOR_ARCHITECTURE = $(PROCESSOR_ARCHITEW6432)
292WIN64 = define
293!ELSE
294!IF "$(PROCESSOR_ARCHITECTURE)" == "IA64"
295WIN64 = define
296!ELSE
297WIN64 = undef
298!ENDIF
299!ENDIF
300!ENDIF
301
302!IF "$(USE_5005THREADS)" == "define"
303ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-thread
304!ELSE
305!IF "$(USE_MULTI)" == "define"
306ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-multi
307!ELSE
308!IF "$(USE_PERLIO)" == "define"
309ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-perlio
310!ELSE
311ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)
312!ENDIF
313!ENDIF
314!ENDIF
315
316!IF "$(USE_PERLIO)" == "define"
317BUILDOPT = $(BUILDOPT) -DUSE_PERLIO
318!ENDIF
319
320!IF "$(USE_ITHREADS)" == "define"
321ARCHNAME = $(ARCHNAME)-thread
322!ENDIF
323
324# Visual Studio 98 specific
325!IF "$(CCTYPE)" == "MSVC60"
326
327# VC 6.0 can load the socket dll on demand. Makes the test suite
328# run in about 10% less time.
329DELAYLOAD = -DELAYLOAD:wsock32.dll -DELAYLOAD:shell32.dll delayimp.lib
330!ENDIF
331
332ARCHDIR = ..\lib\$(ARCHNAME)
333COREDIR = ..\lib\CORE
334AUTODIR = ..\lib\auto
335LIBDIR = ..\lib
336EXTDIR = ..\ext
337PODDIR = ..\pod
338EXTUTILSDIR = $(LIBDIR)\ExtUtils
339
340#
341INST_SCRIPT = $(INST_TOP)$(INST_VER)\bin
342INST_BIN = $(INST_SCRIPT)$(INST_ARCH)
343INST_LIB = $(INST_TOP)$(INST_VER)\lib
344INST_ARCHLIB = $(INST_LIB)$(INST_ARCH)
345INST_COREDIR = $(INST_ARCHLIB)\CORE
346INST_POD = $(INST_LIB)\pod
347INST_HTML = $(INST_TOP)$(INST_VER)\html
348
349#
350# Programs to compile, build .lib files and link
351#
352
353CC = cl
354LINK32 = link
355LIB32 = $(LINK32) -lib
356RSC = rc
357
358#
359# Options
360#
361
362INCLUDES = -I$(COREDIR) -I.\include -I. -I..
363#PCHFLAGS = -Fpc:\temp\vcmoduls.pch -YX
364DEFINES = -DWIN32 -D_CONSOLE -DNO_STRICT $(CRYPT_FLAG)
365LOCDEFS = -DPERLDLL -DPERL_CORE
366SUBSYS = console
367CXX_FLAG = -TP -GX
368
369!IF "$(USE_PERLCRT)" != "define"
370LIBC = msvcrt.lib
371!ELSE
372LIBC = PerlCRT.lib
373!ENDIF
374
caec3c99
NC
375!IF "$(CFG)" == "Debug"
376! IF "$(CCTYPE)" == "MSVC20"
377OPTIMIZE = -Od -MD -Z7 -DDEBUGGING
378! ELSE
379OPTIMIZE = -Od -MD -Zi -DDEBUGGING
380! ENDIF
381LINK_DBG = -debug
382!ELSE
5f36bea8
SH
383OPTIMIZE = -MD -Zi -DNDEBUG
384# we enable debug symbols in release builds also
385LINK_DBG = -debug -opt:ref,icf
386# you may want to enable this if you want COFF symbols in the executables
387# in addition to the PDB symbols. The default Dr. Watson that ships with
388# Windows can use the the former but not latter. The free WinDbg can be
389# installed to get better stack traces from just the PDB symbols, so we
390# avoid the bloat of COFF symbols by default.
391#LINK_DBG = $(LINK_DBG) -debugtype:both
caec3c99
NC
392! IF "$(WIN64)" == "define"
393# enable Whole Program Optimizations (WPO) and Link Time Code Generation (LTCG)
394OPTIMIZE = $(OPTIMIZE) -Ox -GL
395LINK_DBG = $(LINK_DBG) -ltcg
396! ELSE
397# -O1 yields smaller code, which turns out to be faster than -O2 on x86
398OPTIMIZE = $(OPTIMIZE) -O1
399#OPTIMIZE = $(OPTIMIZE) -O2
400! ENDIF
401!ENDIF
402
403!IF "$(WIN64)" == "define"
404DEFINES = $(DEFINES) -DWIN64 -DCONSERVATIVE
405OPTIMIZE = $(OPTIMIZE) -Wp64 -Op
406!ENDIF
407
408!IF "$(USE_PERLCRT)" != "define"
409BUILDOPT = $(BUILDOPT) -DPERL_MSVCRT_READFIX
410!ENDIF
411
412LIBBASEFILES = $(CRYPT_LIB) \
413 oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib \
414 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib \
415 netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib \
416 version.lib
417
418# win64 doesn't have some libs
419!IF "$(WIN64)" != "define"
420LIBBASEFILES = $(LIBBASEFILES) odbc32.lib odbccp32.lib
421!ENDIF
422
423# we add LIBC here, since we may be using PerlCRT.dll
424LIBFILES = $(LIBBASEFILES) $(LIBC)
425
426CFLAGS = -nologo -Gf -W3 $(INCLUDES) $(DEFINES) $(LOCDEFS) \
427 $(PCHFLAGS) $(OPTIMIZE)
428LINK_FLAGS = -nologo -nodefaultlib $(LINK_DBG) \
429 -libpath:"$(INST_COREDIR)" \
430 -machine:$(PROCESSOR_ARCHITECTURE)
431OBJOUT_FLAG = -Fo
432EXEOUT_FLAG = -Fe
433
434CFLAGS_O = $(CFLAGS) $(BUILDOPT)
435
436#################### do not edit below this line #######################
437############# NO USER-SERVICEABLE PARTS BEYOND THIS POINT ##############
438
439o = .obj
440
441#
442# Rules
443#
444
445.SUFFIXES : .c $(o) .dll .lib .exe .rc .res
446
447.c$(o):
448 $(CC) -c -I$(<D) $(CFLAGS_O) $(OBJOUT_FLAG)$@ $<
449
450.y.c:
451 $(NOOP)
452
453$(o).dll:
454 $(LINK32) -dll -subsystem:windows -implib:$(*B).lib -def:$(*B).def \
455 -out:$@ $(LINK_FLAGS) $(LIBFILES) $< $(LIBPERL)
456
457.rc.res:
458 $(RSC) -i.. $<
459
460#
461# various targets
462
463# makedef.pl must be updated if this changes, and this should normally
464# only change when there is an incompatible revision of the public API.
465PERLIMPLIB = ..\perl58.lib
466PERLDLL = ..\perl58.dll
467
468MINIPERL = ..\miniperl.exe
469MINIDIR = .\mini
470PERLEXE = ..\perl.exe
471WPERLEXE = ..\wperl.exe
472GLOBEXE = ..\perlglob.exe
473CONFIGPM = ..\lib\Config.pm
474MINIMOD = ..\lib\ExtUtils\Miniperl.pm
475X2P = ..\x2p\a2p.exe
476
5cde6b89
NC
477PERLEXE_ICO = .\perlexe.ico
478PERLEXE_RES = .\perlexe.res
479PERLDLL_RES =
480
caec3c99
NC
481# Nominate a target which causes extensions to be re-built
482# This used to be $(PERLEXE), but at worst it is the .dll that they depend
483# on and really only the interface - i.e. the .def file used to export symbols
484# from the .dll
485PERLDEP = perldll.def
486
487PL2BAT = bin\pl2bat.pl
488GLOBBAT = bin\perlglob.bat
489
490UTILS = \
491 ..\utils\h2ph \
492 ..\utils\splain \
493 ..\utils\dprofpp \
494 ..\utils\perlbug \
495 ..\utils\pl2pm \
496 ..\utils\c2ph \
497 ..\utils\pstruct \
498 ..\utils\h2xs \
499 ..\utils\perldoc \
500 ..\utils\perlcc \
501 ..\utils\perlivp \
502 ..\utils\libnetcfg \
503 ..\utils\enc2xs \
504 ..\utils\piconv \
505 ..\utils\cpan \
385df56d 506 ..\utils\xsubpp \
7cbe25b2 507 ..\utils\prove \
385df56d 508 ..\utils\instmodsh \
caec3c99
NC
509 ..\pod\checkpods \
510 ..\pod\pod2html \
511 ..\pod\pod2latex \
512 ..\pod\pod2man \
513 ..\pod\pod2text \
514 ..\pod\pod2usage \
515 ..\pod\podchecker \
516 ..\pod\podselect \
517 ..\x2p\find2perl \
518 ..\x2p\psed \
519 ..\x2p\s2p \
caec3c99
NC
520 bin\exetype.pl \
521 bin\runperl.pl \
522 bin\pl2bat.pl \
523 bin\perlglob.pl \
524 bin\search.pl
525
526MAKE = nmake -nologo
527MAKE_BARE = nmake
528
529!IF "$(WIN64)" == "define"
530CFGSH_TMPL = config.vc64
531CFGH_TMPL = config_H.vc64
532!ELSE
533CFGSH_TMPL = config.vc
534CFGH_TMPL = config_H.vc
535!ENDIF
536
537XCOPY = xcopy /f /r /i /d
538RCOPY = xcopy /f /r /i /e /d
539NOOP = @echo
540NULL =
541
542DEL = del
543
544#
545# filenames given to xsubpp must have forward slashes (since it puts
546# full pathnames in #line strings)
547XSUBPP = ..\$(MINIPERL) -I..\..\lib ..\$(EXTUTILSDIR)\xsubpp \
548 -C++ -prototypes
549
550MICROCORE_SRC = \
551 ..\av.c \
552 ..\deb.c \
553 ..\doio.c \
554 ..\doop.c \
555 ..\dump.c \
556 ..\globals.c \
557 ..\gv.c \
558 ..\hv.c \
559 ..\locale.c \
560 ..\mg.c \
561 ..\numeric.c \
562 ..\op.c \
563 ..\pad.c \
564 ..\perl.c \
565 ..\perlapi.c \
566 ..\perly.c \
567 ..\pp.c \
568 ..\pp_ctl.c \
569 ..\pp_hot.c \
570 ..\pp_pack.c \
571 ..\pp_sort.c \
572 ..\pp_sys.c \
573 ..\reentr.c \
574 ..\regcomp.c \
575 ..\regexec.c \
576 ..\run.c \
577 ..\scope.c \
578 ..\sv.c \
579 ..\taint.c \
580 ..\toke.c \
581 ..\universal.c \
582 ..\utf8.c \
583 ..\util.c \
584 ..\xsutils.c
585
586EXTRACORE_SRC = $(EXTRACORE_SRC) perllib.c
587
588!IF "$(PERL_MALLOC)" == "define"
589EXTRACORE_SRC = $(EXTRACORE_SRC) ..\malloc.c
590!ENDIF
591
592EXTRACORE_SRC = $(EXTRACORE_SRC) ..\perlio.c
593
594WIN32_SRC = \
595 .\win32.c \
596 .\win32sck.c \
597 .\win32thread.c
598
599# We need this for miniperl build unless we override canned
600# config.h #define building mini\*
601#!IF "$(USE_PERLIO)" == "define"
602WIN32_SRC = $(WIN32_SRC) .\win32io.c
603#!ENDIF
604
605!IF "$(CRYPT_SRC)" != ""
606WIN32_SRC = $(WIN32_SRC) .\$(CRYPT_SRC)
607!ENDIF
608
609DLL_SRC = $(DYNALOADER).c
610
611X2P_SRC = \
612 ..\x2p\a2p.c \
613 ..\x2p\hash.c \
614 ..\x2p\str.c \
615 ..\x2p\util.c \
616 ..\x2p\walk.c
617
618CORE_NOCFG_H = \
619 ..\av.h \
620 ..\cop.h \
621 ..\cv.h \
622 ..\dosish.h \
623 ..\embed.h \
624 ..\form.h \
625 ..\gv.h \
626 ..\handy.h \
627 ..\hv.h \
628 ..\iperlsys.h \
629 ..\mg.h \
630 ..\nostdio.h \
631 ..\op.h \
632 ..\opcode.h \
633 ..\perl.h \
634 ..\perlapi.h \
635 ..\perlsdio.h \
636 ..\perlsfio.h \
637 ..\perly.h \
638 ..\pp.h \
639 ..\proto.h \
640 ..\regexp.h \
641 ..\scope.h \
642 ..\sv.h \
643 ..\thread.h \
644 ..\unixish.h \
645 ..\utf8.h \
646 ..\util.h \
647 ..\warnings.h \
648 ..\XSUB.h \
649 ..\EXTERN.h \
650 ..\perlvars.h \
651 ..\intrpvar.h \
652 ..\thrdvar.h \
653 .\include\dirent.h \
654 .\include\netdb.h \
655 .\include\sys\socket.h \
656 .\win32.h
657
658CORE_H = $(CORE_NOCFG_H) .\config.h
659
660MICROCORE_OBJ = $(MICROCORE_SRC:.c=.obj)
661CORE_OBJ = $(MICROCORE_OBJ) $(EXTRACORE_SRC:.c=.obj)
662WIN32_OBJ = $(WIN32_SRC:.c=.obj)
663MINICORE_OBJ = $(MICROCORE_OBJ:..\=.\mini\) \
664 $(MINIDIR)\miniperlmain$(o) \
665 $(MINIDIR)\perlio$(o)
666MINIWIN32_OBJ = $(WIN32_OBJ:.\=.\mini\)
667MINI_OBJ = $(MINICORE_OBJ) $(MINIWIN32_OBJ)
668DLL_OBJ = $(DLL_SRC:.c=.obj)
669X2P_OBJ = $(X2P_SRC:.c=.obj)
670
671PERLDLL_OBJ = $(CORE_OBJ)
672PERLEXE_OBJ = perlmain$(o)
673
674PERLDLL_OBJ = $(PERLDLL_OBJ) $(WIN32_OBJ) $(DLL_OBJ)
675#PERLEXE_OBJ = $(PERLEXE_OBJ) $(WIN32_OBJ) $(DLL_OBJ)
676
677!IF "$(USE_SETARGV)" != ""
678SETARGV_OBJ = setargv$(o)
679!ENDIF
680
681DYNALOADER = $(EXTDIR)\DynaLoader\DynaLoader
682SOCKET = $(EXTDIR)\Socket\Socket
683FCNTL = $(EXTDIR)\Fcntl\Fcntl
684OPCODE = $(EXTDIR)\Opcode\Opcode
685SDBM_FILE = $(EXTDIR)\SDBM_File\SDBM_File
686IO = $(EXTDIR)\IO\IO
687POSIX = $(EXTDIR)\POSIX\POSIX
688ATTRS = $(EXTDIR)\attrs\attrs
689THREAD = $(EXTDIR)\Thread\Thread
690B = $(EXTDIR)\B\B
691RE = $(EXTDIR)\re\re
692DUMPER = $(EXTDIR)\Data\Dumper\Dumper
693ERRNO = $(EXTDIR)\Errno\Errno
694PEEK = $(EXTDIR)\Devel\Peek\Peek
695BYTELOADER = $(EXTDIR)\ByteLoader\ByteLoader
696DPROF = $(EXTDIR)\Devel\DProf\DProf
697GLOB = $(EXTDIR)\File\Glob\Glob
698HOSTNAME = $(EXTDIR)\Sys\Hostname\Hostname
699STORABLE = $(EXTDIR)\Storable\Storable
700FILTER = $(EXTDIR)\Filter\Util\Call\Call
701ENCODE = $(EXTDIR)\Encode\Encode
702MD5 = $(EXTDIR)\Digest\MD5\MD5
703PERLIOSCALAR = $(EXTDIR)\PerlIO\scalar\scalar
704MIMEBASE64 = $(EXTDIR)\MIME\Base64\Base64
705TIMEHIRES = $(EXTDIR)\Time\HiRes\HiRes
706CWD = $(EXTDIR)\Cwd\Cwd
707LISTUTIL = $(EXTDIR)\List\Util\Util
708PERLIOVIA = $(EXTDIR)\PerlIO\via\via
709XSAPITEST = $(EXTDIR)\XS\APItest\APItest
710XSTYPEMAP = $(EXTDIR)\XS\Typemap\Typemap
711UNICODENORMALIZE = $(EXTDIR)\Unicode\Normalize\Normalize
5cde6b89 712WIN32_DIR = ext\Win32
caec3c99
NC
713
714SOCKET_DLL = $(AUTODIR)\Socket\Socket.dll
715FCNTL_DLL = $(AUTODIR)\Fcntl\Fcntl.dll
716OPCODE_DLL = $(AUTODIR)\Opcode\Opcode.dll
717SDBM_FILE_DLL = $(AUTODIR)\SDBM_File\SDBM_File.dll
718IO_DLL = $(AUTODIR)\IO\IO.dll
719POSIX_DLL = $(AUTODIR)\POSIX\POSIX.dll
720ATTRS_DLL = $(AUTODIR)\attrs\attrs.dll
721THREAD_DLL = $(AUTODIR)\Thread\Thread.dll
722B_DLL = $(AUTODIR)\B\B.dll
723DUMPER_DLL = $(AUTODIR)\Data\Dumper\Dumper.dll
724PEEK_DLL = $(AUTODIR)\Devel\Peek\Peek.dll
725RE_DLL = $(AUTODIR)\re\re.dll
726BYTELOADER_DLL = $(AUTODIR)\ByteLoader\ByteLoader.dll
727DPROF_DLL = $(AUTODIR)\Devel\DProf\DProf.dll
728GLOB_DLL = $(AUTODIR)\File\Glob\Glob.dll
729HOSTNAME_DLL = $(AUTODIR)\Sys\Hostname\Hostname.dll
730STORABLE_DLL = $(AUTODIR)\Storable\Storable.dll
731FILTER_DLL = $(AUTODIR)\Filter\Util\Call\Call.dll
732ENCODE_DLL = $(AUTODIR)\Encode\Encode.dll
733MD5_DLL = $(AUTODIR)\Digest\MD5\MD5.dll
734PERLIOSCALAR_DLL = $(AUTODIR)\PerlIO\scalar\scalar.dll
735MIMEBASE64_DLL = $(AUTODIR)\MIME\Base64\Base64.dll
736TIMEHIRES_DLL = $(AUTODIR)\Time\HiRes\HiRes.dll
737CWD_DLL = $(AUTODIR)\Cwd\Cwd.dll
738LISTUTIL_DLL = $(AUTODIR)\List\Util\Util.dll
739PERLIOVIA_DLL = $(AUTODIR)\PerlIO\via\via.dll
740XSAPITEST_DLL = $(AUTODIR)\XS\APItest\APItest.dll
741XSTYPEMAP_DLL = $(AUTODIR)\XS\Typemap\Typemap.dll
742UNICODENORMALIZE_DLL = $(AUTODIR)\Unicode\Normalize\Normalize.dll
5cde6b89 743WIN32_DLL = $(AUTODIR)\Win32\Win32.dll
caec3c99
NC
744
745EXTENSION_C = \
746 $(SOCKET).c \
747 $(FCNTL).c \
748 $(OPCODE).c \
749 $(SDBM_FILE).c \
750 $(IO).c \
751 $(POSIX).c \
752 $(ATTRS).c \
753 $(THREAD).c \
754 $(RE).c \
755 $(DUMPER).c \
756 $(PEEK).c \
757 $(B).c \
758 $(BYTELOADER).c \
759 $(DPROF).c \
760 $(GLOB).c \
761 $(HOSTNAME).c \
762 $(STORABLE).c \
763 $(FILTER).c \
764 $(ENCODE).c \
765 $(MD5).c \
766 $(PERLIOSCALAR).c \
767 $(MIMEBASE64).c \
768 $(TIMEHIRES).c \
769 $(CWD).c \
770 $(LISTUTIL).c \
771 $(PERLIOVIA).c \
772 $(XSAPITEST).c \
773 $(XSTYPEMAP).c \
5cde6b89
NC
774 $(UNICODENORMALIZE).c \
775 $(WIN32_DIR).c
caec3c99
NC
776
777EXTENSION_DLL = \
778 $(SOCKET_DLL) \
779 $(FCNTL_DLL) \
780 $(OPCODE_DLL) \
781 $(SDBM_FILE_DLL)\
782 $(IO_DLL) \
783 $(POSIX_DLL) \
784 $(ATTRS_DLL) \
785 $(DUMPER_DLL) \
786 $(PEEK_DLL) \
787 $(B_DLL) \
788 $(RE_DLL) \
789 $(THREAD_DLL) \
790 $(BYTELOADER_DLL) \
791 $(DPROF_DLL) \
792 $(GLOB_DLL) \
793 $(HOSTNAME_DLL) \
794 $(STORABLE_DLL) \
795 $(FILTER_DLL) \
796 $(ENCODE_DLL) \
797 $(MD5_DLL) \
798 $(PERLIOSCALAR_DLL) \
799 $(MIMEBASE64_DLL) \
800 $(TIMEHIRES_DLL) \
801 $(CWD_DLL) \
802 $(LISTUTIL_DLL) \
803 $(PERLIOVIA_DLL) \
804 $(XSAPITEST_DLL) \
805 $(XSTYPEMAP_DLL) \
5cde6b89
NC
806 $(UNICODENORMALIZE_DLL) \
807 $(WIN32_DLL)
caec3c99
NC
808
809POD2HTML = $(PODDIR)\pod2html
810POD2MAN = $(PODDIR)\pod2man
811POD2LATEX = $(PODDIR)\pod2latex
812POD2TEXT = $(PODDIR)\pod2text
813
814CFG_VARS = \
815 "INST_DRV=$(INST_DRV)" \
816 "INST_TOP=$(INST_TOP)" \
817 "INST_VER=$(INST_VER)" \
818 "INST_ARCH=$(INST_ARCH)" \
819 "archname=$(ARCHNAME)" \
820 "cc=$(CC)" \
821 "ld=$(LINK32)" \
822 "ccflags=-nologo -Gf -W3 $(OPTIMIZE:"=\") $(DEFINES) $(BUILDOPT)" \
823 "cf_email=$(EMAIL)" \
824 "d_crypt=$(D_CRYPT)" \
825 "d_mymalloc=$(PERL_MALLOC)" \
826 "libs=$(LIBFILES)" \
827 "incpath=$(CCINCDIR:"=\")" \
828 "libperl=$(PERLIMPLIB:..\=)" \
829 "libpth=$(CCLIBDIR:"=\");$(EXTRALIBDIRS:"=\")" \
830 "libc=$(LIBC)" \
831 "make=$(MAKE_BARE)" \
832 "usethreads=$(USE_ITHREADS)" \
833 "use5005threads=$(USE_5005THREADS)" \
834 "useithreads=$(USE_ITHREADS)" \
835 "usethreads=$(USE_5005THREADS)" \
836 "usemultiplicity=$(USE_MULTI)" \
837 "useperlio=$(USE_PERLIO)" \
838 "uselargefiles=$(USE_LARGE_FILES)" \
839 "LINK_FLAGS=$(LINK_FLAGS:"=\")" \
840 "optimize=$(OPTIMIZE:"=\")"
841
842#
843# Top targets
844#
845
846all : .\config.h $(GLOBEXE) $(MINIMOD) $(CONFIGPM) $(PERLEXE) \
847 $(X2P) Extensions
848 @echo Everything is up to date. '$(MAKE_BARE) test' to run test suite.
849
850$(DYNALOADER)$(o) : $(DYNALOADER).c $(CORE_H) $(EXTDIR)\DynaLoader\dlutils.c
851
852#------------------------------------------------------------
853
854$(GLOBEXE) : perlglob$(o)
855 $(LINK32) $(LINK_FLAGS) $(LIBFILES) -out:$@ -subsystem:$(SUBSYS) \
856 perlglob$(o) setargv$(o)
857
858perlglob$(o) : perlglob.c
859
860config.w32 : $(CFGSH_TMPL)
861 copy $(CFGSH_TMPL) config.w32
862
863.\config.h : $(CFGH_TMPL)
864 -del /f config.h
865 copy $(CFGH_TMPL) config.h
866
867..\config.sh : config.w32 $(MINIPERL) config_sh.PL
868 $(MINIPERL) -I..\lib config_sh.PL $(CFG_VARS) config.w32 > ..\config.sh
869
870# this target is for when changes to the main config.sh happen
871# edit config.{b,v,g}c and make this target once for each supported
872# compiler (e.g. `nmake CCTYPE=BORLAND regen_config_h`)
873regen_config_h:
874 perl config_sh.PL $(CFG_VARS) $(CFGSH_TMPL) > ..\config.sh
875 cd ..
876 -del /f perl.exe perl*.dll
877 perl configpm
878 cd win32
879 -del /f $(CFGH_TMPL)
880 -mkdir $(COREDIR)
881 -perl config_h.PL "INST_VER=$(INST_VER)"
882 rename config.h $(CFGH_TMPL)
883
884$(CONFIGPM) : $(MINIPERL) ..\config.sh config_h.PL ..\minimod.pl
885 cd ..
886 miniperl configpm
887 cd win32
888 if exist lib\* $(RCOPY) lib\*.* ..\lib\$(NULL)
889 $(XCOPY) ..\*.h $(COREDIR)\*.*
890 $(XCOPY) ..\*.inc $(COREDIR)\*.*
891 $(XCOPY) *.h $(COREDIR)\*.*
892 $(XCOPY) ..\ext\re\re.pm $(LIBDIR)\*.*
893 $(RCOPY) include $(COREDIR)\*.*
894 -$(MINIPERL) -I..\lib config_h.PL "INST_VER=$(INST_VER)"
895 if errorlevel 1 $(MAKE) /$(MAKEFLAGS) $(CONFIGPM)
896
897$(MINIPERL) : $(MINIDIR) $(MINI_OBJ)
898 $(LINK32) -subsystem:console -out:$@ @<<
899 $(LINK_FLAGS) $(LIBFILES) $(MINI_OBJ)
900<<
901
902$(MINIDIR) :
903 if not exist "$(MINIDIR)" mkdir "$(MINIDIR)"
904
905$(MINICORE_OBJ) : $(CORE_NOCFG_H)
906 $(CC) -c $(CFLAGS) -DPERL_EXTERNAL_GLOB $(OBJOUT_FLAG)$@ ..\$(*F).c
907
908$(MINIWIN32_OBJ) : $(CORE_NOCFG_H)
909 $(CC) -c $(CFLAGS) $(OBJOUT_FLAG)$@ $(*F).c
910
911# -DPERL_IMPLICIT_SYS needs C++ for perllib.c
912# This is the only file that depends on perlhost.h, vmem.h, and vdir.h
913!IF "$(USE_IMP_SYS)" == "define"
914perllib$(o) : perllib.c .\perlhost.h .\vdir.h .\vmem.h
915 $(CC) -c -I. $(CFLAGS_O) $(CXX_FLAG) $(OBJOUT_FLAG)$@ perllib.c
916!ENDIF
917
918# 1. we don't want to rebuild miniperl.exe when config.h changes
919# 2. we don't want to rebuild miniperl.exe with non-default config.h
920$(MINI_OBJ) : $(CORE_NOCFG_H)
921
922$(WIN32_OBJ) : $(CORE_H)
923$(CORE_OBJ) : $(CORE_H)
924$(DLL_OBJ) : $(CORE_H)
925$(X2P_OBJ) : $(CORE_H)
926
927perldll.def : $(MINIPERL) $(CONFIGPM) ..\global.sym ..\pp.sym ..\makedef.pl
928 $(MINIPERL) -w ..\makedef.pl PLATFORM=win32 $(OPTIMIZE) $(DEFINES) $(BUILDOPT) \
929 CCTYPE=$(CCTYPE) > perldll.def
930
931$(PERLDLL): perldll.def $(PERLDLL_OBJ) $(PERLDLL_RES)
932 $(LINK32) -dll -def:perldll.def -base:0x28000000 -out:$@ @<<
933 $(LINK_FLAGS) $(DELAYLOAD) $(LIBFILES) $(PERLDLL_OBJ) $(PERLDLL_RES)
934<<
935 $(XCOPY) $(PERLIMPLIB) $(COREDIR)
936
a278d680
SH
937$(PERLEXE_ICO): $(MINIPERL) makeico.pl
938 $(MINIPERL) makeico.pl > $@
939
940$(PERLEXE_RES): perlexe.rc $(PERLEXE_ICO)
941
caec3c99
NC
942$(MINIMOD) : $(MINIPERL) ..\minimod.pl
943 cd ..
944 miniperl minimod.pl > lib\ExtUtils\Miniperl.pm
945 cd win32
946
947..\x2p\a2p$(o) : ..\x2p\a2p.c
948 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\a2p.c
949
950..\x2p\hash$(o) : ..\x2p\hash.c
951 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\hash.c
952
953..\x2p\str$(o) : ..\x2p\str.c
954 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\str.c
955
956..\x2p\util$(o) : ..\x2p\util.c
957 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\util.c
958
959..\x2p\walk$(o) : ..\x2p\walk.c
960 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\walk.c
961
962$(X2P) : $(MINIPERL) $(X2P_OBJ)
963 $(MINIPERL) ..\x2p\find2perl.PL
964 $(MINIPERL) ..\x2p\s2p.PL
965 $(LINK32) -subsystem:console -out:$@ @<<
966 $(LINK_FLAGS) $(LIBFILES) $(X2P_OBJ)
967<<
968
969perlmain.c : runperl.c
970 copy runperl.c perlmain.c
971
972perlmain$(o) : perlmain.c
973 $(CC) $(CFLAGS_O) -UPERLDLL $(OBJOUT_FLAG)$@ -c perlmain.c
974
975$(PERLEXE): $(PERLDLL) $(CONFIGPM) $(PERLEXE_OBJ) $(PERLEXE_RES)
976 $(LINK32) -subsystem:console -out:$@ -stack:0x1000000 $(LINK_FLAGS) \
977 $(LIBFILES) $(PERLEXE_OBJ) $(SETARGV_OBJ) $(PERLIMPLIB) $(PERLEXE_RES)
978 copy $(PERLEXE) $(WPERLEXE)
979 $(MINIPERL) -I..\lib bin\exetype.pl $(WPERLEXE) WINDOWS
980 copy splittree.pl ..
981 $(MINIPERL) -I..\lib ..\splittree.pl "../LIB" $(AUTODIR)
982
983$(DYNALOADER).c: $(MINIPERL) $(EXTDIR)\DynaLoader\dl_win32.xs $(CONFIGPM)
984 if not exist $(AUTODIR) mkdir $(AUTODIR)
985 cd $(EXTDIR)\$(*B)
986 ..\$(MINIPERL) -I..\..\lib $(*B)_pm.PL
987 ..\$(MINIPERL) -I..\..\lib XSLoader_pm.PL
988 cd ..\..\win32
989 $(XCOPY) $(EXTDIR)\$(*B)\$(*B).pm $(LIBDIR)\$(NULL)
990 $(XCOPY) $(EXTDIR)\$(*B)\XSLoader.pm $(LIBDIR)\$(NULL)
991 cd $(EXTDIR)\$(*B)
992 $(XSUBPP) dl_win32.xs > $(*B).c
993 cd ..\..\win32
994
995$(EXTDIR)\DynaLoader\dl_win32.xs: dl_win32.xs
996 copy dl_win32.xs $(EXTDIR)\DynaLoader\dl_win32.xs
997
998#----------------------------------------------------------------------------------
999Extensions: buildext.pl $(PERLDEP) $(CONFIGPM)
1000 $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR)
5cde6b89
NC
1001 $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext
1002
1003# Note: The next two targets explicitly remove a "blibdirs.exists" file that
1004# currerntly gets left behind, until CPAN RT Ticket #5616 is resolved.
caec3c99
NC
1005
1006Extensions_clean:
1007 -if exist $(MINIPERL) $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) clean
5cde6b89
NC
1008 -if exist $(MINIPERL) $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext clean
1009 -if exist $(EXTDIR)\SDBM_File\sdbm\blibdirs.exists del /f $(EXTDIR)\SDBM_File\sdbm\blibdirs.exists
1010
1011Extensions_realclean:
1012 -if exist $(MINIPERL) $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) $(EXTDIR) realclean
1013 -if exist $(MINIPERL) $(MINIPERL) -I..\lib buildext.pl $(MAKE) $(PERLDEP) ext realclean
1014 -if exist $(EXTDIR)\SDBM_File\sdbm\blibdirs.exists del /f $(EXTDIR)\SDBM_File\sdbm\blibdirs.exists
caec3c99
NC
1015
1016#----------------------------------------------------------------------------------
1017
1018doc: $(PERLEXE)
1019 $(PERLEXE) -I..\lib ..\installhtml --podroot=.. --htmldir=./html \
1020 --podpath=pod:lib:ext:utils --htmlroot="file://$(INST_HTML::=|)" \
1021 --libpod=perlfunc:perlguts:perlvar:perlrun:perlop --recurse
1022
93ea91c1
AT
1023# Note that this next section is parsed (and regenerated) by pod/buildtoc
1024# so please check that script before making structural changes here
1025
caec3c99
NC
1026utils: $(PERLEXE) $(X2P)
1027 cd ..\utils
1028 $(MAKE) PERL=$(MINIPERL)
1029 cd ..\pod
f6722d80 1030 copy ..\vms\perlvms.pod .\perlvms.pod
93ea91c1
AT
1031 copy ..\README.aix ..\pod\perlaix.pod
1032 copy ..\README.amiga ..\pod\perlamiga.pod
1033 copy ..\README.apollo ..\pod\perlapollo.pod
1034 copy ..\README.beos ..\pod\perlbeos.pod
1035 copy ..\README.bs2000 ..\pod\perlbs2000.pod
1036 copy ..\README.ce ..\pod\perlce.pod
1037 copy ..\README.cn ..\pod\perlcn.pod
1038 copy ..\README.cygwin ..\pod\perlcygwin.pod
1039 copy ..\README.dgux ..\pod\perldgux.pod
1040 copy ..\README.dos ..\pod\perldos.pod
1041 copy ..\README.epoc ..\pod\perlepoc.pod
1042 copy ..\README.freebsd ..\pod\perlfreebsd.pod
1043 copy ..\README.hpux ..\pod\perlhpux.pod
1044 copy ..\README.hurd ..\pod\perlhurd.pod
1045 copy ..\README.irix ..\pod\perlirix.pod
1046 copy ..\README.jp ..\pod\perljp.pod
1047 copy ..\README.ko ..\pod\perlko.pod
1048 copy ..\README.machten ..\pod\perlmachten.pod
1049 copy ..\README.macos ..\pod\perlmacos.pod
1050 copy ..\README.macosx ..\pod\perlmacosx.pod
1051 copy ..\README.mint ..\pod\perlmint.pod
1052 copy ..\README.mpeix ..\pod\perlmpeix.pod
1053 copy ..\README.netware ..\pod\perlnetware.pod
1054 copy ..\README.os2 ..\pod\perlos2.pod
1055 copy ..\README.os390 ..\pod\perlos390.pod
1056 copy ..\README.os400 ..\pod\perlos400.pod
1057 copy ..\README.plan9 ..\pod\perlplan9.pod
1058 copy ..\README.qnx ..\pod\perlqnx.pod
1059 copy ..\README.solaris ..\pod\perlsolaris.pod
1060 copy ..\README.tru64 ..\pod\perltru64.pod
1061 copy ..\README.tw ..\pod\perltw.pod
1062 copy ..\README.uts ..\pod\perluts.pod
1063 copy ..\README.vmesa ..\pod\perlvmesa.pod
1064 copy ..\README.vms ..\pod\perlvms.pod
1065 copy ..\README.vos ..\pod\perlvos.pod
1066 copy ..\README.win32 ..\pod\perlwin32.pod
1598f199 1067 copy ..\pod\perl585delta.pod ..\pod\perldelta.pod
caec3c99
NC
1068 $(MAKE) -f ..\win32\pod.mak converters
1069 cd ..\lib
1070 $(PERLEXE) lib_pm.PL
1071 cd ..\win32
1072 $(PERLEXE) $(PL2BAT) $(UTILS)
1073
93ea91c1
AT
1074# Note that the pod cleanup in this next section is parsed (and regenerated
1075# by pod/buildtoc so please check that script before making changes here
1076
caec3c99
NC
1077# the doubled rmdir calls are needed because older cmd shells
1078# don't understand /q
5cde6b89 1079distclean: realclean
caec3c99
NC
1080 -del /f $(MINIPERL) $(PERLEXE) $(PERLDLL) $(GLOBEXE) \
1081 $(PERLIMPLIB) ..\miniperl.lib $(MINIMOD)
1082 -del /f *.def *.map
1083 -del /f $(EXTENSION_DLL)
1084 -del /f $(EXTENSION_C) $(DYNALOADER).c $(ERRNO).pm
1085 -del /f $(EXTDIR)\DynaLoader\dl_win32.xs
5cde6b89
NC
1086 -del /f $(EXTDIR)\DynaLoader\DynaLoader.pm
1087 -del /f $(EXTDIR)\DynaLoader\XSLoader.pm
1088 -del /f $(LIBDIR)\Encode.pm $(LIBDIR)\encoding.pm $(LIBDIR)\Errno.pm
1089 -del /f $(LIBDIR)\Config.pod $(LIBDIR)\POSIX.pod $(LIBDIR)\threads.pm
caec3c99 1090 -del /f $(LIBDIR)\.exists $(LIBDIR)\attrs.pm $(LIBDIR)\DynaLoader.pm
5cde6b89 1091 -del /f $(LIBDIR)\XSLoader.pm $(LIBDIR)\lib.pm
caec3c99
NC
1092 -del /f $(LIBDIR)\Fcntl.pm $(LIBDIR)\IO.pm $(LIBDIR)\Opcode.pm
1093 -del /f $(LIBDIR)\ops.pm $(LIBDIR)\Safe.pm
1094 -del /f $(LIBDIR)\SDBM_File.pm $(LIBDIR)\Socket.pm $(LIBDIR)\POSIX.pm
1095 -del /f $(LIBDIR)\B.pm $(LIBDIR)\O.pm $(LIBDIR)\re.pm
5cde6b89 1096 -del /f $(LIBDIR)\ByteLoader.pm
caec3c99 1097 -del /f $(LIBDIR)\Devel\Peek.pm $(LIBDIR)\Devel\DProf.pm
5cde6b89 1098 -del /f $(LIBDIR)\Devel\PPPort.pm
caec3c99
NC
1099 -del /f $(LIBDIR)\File\Glob.pm
1100 -del /f $(LIBDIR)\Storable.pm
caec3c99 1101 -del /f $(LIBDIR)\Digest\MD5.pm
5cde6b89 1102 -del /f $(LIBDIR)\PerlIO\encoding.pm
caec3c99
NC
1103 -del /f $(LIBDIR)\PerlIO\scalar.pm
1104 -del /f $(LIBDIR)\PerlIO\via.pm
5cde6b89
NC
1105 -del /f $(LIBDIR)\Sys\Hostname.pm
1106 -del /f $(LIBDIR)\Thread\Signal.pm $(LIBDIR)\Thread\Specific.pm
1107 -del /f $(LIBDIR)\threads\shared.pm
caec3c99 1108 -del /f $(LIBDIR)\Time\HiRes.pm
caec3c99 1109 -del /f $(LIBDIR)\Unicode\Normalize.pm
5cde6b89 1110 -del /f $(LIBDIR)\Win32.pm
caec3c99
NC
1111 -if exist $(LIBDIR)\IO rmdir /s /q $(LIBDIR)\IO
1112 -if exist $(LIBDIR)\IO rmdir /s $(LIBDIR)\IO
1113 -if exist $(LIBDIR)\B rmdir /s /q $(LIBDIR)\B
1114 -if exist $(LIBDIR)\B rmdir /s $(LIBDIR)\B
1115 -if exist $(LIBDIR)\Data rmdir /s /q $(LIBDIR)\Data
1116 -if exist $(LIBDIR)\Data rmdir /s $(LIBDIR)\Data
5cde6b89
NC
1117 -if exist $(LIBDIR)\Encode rmdir /s /q $(LIBDIR)\Encode
1118 -if exist $(LIBDIR)\Encode rmdir /s $(LIBDIR)\Encode
caec3c99
NC
1119 -if exist $(LIBDIR)\Filter\Util rmdir /s /q $(LIBDIR)\Filter\Util
1120 -if exist $(LIBDIR)\Filter\Util rmdir /s $(LIBDIR)\Filter\Util
caec3c99
NC
1121 -if exist $(LIBDIR)\MIME rmdir /s /q $(LIBDIR)\MIME
1122 -if exist $(LIBDIR)\MIME rmdir /s $(LIBDIR)\MIME
1123 -if exist $(LIBDIR)\List rmdir /s /q $(LIBDIR)\List
1124 -if exist $(LIBDIR)\List rmdir /s $(LIBDIR)\List
1125 -if exist $(LIBDIR)\Scalar rmdir /s /q $(LIBDIR)\Scalar
1126 -if exist $(LIBDIR)\Scalar rmdir /s $(LIBDIR)\Scalar
1127 -if exist $(LIBDIR)\XS rmdir /s /q $(LIBDIR)\XS
1128 -if exist $(LIBDIR)\XS rmdir /s $(LIBDIR)\XS
5cde6b89 1129 -cd $(PODDIR) && del /f *.html *.bat checkpods \
caec3c99 1130 perlaix.pod perlamiga.pod perlapollo.pod perlbeos.pod \
f6722d80
NC
1131 perlbs2000.pod perlce.pod perlcn.pod perlcygwin.pod \
1132 perldelta.pod perldgux.pod perldos.pod perlepoc.pod \
1133 perlfreebsd.pod perlhpux.pod perlhurd.pod perlirix.pod \
1134 perljp.pod perlko.pod perlmachten.pod perlmacos.pod \
1135 perlmacosx.pod perlmint.pod perlmpeix.pod perlnetware.pod \
caec3c99 1136 perlos2.pod perlos390.pod perlos400.pod perlplan9.pod \
f6722d80 1137 perlqnx.pod perlsolaris.pod perltru64.pod perltw.pod \
1598f199
NC
1138 perluts.pod perlvmesa.pod perlvms.pod perlvms.pod perlvos.pod \
1139 perlwin32.pod \
f6722d80 1140 pod2html pod2latex pod2man pod2text pod2usage \
caec3c99 1141 podchecker podselect
5cde6b89
NC
1142 -cd ..\utils && del /f h2ph splain perlbug pl2pm c2ph pstruct h2xs \
1143 perldoc perlivp dprofpp perlcc libnetcfg enc2xs piconv cpan *.bat \
1144 xsubpp instmodsh prove
1145 -cd ..\x2p && del /f find2perl s2p psed *.bat
caec3c99
NC
1146 -del /f ..\config.sh ..\splittree.pl perlmain.c dlutils.c config.h.new
1147 -del /f $(CONFIGPM)
1148 -del /f bin\*.bat
5f36bea8 1149 -del /f $(PERLEXE_ICO) perl.base
5cde6b89
NC
1150 -cd .. && del /s *.lib *.map *.pdb *.ilk *.bs *$(o) .exists pm_to_blib
1151 -cd $(EXTDIR) && del /s *.def Makefile Makefile.old
caec3c99
NC
1152 -if exist $(AUTODIR) rmdir /s /q $(AUTODIR)
1153 -if exist $(AUTODIR) rmdir /s $(AUTODIR)
1154 -if exist $(COREDIR) rmdir /s /q $(COREDIR)
1155 -if exist $(COREDIR) rmdir /s $(COREDIR)
1156
1157install : all installbare installhtml
1158
1159installbare : utils
1160 $(PERLEXE) ..\installperl
1161 if exist $(WPERLEXE) $(XCOPY) $(WPERLEXE) $(INST_BIN)\*.*
1162 $(XCOPY) $(GLOBEXE) $(INST_BIN)\*.*
5f36bea8
SH
1163 if exist ..\perl*.pdb $(XCOPY) ..\perl*.pdb $(INST_BIN)\*.*
1164 if exist ..\x2p\a2p.pdb $(XCOPY) ..\x2p\a2p.pdb $(INST_BIN)\*.*
caec3c99
NC
1165 $(XCOPY) bin\*.bat $(INST_SCRIPT)\*.*
1166
1167installhtml : doc
1168 $(RCOPY) html\*.* $(INST_HTML)\*.*
1169
1170inst_lib : $(CONFIGPM)
1171 copy splittree.pl ..
1172 $(MINIPERL) -I..\lib ..\splittree.pl "../LIB" $(AUTODIR)
1173 $(RCOPY) ..\lib $(INST_LIB)\*.*
1174
1175minitest : $(MINIPERL) $(GLOBEXE) $(CONFIGPM) utils
5cde6b89
NC
1176 $(XCOPY) $(MINIPERL) ..\t\$(NULL)
1177 if exist ..\t\perl.exe del /f ..\t\perl.exe
1178 rename ..\t\miniperl.exe perl.exe
caec3c99
NC
1179 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
1180 attrib -r ..\t\*.*
5cde6b89
NC
1181 cd ..\t && \
1182 $(MINIPERL) -I..\lib harness base/*.t comp/*.t cmd/*.t io/*.t op/*.t pragma/*.t
caec3c99
NC
1183
1184test-prep : all utils
1185 $(XCOPY) $(PERLEXE) ..\t\$(NULL)
1186 $(XCOPY) $(PERLDLL) ..\t\$(NULL)
1187 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
1188
1189test : test-prep
1190 cd ..\t
1191 $(PERLEXE) -I..\lib harness
1192 cd ..\win32
1193
1194test-notty : test-prep
1195 set PERL_SKIP_TTY_TEST=1
1196 cd ..\t
1197 $(PERLEXE) -I..\lib harness
1198 cd ..\win32
1199
1200_test :
1201 $(XCOPY) $(PERLEXE) ..\t\$(NULL)
1202 $(XCOPY) $(PERLDLL) ..\t\$(NULL)
1203 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
1204 cd ..\t
1205 $(PERLEXE) -I..\lib harness
1206 cd ..\win32
1207
5cde6b89 1208_clean :
caec3c99
NC
1209 -@$(DEL) miniperlmain$(o)
1210 -@$(DEL) $(MINIPERL)
1211 -@$(DEL) perlglob$(o)
1212 -@$(DEL) perlmain$(o)
1213 -@$(DEL) config.w32
1214 -@$(DEL) config.h
1215 -@$(DEL) $(GLOBEXE)
1216 -@$(DEL) $(PERLEXE)
1217 -@$(DEL) $(WPERLEXE)
1218 -@$(DEL) $(PERLDLL)
1219 -@$(DEL) $(CORE_OBJ)
1220 -if exist $(MINIDIR) rmdir /s /q $(MINIDIR)
1221 -if exist $(MINIDIR) rmdir /s $(MINIDIR)
1222 -@$(DEL) $(WIN32_OBJ)
1223 -@$(DEL) $(DLL_OBJ)
1224 -@$(DEL) $(X2P_OBJ)
1225 -@$(DEL) ..\*$(o) ..\*.lib ..\*.exp *$(o) *.lib *.exp *.res
1226 -@$(DEL) ..\t\*.exe ..\t\*.dll ..\t\*.bat
1227 -@$(DEL) ..\x2p\*.exe ..\x2p\*.bat
1228 -@$(DEL) *.ilk
1229 -@$(DEL) *.pdb
1230
5cde6b89
NC
1231clean : Extensions_clean _clean
1232
1233realclean : Extensions_realclean _clean
1234
caec3c99
NC
1235# Handy way to run perlbug -ok without having to install and run the
1236# installed perlbug. We don't re-run the tests here - we trust the user.
1237# Please *don't* use this unless all tests pass.
1238# If you want to report test failures, use "nmake nok" instead.
1239ok: utils
1240 $(PERLEXE) -I..\lib ..\utils\perlbug -ok -s "(UNINSTALLED)"
1241
1242okfile: utils
1243 $(PERLEXE) -I..\lib ..\utils\perlbug -ok -s "(UNINSTALLED)" -F perl.ok
1244
1245nok: utils
1246 $(PERLEXE) -I..\lib ..\utils\perlbug -nok -s "(UNINSTALLED)"
1247
1248nokfile: utils
1249 $(PERLEXE) -I..\lib ..\utils\perlbug -nok -s "(UNINSTALLED)" -F perl.nok