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