2000-07-08 02:22:20 +02:00
|
|
|
|
#
|
|
|
|
|
# FreeType 2 configuration file to detect a Win32 host platform.
|
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
2007-02-01 08:58:02 +01:00
|
|
|
|
# Copyright 1996-2000, 2003, 2004, 2006, 2007 by
|
2000-07-08 02:22:20 +02:00
|
|
|
|
# David Turner, Robert Wilhelm, and Werner Lemberg.
|
|
|
|
|
#
|
|
|
|
|
# This file is part of the FreeType project, and may only be used, modified,
|
|
|
|
|
# and distributed under the terms of the FreeType project license,
|
|
|
|
|
# LICENSE.TXT. By continuing to use, modify, or distribute this file you
|
|
|
|
|
# indicate that you have read the license and understand and accept it
|
|
|
|
|
# fully.
|
|
|
|
|
|
|
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
|
.PHONY: setup
|
|
|
|
|
|
|
|
|
|
|
2000-07-08 02:22:20 +02:00
|
|
|
|
ifeq ($(PLATFORM),ansi)
|
|
|
|
|
|
|
|
|
|
# Detecting Windows NT is easy, as the OS variable must be defined and
|
2004-11-23 22:38:16 +01:00
|
|
|
|
# contains `Windows_NT'. This also works with Windows 2000 and XP.
|
2000-07-08 02:22:20 +02:00
|
|
|
|
#
|
|
|
|
|
ifeq ($(OS),Windows_NT)
|
2000-10-31 21:42:18 +01:00
|
|
|
|
|
2004-11-23 18:48:52 +01:00
|
|
|
|
PLATFORM := win32
|
2004-11-23 10:17:16 +01:00
|
|
|
|
|
|
|
|
|
else
|
2000-07-08 02:22:20 +02:00
|
|
|
|
|
2004-11-23 22:38:16 +01:00
|
|
|
|
# Detecting Windows 9X
|
2000-07-08 02:22:20 +02:00
|
|
|
|
|
2004-11-23 18:48:52 +01:00
|
|
|
|
# We used to run the `ver' command to see if its output contains the
|
2004-11-23 22:38:16 +01:00
|
|
|
|
# word `Windows'. If this is true, we are running Windows 95 or later:
|
|
|
|
|
#
|
|
|
|
|
# ifdef COMSPEC
|
|
|
|
|
# # First, check if we have the COMSPEC environment variable, which
|
|
|
|
|
# # indicates we can use COMMAND.COM's internal commands
|
|
|
|
|
# is_windows := $(findstring Windows,$(strip $(shell ver)))
|
|
|
|
|
# endif
|
|
|
|
|
#
|
2004-11-23 18:48:52 +01:00
|
|
|
|
# Unfortunately, this also detects the case when one is running
|
2004-11-23 22:38:16 +01:00
|
|
|
|
# DOS 7.x (the MS-DOS version that lies below Windows) without actually
|
2004-11-23 18:48:52 +01:00
|
|
|
|
# launching the GUI.
|
2004-11-23 22:38:16 +01:00
|
|
|
|
#
|
|
|
|
|
# A better test is to check whether there are both the environment
|
|
|
|
|
# variables `winbootdir' and `windir'. The first indicates an
|
|
|
|
|
# underlying DOS 7.x, while the second is set only if win32 is available.
|
|
|
|
|
#
|
|
|
|
|
# Note that on Windows NT, such an environment variable will not be seen
|
|
|
|
|
# from DOS-based tools like DJGPP's make; this is not actually a problem
|
2007-02-01 08:58:02 +01:00
|
|
|
|
# since NT is detected independently above. But do not try to be clever!
|
2004-11-23 22:38:16 +01:00
|
|
|
|
#
|
2004-11-23 18:48:52 +01:00
|
|
|
|
ifdef winbootdir
|
|
|
|
|
ifdef windir
|
|
|
|
|
|
|
|
|
|
PLATFORM := win32
|
|
|
|
|
|
|
|
|
|
endif
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
endif # test NT
|
2000-12-20 23:09:41 +01:00
|
|
|
|
|
|
|
|
|
endif # test PLATFORM ansi
|
|
|
|
|
|
|
|
|
|
ifeq ($(PLATFORM),win32)
|
|
|
|
|
|
2003-06-09 06:46:30 +02:00
|
|
|
|
DELETE := del
|
2006-12-09 21:01:43 +01:00
|
|
|
|
CAT := type
|
2003-06-09 06:46:30 +02:00
|
|
|
|
SEP := $(BACKSLASH)
|
2000-12-20 23:09:41 +01:00
|
|
|
|
|
2004-11-23 22:38:16 +01:00
|
|
|
|
# Setting COPY is a bit trickier. Plain COPY on NT will not work
|
|
|
|
|
# correctly, because it will uppercase 8.3 filenames, creating a
|
|
|
|
|
# `CONFIG.MK' file which isn't found later on by `make'.
|
|
|
|
|
# Since we do not want that, we need to force execution of CMD.EXE.
|
|
|
|
|
# Unfortunately, CMD.EXE is not available on Windows 9X.
|
2004-11-23 18:48:52 +01:00
|
|
|
|
# So we need to hack.
|
2004-11-23 22:38:16 +01:00
|
|
|
|
#
|
2004-11-23 18:48:52 +01:00
|
|
|
|
# Kudos to Eli Zaretskii (DJGPP guru) that helped debug it.
|
2007-01-17 13:45:26 +01:00
|
|
|
|
# Details are available in threads of the freetype mailing list
|
2004-11-23 22:38:16 +01:00
|
|
|
|
# (2004-11-11), and then in the devel mailing list (2004-11-20 to -23).
|
|
|
|
|
#
|
2004-11-23 18:48:52 +01:00
|
|
|
|
ifeq ($(OS),Windows_NT)
|
|
|
|
|
COPY := cmd.exe /c copy
|
|
|
|
|
else
|
|
|
|
|
COPY := copy
|
|
|
|
|
endif # test NT
|
|
|
|
|
|
|
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
|
# gcc Makefile by default
|
|
|
|
|
CONFIG_FILE := w32-gcc.mk
|
|
|
|
|
ifeq ($(firstword $(CC)),cc)
|
|
|
|
|
CC := gcc
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifneq ($(findstring list,$(MAKECMDGOALS)),) # test for the "list" target
|
|
|
|
|
dump_target_list:
|
|
|
|
|
@echo <20>
|
|
|
|
|
@echo $(PROJECT_TITLE) build system -- supported compilers
|
|
|
|
|
@echo <20>
|
|
|
|
|
@echo Several command-line compilers are supported on Win32:
|
|
|
|
|
@echo <20>
|
|
|
|
|
@echo <20><>make setup<75><70><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>gcc (with Mingw)
|
|
|
|
|
@echo <20><>make setup visualc<6C><63><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Microsoft Visual C++
|
|
|
|
|
@echo <20><>make setup bcc32<33><32><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Borland C/C++
|
|
|
|
|
@echo <20><>make setup lcc<63><63><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Win32-LCC
|
|
|
|
|
@echo <20><>make setup intelc<6C><63><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Intel C/C++
|
|
|
|
|
@echo <20>
|
|
|
|
|
|
|
|
|
|
setup: dump_target_list
|
|
|
|
|
.PHONY: dump_target_list list
|
|
|
|
|
else
|
|
|
|
|
setup: dos_setup
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
# additionally, we provide hooks for various other compilers
|
|
|
|
|
#
|
|
|
|
|
ifneq ($(findstring visualc,$(MAKECMDGOALS)),) # Visual C/C++
|
|
|
|
|
CONFIG_FILE := w32-vcc.mk
|
|
|
|
|
CC := cl
|
|
|
|
|
visualc: setup
|
|
|
|
|
.PHONY: visualc
|
|
|
|
|
endif
|
|
|
|
|
|
* builds/win32/detekt.mk: Fix .PHONY target for Intel compiler.
Renamed "ftnames.h" to "ftsnames.h", and FT_NAMES_H to
FT_SFNT_NAMES_H.
* docs/docmaker.py: Added generation of INDEX link in table of
contents.
* INSTALL, docs/BUILD: Updated documentation to indicate that the
compilation process has changed slightly (no more `src' required in
* builds/*/*-def.mk: Changed the objects directory from "obj" to
"objs".
* include/freetype/config/ftheader.h: Removed obsolete macros like
FT_SOURCE_FILE, etc. and added cache-specific macro definitions that
were previously defined in <freetype/ftcache.h>. Added comments to
be included in a new API Reference section.
* src/*/*: Removed the use of FT_SOURCE_FILE, etc. Now, each
component needs to add its own directory to the include path at
compile time. Modified all "rules.mk" and "descrip.mms"
accordingly.
* src/cid/cidobjs.c, src/cid/cidload.c, src/pcf/pcfread.c,
src/type1/t1load.c, src/type1/t1objs.c: Added a few casts to remove
compiler warnings in pedantic modes.
* include/config/ft2build.h, include/config/ftheader.h: The file
top-level <ft2build.h>.
* include/config/ftheader.h: Added new section describing the #include
macros.
the Type 2 glyph charstring (used by conversion programs).
* docs/docmaker.py: Added cross-references generation as well as
seac emulation provided by the Type 2 endchar operator.
* src/cid/cidafm.c, src/cid/cidafm.h: removed un-needed files,
Added support for clipped direct rendering in the smooth renderer.
* src/cff/t2objs.c (T2_Init_Face): For pure CFF fonts, set
2001-03-20 23:58:56 +01:00
|
|
|
|
ifneq ($(findstring intelc,$(MAKECMDGOALS)),) # Intel C/C++
|
2001-03-20 12:14:24 +01:00
|
|
|
|
CONFIG_FILE := w32-intl.mk
|
|
|
|
|
CC := cl
|
|
|
|
|
visualc: setup
|
* builds/win32/detekt.mk: Fix .PHONY target for Intel compiler.
Renamed "ftnames.h" to "ftsnames.h", and FT_NAMES_H to
FT_SFNT_NAMES_H.
* docs/docmaker.py: Added generation of INDEX link in table of
contents.
* INSTALL, docs/BUILD: Updated documentation to indicate that the
compilation process has changed slightly (no more `src' required in
* builds/*/*-def.mk: Changed the objects directory from "obj" to
"objs".
* include/freetype/config/ftheader.h: Removed obsolete macros like
FT_SOURCE_FILE, etc. and added cache-specific macro definitions that
were previously defined in <freetype/ftcache.h>. Added comments to
be included in a new API Reference section.
* src/*/*: Removed the use of FT_SOURCE_FILE, etc. Now, each
component needs to add its own directory to the include path at
compile time. Modified all "rules.mk" and "descrip.mms"
accordingly.
* src/cid/cidobjs.c, src/cid/cidload.c, src/pcf/pcfread.c,
src/type1/t1load.c, src/type1/t1objs.c: Added a few casts to remove
compiler warnings in pedantic modes.
* include/config/ft2build.h, include/config/ftheader.h: The file
top-level <ft2build.h>.
* include/config/ftheader.h: Added new section describing the #include
macros.
the Type 2 glyph charstring (used by conversion programs).
* docs/docmaker.py: Added cross-references generation as well as
seac emulation provided by the Type 2 endchar operator.
* src/cid/cidafm.c, src/cid/cidafm.h: removed un-needed files,
Added support for clipped direct rendering in the smooth renderer.
* src/cff/t2objs.c (T2_Init_Face): For pure CFF fonts, set
2001-03-20 23:58:56 +01:00
|
|
|
|
.PHONY: intelc
|
2001-03-20 12:14:24 +01:00
|
|
|
|
endif
|
|
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
|
ifneq ($(findstring watcom,$(MAKECMDGOALS)),) # Watcom C/C++
|
|
|
|
|
CONFIG_FILE := w32-wat.mk
|
|
|
|
|
CC := wcc386
|
|
|
|
|
watcom: setup
|
|
|
|
|
.PHONY: watcom
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifneq ($(findstring visualage,$(MAKECMDGOALS)),) # Visual Age C++
|
|
|
|
|
CONFIG_FILE := w32-icc.mk
|
|
|
|
|
CC := icc
|
|
|
|
|
visualage: setup
|
|
|
|
|
.PHONY: visualage
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifneq ($(findstring lcc,$(MAKECMDGOALS)),) # LCC-Win32
|
|
|
|
|
CONFIG_FILE := w32-lcc.mk
|
|
|
|
|
CC := lcc
|
|
|
|
|
lcc: setup
|
|
|
|
|
.PHONY: lcc
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifneq ($(findstring mingw32,$(MAKECMDGOALS)),) # mingw32
|
|
|
|
|
CONFIG_FILE := w32-mingw32.mk
|
|
|
|
|
CC := gcc
|
|
|
|
|
mingw32: setup
|
|
|
|
|
.PHONY: mingw32
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifneq ($(findstring bcc32,$(MAKECMDGOALS)),) # Borland C++
|
|
|
|
|
CONFIG_FILE := w32-bcc.mk
|
|
|
|
|
CC := bcc32
|
|
|
|
|
bcc32: setup
|
|
|
|
|
.PHONY: bcc32
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifneq ($(findstring devel-bcc,$(MAKECMDGOALS)),) # development target
|
|
|
|
|
CONFIG_FILE := w32-bccd.mk
|
|
|
|
|
CC := bcc32
|
|
|
|
|
devel-bcc: setup
|
|
|
|
|
.PHONY: devel-bcc
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifneq ($(findstring devel-gcc,$(MAKECMDGOALS)),) # development target
|
|
|
|
|
CONFIG_FILE := w32-dev.mk
|
|
|
|
|
CC := gcc
|
|
|
|
|
devel-gcc: setup
|
|
|
|
|
.PHONY: devel-gcc
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
endif # test PLATFORM win32
|
2000-07-08 02:22:20 +02:00
|
|
|
|
|
2003-06-09 06:46:30 +02:00
|
|
|
|
|
2000-07-08 02:22:20 +02:00
|
|
|
|
# EOF
|