1 # Copyright 2007 TeX Users Group.
2 # Copyright 2014 Clerk Ma.
4 # You may freely use, modify and/or distribute this file.
8 # TO SET UP DEBUGGING INFO:
9 # (1) add -Zi to CFLAGS for CL
10 # (2) add /MAP /DEBUG /PDB:yandytex.pdb for LINK
12 # NOTE: full optimization causes some problems especially in TEX5.C & TEX6.C
13 # NOTE: assuming no aliasing causes some problems especially in TEXMF.C
19 # -Gf saves about 7k bytes in EXE file
21 # For production (-Bd show compiler passes)
22 # ASSUMING WE WORK WITH MS COMPILER AND LINKER ONLY use -Gy and -Gf
23 # CFLAGS=-c -DDOS -DMSDOS -DPHARLAP -DTeX -DMYDEBUG -Ilib -Ox -Gy -Gf -W3
24 # CFLAGS=-c -DDOS -DMSDOS -DPHARLAP -DTeX -DMYDEBUG -Ilib -YX -Ox -Ge -Gy -Gf -W4
26 # CFLAGS=/c /Ge /Gy /Gf /Ox /W4 /DMSDOS /DTeX /DPHARLAP /DNDEBUG /Ilib /YX
27 CFLAGS=/nologo /c /MT /GF /Gy /Ox /W4 /DMSDOS /DTeX /DPHARLAP /DNDEBUG \
29 #/I"libharu/include" /I"libharu/win32/include"
31 # CFLAGS=/c /Ge /Gy /Gf /Od /Zi /W4 /DMSDOS /DTeX /DPHARLAP /Ilib /YX
33 # NOTE: -Ox => -Ogityb1 -Gs
36 # LFLAGS=@yandytex.nt /MAP lib\libdos.lib
38 # LFLAGS=/MAP lib\libdos.lib
42 # LFLAGS=@yandytex.nt /MAP /DEBUG /PDB:yandytex.pdb lib\libdos.lib
43 # LFLAGS=/MAP /DEBUG /PDB:yandytex.pdb
45 objs = texmf.obj itex.obj openinou.obj subroute.obj local.obj \
46 tex0.obj tex1.obj tex2.obj tex3.obj tex4.obj \
47 tex5.obj tex6.obj tex7.obj tex8.obj tex9.obj \
48 yandy_pool.obj yandytex.res md5.obj md5file.obj
50 # ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ###
53 $(LINK) $(LFLAGS) texmf itex openinou subroute local \
54 tex0 tex1 tex2 tex3 tex4 tex5 tex6 tex7 tex8 tex9 \
55 yandy_pool yandytex.res md5 md5file kpathsea\kpathsea.lib
56 # libharu\libhpdf.lib libpng\libpng.lib zlib\zlib.lib
57 copy texmf.exe yandytex.exe
58 del ..\yandy\bin\texmf.exe
59 copy texmf.exe ..\yandy\bin\texmf.exe
60 # ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ###
62 $(CC) -Ilibmd5 $(CFLAGS) libmd5\md5.c
64 md5file.obj: md5file.c
65 $(CC) -Ilibmd5 $(CFLAGS) md5file.c
67 yandytex.res: yandytex.rc
71 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
72 $(CC) /DINITEX /DINI $(CFLAGS) texmf.c
75 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
76 $(CC) /DINITEX $(CFLAGS) itex.c
78 openinou.obj: openinou.c \
79 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
80 $(CC) $(CFLAGS) openinou.c
82 subroute.obj: subroute.c \
83 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
84 $(CC) $(CFLAGS) subroute.c
87 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
88 $(CC) /DINITEX $(CFLAGS) local.c
90 # NOTE: cannot compile tex5.c and tex6.c with full optimizations ...
93 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
96 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
99 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
102 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
105 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
108 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
111 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
114 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
117 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
120 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h
122 yandy_pool.obj: yandy_pool.c \
123 texd.h texmf.h texmfmem.h coerce.h lib.h config.h common.h