1 | # $Id: Config.kmk 8 2008-04-20 03:46:13Z bird $
|
---|
2 | ## @file
|
---|
3 | # kBuild configuration for kStuff
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (c) 2006-2007 knut st. osmundsen <bird-kStuff-spam@anduin.net>
|
---|
8 | #
|
---|
9 | # This file is part of kStuff.
|
---|
10 | #
|
---|
11 | # kStuff is free software; you can redistribute it and/or
|
---|
12 | # modify it under the terms of the GNU Lesser General Public
|
---|
13 | # License as published by the Free Software Foundation; either
|
---|
14 | # version 2.1 of the License, or (at your option) any later version.
|
---|
15 | #
|
---|
16 | # kStuff is distributed in the hope that it will be useful,
|
---|
17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
---|
19 | # Lesser General Public License for more details.
|
---|
20 | #
|
---|
21 | # You should have received a copy of the GNU Lesser General Public
|
---|
22 | # License along with kStuff; if not, write to the Free Software
|
---|
23 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
---|
24 | #
|
---|
25 |
|
---|
26 | #
|
---|
27 | # This is where we install during the build.
|
---|
28 | #
|
---|
29 | PATH_INS := $(PATH_OUT)/kStuff
|
---|
30 |
|
---|
31 |
|
---|
32 | #
|
---|
33 | # Templates for the kStuff.
|
---|
34 | #
|
---|
35 | TEMPLATE_kStuff = kStuff Template
|
---|
36 | TEMPLATE_kStuff_TOOL = GCC3
|
---|
37 | TEMPLATE_kStuff_TOOL.darwin = GCC4MACHO
|
---|
38 | TEMPLATE_kStuff_TOOL.os2 = GCC3OMF
|
---|
39 | TEMPLATE_kStuff_TOOL.solaris = GCC3PLAIN
|
---|
40 | TEMPLATE_kStuff_TOOL.win.x86 = VCC70
|
---|
41 | TEMPLATE_kStuff_TOOL.win.amd64 = VCC80AMD64
|
---|
42 |
|
---|
43 | TEMPLATE_kStuff_SDKS.win.x86 = WINPSDK W2K3DDKX86
|
---|
44 | TEMPLATE_kStuff_SDKS.win.amd64 = WINPSDK W2K3DDKAMD64
|
---|
45 |
|
---|
46 | TEMPLATE_kStuff_DEFS.freebsd = KS_OS_FREEBSD
|
---|
47 | TEMPLATE_kStuff_DEFS.darwin = KS_OS_DARWIN
|
---|
48 | TEMPLATE_kStuff_DEFS.linux = KS_OS_LINUX
|
---|
49 | TEMPLATE_kStuff_DEFS.netbsd = KS_OS_NETBSD
|
---|
50 | TEMPLATE_kStuff_DEFS.openbsd = KS_OS_OPENBSD
|
---|
51 | TEMPLATE_kStuff_DEFS.os2 = KS_OS_OS2
|
---|
52 | TEMPLATE_kStuff_DEFS.solaris = KS_OS_SOLARIS
|
---|
53 | TEMPLATE_kStuff_DEFS.win = KS_OS_WINDOWS _CRT_SECURE_NO_DEPRECATE _CRT_NONSTDC_NO_WARNINGS
|
---|
54 |
|
---|
55 | TEMPLATE_kStuff_DEFS.x86 = KS_BITS=32
|
---|
56 | TEMPLATE_kStuff_DEFS.amd64 = KS_BITS=64
|
---|
57 |
|
---|
58 | TEMPLATE_kStuff_INCS = $(PATH_ROOT)/include
|
---|
59 |
|
---|
60 | TEMPLATE_kStuff_ASTOOL = YASM
|
---|
61 | TEMPLATE_kStuff_ASTOOL.os2 = NASM
|
---|
62 | TEMPLATE_kStuff_ASFLAGS.freebsd = -f elf
|
---|
63 | TEMPLATE_kStuff_ASFLAGS.linux = -f elf
|
---|
64 | TEMPLATE_kStuff_ASFLAGS.os2 = -f omf
|
---|
65 | TEMPLATE_kStuff_ASFLAGS.win.x86 = -f win32 -g cv8
|
---|
66 | TEMPLATE_kStuff_ASFLAGS.win.amd64= -f win64 -g cv8
|
---|
67 |
|
---|
68 | TEMPLATE_kStuff_CFLAGS.darwin = -g -fno-common
|
---|
69 | TEMPLATE_kStuff_CFLAGS.freebsd = -g
|
---|
70 | TEMPLATE_kStuff_CFLAGS.linux = -g
|
---|
71 | TEMPLATE_kStuff_CFLAGS.os2 = -g
|
---|
72 | TEMPLATE_kStuff_CFLAGS.win = -Zi -Zl -W3 -GF -GR-
|
---|
73 | TEMPLATE_kStuff_CFLAGS.win.x86 = -MD
|
---|
74 | TEMPLATE_kStuff_CFLAGS.win.amd64 = -MT
|
---|
75 | ifneq ($(BUILD_TYPE),debug)
|
---|
76 | TEMPLATE_kStuff_CFLAGS.freebsd += -O3
|
---|
77 | TEMPLATE_kStuff_CFLAGS.linux += -O3
|
---|
78 | TEMPLATE_kStuff_CFLAGS.os2 += -O3
|
---|
79 | TEMPLATE_kStuff_CFLAGS.win += -O2b2
|
---|
80 | else
|
---|
81 | TEMPLATE_kStuff_CFLAGS.win += -Od
|
---|
82 | endif
|
---|
83 |
|
---|
84 | TEMPLATE_kStuff_CXXFLAGS.darwin = -g -fno-common
|
---|
85 | TEMPLATE_kStuff_CXXFLAGS.freebsd = -g
|
---|
86 | TEMPLATE_kStuff_CXXFLAGS.linux = -g
|
---|
87 | TEMPLATE_kStuff_CXXFLAGS.os2 = -g
|
---|
88 | TEMPLATE_kStuff_CXXFLAGS.win = -Zi -Zl -W3 -GF -GR-
|
---|
89 | TEMPLATE_kStuff_CXXFLAGS.win.x86 = -MD
|
---|
90 | TEMPLATE_kStuff_CXXFLAGS.win.amd64 = -MT
|
---|
91 | ifneq ($(BUILD_TYPE),debug)
|
---|
92 | TEMPLATE_kStuff_CXXFLAGS.freebsd+= -O3
|
---|
93 | TEMPLATE_kStuff_CXXFLAGS.linux += -O3
|
---|
94 | TEMPLATE_kStuff_CXXFLAGS.os2 += -O3
|
---|
95 | TEMPLATE_kStuff_CXXFLAGS.win += -O2b2
|
---|
96 | else
|
---|
97 | TEMPLATE_kStuff_CXXFLAGS.win += -Od
|
---|
98 | endif
|
---|
99 |
|
---|
100 | TEMPLATE_kStuff_LDFLAGS.freebsd = -g
|
---|
101 | TEMPLATE_kStuff_LDFLAGS.linux = -g
|
---|
102 | TEMPLATE_kStuff_LDFLAGS.os2 = -g
|
---|
103 | TEMPLATE_kStuff_LDFLAGS.win = /DEBUG /NODEFAULTLIB
|
---|
104 |
|
---|
105 | TEMPLATE_kStuff_LIBS.freebsd =
|
---|
106 | TEMPLATE_kStuff_LIBS.linux =
|
---|
107 | TEMPLATE_kStuff_LIBS.os2 =
|
---|
108 | TEMPLATE_kStuff_LIBS.win = \
|
---|
109 | $(PATH_SDK_WINPSDK_LIB)/psapi.Lib
|
---|
110 | TEMPLATE_kStuff_LIBS.win.x86 = \
|
---|
111 | $(PATH_TOOL_VCC70_LIB)/msvcrt.lib \
|
---|
112 | $(PATH_TOOL_VCC70_LIB)/msvcprt.lib \
|
---|
113 | $(PATH_TOOL_VCC70_LIB)/oldnames.lib \
|
---|
114 | $(PATH_SDK_W2K3DDKX86_LIB)/ntdll.lib
|
---|
115 | TEMPLATE_kStuff_LIBS.win.amd64 = \
|
---|
116 | $(PATH_TOOL_VCC80AMD64_LIB)/libcmt.lib \
|
---|
117 | $(PATH_TOOL_VCC80AMD64_LIB)/oldnames.lib \
|
---|
118 | $(PATH_SDK_W2K3DDKAMD64_LIB)/ntdll.lib
|
---|
119 |
|
---|
120 | TEMPLATE_kStuffEXE = kStuff Executable Template
|
---|
121 | TEMPLATE_kStuffEXE_EXTENDS = kStuff
|
---|
122 | TEMPLATE_kStuffEXE_DEFS = $(TEMPLATE_kStuff) KS_EXE_TARGET
|
---|
123 |
|
---|
124 | TEMPLATE_kStuffLIB = kStuff Library Template
|
---|
125 | TEMPLATE_kStuffLIB_EXTENDS = kStuff
|
---|
126 | TEMPLATE_kStuffLIB_DEFS = $(TEMPLATE_kStuff) KS_LIB_TARGET
|
---|
127 |
|
---|
128 | TEMPLATE_kStuffDLL = kStuff DLL Template
|
---|
129 | TEMPLATE_kStuffDLL_EXTENDS = kStuff
|
---|
130 | TEMPLATE_kStuffDLL_DEFS = $(TEMPLATE_kStuff) KS_DLL_TARGET
|
---|
131 | TEMPLATE_kStuffDLL_LDFLAGS.os2 = $(TEMPLATE_kStuff_LDFLAGS.os2) -Zdll
|
---|
132 |
|
---|
133 |
|
---|