1 # Visual C++ 2.x, 4.x, 5.0 and 6.0 makefile for freetype
2 # adapted from suns example makefile (related to the TCL script language)
4 # Does not depend on the presence of any environment variables in
5 # order to compile freetype; all needed information is derived from
6 # location of the compiler directories.
11 # ROOT = top of source tree
13 # TMPDIR = location where .obj files should be stored during build
15 # TOOLS32 = location of VC++ 32-bit development tools. Note that the
16 # VC++ 2.0 header files are broken, so you need to use the
17 # ones that come with the developer network CD's, or later
23 #TOOLS32 = c:\msdev # VC++ 2.x,4.x
24 #TOOLS32 = c:\Program Files\devstudio\vc # VC++ 5.x
25 TOOLS32 = c:\Program Files\Microsoft Visual Studio\Vc98 # VC++ 6.x
26 INSTALLDIR = c:\WINNT\SYSTEM32
28 # Set this to the appropriate value of /MACHINE: for your platform
31 # Comment the following line to compile with symbols
35 ######################################################################
36 # Do not modify below this line
37 ######################################################################
45 $(TMPDIR)\ttcache.obj \
46 $(TMPDIR)\ttcalc.obj \
47 $(TMPDIR)\ttcmap.obj \
48 $(TMPDIR)\ttdebug.obj \
49 $(TMPDIR)\ttfile.obj \
50 $(TMPDIR)\ttgload.obj \
51 $(TMPDIR)\ttinterp.obj \
52 $(TMPDIR)\ttload.obj \
53 $(TMPDIR)\ttmemory.obj \
54 $(TMPDIR)\ttmutex.obj \
55 $(TMPDIR)\ttobjs.obj \
56 $(TMPDIR)\ttraster.obj \
57 $(TMPDIR)\ttextend.obj \
58 $(TMPDIR)\ftxcmap.obj \
59 $(TMPDIR)\ftxgasp.obj \
60 $(TMPDIR)\ftxkern.obj \
61 $(TMPDIR)\ftxpost.obj \
62 $(TMPDIR)\ftxwidth.obj \
63 $(TMPDIR)\ftxerr18.obj
66 PATH=$(TOOLS32)\bin;$(PATH)
68 cc32 = "$(TOOLS32)\bin\cl.exe"
69 link32 = "$(TOOLS32)\bin\link.exe"
70 include32 = "-I$(TOOLS32)\include" -I$(ROOT)\arch\win32
74 TTF_INCLUDES = -I$(ROOT)
75 TTF_DEFINES = -nologo -D__WIN32__ -D__WIN32DLL__
77 TTF_CFLAGS = $(cdebug) $(cflags) $(cvarsdll) $(include32) \
78 $(TTF_INCLUDES) $(TTF_DEFINES)
79 CON_CFLAGS = $(cdebug) $(cflags) $(cvars) $(include32) -DCONSOLE
80 DOS_CFLAGS = $(cdebug) $(cflags) $(include16) -AL
82 ######################################################################
84 ######################################################################
89 ldebug = -debug:full -debugtype:cv
92 # declarations common to all linker options
93 lcommon = /NODEFAULTLIB /RELEASE /NOLOGO
95 # declarations for use on Intel i386, i486, and Pentium systems
96 !IF "$(MACHINE)" == "IX86"
98 lflags = $(lcommon) /MACHINE:$(MACHINE)
100 lflags = $(lcommon) /MACHINE:$(MACHINE)
103 conlflags = $(lflags) -subsystem:console -entry:mainCRTStartup
104 guilflags = $(lflags) -subsystem:windows -entry:WinMainCRTStartup
105 dlllflags = $(lflags) -entry:_DllMainCRTStartup$(DLLENTRY) -dll
107 !IF "$(MACHINE)" == "PPC"
111 libc = libc.lib oldnames.lib
112 libcdll = msvcrt.lib oldnames.lib
115 baselibs = kernel32.lib $(optlibs) advapi32.lib
116 winlibs = $(baselibs) user32.lib gdi32.lib comdlg32.lib winspool.lib
118 guilibs = $(libc) $(winlibs)
119 conlibs = $(libc) $(baselibs)
120 guilibsdll = $(libcdll) $(winlibs)
121 conlibsdll = $(libcdll) $(baselibs)
123 ######################################################################
125 ######################################################################
133 # declarations common to all compiler options
134 ccommon = -c -W3 -nologo -YX -Dtry=__try -Dexcept=__except
136 # NEED BYTEORDER INFORMATION HERE !!
137 !IF "$(MACHINE)" == "IX86"
138 cflags = $(ccommon) -D_X86_=1
140 !IF "$(MACHINE)" == "MIPS"
141 cflags = $(ccommon) -D_MIPS_=1
143 !IF "$(MACHINE)" == "PPC"
144 cflags = $(ccommon) -D_PPC_=1
146 !IF "$(MACHINE)" == "ALPHA"
147 cflags = $(ccommon) -D_ALPHA_=1
153 cvars = -DWIN32 -D_WIN32
154 cvarsmt = $(cvars) -D_MT
155 cvarsdll = $(cvarsmt) -D_DLL
157 ######################################################################
158 # Project specific targets
159 ######################################################################
166 -@$(CP) $(TTFDLL) $(INSTALLDIR)
170 $(TTFDLL): $(TTFOBJS) ttf.def
171 $(link32) $(ldebug) $(dlllflags) \
172 $(guilibsdll) -out:$(TTFDLL) -def:ttf.def $(TTFOBJS)
175 # ..\..\tcl8.0.4\win\release\dumpexts -o $@ ttf.dll $(TTFOBJS)
182 {$(ROOT)\extend}.c{$(TMPDIR)}.obj:
183 $(cc32) $(TTF_CFLAGS) -Fo$(TMPDIR)\ $<
185 {$(ROOT)}.c{$(TMPDIR)}.obj:
186 $(cc32) $(TTF_CFLAGS) -Fo$(TMPDIR)\ $<
193 -@del $(TMPDIR)\*.obj