forked from SWI-Prolog/packages-sgml
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.mak
83 lines (67 loc) · 1.89 KB
/
Makefile.mak
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
################################################################
# Build the SWI-Prolog XML/SGML package for MS-Windows
#
# Author: Jan Wielemaker
#
# Use:
# nmake /f Makefile.mak
# nmake /f Makefile.mak install
################################################################
PLHOME=..\..
!include ..\..\src\rules.mk
PKGDLL=sgml2pl
LIBOBJ= parser.obj util.obj charmap.obj catalog.obj \
model.obj xmlns.obj utf8.obj xml_unicode.obj
OBJ= $(LIBOBJ) sgml2pl.obj error.obj quote.obj
SGMLOBJ= $(LIBOBJ) sgml.obj
DTDFILES= HTML4.dcl HTML4.dtd HTML4.soc \
HTMLlat1.ent HTMLspec.ent HTMLsym.ent
DTDDIR= $(PLBASE)\library\DTD
all: $(PKGDLL).dll
$(PKGDLL).dll: $(OBJ)
$(LD) /dll /out:$@ $(LDFLAGS) $(OBJ) $(PLLIB) $(LIBS)
sgml.exe: $(SGMLOBJ)
$(LD) $(LDFLAGS) /out:$@ $(SGMLOBJ) $(LIBS)
!IF "$(CFG)" == "rt"
install: idll
!ELSE
install: idtd idll ilib
!ENDIF
idll::
copy $(PKGDLL).dll "$(PLBASE)\bin"
!IF "$(PDB)" == "true"
copy $(PKGDLL).pdb "$(PLBASE)\bin"
!ENDIF
ilib::
copy sgml.pl "$(PLBASE)\library"
copy xsdp_types.pl "$(PLBASE)\library"
copy iso_639.pl "$(PLBASE)\library"
copy sgml_write.pl "$(PLBASE)\library"
copy xpath.pl "$(PLBASE)\library"
copy pwp.pl "$(PLBASE)\library"
$(MAKEINDEX)
idtd::
@if not exist "$(DTDDIR)\$(NULL)" $(MKDIR) "$(DTDDIR)"
@echo "Installing DTD files in $(DTDDIR)"
@for %f in ($(DTDFILES)) do \
@copy DTD\%f "$(DTDDIR)"
@echo "done"
uninstall::
del "$(PLBASE)\bin\$(PKGDLL).dll"
del "$(PLBASE)\library\sgml.pl"
del "$(PLBASE)\library\xsdp_types.pl"
del "$(PLBASE)\library\iso_639.pl"
del "$(PLBASE)\library\sgml_write.pl"
del "$(PLBASE)\library\xpath.pl"
del "$(PLBASE)\library\pwp.pl"
$(MAKEINDEX)
html-install::
copy sgml.html "$(PKGDOC)"
xpce-install::
check::
cd Test && "$(PLCON)" -f test.pl -g test,halt.
clean::
if exist *.obj del *.obj
if exist *~ del *~
distclean: clean
-DEL *.dll *.lib *.exp *.pdb *.ilk 2>nul