forked from FirestormViewer/fs-build-variables
-
Notifications
You must be signed in to change notification settings - Fork 0
/
variables
104 lines (88 loc) · 6.41 KB
/
variables
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
# The intended use of this file is for a calling bash script to read it with
# the "source" or "." command. However, keep the syntax as simple as possible
# to permit other languages to parse it. Syntax rules:
# - Ignore (of course) any line starting with #.
# - Ignore completely empty lines.
# - Every remaining line is a variable assignment of the form:
# VAR="text"
# Please always quote the "text" value, specifically with double-quotes.
# - Do not use line continuation. Every assignment should be on a single line.
# - It is permitted for "text" to embed references to other variables, using
# either $OTHERVAR or ${OTHERVAR} syntax. Do not use fancier bash
# substitutions. In particular, one variable can simply be an alias for
# another:
# VAR="$OTHERVAR"
# These conventions should permit this file to be (for instance) imported by a
# Python script. (See os.path.expandvars() for processing of embedded
# variables.) However, keep the syntax strictly to the rules above to permit
# hand-coded parsing by other languages.
# This means, in particular, that when maintaining the variables in this file,
# do not use bash fanciness to remove or replace individual switches. Instead,
# refactor the definitions to build up the variables additively.
# *Consumers* of this file may freely use the remove/replace functions in the
# *companion convenience script.
# Marker variable so you can test whether or not this has been done already
AUTOBUILD_SOURCE_ENVIRONMENT="Initialized"
# Windows
LL_BUILD_WINDOWS_BASE_MACROS="/D_SECURE_STL=0 /D_HAS_ITERATOR_DEBUGGING=0 /DWIN32 /D_WINDOWS /DLL_WINDOWS=1 /DUNICODE /D_UNICODE /DWINVER=0x0601 /D_WIN32_WINNT=0x0601 /DLL_OS_DRAGDROP_ENABLED=1 /DLIB_NDOF=1"
# removed the /SAFESEH:NO /NODEFAULTLIB:LIBCMT altogether. Earlier solution of inserting /LINK switch
# earlier in the command line did not work for all projects. Removing switches entirely still works as expected.
LL_BUILD_WINDOWS_BASE_SWITCHES="/std:c++17 /Zc:wchar_t- /Zi /GR /DEBUG"
LL_BUILD_WINDOWS_BASE="$LL_BUILD_WINDOWS_BASE_SWITCHES $LL_BUILD_WINDOWS_BASE_MACROS"
LL_BUILD_WINDOWS_RELEASE_MACROS="/DLL_RELEASE=1 /DLL_RELEASE_FOR_DOWNLOAD=1 /DNDEBUG $LL_BUILD_WINDOWS_BASE_MACROS"
LL_BUILD_WINDOWS_RELEASE_SWITCHES="/MD /O2 /Ob2 $LL_BUILD_WINDOWS_BASE_SWITCHES"
LL_BUILD_WINDOWS_RELEASE="$LL_BUILD_WINDOWS_RELEASE_SWITCHES $LL_BUILD_WINDOWS_RELEASE_MACROS"
LL_BUILD_WINDOWS_RELEASEOS="$LL_BUILD_WINDOWS_RELEASE"
LL_BUILD_WINDOWS_RELEASEFS="$LL_BUILD_WINDOWS_RELEASE"
LL_BUILD_WINDOWS_RELEASEFS_AVX="LL_BUILD_WINDOWS_RELEASE"
LL_BUILD_WINDOWS_RELEASEFS_AVX2="LL_BUILD_WINDOWS_RELEASE"
LL_BUILD_WINDOWS_RELEASEFS_OPEN="LL_BUILD_WINDOWS_RELEASE"
LL_BUILD_WINDOWS_RELWITHDEBINFO_MACROS="/DLL_RELEASE=1 /DLL_RELEASE_WITH_DEBUG_INFO=1 /DNDEBUG $LL_BUILD_WINDOWS_BASE_MACROS"
LL_BUILD_WINDOWS_RELWITHDEBINFO_SWITCHES="/MD /Od /Ob0 $LL_BUILD_WINDOWS_BASE_SWITCHES"
LL_BUILD_WINDOWS_RELWITHDEBINFO="$LL_BUILD_WINDOWS_RELWITHDEBINFO_SWITCHES $LL_BUILD_WINDOWS_RELWITHDEBINFO_MACROS"
LL_BUILD_WINDOWS_RELWITHDEBINFOOS="$LL_BUILD_WINDOWS_RELWITHDEBINFO"
LL_BUILD_WINDOWS_RELWITHDEBINFOFS="$LL_BUILD_WINDOWS_RELWITHDEBINFO"
LL_BUILD_WINDOWS_RELWITHDEBINFOFS_OPEN="$LL_BUILD_WINDOWS_RELWITHDEBINFO"
LL_BUILD_WINDOWS_DEBUG_MACROS="/D_DEBUG /DLL_DEBUG=1 /D_SCL_SECURE_NO_WARNINGS=1 $LL_BUILD_WINDOWS_BASE_MACROS"
LL_BUILD_WINDOWS_DEBUG_SWITCHES="/MDd /Od /NODEFAULTLIB:LIBCMTD /NODEFAULTLIB:MSVCRT $LL_BUILD_WINDOWS_BASE_SWITCHES"
LL_BUILD_WINDOWS_DEBUG="$LL_BUILD_WINDOWS_DEBUG_SWITCHES $LL_BUILD_WINDOWS_DEBUG_MACROS"
LL_BUILD_WINDOWS_DEBUGOS="$LL_BUILD_WINDOWS_DEBUG"
# Mac and Linux common
LL_BUILD_POSIX_BASE_MACROS="-DLL_OS_DRAGDROP_ENABLED=1"
LL_BUILD_POSIX_BASE_SWITCHES="-std=c++17 -fPIC"
# Mac
LL_BUILD_DARWIN_BASE_MACROS="-DPIC -DLL_DARWIN=1 $LL_BUILD_POSIX_BASE_MACROS"
LL_BUILD_DARWIN_BASE_SWITCHES="-gdwarf-2 -stdlib=libc++ -Wno-unused-but-set-variable -Wno-return-type -Wno-tautological-overlap-compare -mmacosx-version-min=10.15 -iwithsysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/ $LL_BUILD_POSIX_BASE_SWITCHES"
LL_BUILD_DARWIN_BASE="$LL_BUILD_DARWIN_BASE_SWITCHES $LL_BUILD_DARWIN_BASE_MACROS"
LL_BUILD_DARWIN_RELEASE_MACROS="-DLL_RELEASE=1 -DLL_RELEASE_FOR_DOWNLOAD=1 -DNDEBUG $LL_BUILD_DARWIN_BASE_MACROS"
LL_BUILD_DARWIN_RELEASE_SWITCHES="-O3 $LL_BUILD_DARWIN_BASE_SWITCHES"
LL_BUILD_DARWIN_RELEASE="$LL_BUILD_DARWIN_RELEASE_SWITCHES $LL_BUILD_DARWIN_RELEASE_MACROS"
LL_BUILD_DARWIN_RELEASEOS="$LL_BUILD_DARWIN_RELEASE"
LL_BUILD_DARWIN_RELEASEFS="$LL_BUILD_DARWIN_RELEASE"
LL_BUILD_DARWIN_RELEASEFS_OPEN="$LL_BUILD_DARWIN_RELEASE"
LL_BUILD_DARWIN_RELWITHDEBINFO_MACROS="-DLL_RELEASE=1 -DNDEBUG -DLL_RELEASE_WITH_DEBUG_INFO=1 $LL_BUILD_DARWIN_BASE_MACROS"
LL_BUILD_DARWIN_RELWITHDEBINFO_SWITCHES="-O0 $LL_BUILD_DARWIN_BASE_SWITCHES"
LL_BUILD_DARWIN_RELWITHDEBINFO="$LL_BUILD_DARWIN_RELWITHDEBINFO_SWITCHES $LL_BUILD_DARWIN_RELWITHDEBINFO_MACROS"
LL_BUILD_DARWIN_RELWITHDEBINFOOS="$LL_BUILD_DARWIN_RELWITHDEBINFO"
LL_BUILD_DARWIN_RELWITHDEBINFOFS="$LL_BUILD_DARWIN_RELWITHDEBINFO"
LL_BUILD_DARWIN_RELWITHDEBINFOFS_OPEN="$LL_BUILD_DARWIN_RELWITHDEBINFO"
LL_BUILD_DARWIN_DEBUG_MACROS="-D_DEBUG -DLL_DEBUG=1 $LL_BUILD_DARWIN_BASE_MACROS"
LL_BUILD_DARWIN_DEBUG_SWITCHES="-O0 $LL_BUILD_DARWIN_BASE_SWITCHES"
LL_BUILD_DARWIN_DEBUG="$LL_BUILD_DARWIN_DEBUG_SWITCHES $LL_BUILD_DARWIN_DEBUG_MACROS"
LL_BUILD_DARWIN_DEBUGOS="$LL_BUILD_DARWIN_DEBUG"
# Linux
LL_BUILD_LINUX_BASE_MACROS="-DLL_LINUX=1 $LL_BUILD_POSIX_BASE_MACROS"
LL_BUILD_LINUX_BASE_SWITCHES=" -g -pipe $LL_BUILD_POSIX_BASE_SWITCHES"
LL_BUILD_LINUX_BASE="$LL_BUILD_LINUX_BASE_SWITCHES $LL_BUILD_LINUX_BASE_MACROS"
LL_BUILD_LINUX_RELEASE_MACROS="-DLL_RELEASE=1 -DLL_RELEASE_FOR_DOWNLOAD=1 $LL_BUILD_LINUX_BASE_MACROS"
LL_BUILD_LINUX_RELEASE_SWITCHES="$LL_BUILD_LINUX_BASE_SWITCHES"
LL_BUILD_LINUX_RELEASE="$LL_BUILD_LINUX_RELEASE_SWITCHES $LL_BUILD_LINUX_RELEASE_MACROS"
LL_BUILD_LINUX_RELEASEOS="$LL_BUILD_LINUX_RELEASE"
LL_BUILD_LINUX_RELEASEFS="$LL_BUILD_LINUX_RELEASE"
LL_BUILD_LINUX_RELEASEFS_OPEN="$LL_BUILD_LINUX_RELEASE"
LL_BUILD_LINUX_RELWITHDEBINFO_MACROS="-DLL_RELEASE=1 -D_GLIBCXX_ASSERTIONS $LL_BUILD_LINUX_BASE_MACROS"
LL_BUILD_LINUX_RELWITHDEBINFO_SWITCHES="$LL_BUILD_LINUX_BASE_SWITCHES"
LL_BUILD_LINUX_RELWITHDEBINFO="$LL_BUILD_LINUX_RELWITHDEBINFO_SWITCHES $LL_BUILD_LINUX_RELWITHDEBINFO_MACROS"
LL_BUILD_LINUX_RELWITHDEBINFOOS="$LL_BUILD_LINUX_RELWITHDEBINFO"
LL_BUILD_LINUX_RELWITHDEBINFOFS="$LL_BUILD_LINUX_RELWITHDEBINFO"
LL_BUILD_LINUX_RELWITHDEBINFOFS_OPEN="$LL_BUILD_LINUX_RELWITHDEBINFO"