~oif-team/ubuntu/natty/qt4-x11/xi2.1

« back to all changes in this revision

Viewing changes to src/3rdparty/freetype/builds/dos/detect.mk

  • Committer: Bazaar Package Importer
  • Author(s): Adam Conrad
  • Date: 2005-08-24 04:09:09 UTC
  • Revision ID: james.westby@ubuntu.com-20050824040909-xmxe9jfr4a0w5671
Tags: upstream-4.0.0
ImportĀ upstreamĀ versionĀ 4.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#
 
2
# FreeType 2 configuration file to detect a DOS host platform.
 
3
#
 
4
 
 
5
 
 
6
# Copyright 1996-2000, 2003 by
 
7
# David Turner, Robert Wilhelm, and Werner Lemberg.
 
8
#
 
9
# This file is part of the FreeType project, and may only be used, modified,
 
10
# and distributed under the terms of the FreeType project license,
 
11
# LICENSE.TXT.  By continuing to use, modify, or distribute this file you
 
12
# indicate that you have read the license and understand and accept it
 
13
# fully.
 
14
 
 
15
 
 
16
.PHONY: setup
 
17
 
 
18
 
 
19
ifeq ($(PLATFORM),ansi)
 
20
 
 
21
  # Test for DJGPP by checking the DJGPP environment variable, which must be
 
22
  # set in order to use the system (ie. it will always be present when the
 
23
  # `make' utility is run).
 
24
  #
 
25
  # We test for the COMSPEC environment variable, then run the `ver'
 
26
  # command-line program to see if its output contains the word `Dos' or
 
27
  # `DOS'.
 
28
  #
 
29
  # If this is true, we are running a Dos-ish platform (or an emulation).
 
30
  #
 
31
  ifdef DJGPP
 
32
    PLATFORM := dos
 
33
  else
 
34
    ifdef COMSPEC
 
35
      is_dos := $(findstring DOS,$(subst Dos,DOS,$(shell ver)))
 
36
 
 
37
      # We try to recognize a Dos session under OS/2.  The `ver' command
 
38
      # returns `Operating System/2 ...' there, so `is_dos' should be empty.
 
39
      #
 
40
      # To recognize a Dos session under OS/2, we check COMSPEC for the
 
41
      # substring `MDOS\COMMAND'
 
42
      #
 
43
      ifeq ($(is_dos),)
 
44
        is_dos := $(findstring MDOS\COMMAND,$(COMSPEC))
 
45
      endif
 
46
    endif # test COMSPEC
 
47
 
 
48
    ifneq ($(is_dos),)
 
49
 
 
50
      PLATFORM := dos
 
51
 
 
52
    endif # test Dos
 
53
  endif # test DJGPP
 
54
endif # test PLATFORM ansi
 
55
 
 
56
ifeq ($(PLATFORM),dos)
 
57
 
 
58
  # Use DJGPP (i.e. gcc) by default.
 
59
  #
 
60
  CONFIG_FILE := dos-gcc.mk
 
61
  ifndef CC
 
62
    CC        := gcc
 
63
  endif
 
64
 
 
65
  # additionally, we provide hooks for various other compilers
 
66
  #
 
67
  ifneq ($(findstring emx,$(MAKECMDGOALS)),)        # EMX gcc
 
68
    CONFIG_FILE := dos-emx.mk
 
69
    CC          := gcc
 
70
    emx: setup
 
71
    .PHONY: emx
 
72
  endif
 
73
 
 
74
  ifneq ($(findstring turboc,$(MAKECMDGOALS)),)     # Turbo C
 
75
    CONFIG_FILE := dos-tcc.mk
 
76
    CC          := tcc
 
77
    turboc: setup
 
78
    .PHONY: turboc
 
79
  endif
 
80
 
 
81
  ifneq ($(findstring watcom,$(MAKECMDGOALS)),)     # Watcom C/C++
 
82
    CONFIG_FILE := dos-wat.mk
 
83
    CC          := wcc386
 
84
    watcom: setup
 
85
    .PHONY: watcom
 
86
  endif
 
87
 
 
88
  ifneq ($(findstring borlandc,$(MAKECMDGOALS)),)   # Borland C/C++ 32-bit
 
89
    CONFIG_FILE := dos-bcc.mk
 
90
    CC          := bcc32
 
91
    borlandc: setup
 
92
    .PHONY: borlandc
 
93
  endif
 
94
 
 
95
  ifneq ($(findstring borlandc16,$(MAKECMDGOALS)),) # Borland C/C++ 16-bit
 
96
    CONFIG_FILE := dos-bcc.mk
 
97
    CC          := bcc
 
98
    borlandc16: setup
 
99
    .PHONY: borlandc16
 
100
  endif
 
101
 
 
102
  ifneq ($(findstring bash,$(SHELL)),)              # check for bash
 
103
    SEP    := /
 
104
    DELETE := rm
 
105
    COPY   := cp
 
106
    setup: std_setup
 
107
  else
 
108
    SEP    := $(BACKSLASH)
 
109
    DELETE := del
 
110
    COPY   := copy
 
111
    setup: dos_setup
 
112
  endif
 
113
 
 
114
endif     # test PLATFORM dos
 
115
 
 
116
 
 
117
# EOF