-
Notifications
You must be signed in to change notification settings - Fork 5
/
Common.om
127 lines (109 loc) · 3.28 KB
/
Common.om
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
# Mention a few of the other standard variables here.
# ROOT The root directory of the current project.
# CWD The current working directory (the directory is set for each OMakefile in the project).
# EMPTY The empty string.
# STDROOT The name of the standard installed \File{OMakeroot} file.
ROOT = $(dir .)
LIB = $(dir lib)
BIN = $(dir bin)
#
# A default sort rule
#
.ORDER: .BUILDORDER
#
# ABORT_ON_COMMAND_ERROR If set to true, the construction of a target should
# be aborted whenever one of the commands to build it fail. This defaults to true,
# and should normally be left that way.
#
# \varlabel{SCANNER_MODE}{SCANNER\_MODE} This variable should be defined as one of four values
# (defaults to \verb+enabled+).
# \begin{description}
# \item[enabled] Allow the use of default \verb+.SCANNER+ rules. Whenever a rule does
# not specify a \verb+:scanner:+ dependency explicitly, try to find a
# \verb+.SCANNER+ with the same target name.
# \item[disabled] Never use default \verb+.SCANNER+ rules.
# \item[warning] Allow the use of default \verb+.SCANNER+ rules, but print a warning
# whenever one is selected.
# \item[error] Do not allow the use of default \verb+.SCANNER+ rules. If a rule
# does not specify a \verb+:scanner:+ dependency, and there is a default
# \verb+.SCANNER+ rule, the build will terminate abnormally.
# \end{description}
# \end{doc}
#
# These are defined in Omake_builtin_base
# ABORT_ON_COMMAND_ERROR = true
# SCANNER_MODE = enabled
########################################################################
# Generic Unix section
#
#
#
# INSTALL The command to install a program (install on Unix, cp on Win32).
# PATHSEP The normal path separator (: on Unix, ; on Win32).
# DIRSEP The normal directory separator (/ on Unix, \ on Win32).
# EXT_OBJ File suffix for an object file (default is .o on Unix, and .obj on Win32).
# EXT_LIB File suffix for a static library (default is .a on Unix, and .lib on Win32).
# EXT_DLL File suffix for a shared library (default is .so on Unix, and .dll on Win32).
# EXT_ASM File suffix for an assembly file (default is .s on Unix, and .asm on Win32).
# EXE File suffix for executables (default is empty for Unix, and .exe on Win32 and Cygwin).
#
# These commands are builtin, and they are the same on all platforms.
# The uppercase variables are defined for backwards compatibility only,
# their usage is deprecated.
#
CP = cp
MV = mv
RM = rm -f
MKDIR = mkdir
RMDIR = rmdir
CHMOD = chmod
if $(equal $(OSTYPE), Win32)
#
# Command names
#
INSTALL = cp
PATHSEP = ;
DIRSEP = \\
#
# Common suffixes for files
#
EXT_LIB = .lib
EXT_DLL = .dll
EXT_OBJ = .obj
EXT_ASM = .asm
EXE = .exe
export
else
#
# Command names
#
INSTALL = install
PATHSEP = :
DIRSEP = /
#
# Common suffixes for files
#
EXT_LIB = .a
EXT_DLL = .so
EXT_OBJ = .o
EXT_ASM = .s
EXE =
export
if $(equal $(OSTYPE), Cygwin)
EXE = .exe
export
declare LN
if $(not $(defined USE_SYSTEM_COMMANDS))
if $(not $(equal $(OSTYPE), Win32))
LN = ln -sf
export
export
else
LN = ln-or-cp
export
# XXX: JYH: this is a total hack.
# It should be the case the :scanner: $(EMPTY) turns off scanners.
#
NOSCANNER = /scan-dummy
.SCANNER: $(NOSCANNER)
@