forked from Mich-Dich/gluttony_old
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpremake5.lua
More file actions
55 lines (45 loc) · 1.4 KB
/
premake5.lua
File metadata and controls
55 lines (45 loc) · 1.4 KB
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
include "dependencies.lua"
workspace "gluttony"
platforms "x64"
startproject "gluttony"
configurations
{
"Debug",
"RelWithDebInfo",
"Release",
}
flags
{
"MultiProcessorCompile"
}
outputs = "%{cfg.buildcfg}-%{cfg.system}-%{cfg.architecture}"
local project_path = os.getcwd()
defines
{
"ENGINE_INSTALL_DIR=\"" .. project_path .. "/bin/" .. outputs .. "\"",
"OUTPUTS=\"" .. outputs .. "\"",
}
if os.target() == "linux" then
print("---------- target platform is linux => manually compile GLFW ----------")
os.execute("cmake -S ./vendor/glfw -B ./vendor/glfw/build") -- manuel compilation
os.execute("cmake --build ./vendor/glfw/build") -- manuel compilation
print("---------- Done compiling GLFW ----------")
print("---------- target platform is linux => manually compile meshoptimizer ----------")
os.execute("{MKDIR} vendor/meshoptimizer/build") -- manuel compilation
os.execute("cmake -S ./vendor/meshoptimizer -B ./vendor/meshoptimizer/build") -- manuel compilation
os.execute("cmake --build ./vendor/meshoptimizer/build") -- manuel compilation
print("---------- Done compiling meshoptimizer ----------")
end
group "dependencies"
include "vendor/imgui"
if os.target() == "windows" then
include "vendor/glfw"
end
group ""
group "Engine"
include "gluttony"
group ""
group "Tools"
include "gluttony_editor"
-- include "gluttony_helper"
group ""