2000-07-08 02:22:20 +02:00
|
|
|
#
|
|
|
|
# FreeType 2 configuration file to detect a DOS host platform.
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2021-01-17 07:18:48 +01:00
|
|
|
# Copyright (C) 1996-2021 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-11-04 02:55:49 +01:00
|
|
|
|
|
|
|
|
2000-07-08 02:22:20 +02:00
|
|
|
ifeq ($(PLATFORM),ansi)
|
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
# Test for DJGPP by checking the DJGPP environment variable, which must be
|
|
|
|
# set in order to use the system (ie. it will always be present when the
|
|
|
|
# `make' utility is run).
|
|
|
|
#
|
|
|
|
# We test for the COMSPEC environment variable, then run the `ver'
|
2003-06-13 09:38:22 +02:00
|
|
|
# command-line program to see if its output contains the word `Dos' or
|
|
|
|
# `DOS'.
|
2000-12-20 23:09:41 +01:00
|
|
|
#
|
|
|
|
# If this is true, we are running a Dos-ish platform (or an emulation).
|
|
|
|
#
|
|
|
|
ifdef DJGPP
|
|
|
|
PLATFORM := dos
|
|
|
|
else
|
|
|
|
ifdef COMSPEC
|
2003-06-13 09:38:22 +02:00
|
|
|
is_dos := $(findstring DOS,$(subst Dos,DOS,$(shell ver)))
|
2000-10-31 21:42:18 +01:00
|
|
|
|
2000-10-03 19:51:29 +02:00
|
|
|
# We try to recognize a Dos session under OS/2. The `ver' command
|
|
|
|
# returns `Operating System/2 ...' there, so `is_dos' should be empty.
|
|
|
|
#
|
|
|
|
# To recognize a Dos session under OS/2, we check COMSPEC for the
|
|
|
|
# substring `MDOS\COMMAND'
|
|
|
|
#
|
|
|
|
ifeq ($(is_dos),)
|
2001-04-10 15:59:58 +02:00
|
|
|
is_dos := $(findstring MDOS\COMMAND,$(COMSPEC))
|
2000-10-03 19:51:29 +02:00
|
|
|
endif
|
2004-11-23 18:49:40 +01:00
|
|
|
|
|
|
|
# We also try to recognize Dos 7.x without Windows 9X launched.
|
2014-02-06 20:23:49 +01:00
|
|
|
# See builds/windows/detect.mk for explanations about the logic.
|
2004-11-23 22:38:16 +01:00
|
|
|
#
|
2004-11-23 18:49:40 +01:00
|
|
|
ifeq ($(is_dos),)
|
|
|
|
ifdef winbootdir
|
|
|
|
#ifneq ($(OS),Windows_NT)
|
2014-02-08 11:34:33 +01:00
|
|
|
# If windows is available, do not trigger this test.
|
2004-11-23 18:49:40 +01:00
|
|
|
ifndef windir
|
|
|
|
is_dos := $(findstring Windows,$(strip $(shell ver)))
|
|
|
|
endif
|
|
|
|
#endif
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
endif # test COMSPEC
|
2000-07-08 02:22:20 +02:00
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
ifneq ($(is_dos),)
|
2000-07-08 02:22:20 +02:00
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
PLATFORM := dos
|
|
|
|
|
|
|
|
endif # test Dos
|
|
|
|
endif # test DJGPP
|
|
|
|
endif # test PLATFORM ansi
|
|
|
|
|
|
|
|
ifeq ($(PLATFORM),dos)
|
|
|
|
|
|
|
|
# Use DJGPP (i.e. gcc) by default.
|
|
|
|
#
|
|
|
|
CONFIG_FILE := dos-gcc.mk
|
2006-02-01 08:52:11 +01:00
|
|
|
CC ?= gcc
|
2000-12-20 23:09:41 +01:00
|
|
|
|
|
|
|
# additionally, we provide hooks for various other compilers
|
|
|
|
#
|
2003-06-13 09:38:22 +02:00
|
|
|
ifneq ($(findstring emx,$(MAKECMDGOALS)),) # EMX gcc
|
|
|
|
CONFIG_FILE := dos-emx.mk
|
|
|
|
CC := gcc
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
|
2003-06-13 09:38:22 +02:00
|
|
|
.PHONY: emx
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
emx: setup
|
|
|
|
@cd .
|
2003-06-13 09:38:22 +02:00
|
|
|
endif
|
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
ifneq ($(findstring turboc,$(MAKECMDGOALS)),) # Turbo C
|
|
|
|
CONFIG_FILE := dos-tcc.mk
|
|
|
|
CC := tcc
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
.PHONY: turboc
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
turboc: setup
|
|
|
|
@cd .
|
2000-12-20 23:09:41 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifneq ($(findstring watcom,$(MAKECMDGOALS)),) # Watcom C/C++
|
|
|
|
CONFIG_FILE := dos-wat.mk
|
|
|
|
CC := wcc386
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
.PHONY: watcom
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
watcom: setup
|
|
|
|
@cd .
|
2000-12-20 23:09:41 +01:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifneq ($(findstring borlandc,$(MAKECMDGOALS)),) # Borland C/C++ 32-bit
|
|
|
|
CONFIG_FILE := dos-bcc.mk
|
|
|
|
CC := bcc32
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
|
2000-12-20 23:09:41 +01:00
|
|
|
.PHONY: borlandc
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
borlandc: setup
|
|
|
|
@cd .
|
2000-12-20 23:09:41 +01:00
|
|
|
endif
|
|
|
|
|
2001-12-25 21:54:33 +01:00
|
|
|
ifneq ($(findstring borlandc16,$(MAKECMDGOALS)),) # Borland C/C++ 16-bit
|
|
|
|
CONFIG_FILE := dos-bcc.mk
|
|
|
|
CC := bcc
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
|
2001-12-25 21:54:33 +01:00
|
|
|
.PHONY: borlandc16
|
[build] Suppress configure's `nothing to be done' message.
This is due to calling the configure script via `make' (within the
top-level `configure' wrapper script). The same can happen for all
other secondary make targets that are used to only modify the
primary one, e.g., `make setup devel'.
* builds/dos/detect.mk (emx, turboc, watcom, borlandc, borlandc16),
builds/os2/detect (visualage, watcom, borlandc, devel),
builds/unix/detect.mk (devel, lcc, unix), builds/windows/detect.mk
(visualc, watcom, visualage, lcc, mingw32, bcc32, devel-bcc,
devel-gcc): Use no-op recipe.
2018-05-07 08:54:34 +02:00
|
|
|
borlandc16: setup
|
|
|
|
@cd .
|
2001-12-25 21:54:33 +01:00
|
|
|
endif
|
|
|
|
|
2001-04-10 15:59:58 +02:00
|
|
|
ifneq ($(findstring bash,$(SHELL)),) # check for bash
|
2003-06-09 06:46:30 +02:00
|
|
|
SEP := /
|
2001-04-10 15:59:58 +02:00
|
|
|
DELETE := rm
|
|
|
|
COPY := cp
|
2006-12-09 21:01:43 +01:00
|
|
|
CAT := cat
|
2001-04-10 15:59:58 +02:00
|
|
|
setup: std_setup
|
|
|
|
else
|
2003-06-09 06:46:30 +02:00
|
|
|
SEP := $(BACKSLASH)
|
2001-04-10 15:59:58 +02:00
|
|
|
DELETE := del
|
2006-12-09 21:01:43 +01:00
|
|
|
CAT := type
|
2004-11-23 18:49:40 +01:00
|
|
|
|
2004-11-23 22:38:16 +01:00
|
|
|
# Setting COPY is a bit trickier. We can be running DJGPP on some
|
2014-02-06 20:23:49 +01:00
|
|
|
# Windows NT derivatives, like XP. See builds/windows/detect.mk for
|
2004-11-23 18:49:40 +01:00
|
|
|
# explanations why we need hacking here.
|
|
|
|
#
|
|
|
|
ifeq ($(OS),Windows_NT)
|
|
|
|
COPY := cmd.exe /c copy
|
|
|
|
else
|
|
|
|
COPY := copy
|
|
|
|
endif # test NT
|
|
|
|
|
2018-04-15 22:27:10 +02:00
|
|
|
setup: std_setup
|
2001-04-10 15:59:58 +02:00
|
|
|
endif
|
2000-12-20 23:09:41 +01:00
|
|
|
|
|
|
|
endif # test PLATFORM dos
|
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
|