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