-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpremake5.lua
90 lines (65 loc) · 1.59 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
workspace "SDF"
language "C++"
cppdialect "C++17"
platforms { "x64" }
configurations { "release", "debug" }
flags "NoPCH"
flags "MultiProcessorCompile"
startproject "sdf"
debugdir "%{wks.location}"
objdir "prebuild/%{cfg.buildcfg}-%{cfg.platform}-%{cfg.toolset}"
targetsuffix "-%{cfg.buildcfg}-%{cfg.platform}-%{cfg.toolset}"
-- Default toolset options
filter "toolset:gcc or toolset:clang"
linkoptions { "-pthread" }
buildoptions { "-march=native", "-Wall", "-pthread" }
filter "toolset:msc-*"
defines { "_CRT_SECURE_NO_WARNINGS=1" }
defines { "_SCL_SECURE_NO_WARNINGS=1" }
buildoptions { "/utf-8" }
filter "*"
-- default libraries
filter "system:linux"
links "dl"
filter "system:windows"
filter "*"
-- default outputs
filter "kind:StaticLib"
targetdir "prebuild/lib/"
filter "kind:ConsoleApp"
targetdir "prebuild/bin/"
targetextension ".exe"
filter "*"
--configurations
filter "debug"
symbols "On"
defines { "_DEBUG=1" }
filter "release"
optimize "On"
defines { "NDEBUG=1" }
filter "*"
-- Third party dependencies
include "extern"
-- Projects
project "sdf"
includedirs( "src" );
local sources = {
"src/**.cpp",
"src/**.hpp",
"src/**.hxx",
"src/**.h"
}
kind "ConsoleApp"
location "src"
files( sources )
links "x-glad"
links "x-glad"
links "x-glfw"
links "x-tinyobj"
links "x-imgui"
dependson "x-glm"
-- The Visual Studio implementation integrates natively with the system thread pool,
-- GCC and Clang needs us to take a dependency on the Intel Thread Building Blocks library.
filter "system:linux"
links "tbb"
--EOF