This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Further ANSI changes now builds and passes (most) tests
[perl5.git] / win32 / makefile.mk
CommitLineData
08aa1457
PP
1#
2# Makefile to build perl on Windowns NT using Microsoft NMAKE.
3#
4#
5# This is set up to build a perl.exe that runs off a shared library
6# (perl.dll). Also makes individual DLLs for the XS extensions.
7#
8
9#
10# Set these to wherever you want "nmake install" to put your
11# newly built perl.
12INST_DRV=c:
13INST_TOP=$(INST_DRV)\perl
f0f333f4 14BUILDOPT=-DUSE_THREADS
08aa1457
PP
15
16#
17# uncomment one if you are using Visual C++ 2.x or Borland
18# comment out both if you are using Visual C++ 4.x and above
19#CCTYPE=MSVC20
20CCTYPE=BORLAND
21
22#
23# uncomment next line if you want debug version of perl (big,slow)
24#CFG=Debug
25
26#
27# set the install locations of the compiler include/libraries
28#CCHOME = f:\msdev\vc
f0f333f4 29CCHOME = C:\bc5
08aa1457
PP
30CCINCDIR = $(CCHOME)\include
31CCLIBDIR = $(CCHOME)\lib
32
33#
34# set this to point to cmd.exe (only needed if you use some
35# alternate shell that doesn't grok cmd.exe style commands)
f0f333f4 36#SHELL = g:\winnt\system32\cmd.exe
08aa1457
PP
37
38#
39# set this to your email address (perl will guess a value from
40# from your loginname and your hostname, which may not be right)
41#EMAIL =
42
43##################### CHANGE THESE ONLY IF YOU MUST #####################
44
45#
46# Programs to compile, build .lib files and link
47#
48
49.USESHELL :
50
51.IF "$(CCTYPE)" == "BORLAND"
52
53CC = bcc32
54LINK32 = tlink32
55LIB32 = tlib
56IMPLIB = implib
57
58#
59# Options
60#
61RUNTIME = -D_RTLDLL
62INCLUDES = -I.\include -I. -I.. -I$(CCINCDIR)
63#PCHFLAGS = -H -H$(INTDIR)\bcmoduls.pch
f0f333f4
NIS
64DEFINES = -DWIN32 $(BUILDOPT) -D_WIN32_WINNT=0x400
65LOCDEFS = -DPERLDLL
08aa1457
PP
66SUBSYS = console
67LIBC = cw32mti.lib
68LIBFILES = import32.lib $(LIBC) odbc32.lib odbccp32.lib
69
70WINIOMAYBE =
71
72.IF "$(CFG)" == "Debug"
73OPTIMIZE = -v $(RUNTIME)
74LINK_DBG = -v
75.ELSE
f0f333f4 76OPTIMIZE = -5 -O2 $(RUNTIME)
08aa1457
PP
77LINK_DBG =
78.ENDIF
79
f0f333f4 80CFLAGS = -w -tWM -tWD $(INCLUDES) $(DEFINES) $(LOCDEFS) $(PCHFLAGS) $(OPTIMIZE)
08aa1457
PP
81LINK_FLAGS = $(LINK_DBG) -L$(CCLIBDIR)
82OBJOUT_FLAG = -o
83
84.ELSE
85
86CC=cl.exe
87LINK32=link.exe
88LIB32=$(LINK32) -lib
89#
90# Options
91#
92.IF "$(RUNTIME)" == ""
93RUNTIME = -MD
94.ENDIF
95INCLUDES = -I.\include -I. -I..
96#PCHFLAGS = -Fp$(INTDIR)\vcmoduls.pch -YX
f0f333f4
NIS
97DEFINES = -DWIN32 $(BUILDOPT) -D_CONSOLE -D_WIN32_WINNT=0x400
98LOCDEFS = -DPERLDLL
08aa1457
PP
99SUBSYS = console
100
101.IF "$(RUNTIME)" == "-MD"
102LIBC = msvcrt.lib
103WINIOMAYBE =
104.ELSE
105LIBC = libcmt.lib
106WINIOMAYBE = win32io.obj
107.ENDIF
108
109.IF "$(CFG)" == "Debug"
110.IF "$(CCTYPE)" == "MSVC20"
111OPTIMIZE = -Od $(RUNTIME) -Z7 -D_DEBUG
112.ELSE
113OPTIMIZE = -Od $(RUNTIME)d -Z7 -D_DEBUG
114.ENDIF
115LINK_DBG = -debug -pdb:none
116.ELSE
117.IF "$(CCTYPE)" == "MSVC20"
118OPTIMIZE = -Od $(RUNTIME) -DNDEBUG
119.ELSE
120OPTIMIZE = -Od $(RUNTIME) -DNDEBUG
121.ENDIF
122LINK_DBG = -release
123.ENDIF
124
125# we don't add LIBC here, the compiler do it based on -MD/-MT
126LIBFILES = oldnames.lib kernel32.lib user32.lib gdi32.lib \
127 winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib \
128 oleaut32.lib netapi32.lib uuid.lib wsock32.lib mpr.lib winmm.lib \
129 version.lib odbc32.lib odbccp32.lib
130
f0f333f4 131CFLAGS = -nologo -W3 $(INCLUDES) $(DEFINES) $(LOCDEFS) $(PCHFLAGS) $(OPTIMIZE)
08aa1457
PP
132LINK_FLAGS = -nologo $(LIBFILES) $(LINK_DBG) -machine:I386
133OBJOUT_FLAG = -Fo
134
135.ENDIF
136
137#################### do not edit below this line #######################
138############# NO USER-SERVICEABLE PARTS BEYOND THIS POINT ##############
139
140#
141# Rules
142#
143.SUFFIXES :
144.SUFFIXES : .c .obj .dll .lib .exe
145
146.c.obj:
147 $(CC) -c $(CFLAGS) $(OBJOUT_FLAG)$@ $<
148
149.IF "$(CCTYPE)" == "BORLAND"
150
151.obj.dll:
152 $(LINK32) -Tpd -ap $(LINK_FLAGS) c0d32.obj $<,$@,,$(LIBFILES),$(*B).def
153 $(IMPLIB) $(*B).lib $@
154.ELSE
155
156.obj.dll:
157 $(LINK32) -dll -subsystem:windows -implib:$(*B).lib -def:$(*B).def \
158 -out:$@ $(LINK_FLAGS) $< $(LIBPERL)
159
160.ENDIF
161
162#
163INST_BIN=$(INST_TOP)\bin
164INST_LIB=$(INST_TOP)\lib
165INST_POD=$(INST_LIB)\pod
166INST_HTML=$(INST_POD)\html
167LIBDIR=..\lib
168EXTDIR=..\ext
169PODDIR=..\pod
170EXTUTILSDIR=$(LIBDIR)\extutils
171
172#
173# various targets
174PERLIMPLIB=..\perl.lib
175MINIPERL=..\miniperl.exe
176PERLDLL=..\perl.dll
177PERLEXE=..\perl.exe
178GLOBEXE=..\perlglob.exe
179CONFIGPM=..\lib\Config.pm
180MINIMOD=..\lib\ExtUtils\Miniperl.pm
181
d444a431
TB
182PL2BAT=bin\pl2bat.pl
183GLOBBAT = bin\perlglob.bat
08aa1457
PP
184
185.IF "$(CCTYPE)" == "BORLAND"
186
187# Borland wildargs is incompatible with MS setargv
188CFGSH_TMPL = config.bc
189CFGH_TMPL = config_H.bc
190# Borland's perl.exe will work on W95, so we don't make this
191
192.ELSE
193
194MAKE = nmake -nologo
195CFGSH_TMPL = config.vc
196CFGH_TMPL = config_H.vc
197PERL95EXE=..\perl95.exe
198
199.ENDIF
200
201XCOPY=xcopy /f /r /i /d
202RCOPY=xcopy /f /r /i /e /d
203#NULL=
204
205#
206# filenames given to xsubpp must have forward slashes (since it puts
207# full pathnames in #line strings)
208XSUBPP=..\$(MINIPERL) -I..\..\lib ..\$(EXTUTILSDIR)\xsubpp -C++ -prototypes
209
210CORE_C= ..\av.c \
211 ..\deb.c \
212 ..\doio.c \
213 ..\doop.c \
214 ..\dump.c \
215 ..\globals.c \
216 ..\gv.c \
217 ..\hv.c \
218 ..\mg.c \
219 ..\op.c \
220 ..\perl.c \
221 ..\perlio.c \
222 ..\perly.c \
223 ..\pp.c \
224 ..\pp_ctl.c \
225 ..\pp_hot.c \
226 ..\pp_sys.c \
227 ..\regcomp.c \
228 ..\regexec.c \
229 ..\run.c \
230 ..\scope.c \
231 ..\sv.c \
232 ..\taint.c \
233 ..\toke.c \
234 ..\universal.c \
235 ..\util.c
236
237CORE_OBJ= ..\av.obj \
238 ..\deb.obj \
239 ..\doio.obj \
240 ..\doop.obj \
241 ..\dump.obj \
242 ..\globals.obj \
243 ..\gv.obj \
244 ..\hv.obj \
245 ..\mg.obj \
246 ..\op.obj \
247 ..\perl.obj \
248 ..\perlio.obj \
249 ..\perly.obj \
250 ..\pp.obj \
251 ..\pp_ctl.obj \
252 ..\pp_hot.obj \
253 ..\pp_sys.obj \
254 ..\regcomp.obj \
255 ..\regexec.obj \
256 ..\run.obj \
257 ..\scope.obj \
258 ..\sv.obj \
259 ..\taint.obj \
260 ..\toke.obj \
261 ..\universal.obj\
262 ..\util.obj
263
264WIN32_C = perllib.c \
265 win32.c \
266 win32io.c \
f0f333f4
NIS
267 win32sck.c \
268 win32thread.c
08aa1457
PP
269
270WIN32_OBJ = win32.obj \
271 win32io.obj \
f0f333f4
NIS
272 win32sck.obj \
273 win32thread.obj
08aa1457 274
fb73857a
PP
275PERL95_OBJ = perl95.obj \
276 win32mt.obj \
277 win32iomt.obj \
278 win32sckmt.obj
279
08aa1457
PP
280DLL_OBJ = perllib.obj $(DYNALOADER).obj
281
282CORE_H = ..\av.h \
283 ..\cop.h \
284 ..\cv.h \
285 ..\dosish.h \
286 ..\embed.h \
287 ..\form.h \
288 ..\gv.h \
289 ..\handy.h \
290 ..\hv.h \
291 ..\mg.h \
292 ..\nostdio.h \
293 ..\op.h \
294 ..\opcode.h \
295 ..\perl.h \
296 ..\perlio.h \
297 ..\perlsdio.h \
298 ..\perlsfio.h \
299 ..\perly.h \
300 ..\pp.h \
301 ..\proto.h \
302 ..\regexp.h \
303 ..\scope.h \
304 ..\sv.h \
f0f333f4 305 ..\thread.h \
08aa1457
PP
306 ..\unixish.h \
307 ..\util.h \
308 ..\XSUB.h \
309 .\config.h \
310 ..\EXTERN.h \
311 .\include\dirent.h \
312 .\include\netdb.h \
313 .\include\sys\socket.h \
314 .\win32.h
315
316
f0f333f4 317EXTENSIONS=DynaLoader Socket IO Fcntl Opcode SDBM_File attrs Thread
08aa1457
PP
318
319DYNALOADER=$(EXTDIR)\DynaLoader\DynaLoader
320SOCKET=$(EXTDIR)\Socket\Socket
321FCNTL=$(EXTDIR)\Fcntl\Fcntl
322OPCODE=$(EXTDIR)\Opcode\Opcode
323SDBM_FILE=$(EXTDIR)\SDBM_File\SDBM_File
324IO=$(EXTDIR)\IO\IO
ea0efc06 325ATTRS=$(EXTDIR)\attrs\attrs
f0f333f4 326THREAD=$(EXTDIR)\Thread\Thread
08aa1457
PP
327
328SOCKET_DLL=..\lib\auto\Socket\Socket.dll
329FCNTL_DLL=..\lib\auto\Fcntl\Fcntl.dll
330OPCODE_DLL=..\lib\auto\Opcode\Opcode.dll
331SDBM_FILE_DLL=..\lib\auto\SDBM_File\SDBM_File.dll
332IO_DLL=..\lib\auto\IO\IO.dll
ea0efc06 333ATTRS_DLL=..\lib\auto\attrs\attrs.dll
f0f333f4 334THREAD_DLL=..\lib\auto\Thread\Thread.dll
08aa1457
PP
335
336STATICLINKMODULES=DynaLoader
337DYNALOADMODULES= \
338 $(SOCKET_DLL) \
339 $(FCNTL_DLL) \
340 $(OPCODE_DLL) \
341 $(SDBM_FILE_DLL)\
ea0efc06 342 $(IO_DLL) \
f0f333f4
NIS
343 $(ATTRS_DLL) \
344 $(THREAD_DLL)
08aa1457
PP
345
346POD2HTML=$(PODDIR)\pod2html
347POD2MAN=$(PODDIR)\pod2man
348POD2LATEX=$(PODDIR)\pod2latex
349POD2TEXT=$(PODDIR)\pod2text
350
351#
352# Top targets
353#
354
355all: $(PERLEXE) $(PERL95EXE) $(GLOBEXE) $(DYNALOADMODULES) $(MINIMOD) $(GLOBBAT)
356
357$(DYNALOADER).obj : $(DYNALOADER).c $(CORE_H) $(EXTDIR)\DynaLoader\dlutils.c
358
359#------------------------------------------------------------
360
361$(GLOBEXE): perlglob.obj
362.IF "$(CCTYPE)" == "BORLAND"
363 $(CC) -c -w -v -tWM -I$(CCINCDIR) perlglob.c
364 $(LINK32) -Tpe -ap $(LINK_FLAGS) c0x32.obj perlglob.obj \
365 $(CCLIBDIR)\32BIT\wildargs.obj,$@,,import32.lib cw32mt.lib,
366.ELSE
367 $(LINK32) $(LINK_FLAGS) -out:$@ -subsystem:$(SUBSYS) perlglob.obj setargv.obj
368.ENDIF
369
d444a431
TB
370$(GLOBBAT) : ..\lib\File\DosGlob.pm $(MINIPERL)
371 $(MINIPERL) $(PL2BAT) - < ..\lib\File\DosGlob.pm > $(GLOBBAT)
08aa1457
PP
372
373perlglob.obj : perlglob.c
374
375..\miniperlmain.obj : ..\miniperlmain.c $(CORE_H)
376
377config.w32 : $(CFGSH_TMPL)
378 copy $(CFGSH_TMPL) config.w32
379
380.\config.h : $(CFGSH_TMPL)
381 -del /f config.h
382 copy $(CFGH_TMPL) config.h
383
384..\config.sh : config.w32 $(MINIPERL) config_sh.PL
385 $(MINIPERL) -I..\lib config_sh.PL "INST_DRV=$(INST_DRV)" \
f0f333f4 386 "INST_TOP=$(INST_TOP)" "cc=$(CC)" "ccflags=$(OPTIMIZE) $(DEFINES)" \
f7c603cb 387 "cf_email=$(EMAIL)" "libs=$(LIBFILES:f)" "incpath=$(CCINCDIR)" \
08aa1457
PP
388 "libpth=$(strip $(CCLIBDIR) $(LIBFILES:d))" "libc=$(LIBC)" \
389 config.w32 > ..\config.sh
390
391$(CONFIGPM) : $(MINIPERL) ..\config.sh config_h.PL ..\minimod.pl
392 cd .. && miniperl configpm
393 if exist lib\* $(RCOPY) lib\*.* ..\lib\$(NULL)
394 $(XCOPY) ..\*.h ..\lib\CORE\*.*
395 $(XCOPY) *.h ..\lib\CORE\*.*
396 $(RCOPY) include ..\lib\CORE\*.*
397 $(MINIPERL) -I..\lib config_h.PL || $(MAKE) CCTYPE=$(CCTYPE) \
398 RUNTIME=$(RUNTIME) CFG=$(CFG) $(CONFIGPM)
399
400$(MINIPERL) : ..\miniperlmain.obj $(CORE_OBJ) $(WIN32_OBJ)
401.IF "$(CCTYPE)" == "BORLAND"
402 $(LINK32) -Tpe -ap $(LINK_FLAGS) \
403 @$(mktmp c0x32.obj ..\miniperlmain.obj \
404 $(CORE_OBJ:s,\,\\) $(WIN32_OBJ:s,\,\\),$@,,$(LIBFILES),)
405.ELSE
406 $(LINK32) -subsystem:console -out:$@ \
407 @$(mktmp $(LINK_FLAGS) ..\miniperlmain.obj \
408 $(CORE_OBJ:s,\,\\) $(WIN32_OBJ:s,\,\\))
409.ENDIF
410
411$(WIN32_OBJ) : $(CORE_H)
412$(CORE_OBJ) : $(CORE_H)
413$(DLL_OBJ) : $(CORE_H)
414
f0f333f4
NIS
415perldll.def : $(MINIPERL) $(CONFIGPM) ..\global.sym makedef.pl
416 $(MINIPERL) -w makedef.pl $(DEFINES) $(CCTYPE) > perldll.def
08aa1457
PP
417
418$(PERLDLL): perldll.def $(CORE_OBJ) $(WIN32_OBJ) $(DLL_OBJ)
419.IF "$(CCTYPE)" == "BORLAND"
420 $(LINK32) -Tpd -ap $(LINK_FLAGS) \
421 @$(mktmp c0d32.obj $(CORE_OBJ:s,\,\\) \
422 $(WIN32_OBJ:s,\,\\) $(DLL_OBJ:s,\,\\)\n \
423 $@,\n \
424 $(LIBFILES)\n \
425 perldll.def\n)
426 $(IMPLIB) $*.lib $@
427.ELSE
428 $(LINK32) -dll -def:perldll.def -out:$@ \
429 @$(mktmp $(LINK_FLAGS) $(CORE_OBJ:s,\,\\) \
430 $(WIN32_OBJ:s,\,\\) $(DLL_OBJ:s,\,\\))
431.ENDIF
432 $(XCOPY) $(PERLIMPLIB) ..\lib\CORE
433
434perl.def : $(MINIPERL) makeperldef.pl
435 $(MINIPERL) -I..\lib makeperldef.pl $(NULL) > perl.def
436
437$(MINIMOD) : $(MINIPERL) ..\minimod.pl
438 cd .. && miniperl minimod.pl > lib\ExtUtils\Miniperl.pm
439
440perlmain.c : runperl.c
441 copy runperl.c perlmain.c
442
443perlmain.obj : perlmain.c
444 $(CC) $(CFLAGS) -UPERLDLL -c perlmain.c
445
446
447$(PERLEXE): $(PERLDLL) $(CONFIGPM) perlmain.obj
448.IF "$(CCTYPE)" == "BORLAND"
449 $(LINK32) -Tpe -ap $(LINK_FLAGS) \
450 @$(mktmp c0x32.obj perlmain.obj $(WINIOMAYBE)\n \
451 $@,\n \
452 $(PERLIMPLIB) $(LIBFILES)\n)
453.ELSE
454 $(LINK32) -subsystem:console -out:perl.exe $(LINK_FLAGS) \
455 perlmain.obj $(WINIOMAYBE) $(PERLIMPLIB)
456 copy perl.exe $@
457 del perl.exe
458.ENDIF
459 copy splittree.pl ..
460 $(MINIPERL) -I..\lib ..\splittree.pl "../LIB" "../LIB/auto"
461 attrib -r ..\t\*.*
462 copy test ..\t
463
464.IF "$(CCTYPE)" != "BORLAND"
465
466perl95.c : runperl.c
467 copy runperl.c perl95.c
468
469perl95.obj : perl95.c
470 $(CC) $(CFLAGS) -MT -UPERLDLL -c perl95.c
471
472win32iomt.obj : win32io.c
473 $(CC) $(CFLAGS) -MT -c $(OBJOUT_FLAG)win32iomt.obj win32io.c
474
fb73857a
PP
475win32sckmt.obj : win32sck.c
476 $(CC) $(CFLAGS) -MT -c $(OBJOUT_FLAG)win32sckmt.obj win32sck.c
477
478win32mt.obj : win32.c
479 $(CC) $(CFLAGS) -MT -c $(OBJOUT_FLAG)win32mt.obj win32.c
480
481$(PERL95EXE): $(PERLDLL) $(CONFIGPM) $(PERL95_OBJ)
08aa1457 482 $(LINK32) -subsystem:console -out:perl95.exe $(LINK_FLAGS) \
fb73857a 483 $(PERL95_OBJ) $(PERLIMPLIB)
08aa1457
PP
484 copy perl95.exe $@
485 del perl95.exe
486
487.ENDIF
488
489$(DYNALOADER).c: $(MINIPERL) $(EXTDIR)\DynaLoader\dl_win32.xs $(CONFIGPM)
490 if not exist ..\lib\auto mkdir ..\lib\auto
491 $(XCOPY) $(EXTDIR)\$(*B)\$(*B).pm $(LIBDIR)\$(NULL)
492 cd $(EXTDIR)\$(*B) && $(XSUBPP) dl_win32.xs > $(*B).c
493 $(XCOPY) $(EXTDIR)\$(*B)\dlutils.c .
494
495$(EXTDIR)\DynaLoader\dl_win32.xs: dl_win32.xs
496 copy dl_win32.xs $(EXTDIR)\DynaLoader\dl_win32.xs
497
f0f333f4
NIS
498$(THREAD_DLL): $(PERLEXE) $(THREAD).xs
499 cd $(EXTDIR)\$(*B) && \
500 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
501 cd $(EXTDIR)\$(*B) && $(MAKE)
502
ea0efc06
MB
503$(ATTRS_DLL): $(PERLEXE) $(ATTRS).xs
504 cd $(EXTDIR)\$(*B) && \
505 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
506 cd $(EXTDIR)\$(*B) && $(MAKE)
507
f0f333f4 508$(IO_DLL): $(PERLEXE) $(IO).xs
08aa1457
PP
509 cd $(EXTDIR)\$(*B) && \
510 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
511 cd $(EXTDIR)\$(*B) && $(MAKE)
512
513$(SDBM_FILE_DLL) : $(PERLEXE) $(SDBM_FILE).xs
514 cd $(EXTDIR)\$(*B) && \
515 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
516 cd $(EXTDIR)\$(*B) && $(MAKE)
517
518$(FCNTL_DLL): $(PERLEXE) $(FCNTL).xs
519 cd $(EXTDIR)\$(*B) && \
520 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
521 cd $(EXTDIR)\$(*B) && $(MAKE)
522
523$(OPCODE_DLL): $(PERLEXE) $(OPCODE).xs
524 cd $(EXTDIR)\$(*B) && \
525 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
526 cd $(EXTDIR)\$(*B) && $(MAKE)
527
ea0efc06 528$(SOCKET_DLL): $(PERLEXE) $(SOCKET).xs
08aa1457
PP
529 cd $(EXTDIR)\$(*B) && \
530 ..\..\miniperl -I..\..\lib Makefile.PL INSTALLDIRS=perl
531 cd $(EXTDIR)\$(*B) && $(MAKE)
532
533doc: $(PERLEXE)
84902520
TB
534 cd ..\pod && $(MAKE) -f ..\win32\pod.mak checkpods \
535 pod2html pod2latex pod2man pod2text
536 cd ..\pod && $(XCOPY) *.bat ..\win32\bin\*.*
08aa1457
PP
537 copy ..\README.win32 ..\pod\perlwin32.pod
538 $(PERLEXE) ..\installhtml --podroot=.. --htmldir=./html \
539 --podpath=pod:lib:ext:utils --htmlroot="//$(INST_HTML:s,:,|,)" \
540 --libpod=perlfunc:perlguts:perlvar:perlrun:perlop --recurse
541
542utils: $(PERLEXE)
543 cd ..\utils && $(MAKE) PERL=$(MINIPERL)
544 cd ..\utils && $(PERLEXE) ..\win32\$(PL2BAT) h2ph splain perlbug \
545 pl2pm c2ph h2xs perldoc pstruct
d444a431
TB
546 $(XCOPY) ..\utils\*.bat bin\*.*
547 $(PERLEXE) $(PL2BAT) bin\network.pl bin\www.pl bin\runperl.pl \
548 bin\pl2bat.pl
08aa1457
PP
549
550distclean: clean
551 -del /f $(MINIPERL) $(PERLEXE) $(PERLDLL) $(GLOBEXE) \
552 $(PERLIMPLIB) ..\miniperl.lib $(MINIMOD)
553 -del /f *.def *.map
554 -del /f $(SOCKET_DLL) $(IO_DLL) $(SDBM_FILE_DLL) $(FCNTL_DLL) \
f0f333f4 555 $(OPCODE_DLL) $(ATTRS_DLL) $(THREAD_DLL)
08aa1457 556 -del /f $(SOCKET).c $(IO).c $(SDBM_FILE).c $(FCNTL).c $(OPCODE).c \
f0f333f4 557 $(DYNALOADER).c $(ATTRS).c $(THREAD).c
08aa1457
PP
558 -del /f $(PODDIR)\*.html
559 -del /f $(PODDIR)\*.bat
d444a431
TB
560 -del /f ..\config.sh ..\splittree.pl perlmain.c dlutils.c config.h.new
561.IF "$(PERL95EXE)" != ""
562 -del /f perl95.c
563.ENDIF
564 -del /f bin\*.bat
08aa1457
PP
565 -cd $(EXTDIR) && del /s *.lib *.def *.map *.bs Makefile *.obj pm_to_blib
566 -rmdir /s /q ..\lib\auto
567 -rmdir /s /q ..\lib\CORE
568
569install : all doc utils
570 if not exist $(INST_TOP) mkdir $(INST_TOP)
571 echo I $(INST_TOP) L $(LIBDIR)
572 $(XCOPY) $(PERLEXE) $(INST_BIN)\*.*
573.IF "$(PERL95EXE)" != ""
574 $(XCOPY) $(PERL95EXE) $(INST_BIN)\*.*
575.ENDIF
576 $(XCOPY) $(GLOBEXE) $(INST_BIN)\*.*
08aa1457 577 $(XCOPY) $(PERLDLL) $(INST_BIN)\*.*
d444a431 578 $(XCOPY) bin\*.bat $(INST_BIN)\*.*
08aa1457
PP
579 $(RCOPY) ..\lib $(INST_LIB)\*.*
580 $(XCOPY) ..\pod\*.bat $(INST_BIN)\*.*
581 $(XCOPY) ..\pod\*.pod $(INST_POD)\*.*
582 $(RCOPY) html\*.* $(INST_HTML)\*.*
583
584inst_lib : $(CONFIGPM)
585 copy splittree.pl ..
586 $(MINIPERL) -I..\lib ..\splittree.pl "../LIB" "../LIB/auto"
587 $(RCOPY) ..\lib $(INST_LIB)\*.*
588
589minitest : $(MINIPERL) $(GLOBEXE) $(CONFIGPM)
590 $(XCOPY) $(MINIPERL) ..\t\perl.exe
591.IF "$(CCTYPE)" == "BORLAND"
592 $(XCOPY) $(GLOBBAT) ..\t\$(NULL)
593.ELSE
594 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
595.ENDIF
596 attrib -r ..\t\*.*
597 copy test ..\t
598 cd ..\t && \
599 $(MINIPERL) -I..\lib test base/*.t comp/*.t cmd/*.t io/*.t op/*.t pragma/*.t
600
601test : all
602 $(XCOPY) $(PERLEXE) ..\t\$(NULL)
603 $(XCOPY) $(PERLDLL) ..\t\$(NULL)
604.IF "$(CCTYPE)" == "BORLAND"
605 $(XCOPY) $(GLOBBAT) ..\t\$(NULL)
606.ELSE
607 $(XCOPY) $(GLOBEXE) ..\t\$(NULL)
608.ENDIF
609 cd ..\t && $(PERLEXE) -I..\lib harness
610
611clean :
612 -@erase miniperlmain.obj
613 -@erase $(MINIPERL)
614 -@erase perlglob.obj
615 -@erase perlmain.obj
616 -@erase config.w32
617 -@erase /f config.h
618 -@erase $(GLOBEXE)
619 -@erase $(PERLEXE)
620 -@erase $(PERLDLL)
621 -@erase $(CORE_OBJ)
622 -@erase $(WIN32_OBJ)
623 -@erase $(DLL_OBJ)
d444a431
TB
624 -@erase ..\*.obj ..\*.lib ..\*.exp *.obj *.lib *.exp
625 -@erase ..\t\*.exe ..\t\*.dll ..\t\*.bat
08aa1457
PP
626 -@erase *.ilk
627 -@erase *.pdb
628
629