-
Notifications
You must be signed in to change notification settings - Fork 0
/
premake5.lua
114 lines (91 loc) · 1.99 KB
/
premake5.lua
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
workspace "Gozel"
architecture "x64"
startproject "Gozel"
configurations{ "Debug", "Release" }
flags{ "MultiProcessorCompile" }
outputdir = "%{cfg.buildcfg}-%{cfg.system}-%{cfg.architecture}"
group "Dependencies"
include "Gozel/vendor/GLFW"
include "Gozel/vendor/GLAD"
group ""
project "Gozel"
location "Gozel"
kind "StaticLib"
language "C++"
cppdialect "C++17"
staticruntime "on"
targetdir ("bin/" .. outputdir .. "/%{prj.name}")
objdir ("bin-int/" .. outputdir .. "/%{prj.name}")
files
{
"%{prj.location}/vendor/slogger/**.h",
"%{prj.location}/vendor/slogger/**.cpp",
"%{prj.location}/vendor/stb_image/**.h",
"%{prj.location}/vendor/stb_image/**.cpp",
"%{prj.location}/vendor/glm/**.hpp",
"%{prj.location}/vendor/glm/**.inl",
"%{prj.location}/src/**.h",
"%{prj.location}/src/**.cpp",
"%{prj.location}/src/**.c",
"%{prj.location}/src/**.hpp"
}
includedirs
{
"%{prj.location}/src/*",
"%{prj.location}/vendor",
"%{prj.location}/vendor/GLFW/include",
"%{prj.location}/vendor/GLAD/include"
}
links
{
"GLFW",
"GLAD"
}
filter "system:windows"
systemversion "latest"
defines
{
"_CRT_SECURE_NO_WARNINGS",
"GLFW_INCLUDE_NONE",
"RENDER_PLATFORM_WINDOWS_"
}
links{"opengl32.lib"}
filter "system:linux"
systemversion "latest"
defines
{
"_GLFW_X11",
"RENDER_PLATFORM_LINUX_"
}
project "Sandbox"
location "Sandbox"
kind "ConsoleApp"
language "C++"
cppdialect "C++17"
staticruntime "on"
targetdir ("bin/" .. outputdir .. "/%{prj.name}")
objdir ("bin-int/" .. outputdir .. "/%{prj.name}")
files
{
"%{prj.location}/src/**.h",
"%{prj.location}/src/**.cpp",
"%{prj.location}/src/**.c",
"%{prj.location}/src/**.hpp"
}
includedirs
{
"Gozel/src/*",
"Gozel/vendor"
}
links
{
"Gozel",
"GLFW",
"GLAD"
}
configuration { "linux", "gmake" }
linkoptions {"-lX11 -lpthread -ldl"}
filter "system:windows"
systemversion "latest"
filter "system:linux"
systemversion "latest"