forked from lsalzman/enet
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathpremake5.lua
More file actions
90 lines (85 loc) · 2.33 KB
/
premake5.lua
File metadata and controls
90 lines (85 loc) · 2.33 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
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
solution "enet"
configurations { "Debug", "Release" }
defines { "ENET_NETWORK_NEXT=1" }
platforms { "portable", "x64" }
project "next"
kind "StaticLib"
links { "sodium" }
files {
"next/next.h",
"next/next.cpp",
"next/next_*.h",
"next/next_*.cpp",
}
includedirs { "next", "sodium" }
filter "system:windows"
linkoptions { "/ignore:4221" }
disablewarnings { "4324" }
filter "system:macosx"
linkoptions { "-framework SystemConfiguration -framework CoreFoundation" }
project "enet"
kind "StaticLib"
language "C"
cdialect "C99"
links { "next" }
files { "enet/*.c" }
includedirs { "enet", "next", "sodium" }
filter "configurations:Debug"
targetsuffix "d"
defines({ "DEBUG" })
symbols "On"
filter "configurations:Release"
optimize "Speed"
defines({ "NDEBUG" })
optimize "On"
editandcontinue "Off"
filter "system:windows"
location ("visualstudio")
project "sodium"
kind "StaticLib"
includedirs { "sodium" }
files {
"sodium/**.c",
"sodium/**.h",
}
filter { "system:not windows", "platforms:*x64 or *avx or *avx2" }
files {
"sodium/**.S"
}
filter "platforms:*x86"
architecture "x86"
defines { "NEXT_X86=1" }
filter "platforms:*x64"
architecture "x86_64"
defines { "NEXT_X64=1" }
filter "platforms:*avx"
architecture "x86_64"
vectorextensions "AVX"
defines { "NEXT_X64=1", "NEXT_AVX=1" }
filter "platforms:*avx2"
architecture "x86_64"
vectorextensions "AVX2"
defines { "NEXT_X64=1", "NEXT_AVX=1", "NEXT_AVX2=1" }
filter "system:windows"
disablewarnings { "4221", "4244", "4715", "4197", "4146", "4324", "4456", "4100", "4459", "4245" }
linkoptions { "/ignore:4221" }
filter { "action:gmake" }
buildoptions { "-Wno-unused-parameter", "-Wno-unused-function", "-Wno-unknown-pragmas", "-Wno-unused-variable", "-Wno-type-limits" }
project "client"
kind "ConsoleApp"
links { "enet", "next", "sodium" }
files { "client.cpp" }
includedirs { "enet", "next" }
filter "system:not windows"
links { "pthread" }
filter "system:macosx"
linkoptions { "-framework SystemConfiguration -framework CoreFoundation" }
project "server"
kind "ConsoleApp"
links { "enet", "next", "sodium" }
files { "server.cpp" }
includedirs { "enet", "next" }
filter "system:not windows"
links { "pthread" }
filter "system:macosx"
linkoptions { "-framework SystemConfiguration -framework CoreFoundation" }