|
1 | 1 | local BUILD_DIR = path.join("build", "ios") |
2 | | -local BGFX_DIR = "bgfx" |
3 | | -local BIMG_DIR = "bimg" |
4 | | -local BX_DIR = "bx" |
| 2 | +local SUPPORT_DIR = "StapleSupport" |
| 3 | +local TOOLING_SUPPORT_DIR = "StapleToolingSupport" |
| 4 | +local UFBX_DIR = "ufbx" |
5 | 5 |
|
6 | 6 | solution "Dependencies" |
7 | 7 | location(BUILD_DIR) |
@@ -35,220 +35,27 @@ solution "Dependencies" |
35 | 35 | ["CODE_SIGNING_ALLOWED"] = "NO", |
36 | 36 | }; |
37 | 37 |
|
38 | | -function setBxCompat() |
39 | | - filter "action:vs*" |
40 | | - includedirs { path.join(BX_DIR, "include/compat/msvc") } |
41 | | - |
42 | | - filter { "system:ios" } |
43 | | - includedirs { |
44 | | - path.join(BGFX_DIR, "3rdparty/directx-headers/include/wsl"), |
45 | | - path.join(BGFX_DIR, "3rdparty/directx-headers/include/wsl/stubs"), |
46 | | - path.join(BX_DIR, "include/compat/ios") |
47 | | - } |
48 | | - buildoptions { "-x objective-c++" } |
49 | | - |
50 | | - filter { "system:macosx" } |
51 | | - includedirs { |
52 | | - path.join(BGFX_DIR, "3rdparty/directx-headers/include/wsl"), |
53 | | - path.join(BGFX_DIR, "3rdparty/directx-headers/include/wsl/stubs"), |
54 | | - path.join(BX_DIR, "include/compat/osx") |
55 | | - } |
56 | | - buildoptions { "-x objective-c++" } |
57 | | - |
58 | | - filter { "system:linux" } |
59 | | - includedirs { |
60 | | - path.join(BGFX_DIR, "3rdparty/directx-headers/include/wsl"), |
61 | | - path.join(BGFX_DIR, "3rdparty/directx-headers/include/wsl/stubs"), |
62 | | - path.join(BX_DIR, "include/compat/linux") |
63 | | - } |
64 | | - |
65 | | - filter { "system:windows", "action:gmake" } |
66 | | - includedirs { path.join(BX_DIR, "include/compat/mingw") } |
67 | | - |
68 | | - filter "action:gmake" |
69 | | - buildoptions { "-fPIC" } |
70 | | -end |
71 | | - |
72 | | -project "bgfx" |
73 | | - kind "SharedLib" |
74 | | - language "C++" |
75 | | - cppdialect "C++20" |
76 | | - exceptionhandling "Off" |
77 | | - rtti "Off" |
78 | | - |
79 | | - defines { |
80 | | - "__STDC_FORMAT_MACROS", |
81 | | - "BGFX_SHARED_LIB_BUILD" |
82 | | - } |
83 | | - |
84 | | - files { |
85 | | - path.join(BGFX_DIR, "include/bgfx/**.h"), |
86 | | - path.join(BGFX_DIR, "src/*.cpp"), |
87 | | - path.join(BGFX_DIR, "src/*.h"), |
88 | | - } |
89 | | - |
90 | | - excludes { |
91 | | - path.join(BGFX_DIR, "src/amalgamated.cpp"), |
92 | | - } |
93 | | - |
94 | | - includedirs { |
95 | | - path.join(BX_DIR, "include"), |
96 | | - path.join(BIMG_DIR, "include"), |
97 | | - path.join(BGFX_DIR, "include"), |
98 | | - path.join(BGFX_DIR, "3rdparty"), |
99 | | - path.join(BGFX_DIR, "3rdparty/directx-headers/include"), |
100 | | - path.join(BGFX_DIR, "3rdparty/directx-headers/include/directx"), |
101 | | - path.join(BGFX_DIR, "3rdparty/khronos") |
102 | | - } |
103 | | - |
104 | | - links { "bx", "bimg" } |
105 | | - |
106 | | - filter "configurations:Debug" |
107 | | - defines { "BX_CONFIG_DEBUG=1" } |
108 | | - |
109 | | - filter "configurations:Release" |
110 | | - defines { "BX_CONFIG_DEBUG=0" } |
111 | | - |
112 | | - filter "action:vs*" |
113 | | - defines "_CRT_SECURE_NO_WARNINGS" |
114 | | - buildoptions { "/Zc:__cplusplus" } |
115 | | - |
116 | | - excludes { |
117 | | - path.join(BGFX_DIR, "src/glcontext_glx.cpp"), |
118 | | - path.join(BGFX_DIR, "src/glcontext_egl.cpp") |
119 | | - } |
120 | | - |
121 | | - filter "system:macosx" |
122 | | - files { |
123 | | - path.join(BGFX_DIR, "src/*.mm"), |
124 | | - } |
125 | | - |
126 | | - excludes { |
127 | | - path.join(BGFX_DIR, "src/amalgamated.mm"), |
128 | | - } |
129 | | - |
130 | | - links { "Cocoa.framework", "IOKit.framework", "CoreGraphics.framework", "Metal.framework", "QuartzCore.framework" } |
131 | | - |
132 | | - filter "system:ios" |
133 | | - files { |
134 | | - path.join(BGFX_DIR, "src/*.mm"), |
135 | | - } |
136 | | - |
137 | | - excludes { |
138 | | - path.join(BGFX_DIR, "src/amalgamated.mm"), |
139 | | - } |
140 | | - |
141 | | - links { "UIKit.framework", "Metal.framework", "MetalKit.framework", "QuartzCore.framework" } |
142 | | - |
143 | | - filter "system:linux" |
144 | | - links { |
145 | | - "m", "pthread", "X11", "GL" |
146 | | - } |
147 | | - |
148 | | - setBxCompat() |
149 | | - |
150 | | -project "bimg" |
151 | | - kind "StaticLib" |
152 | | - language "C++" |
153 | | - cppdialect "C++20" |
154 | | - exceptionhandling "Off" |
155 | | - rtti "Off" |
156 | | - |
157 | | - files { |
158 | | - path.join(BIMG_DIR, "include/bimg/*.h"), |
159 | | - path.join(BIMG_DIR, "src/image*.cpp"), |
160 | | - path.join(BIMG_DIR, "src/*.h"), |
161 | | - path.join(BIMG_DIR, "3rdparty/**.cpp"), |
162 | | - path.join(BIMG_DIR, "3rdparty/**.c"), |
163 | | - } |
164 | | - |
165 | | - includedirs { |
166 | | - path.join(BX_DIR, "include"), |
167 | | - path.join(BIMG_DIR, "include"), |
168 | | - path.join(BIMG_DIR, "3rdparty/"), |
169 | | - path.join(BIMG_DIR, "3rdparty/astc-encoder/include"), |
170 | | - path.join(BIMG_DIR, "3rdparty/edtaa3/"), |
171 | | - path.join(BIMG_DIR, "3rdparty/etc1"), |
172 | | - path.join(BIMG_DIR, "3rdparty/etc2"), |
173 | | - path.join(BIMG_DIR, "3rdparty/iqa/include/"), |
174 | | - path.join(BIMG_DIR, "3rdparty/libsquish/include"), |
175 | | - path.join(BIMG_DIR, "3rdparty/lodepng"), |
176 | | - path.join(BIMG_DIR, "3rdparty/nvtt"), |
177 | | - path.join(BIMG_DIR, "3rdparty/nvtt/**"), |
178 | | - path.join(BIMG_DIR, "3rdparty/pvrtc"), |
179 | | - path.join(BIMG_DIR, "3rdparty/stb"), |
180 | | - path.join(BIMG_DIR, "3rdparty/tinyexr"), |
181 | | - path.join(BIMG_DIR, "3rdparty/tinyexr/deps/miniz/"), |
182 | | - } |
183 | | - |
184 | | - excludes { path.join(BIMG_DIR, "3rdparty/lodepng/lodepng.cpp") } |
185 | | - |
186 | | - filter "configurations:Debug" |
187 | | - defines { "BX_CONFIG_DEBUG=1" } |
188 | | - |
189 | | - filter "configurations:Release" |
190 | | - defines { "BX_CONFIG_DEBUG=0" } |
191 | | - |
192 | | - setBxCompat() |
193 | | - |
194 | | - filter "action:vs*" |
195 | | - defines "_CRT_SECURE_NO_WARNINGS" |
196 | | - buildoptions { "/Zc:__cplusplus" } |
197 | | - |
198 | | -project "bx" |
199 | | - kind "StaticLib" |
200 | | - language "C++" |
201 | | - cppdialect "C++20" |
202 | | - exceptionhandling "Off" |
203 | | - rtti "Off" |
204 | | - defines "__STDC_FORMAT_MACROS" |
205 | | - |
206 | | - files { |
207 | | - path.join(BX_DIR, "include/bx/*.h"), |
208 | | - path.join(BX_DIR, "include/bx/inline/*.inl"), |
209 | | - path.join(BX_DIR, "src/*.cpp") |
210 | | - } |
211 | | - |
212 | | - excludes { |
213 | | - path.join(BX_DIR, "src/amalgamated.cpp"), |
214 | | - path.join(BX_DIR, "src/crtnone.cpp") |
215 | | - } |
216 | | - |
217 | | - includedirs { |
218 | | - path.join(BX_DIR, "3rdparty"), |
219 | | - path.join(BX_DIR, "include") |
220 | | - } |
221 | | - |
222 | | - filter "action:vs*" |
223 | | - defines "_CRT_SECURE_NO_WARNINGS" |
224 | | - buildoptions { "/Zc:__cplusplus" } |
225 | | - |
226 | | - filter "configurations:Debug" |
227 | | - defines { "BX_CONFIG_DEBUG=1" } |
228 | | - |
229 | | - filter "configurations:Release" |
230 | | - defines { "BX_CONFIG_DEBUG=0" } |
231 | | - |
232 | | - setBxCompat() |
233 | | - |
234 | | -project "StapleSupport" |
| 38 | +project "StapleToolingSupport" |
235 | 39 | kind "SharedLib" |
236 | | - language "C++" |
| 40 | + language "C" |
237 | 41 |
|
238 | 42 | includedirs { |
239 | | - "freetype/include" |
| 43 | + SUPPORT_DIR, |
| 44 | + "ufbx", |
240 | 45 | } |
241 | 46 |
|
242 | | - libdirs { "build/native/freetype/Release/Release" } |
243 | | - |
244 | | - links { "freetype" } |
| 47 | + defines { "UFBX_REAL_IS_FLOAT" } |
245 | 48 |
|
246 | 49 | files { |
247 | 50 |
|
248 | | - path.join(SUPPORT_DIR, "*.c"); |
249 | | - path.join(SUPPORT_DIR, "*.cpp"); |
250 | 51 | path.join(SUPPORT_DIR, "*.h"); |
251 | 52 | path.join(SUPPORT_DIR, "*.hpp"); |
| 53 | + path.join(TOOLING_SUPPORT_DIR, "**.c"); |
| 54 | + path.join(TOOLING_SUPPORT_DIR, "**.cpp"); |
| 55 | + path.join(TOOLING_SUPPORT_DIR, "**.h"); |
| 56 | + path.join(TOOLING_SUPPORT_DIR, "**.hpp"); |
| 57 | + path.join(UFBX_DIR, "*.h"); |
| 58 | + path.join(UFBX_DIR, "*.c"); |
252 | 59 | } |
253 | 60 |
|
254 | 61 | filter "system:macosx" |
|
0 commit comments