Windows build tweaks due to change#4623
[p5sagit/p5-mst-13.2.git] / win32 / Makefile
CommitLineData
e7083a8c 1#
2# Makefile to build perl on Windows NT using Microsoft NMAKE.
68dc0745 3#
4# This is set up to build a perl.exe that runs off a shared library
5# (perl.dll). Also makes individual DLLs for the XS extensions.
e7083a8c 6#
7
8##
69e1fe5e 9## Make sure you read README.win32 *before* you mess with anything here!
10##
11
12##
e7083a8c 13## Build configuration. Edit the values below to suit your needs.
14##
15
137443ea 16#
17# Set these to wherever you want "nmake install" to put your
18# newly built perl.
e7083a8c 19#
eb480a0b 20INST_DRV = c:
e5a95ffb 21INST_TOP = $(INST_DRV)\perl
22
e7083a8c 23#
e5a95ffb 24# Comment this out if you DON'T want your perl installation to be versioned.
25# This means that the new installation will overwrite any files from the
26# old installation at the same INST_TOP location. Leaving it enabled is
27# the safest route, as perl adds the extra version directory to all the
28# locations it installs files to. If you disable it, an alternative
29# versioned installation can be obtained by setting INST_TOP above to a
30# path that includes an arbitrary version string.
e7083a8c 31#
52b0428e 32INST_VER = \5.00563
d07c2202 33
34#
0cb96387 35# Comment this out if you DON'T want your perl installation to have
36# architecture specific components. This means that architecture-
37# specific files will be installed along with the architecture-neutral
38# files. Leaving it enabled is safer and more flexible, in case you
39# want to build multiple flavors of perl and install them together in
40# the same location. Commenting it out gives you a simpler
41# installation that is easier to understand for beginners.
42#
51371543 43INST_ARCH = \$(ARCHNAME)
0cb96387 44
45#
c5be433b 46# XXX WARNING! This option currently undergoing changes. May be broken.
47#
d07c2202 48# uncomment to enable threads-capabilities
e7083a8c 49#
eb480a0b 50#USE_THREADS = define
137443ea 51
c90c0ff4 52#
c5be433b 53# XXX WARNING! This option currently undergoing changes. May be broken.
54#
b86a2fa7 55# uncomment to enable multiple interpreters
56#
57#USE_MULTI = define
58
59#
c5be433b 60# XXX WARNING! This option currently undergoing changes. May be broken.
61#
62# uncomment next line if you want to use the perl object
63# Currently, this cannot be enabled if you ask for threads above
64#
65#USE_OBJECT = define
66
67#
7766f137 68# XXX WARNING! This option currently undergoing changes. May be broken.
69#
70# Beginnings of interpreter cloning/threads: still rather rough, fails
71# tests. This should be enabled to get the fork() emulation. Do not
72# enable unless you know what you're doing!
73#
638eceb6 74#USE_ITHREADS = define
7766f137 75
76#
77# uncomment to enable the implicit "host" layer for all system calls
78# made by perl. This is needed and auto-enabled by USE_OBJECT above.
79#
638eceb6 80#USE_IMP_SYS = define
7766f137 81
82#
7fac1903 83# uncomment one of the following lines if you are using either
84# Visual C++ 2.x or Visual C++ 6.x (aka Visual Studio 98)
e7083a8c 85#
eb480a0b 86#CCTYPE = MSVC20
7fac1903 87#CCTYPE = MSVC60
c90c0ff4 88
89#
90# uncomment next line if you want debug version of perl (big,slow)
e7083a8c 91#
eb480a0b 92#CFG = Debug
137443ea 93
d484a829 94#
66aa1127 95# uncomment to enable use of PerlCRT.DLL when using the Visual C compiler.
e9ee4811 96# Highly recommended. It has patches that fix known bugs in MSVCRT.DLL.
c5be433b 97# This currently requires VC 5.0 with Service Pack 3 or later.
b89743e8 98# Get it from CPAN at http://www.perl.com/CPAN/authors/id/D/DO/DOUGL/
66aa1127 99# and follow the directions in the package to install.
e7083a8c 100#
101#USE_PERLCRT = define
7766f137 102#BUILD_FOR_WIN95 = define
e7083a8c 103
104#
baed7233 105# uncomment to enable linking with setargv.obj under the Visual C
106# compiler. Setting this options enables perl to expand wildcards in
107# arguments, but it may be harder to use alternate methods like
108# File::DosGlob that are more powerful. This option is supported only with
109# Visual C.
110#
111#USE_SETARGV = define
112
113#
26618a56 114# if you have the source for des_fcrypt(), uncomment this and make sure the
8d9b2e3c 115# file exists (see README.win32). File should be located in the same
ff95b63e 116# directory as this file.
e7083a8c 117#
2d77217b 118#CRYPT_SRC = fcrypt.c
26618a56 119
120#
121# if you didn't set CRYPT_SRC and if you have des_fcrypt() available in a
122# library, uncomment this, and make sure the library exists (see README.win32)
a1dd9325 123# Specify the full pathname of the library.
e7083a8c 124#
2d77217b 125#CRYPT_LIB = fcrypt.lib
26618a56 126
127#
1c1c7f20 128# set this if you wish to use perl's malloc
129# WARNING: Turning this on/off WILL break binary compatibility with extensions
5fd76c3e 130# you may have compiled with/without it. Be prepared to recompile all
131# extensions if you change the default. Currently, this cannot be enabled
c5be433b 132# if you ask for USE_OBJECT above.
e7083a8c 133#
01f988be 134#PERL_MALLOC = define
1c1c7f20 135
136#
3e3baf6d 137# set the install locations of the compiler include/libraries
69e1fe5e 138# Running VCVARS32.BAT is *required* when using Visual C.
95883bf3 139# Some versions of Visual C don't define MSVCDIR in the environment,
80252599 140# so you may have to set CCHOME explicitly (spaces in the path name should
141# not be quoted)
a8deba26 142#
eb480a0b 143#CCHOME = f:\msvc20
144CCHOME = $(MSVCDIR)
145CCINCDIR = $(CCHOME)\include
146CCLIBDIR = $(CCHOME)\lib
3e3baf6d 147
148#
e02fdbd2 149# additional compiler flags can be specified here.
150#
151# Adding -DPERL_POLLUTE enables support for old symbols, at the expense of
152# extreme pollution. You most probably want this if you're compiling modules
153# from CPAN, or other such serious uses of this experimental perl release.
154# We don't enable this by default because we want the modules to get fixed
155# instead of clinging to shortcuts like this one.
156#
c5be433b 157#BUILDOPT = $(BUILDOPT) -DPERL_POLLUTE
e02fdbd2 158
159#
a7089531 160# enable this to test the File::Glob implementation of CORE::glob
161#
162#BUILDOPT = $(BUILDOPT) -DPERL_INTERNAL_GLOB
163
7766f137 164# Enabling this runs a cloned toplevel interpreter (fails tests)
165#BUILDOPT = $(BUILDOPT) -DTOP_CLONE
971a9dd3 166
80252599 167# specify semicolon-separated list of extra directories that modules will
168# look for libraries (spaces in path names need not be quoted)
fa4efe8e 169#
170EXTRALIBDIRS =
171
172#
d484a829 173# set this to your email address (perl will guess a value from
174# from your loginname and your hostname, which may not be right)
e7083a8c 175#
eb480a0b 176#EMAIL =
d484a829 177
e7083a8c 178##
179## Build configuration ends.
180##
181
137443ea 182##################### CHANGE THESE ONLY IF YOU MUST #####################
183
26618a56 184!IF "$(CRYPT_SRC)$(CRYPT_LIB)" == ""
eb480a0b 185D_CRYPT = undef
26618a56 186!ELSE
eb480a0b 187D_CRYPT = define
188CRYPT_FLAG = -DHAVE_DES_FCRYPT
189!ENDIF
190
c5be433b 191!IF "$(USE_OBJECT)" == "define"
eb480a0b 192PERL_MALLOC = undef
e2f80c04 193USE_THREADS = undef
b86a2fa7 194USE_MULTI = undef
7766f137 195USE_IMP_SYS = define
26618a56 196!ENDIF
197
1c1c7f20 198!IF "$(PERL_MALLOC)" == ""
199PERL_MALLOC = undef
200!ENDIF
201
eb480a0b 202!IF "$(USE_THREADS)" == ""
203USE_THREADS = undef
204!ENDIF
205
7766f137 206!IF "$(USE_THREADS)" == "define"
207USE_ITHREADS = undef
208!ENDIF
209
b86a2fa7 210!IF "$(USE_MULTI)" == ""
211USE_MULTI = undef
212!ENDIF
213
3bb366e1 214!IF "$(USE_OBJECT)" == ""
215USE_OBJECT = undef
216!ENDIF
217
7766f137 218!IF "$(USE_ITHREADS)" == ""
219USE_ITHREADS = undef
220!ENDIF
221
222!IF "$(USE_IMP_SYS)" == ""
223USE_IMP_SYS = undef
224!ENDIF
225
3bb366e1 226!IF "$(USE_MULTI)$(USE_THREADS)$(USE_OBJECT)" != "undefundefundef"
0b94c7bb 227BUILDOPT = $(BUILDOPT) -DPERL_IMPLICIT_CONTEXT
228!ENDIF
229
7766f137 230!IF "$(USE_ITHREADS)" != "undef"
231BUILDOPT = $(BUILDOPT) -DUSE_ITHREADS
232!ENDIF
233
234!IF "$(USE_IMP_SYS)" != "undef"
235BUILDOPT = $(BUILDOPT) -DPERL_IMPLICIT_SYS
236!ENDIF
237
d07c2202 238!IF "$(PROCESSOR_ARCHITECTURE)" == ""
239PROCESSOR_ARCHITECTURE = x86
240!ENDIF
241
c5be433b 242!IF "$(USE_OBJECT)" == "define"
b83ac84c 243ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-object
244!ELSE
924b3ec4 245!IF "$(USE_THREADS)" == "define"
d07c2202 246ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-thread
924b3ec4 247!ELSE
c5be433b 248!IF "$(USE_MULTI)" == "define"
249ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-multi
250!ELSE
924b3ec4 251ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)
d07c2202 252!ENDIF
b83ac84c 253!ENDIF
c5be433b 254!ENDIF
d07c2202 255
7fac1903 256# Visual Studio 98 specific
257!IF "$(CCTYPE)" == "MSVC60"
258
259# VC 6.0 can load the socket dll on demand. Makes the test suite
260# run in about 10% less time.
261DELAYLOAD = -DELAYLOAD:wsock32.dll delayimp.lib
262
263# VC 6.0 seems capable of compiling perl correctly with optimizations
264# enabled. Anything earlier fails tests.
265!IF "$(CFG)" == ""
266CFG = Optimize
267!ENDIF
268!ENDIF
269
28004758 270ARCHDIR = ..\lib\$(ARCHNAME)
d07c2202 271COREDIR = ..\lib\CORE
eb480a0b 272AUTODIR = ..\lib\auto
28004758 273LIBDIR = ..\lib
274EXTDIR = ..\ext
275PODDIR = ..\pod
276EXTUTILSDIR = $(LIBDIR)\ExtUtils
277
278#
279INST_SCRIPT = $(INST_TOP)$(INST_VER)\bin
280INST_BIN = $(INST_SCRIPT)$(INST_ARCH)
281INST_LIB = $(INST_TOP)$(INST_VER)\lib
282INST_ARCHLIB = $(INST_LIB)$(INST_ARCH)
283INST_COREDIR = $(INST_ARCHLIB)\CORE
284INST_POD = $(INST_LIB)\pod
285INST_HTML = $(INST_POD)\html
d07c2202 286
137443ea 287#
288# Programs to compile, build .lib files and link
289#
68dc0745 290
045453ec 291CC = cl
292LINK32 = link
eb480a0b 293LIB32 = $(LINK32) -lib
294
68dc0745 295#
137443ea 296# Options
297#
eb480a0b 298
af883608 299RUNTIME = -MD
9036c72f 300INCLUDES = -I$(COREDIR) -I.\include -I. -I..
eb480a0b 301#PCHFLAGS = -Fpc:\temp\vcmoduls.pch -YX
c5be433b 302DEFINES = -DWIN32 -D_CONSOLE -DNO_STRICT $(CRYPT_FLAG)
eb480a0b 303LOCDEFS = -DPERLDLL -DPERL_CORE
304SUBSYS = console
305CXX_FLAG = -TP -GX
137443ea 306
e7083a8c 307!IF "$(USE_PERLCRT)" == ""
308! IF "$(CFG)" == "Debug"
309PERLCRTLIBC = msvcrtd.lib
310! ELSE
311PERLCRTLIBC = msvcrt.lib
312! ENDIF
313!ELSE
314! IF "$(CFG)" == "Debug"
315PERLCRTLIBC = PerlCRTD.lib
316! ELSE
317PERLCRTLIBC = PerlCRT.lib
318! ENDIF
319!ENDIF
320
137443ea 321!IF "$(RUNTIME)" == "-MD"
e7083a8c 322LIBC = $(PERLCRTLIBC)
137443ea 323!ELSE
eb480a0b 324LIBC = libcmt.lib
137443ea 325!ENDIF
326
327!IF "$(CFG)" == "Debug"
328! IF "$(CCTYPE)" == "MSVC20"
eb480a0b 329OPTIMIZE = -Od $(RUNTIME) -Z7 -D_DEBUG -DDEBUGGING
137443ea 330! ELSE
3dfd1da1 331OPTIMIZE = -Od $(RUNTIME)d -Zi -D_DEBUG -DDEBUGGING
137443ea 332! ENDIF
eb480a0b 333LINK_DBG = -debug -pdb:none
137443ea 334!ELSE
74593e1f 335! IF "$(CFG)" == "Optimize"
c5be433b 336# -O1 yields smaller code, which turns out to be faster than -O2
337#OPTIMIZE = -O2 $(RUNTIME) -DNDEBUG
338OPTIMIZE = -O1 $(RUNTIME) -DNDEBUG
137443ea 339! ELSE
af883608 340OPTIMIZE = -Od $(RUNTIME) -DNDEBUG
137443ea 341! ENDIF
eb480a0b 342LINK_DBG = -release
343!ENDIF
344
c5be433b 345!IF "$(USE_OBJECT)" == "define"
eb480a0b 346OPTIMIZE = $(OPTIMIZE) $(CXX_FLAG)
c5be433b 347BUILDOPT = $(BUILDOPT) -DPERL_OBJECT
137443ea 348!ENDIF
68dc0745 349
7fac1903 350LIBBASEFILES = $(DELAYLOAD) $(CRYPT_LIB) \
351 oldnames.lib kernel32.lib user32.lib gdi32.lib \
eb480a0b 352 winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib \
353 oleaut32.lib netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib \
354 version.lib odbc32.lib odbccp32.lib
3e3baf6d 355
e7083a8c 356# we add LIBC here, since we may be using PerlCRT.dll
357LIBFILES = $(LIBBASEFILES) $(LIBC)
358
eb480a0b 359CFLAGS = -nologo -Gf -W3 $(INCLUDES) $(DEFINES) $(LOCDEFS) \
360 $(PCHFLAGS) $(OPTIMIZE)
28004758 361LINK_FLAGS = -nologo -nodefaultlib $(LINK_DBG) \
362 -libpath:"$(INST_COREDIR)" \
363 -machine:$(PROCESSOR_ARCHITECTURE)
eb480a0b 364OBJOUT_FLAG = -Fo
365EXEOUT_FLAG = -Fe
366
c5be433b 367CFLAGS_O = $(CFLAGS) $(BUILDOPT)
137443ea 368
369#################### do not edit below this line #######################
370############# NO USER-SERVICEABLE PARTS BEYOND THIS POINT ##############
371
d56e6723 372o = .obj
373
137443ea 374#
375# Rules
376#
137443ea 377
d56e6723 378.SUFFIXES : .c $(o) .dll .lib .exe
379
380.c$(o):
eb480a0b 381 $(CC) -c -I$(<D) $(CFLAGS_O) $(OBJOUT_FLAG)$@ $<
382
383.y.c:
384 $(NOOP)
137443ea 385
d56e6723 386$(o).dll:
3e3baf6d 387 $(LINK32) -dll -subsystem:windows -implib:$(*B).lib -def:$(*B).def \
dc050285 388 -out:$@ $(LINK_FLAGS) $(LIBFILES) $< $(LIBPERL)
68dc0745 389
68dc0745 390#
68dc0745 391# various targets
c5be433b 392!IF "$(USE_OBJECT)" == "define"
3075ddba 393PERLIMPLIB = ..\perl56.lib
394PERLDLL = ..\perl56.dll
eb480a0b 395!ELSE
396PERLIMPLIB = ..\perl.lib
397PERLDLL = ..\perl.dll
26618a56 398!ENDIF
399
eb480a0b 400MINIPERL = ..\miniperl.exe
401MINIDIR = .\mini
402PERLEXE = ..\perl.exe
7766f137 403WPERLEXE = ..\wperl.exe
eb480a0b 404GLOBEXE = ..\perlglob.exe
405CONFIGPM = ..\lib\Config.pm
406MINIMOD = ..\lib\ExtUtils\Miniperl.pm
407X2P = ..\x2p\a2p.exe
408
409PL2BAT = bin\pl2bat.pl
410GLOBBAT = bin\perlglob.bat
411
4a71ed0c 412UTILS = \
413 ..\utils\h2ph \
414 ..\utils\splain \
95667ae4 415 ..\utils\dprofpp \
4a71ed0c 416 ..\utils\perlbug \
417 ..\utils\pl2pm \
418 ..\utils\c2ph \
419 ..\utils\h2xs \
420 ..\utils\perldoc \
421 ..\utils\pstruct \
422 ..\utils\perlcc \
423 ..\pod\checkpods \
424 ..\pod\pod2html \
425 ..\pod\pod2latex \
426 ..\pod\pod2man \
427 ..\pod\pod2text \
360aca43 428 ..\pod\pod2usage \
429 ..\pod\podchecker \
430 ..\pod\podselect \
4a71ed0c 431 ..\x2p\find2perl \
432 ..\x2p\s2p \
4a71ed0c 433 bin\runperl.pl \
434 bin\pl2bat.pl \
435 bin\perlglob.pl \
436 bin\search.pl
437
eb480a0b 438MAKE = nmake -nologo
439
440CFGSH_TMPL = config.vc
441CFGH_TMPL = config_H.vc
e7083a8c 442
7766f137 443!IF "$(BUILD_FOR_WIN95)" == "define"
eb480a0b 444PERL95EXE = ..\perl95.exe
e7083a8c 445!ENDIF
eb480a0b 446
447XCOPY = xcopy /f /r /i /d
448RCOPY = xcopy /f /r /i /e /d
449NOOP = @echo
450NULL =
1c1c7f20 451
68dc0745 452#
453# filenames given to xsubpp must have forward slashes (since it puts
454# full pathnames in #line strings)
eb480a0b 455XSUBPP = ..\$(MINIPERL) -I..\..\lib ..\$(EXTUTILSDIR)\xsubpp \
456 -C++ -prototypes
457
852c2e52 458MICROCORE_SRC = \
eb480a0b 459 ..\av.c \
eb480a0b 460 ..\deb.c \
461 ..\doio.c \
462 ..\doop.c \
463 ..\dump.c \
464 ..\globals.c \
465 ..\gv.c \
466 ..\hv.c \
467 ..\mg.c \
468 ..\op.c \
469 ..\perl.c \
51371543 470 ..\perlapi.c \
eb480a0b 471 ..\perly.c \
472 ..\pp.c \
473 ..\pp_ctl.c \
474 ..\pp_hot.c \
475 ..\pp_sys.c \
476 ..\regcomp.c \
477 ..\regexec.c \
478 ..\run.c \
479 ..\scope.c \
480 ..\sv.c \
481 ..\taint.c \
482 ..\toke.c \
483 ..\universal.c \
a176fa2a 484 ..\utf8.c \
349fd7b7 485 ..\util.c \
486 ..\xsutils.c
eb480a0b 487
0cb96387 488EXTRACORE_SRC = $(EXTRACORE_SRC) perllib.c
489
eb480a0b 490!IF "$(PERL_MALLOC)" == "define"
852c2e52 491EXTRACORE_SRC = $(EXTRACORE_SRC) ..\malloc.c
eb480a0b 492!ENDIF
493
c5be433b 494!IF "$(USE_OBJECT)" != "define"
852c2e52 495EXTRACORE_SRC = $(EXTRACORE_SRC) ..\perlio.c
eb480a0b 496!ENDIF
497
498WIN32_SRC = \
499 .\win32.c \
500 .\win32sck.c
501
502!IF "$(USE_THREADS)" == "define"
503WIN32_SRC = $(WIN32_SRC) .\win32thread.c
504!ENDIF
505
8d9b2e3c 506!IF "$(CRYPT_SRC)" != ""
507WIN32_SRC = $(WIN32_SRC) .\$(CRYPT_SRC)
508!ENDIF
509
eb480a0b 510PERL95_SRC = \
511 perl95.c \
512 win32mt.c \
513 win32sckmt.c
514
a1dd9325 515!IF "$(CRYPT_SRC)" != ""
8d9b2e3c 516PERL95_SRC = $(PERL95_SRC) .\$(CRYPT_SRC)
a1dd9325 517!ENDIF
518
eb480a0b 519DLL_SRC = $(DYNALOADER).c
520
eb480a0b 521X2P_SRC = \
522 ..\x2p\a2p.c \
523 ..\x2p\hash.c \
524 ..\x2p\str.c \
525 ..\x2p\util.c \
526 ..\x2p\walk.c
527
852c2e52 528CORE_NOCFG_H = \
eb480a0b 529 ..\av.h \
eb480a0b 530 ..\cop.h \
531 ..\cv.h \
532 ..\dosish.h \
533 ..\embed.h \
534 ..\form.h \
535 ..\gv.h \
536 ..\handy.h \
537 ..\hv.h \
0f4eea8f 538 ..\iperlsys.h \
eb480a0b 539 ..\mg.h \
540 ..\nostdio.h \
541 ..\op.h \
542 ..\opcode.h \
543 ..\perl.h \
51371543 544 ..\perlapi.h \
eb480a0b 545 ..\perlsdio.h \
546 ..\perlsfio.h \
547 ..\perly.h \
548 ..\pp.h \
549 ..\proto.h \
550 ..\regexp.h \
551 ..\scope.h \
552 ..\sv.h \
553 ..\thread.h \
554 ..\unixish.h \
a176fa2a 555 ..\utf8.h \
eb480a0b 556 ..\util.h \
2985053f 557 ..\warnings.h \
eb480a0b 558 ..\XSUB.h \
eb480a0b 559 ..\EXTERN.h \
560 ..\perlvars.h \
561 ..\intrpvar.h \
562 ..\thrdvar.h \
563 .\include\dirent.h \
564 .\include\netdb.h \
565 .\include\sys\socket.h \
7766f137 566 .\win32.h \
567 .\perlhost.h \
568 .\vdir.h \
569 .\vmem.h
eb480a0b 570
852c2e52 571CORE_H = $(CORE_NOCFG_H) .\config.h
572
573MICROCORE_OBJ = $(MICROCORE_SRC:.c=.obj)
574CORE_OBJ = $(MICROCORE_OBJ) $(EXTRACORE_SRC:.c=.obj)
eb480a0b 575WIN32_OBJ = $(WIN32_SRC:.c=.obj)
852c2e52 576MINICORE_OBJ = $(MICROCORE_OBJ:..\=.\mini\) \
577 $(MINIDIR)\miniperlmain$(o) \
578 $(MINIDIR)\perlio$(o)
eb480a0b 579MINIWIN32_OBJ = $(WIN32_OBJ:.\=.\mini\)
580MINI_OBJ = $(MINICORE_OBJ) $(MINIWIN32_OBJ)
af883608 581PERL95_OBJ = $(PERL95_SRC:.c=.obj)
eb480a0b 582DLL_OBJ = $(DLL_SRC:.c=.obj)
583X2P_OBJ = $(X2P_SRC:.c=.obj)
584
eb480a0b 585PERLDLL_OBJ = $(CORE_OBJ)
586PERLEXE_OBJ = perlmain$(o)
587
eb480a0b 588PERLDLL_OBJ = $(PERLDLL_OBJ) $(WIN32_OBJ) $(DLL_OBJ)
0cb96387 589#PERLEXE_OBJ = $(PERLEXE_OBJ) $(WIN32_OBJ) $(DLL_OBJ)
590#PERL95_OBJ = $(PERL95_OBJ) DynaLoadmt$(o)
eb480a0b 591
baed7233 592!IF "$(USE_SETARGV)" != ""
593SETARGV_OBJ = setargv$(o)
594!ENDIF
595
823edd99 596DYNAMIC_EXT = Socket IO Fcntl Opcode SDBM_File POSIX attrs Thread B re \
4f49e16e 597 Data/Dumper Devel/Peek ByteLoader Devel/DProf File/Glob
eb480a0b 598STATIC_EXT = DynaLoader
eab60bb1 599NONXS_EXT = Errno
eb480a0b 600
601DYNALOADER = $(EXTDIR)\DynaLoader\DynaLoader
602SOCKET = $(EXTDIR)\Socket\Socket
603FCNTL = $(EXTDIR)\Fcntl\Fcntl
604OPCODE = $(EXTDIR)\Opcode\Opcode
605SDBM_FILE = $(EXTDIR)\SDBM_File\SDBM_File
606IO = $(EXTDIR)\IO\IO
607POSIX = $(EXTDIR)\POSIX\POSIX
608ATTRS = $(EXTDIR)\attrs\attrs
609THREAD = $(EXTDIR)\Thread\Thread
610B = $(EXTDIR)\B\B
823edd99 611RE = $(EXTDIR)\re\re
612DUMPER = $(EXTDIR)\Data\Dumper\Dumper
eab60bb1 613ERRNO = $(EXTDIR)\Errno\Errno
3967c732 614PEEK = $(EXTDIR)\Devel\Peek\Peek
a6c40364 615BYTELOADER = $(EXTDIR)\ByteLoader\ByteLoader
38b3a85b 616DPROF = $(EXTDIR)\Devel\DProf\DProf
4f49e16e 617GLOB = $(EXTDIR)\File\Glob\Glob
eb480a0b 618
619SOCKET_DLL = $(AUTODIR)\Socket\Socket.dll
620FCNTL_DLL = $(AUTODIR)\Fcntl\Fcntl.dll
621OPCODE_DLL = $(AUTODIR)\Opcode\Opcode.dll
622SDBM_FILE_DLL = $(AUTODIR)\SDBM_File\SDBM_File.dll
623IO_DLL = $(AUTODIR)\IO\IO.dll
624POSIX_DLL = $(AUTODIR)\POSIX\POSIX.dll
625ATTRS_DLL = $(AUTODIR)\attrs\attrs.dll
626THREAD_DLL = $(AUTODIR)\Thread\Thread.dll
627B_DLL = $(AUTODIR)\B\B.dll
823edd99 628DUMPER_DLL = $(AUTODIR)\Data\Dumper\Dumper.dll
3967c732 629PEEK_DLL = $(AUTODIR)\Devel\Peek\Peek.dll
15e52e56 630RE_DLL = $(AUTODIR)\re\re.dll
b295d113 631BYTELOADER_DLL = $(AUTODIR)\ByteLoader\ByteLoader.dll
38b3a85b 632DPROF_DLL = $(AUTODIR)\Devel\DProf\DProf.dll
4f49e16e 633GLOB_DLL = $(AUTODIR)\File\Glob\Glob.dll
eb480a0b 634
eab60bb1 635ERRNO_PM = $(LIBDIR)\Errno.pm
636
eb480a0b 637EXTENSION_C = \
638 $(SOCKET).c \
639 $(FCNTL).c \
640 $(OPCODE).c \
641 $(SDBM_FILE).c \
642 $(IO).c \
643 $(POSIX).c \
644 $(ATTRS).c \
645 $(THREAD).c \
15e52e56 646 $(RE).c \
823edd99 647 $(DUMPER).c \
3967c732 648 $(PEEK).c \
b295d113 649 $(B).c \
38b3a85b 650 $(BYTELOADER).c \
4f49e16e 651 $(DPROF).c \
652 $(GLOB).c
eb480a0b 653
654EXTENSION_DLL = \
655 $(SOCKET_DLL) \
656 $(FCNTL_DLL) \
657 $(OPCODE_DLL) \
658 $(SDBM_FILE_DLL)\
659 $(IO_DLL) \
660 $(POSIX_DLL) \
51aa15f3 661 $(ATTRS_DLL) \
823edd99 662 $(DUMPER_DLL) \
3967c732 663 $(PEEK_DLL) \
b295d113 664 $(B_DLL) \
c5be433b 665 $(RE_DLL) \
666 $(THREAD_DLL) \
38b3a85b 667 $(BYTELOADER_DLL) \
4f49e16e 668 $(DPROF_DLL) \
669 $(GLOB_DLL)
26ca90b6 670
eab60bb1 671EXTENSION_PM = \
672 $(ERRNO_PM)
673
eb480a0b 674POD2HTML = $(PODDIR)\pod2html
675POD2MAN = $(PODDIR)\pod2man
676POD2LATEX = $(PODDIR)\pod2latex
677POD2TEXT = $(PODDIR)\pod2text
678
679CFG_VARS = \
680 "INST_DRV=$(INST_DRV)" \
681 "INST_TOP=$(INST_TOP)" \
e5a95ffb 682 "INST_VER=$(INST_VER)" \
0cb96387 683 "INST_ARCH=$(INST_ARCH)" \
eb480a0b 684 "archname=$(ARCHNAME)" \
685 "cc=$(CC)" \
c5be433b 686 "ccflags=$(OPTIMIZE:"=\") $(DEFINES) $(BUILDOPT)" \
eb480a0b 687 "cf_email=$(EMAIL)" \
688 "d_crypt=$(D_CRYPT)" \
689 "d_mymalloc=$(PERL_MALLOC)" \
690 "libs=$(LIBFILES)" \
80252599 691 "incpath=$(CCINCDIR:"=\")" \
692 "libperl=$(PERLIMPLIB:..\=)" \
693 "libpth=$(CCLIBDIR:"=\");$(EXTRALIBDIRS:"=\")" \
eb480a0b 694 "libc=$(LIBC)" \
695 "make=nmake" \
696 "static_ext=$(STATIC_EXT)" \
697 "dynamic_ext=$(DYNAMIC_EXT)" \
eab60bb1 698 "nonxs_ext=$(NONXS_EXT)" \
eb480a0b 699 "usethreads=$(USE_THREADS)" \
b86a2fa7 700 "usemultiplicity=$(USE_MULTI)" \
80252599 701 "LINK_FLAGS=$(LINK_FLAGS:"=\")" \
702 "optimize=$(OPTIMIZE:"=\")"
924b3ec4 703
137443ea 704#
705# Top targets
706#
0a753a76 707
852c2e52 708all : .\config.h $(GLOBEXE) $(MINIMOD) $(CONFIGPM) $(PERLEXE) $(PERL95EXE) \
c5be433b 709 $(X2P) $(EXTENSION_DLL) $(EXTENSION_PM)
0a753a76 710
d56e6723 711$(DYNALOADER)$(o) : $(DYNALOADER).c $(CORE_H) $(EXTDIR)\DynaLoader\dlutils.c
0a753a76 712
137443ea 713#------------------------------------------------------------
0a753a76 714
eb480a0b 715$(GLOBEXE) : perlglob$(o)
dc050285 716 $(LINK32) $(LINK_FLAGS) $(LIBFILES) -out:$@ -subsystem:$(SUBSYS) \
d56e6723 717 perlglob$(o) setargv$(o)
0a753a76 718
d56e6723 719perlglob$(o) : perlglob.c
137443ea 720
3e3baf6d 721config.w32 : $(CFGSH_TMPL)
722 copy $(CFGSH_TMPL) config.w32
723
d55594ae 724.\config.h : $(CFGH_TMPL)
3e3baf6d 725 -del /f config.h
726 copy $(CFGH_TMPL) config.h
727
137443ea 728..\config.sh : config.w32 $(MINIPERL) config_sh.PL
924b3ec4 729 $(MINIPERL) -I..\lib config_sh.PL $(CFG_VARS) config.w32 > ..\config.sh
137443ea 730
ac4c12e7 731# this target is for when changes to the main config.sh happen
732# edit config.{b,v,g}c and make this target once for each supported
733# compiler (e.g. `dmake CCTYPE=BORLAND regen_config_h`)
734regen_config_h:
735 perl config_sh.PL $(CFG_VARS) $(CFGSH_TMPL) > ..\config.sh
736 cd ..
737 -del /f perl.exe
738 perl configpm
739 cd win32
740 -del /f $(CFGH_TMPL)
80252599 741 -mkdir $(COREDIR)
e5a95ffb 742 -perl -I..\lib config_h.PL "INST_VER=$(INST_VER)"
ac4c12e7 743 rename config.h $(CFGH_TMPL)
744
83437bec 745$(CONFIGPM) : $(MINIPERL) ..\config.sh config_h.PL ..\minimod.pl
137443ea 746 cd .. && miniperl configpm
c90c0ff4 747 if exist lib\* $(RCOPY) lib\*.* ..\lib\$(NULL)
d07c2202 748 $(XCOPY) ..\*.h $(COREDIR)\*.*
749 $(XCOPY) *.h $(COREDIR)\*.*
15e52e56 750 $(XCOPY) ..\ext\re\re.pm $(LIBDIR)\*.*
d07c2202 751 $(RCOPY) include $(COREDIR)\*.*
e5a95ffb 752 $(MINIPERL) -I..\lib config_h.PL "INST_VER=$(INST_VER)" \
80252599 753 || $(MAKE) /$(MAKEFLAGS) $(CONFIGPM)
137443ea 754
eb480a0b 755$(MINIPERL) : $(MINIDIR) $(MINI_OBJ)
137443ea 756 $(LINK32) -subsystem:console -out:$@ @<<
eb480a0b 757 $(LINK_FLAGS) $(LIBFILES) $(MINI_OBJ)
137443ea 758<<
759
eb480a0b 760$(MINIDIR) :
761 if not exist "$(MINIDIR)" mkdir "$(MINIDIR)"
762
852c2e52 763$(MINICORE_OBJ) : $(CORE_NOCFG_H)
eb480a0b 764 $(CC) -c $(CFLAGS) $(OBJOUT_FLAG)$@ ..\$(*F).c
765
852c2e52 766$(MINIWIN32_OBJ) : $(CORE_NOCFG_H)
eb480a0b 767 $(CC) -c $(CFLAGS) $(OBJOUT_FLAG)$@ $(*F).c
768
7766f137 769# -DPERL_IMPLICIT_SYS needs C++ for perllib.c
770!IF "$(USE_IMP_SYS)$(USE_OBJECT)" == "defineundef"
771perllib$(o) : perllib.c
772 $(CC) -c -I. $(CFLAGS_O) $(CXX_FLAG) $(OBJOUT_FLAG)$@ perllib.c
773!ENDIF
774
852c2e52 775# 1. we don't want to rebuild miniperl.exe when config.h changes
776# 2. we don't want to rebuild miniperl.exe with non-default config.h
777$(MINI_OBJ) : $(CORE_NOCFG_H)
778
eb480a0b 779$(WIN32_OBJ) : $(CORE_H)
780$(CORE_OBJ) : $(CORE_H)
eb480a0b 781$(DLL_OBJ) : $(CORE_H)
782$(PERL95_OBJ) : $(CORE_H)
783$(X2P_OBJ) : $(CORE_H)
0a753a76 784
549a6b10 785perldll.def : $(MINIPERL) $(CONFIGPM) ..\global.sym ..\pp.sym ..\makedef.pl
786 $(MINIPERL) -w ..\makedef.pl PLATFORM=win32 $(OPTIMIZE) $(DEFINES) $(BUILDOPT) \
910dfcc8 787 CCTYPE=$(CCTYPE) > perldll.def
0a753a76 788
eb480a0b 789$(PERLDLL): perldll.def $(PERLDLL_OBJ)
137443ea 790 $(LINK32) -dll -def:perldll.def -out:$@ @<<
eb480a0b 791 $(LINK_FLAGS) $(LIBFILES) $(PERLDLL_OBJ)
137443ea 792<<
d07c2202 793 $(XCOPY) $(PERLIMPLIB) $(COREDIR)
137443ea 794
83437bec 795$(MINIMOD) : $(MINIPERL) ..\minimod.pl
796 cd .. && miniperl minimod.pl > lib\ExtUtils\Miniperl.pm
797
eb480a0b 798..\x2p\a2p$(o) : ..\x2p\a2p.c
799 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\a2p.c
800
801..\x2p\hash$(o) : ..\x2p\hash.c
802 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\hash.c
803
804..\x2p\str$(o) : ..\x2p\str.c
805 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\str.c
806
807..\x2p\util$(o) : ..\x2p\util.c
808 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\util.c
809
810..\x2p\walk$(o) : ..\x2p\walk.c
811 $(CC) -I..\x2p $(CFLAGS) $(OBJOUT_FLAG)$@ -c ..\x2p\walk.c
812
813$(X2P) : $(MINIPERL) $(X2P_OBJ)
814 $(MINIPERL) ..\x2p\find2perl.PL
815 $(MINIPERL) ..\x2p\s2p.PL
d07c2202 816 $(LINK32) -subsystem:console -out:$@ @<<
eb480a0b 817 $(LINK_FLAGS) $(LIBFILES) $(X2P_OBJ)
d07c2202 818<<
819
83437bec 820perlmain.c : runperl.c
0a753a76 821 copy runperl.c perlmain.c
137443ea 822
d56e6723 823perlmain$(o) : perlmain.c
8957be0a 824 $(CC) $(CFLAGS_O) -UPERLDLL $(OBJOUT_FLAG)$@ -c perlmain.c
137443ea 825
eb480a0b 826$(PERLEXE): $(PERLDLL) $(CONFIGPM) $(PERLEXE_OBJ)
827 $(LINK32) -subsystem:console -out:$@ $(LINK_FLAGS) $(LIBFILES) \
baed7233 828 $(PERLEXE_OBJ) $(SETARGV_OBJ) $(PERLIMPLIB)
7766f137 829 copy $(PERLEXE) $(WPERLEXE)
830 editbin /subsystem:windows $(WPERLEXE)
0a753a76 831 copy splittree.pl ..
eb480a0b 832 $(MINIPERL) -I..\lib ..\splittree.pl "../LIB" $(AUTODIR)
0a753a76 833
7766f137 834!IF "$(BUILD_FOR_WIN95)" == "define"
e7083a8c 835
3e3baf6d 836perl95.c : runperl.c
837 copy runperl.c perl95.c
838
d56e6723 839perl95$(o) : perl95.c
eb480a0b 840 $(CC) $(CFLAGS_O) -MT -UPERLDLL -DWIN95FIX -c perl95.c
3e3baf6d 841
d56e6723 842win32sckmt$(o) : win32sck.c
eb480a0b 843 $(CC) $(CFLAGS_O) -MT -UPERLDLL -DWIN95FIX -c \
844 $(OBJOUT_FLAG)win32sckmt$(o) win32sck.c
fb73857a 845
d56e6723 846win32mt$(o) : win32.c
eb480a0b 847 $(CC) $(CFLAGS_O) -MT -UPERLDLL -DWIN95FIX -c \
848 $(OBJOUT_FLAG)win32mt$(o) win32.c
fb73857a 849
ac4c12e7 850DynaLoadmt$(o) : $(DYNALOADER).c
851 $(CC) $(CFLAGS_O) -MT -UPERLDLL -DWIN95FIX -c \
852 $(OBJOUT_FLAG)DynaLoadmt$(o) $(DYNALOADER).c
c69f6586 853
fb73857a 854$(PERL95EXE): $(PERLDLL) $(CONFIGPM) $(PERL95_OBJ)
eb480a0b 855 $(LINK32) -subsystem:console -nodefaultlib -out:$@ $(LINK_FLAGS) \
baed7233 856 $(LIBBASEFILES) $(PERL95_OBJ) $(SETARGV_OBJ) $(PERLIMPLIB) \
857 libcmt.lib
e7083a8c 858
859!ENDIF
3e3baf6d 860
137443ea 861$(DYNALOADER).c: $(MINIPERL) $(EXTDIR)\DynaLoader\dl_win32.xs $(CONFIGPM)
eb480a0b 862 if not exist $(AUTODIR) mkdir $(AUTODIR)
a1dd9325 863 cd $(EXTDIR)\$(*B)
bfab39a2 864 ..\$(MINIPERL) -I..\..\lib $(*B)_pm.PL
8454a2ba 865 ..\$(MINIPERL) -I..\..\lib XSLoader_pm.PL
a1dd9325 866 cd ..\..\win32
68dc0745 867 $(XCOPY) $(EXTDIR)\$(*B)\$(*B).pm $(LIBDIR)\$(NULL)
8454a2ba 868 $(XCOPY) $(EXTDIR)\$(*B)\XSLoader.pm $(LIBDIR)\$(NULL)
68dc0745 869 cd $(EXTDIR)\$(*B)
870 $(XSUBPP) dl_win32.xs > $(*B).c
0a753a76 871 cd ..\..\win32
872
68dc0745 873$(EXTDIR)\DynaLoader\dl_win32.xs: dl_win32.xs
874 copy dl_win32.xs $(EXTDIR)\DynaLoader\dl_win32.xs
0a753a76 875
823edd99 876$(DUMPER_DLL): $(PERLEXE) $(DUMPER).xs
877 cd $(EXTDIR)\Data\$(*B)
878 ..\..\..\miniperl -I..\..\..\lib Makefile.PL INSTALLDIRS=perl
879 $(MAKE)
880 cd ..\..\..\win32
881
38b3a85b 882$(DPROF_DLL): $(PERLEXE) $(DPROF).xs
883 cd $(EXTDIR)\Devel\$(*B)
884 ..\..\..\miniperl -I..\..\..\lib Makefile.PL INSTALLDIRS=perl
885 $(MAKE)
886 cd ..\..\..\win32
887
4f49e16e 888$(GLOB_DLL): $(PERLEXE) $(GLOB).xs
889 cd $(EXTDIR)\File\$(*B)
890 ..\..\..\miniperl -I..\..\..\lib Makefile.PL INSTALLDIRS=perl
891 $(MAKE)
892 cd ..\..\..\win32
893
3967c732 894$(PEEK_DLL): $(PERLEXE) $(PEEK).xs
895 cd $(EXTDIR)\Devel\$(*B)
896 ..\..\..\miniperl -I..\..\..\lib Makefile.PL INSTALLDIRS=perl
897 $(MAKE)
898 cd ..\..\..\win32
899
15e52e56 900$(RE_DLL): $(PERLEXE) $(RE).xs
901 cd $(EXTDIR)\$(*B)
902 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
903 $(MAKE)
904 cd ..\..\win32
905
2a321948 906$(B_DLL): $(PERLEXE) $(B).xs
a98bd6f4 907 cd $(EXTDIR)\$(*B)
908 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
909 $(MAKE)
910 cd ..\..\win32
911
d55594ae 912$(THREAD_DLL): $(PERLEXE) $(THREAD).xs
059e4e88 913 cd $(EXTDIR)\$(*B)
914 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
915 $(MAKE)
916 cd ..\..\win32
917
2a321948 918$(ATTRS_DLL): $(PERLEXE) $(ATTRS).xs
919 cd $(EXTDIR)\$(*B)
920 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
921 $(MAKE)
922 cd ..\..\win32
d55594ae 923
6dead956 924$(POSIX_DLL): $(PERLEXE) $(POSIX).xs
925 cd $(EXTDIR)\$(*B)
926 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
927 $(MAKE)
928 cd ..\..\win32
929
eb480a0b 930$(IO_DLL): $(PERLEXE) $(IO).xs
68dc0745 931 cd $(EXTDIR)\$(*B)
137443ea 932 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
933 $(MAKE)
0a753a76 934 cd ..\..\win32
935
137443ea 936$(SDBM_FILE_DLL) : $(PERLEXE) $(SDBM_FILE).xs
68dc0745 937 cd $(EXTDIR)\$(*B)
137443ea 938 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
939 $(MAKE)
68dc0745 940 cd ..\..\win32
0a753a76 941
137443ea 942$(FCNTL_DLL): $(PERLEXE) $(FCNTL).xs
68dc0745 943 cd $(EXTDIR)\$(*B)
137443ea 944 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
945 $(MAKE)
0a753a76 946 cd ..\..\win32
947
137443ea 948$(OPCODE_DLL): $(PERLEXE) $(OPCODE).xs
68dc0745 949 cd $(EXTDIR)\$(*B)
137443ea 950 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
951 $(MAKE)
68dc0745 952 cd ..\..\win32
0a753a76 953
059e4e88 954$(SOCKET_DLL): $(PERLEXE) $(SOCKET).xs
68dc0745 955 cd $(EXTDIR)\$(*B)
137443ea 956 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
957 $(MAKE)
0a753a76 958 cd ..\..\win32
959
b295d113 960$(BYTELOADER_DLL): $(PERLEXE) $(BYTELOADER).xs
961 cd $(EXTDIR)\$(*B)
962 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
963 $(MAKE)
964 cd ..\..\win32
965
eab60bb1 966$(ERRNO_PM): $(PERLEXE) $(ERRNO)_pm.PL
967 cd $(EXTDIR)\$(*B)
968 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
969 $(MAKE)
970 cd ..\..\win32
971
68dc0745 972doc: $(PERLEXE)
d07c2202 973 $(PERLEXE) -I..\lib ..\installhtml --podroot=.. --htmldir=./html \
b3b61bd8 974 --podpath=pod:lib:ext:utils --htmlroot="file://$(INST_HTML::=|)" \
3e3baf6d 975 --libpod=perlfunc:perlguts:perlvar:perlrun:perlop --recurse
68dc0745 976
4a71ed0c 977utils: $(PERLEXE) $(X2P)
3fe9a6f1 978 cd ..\utils
eb480a0b 979 $(MAKE) PERL=$(MINIPERL)
4a71ed0c 980 cd ..\pod
66aa1127 981 copy ..\README.win32 .\perlwin32.pod
4a71ed0c 982 $(MAKE) -f ..\win32\pod.mak converters
3fe9a6f1 983 cd ..\win32
4a71ed0c 984 $(PERLEXE) $(PL2BAT) $(UTILS)
3fe9a6f1 985
137443ea 986distclean: clean
dc050285 987 -del /f $(MINIPERL) $(PERLEXE) $(PERL95EXE) $(PERLDLL) $(GLOBEXE) \
83437bec 988 $(PERLIMPLIB) ..\miniperl.lib $(MINIMOD)
3e3baf6d 989 -del /f *.def *.map
eab60bb1 990 -del /f $(EXTENSION_DLL) $(EXTENSION_PM)
991 -del /f $(EXTENSION_C) $(DYNALOADER).c $(ERRNO).pm
eb480a0b 992 -del /f $(EXTDIR)\DynaLoader\dl_win32.xs
993 -del /f $(LIBDIR)\.exists $(LIBDIR)\attrs.pm $(LIBDIR)\DynaLoader.pm
8454a2ba 994 -del /f $(LIBDIR)\XSLoader.pm
eb480a0b 995 -del /f $(LIBDIR)\Fcntl.pm $(LIBDIR)\IO.pm $(LIBDIR)\Opcode.pm
996 -del /f $(LIBDIR)\ops.pm $(LIBDIR)\Safe.pm $(LIBDIR)\Thread.pm
997 -del /f $(LIBDIR)\SDBM_File.pm $(LIBDIR)\Socket.pm $(LIBDIR)\POSIX.pm
15e52e56 998 -del /f $(LIBDIR)\B.pm $(LIBDIR)\O.pm $(LIBDIR)\re.pm
b295d113 999 -del /f $(LIBDIR)\Data\Dumper.pm $(LIBDIR)\ByteLoader.pm
38b3a85b 1000 -del /f $(LIBDIR)\Devel\Peek.pm $(LIBDIR)\Devel\DProf.pm
4f49e16e 1001 -del /f $(LIBDIR)\File\Glob.pm
eb480a0b 1002 -rmdir /s /q $(LIBDIR)\IO || rmdir /s $(LIBDIR)\IO
1003 -rmdir /s /q $(LIBDIR)\Thread || rmdir /s $(LIBDIR)\Thread
1004 -rmdir /s /q $(LIBDIR)\B || rmdir /s $(LIBDIR)\B
823edd99 1005 -rmdir /s /q $(LIBDIR)\Data || rmdir /s $(LIBDIR)\Data
68dc0745 1006 -del /f $(PODDIR)\*.html
1007 -del /f $(PODDIR)\*.bat
eb480a0b 1008 cd ..\utils
95667ae4 1009 -del /f h2ph splain perlbug pl2pm c2ph h2xs perldoc pstruct dprofpp
eb480a0b 1010 -del /f *.bat
1011 cd ..\win32
1012 cd ..\x2p
1013 -del /f find2perl s2p
1014 -del /f *.bat
1015 cd ..\win32
1016 -del /f ..\config.sh ..\splittree.pl perlmain.c dlutils.c config.h.new
1017 -del /f $(CONFIGPM)
1018 -del /f perl95.c
d444a431 1019 -del /f bin\*.bat
3e3baf6d 1020 cd $(EXTDIR)
22c35a8c 1021 -del /s *.lib *.def *.map *.pdb *.bs Makefile *$(o) pm_to_blib
3e3baf6d 1022 cd ..\win32
eb480a0b 1023 -rmdir /s /q $(AUTODIR) || rmdir /s $(AUTODIR)
1024 -rmdir /s /q $(COREDIR) || rmdir /s $(COREDIR)
68dc0745 1025
4a71ed0c 1026install : all installbare installhtml
6dead956 1027
4a71ed0c 1028installbare : utils
d07c2202 1029 $(PERLEXE) ..\installperl
7766f137 1030!IF "$(BUILD_FOR_WIN95)" == "define"
3e3baf6d 1031 $(XCOPY) $(PERL95EXE) $(INST_BIN)\*.*
e7083a8c 1032!ENDIF
7766f137 1033 if exist $(WPERLEXE) $(XCOPY) $(WPERLEXE) $(INST_BIN)\*.*
68dc0745 1034 $(XCOPY) $(GLOBEXE) $(INST_BIN)\*.*
e5a95ffb 1035 $(XCOPY) bin\*.bat $(INST_SCRIPT)\*.*
6dead956 1036
1037installhtml : doc
3e3baf6d 1038 $(RCOPY) html\*.* $(INST_HTML)\*.*
68dc0745 1039
137443ea 1040inst_lib : $(CONFIGPM)
68dc0745 1041 copy splittree.pl ..
eb480a0b 1042 $(MINIPERL) -I..\lib ..\splittree.pl "../LIB" $(AUTODIR)
c90c0ff4 1043 $(RCOPY) ..\lib $(INST_LIB)\*.*
0a753a76 1044
dfb634a9 1045minitest : $(MINIPERL) $(GLOBEXE) $(CONFIGPM) utils
137443ea 1046 $(XCOPY) $(MINIPERL) ..\t\perl.exe
1047 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
1048 attrib -r ..\t\*.*
1049 copy test ..\t
1050 cd ..\t
1051 $(MINIPERL) -I..\lib test base/*.t comp/*.t cmd/*.t io/*.t op/*.t pragma/*.t
1052 cd ..\win32
1053
dfb634a9 1054test-prep : all utils
68dc0745 1055 $(XCOPY) $(PERLEXE) ..\t\$(NULL)
1056 $(XCOPY) $(PERLDLL) ..\t\$(NULL)
1057 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
fb73857a 1058
1059test : test-prep
1060 cd ..\t
1061 $(PERLEXE) -I..\lib harness
1062 cd ..\win32
1063
1064test-notty : test-prep
1065 set PERL_SKIP_TTY_TEST=1
137443ea 1066 cd ..\t
1067 $(PERLEXE) -I..\lib harness
68dc0745 1068 cd ..\win32
137443ea 1069
1070clean :
d56e6723 1071 -@erase miniperlmain$(o)
137443ea 1072 -@erase $(MINIPERL)
d56e6723 1073 -@erase perlglob$(o)
1074 -@erase perlmain$(o)
3e3baf6d 1075 -@erase config.w32
1076 -@erase /f config.h
137443ea 1077 -@erase $(GLOBEXE)
1078 -@erase $(PERLEXE)
7766f137 1079 -@erase $(WPERLEXE)
137443ea 1080 -@erase $(PERLDLL)
1081 -@erase $(CORE_OBJ)
eb480a0b 1082 -rmdir /s /q $(MINIDIR) || rmdir /s $(MINIDIR)
137443ea 1083 -@erase $(WIN32_OBJ)
1084 -@erase $(DLL_OBJ)
d07c2202 1085 -@erase $(X2P_OBJ)
c5be433b 1086 -@erase ..\*$(o) ..\*.lib ..\*.exp *$(o) *.lib *.exp *.res
d444a431 1087 -@erase ..\t\*.exe ..\t\*.dll ..\t\*.bat
d07c2202 1088 -@erase ..\x2p\*.exe ..\x2p\*.bat
137443ea 1089 -@erase *.ilk
1090 -@erase *.pdb