209 lines
4.3 KiB
Lua
209 lines
4.3 KiB
Lua
workspace "BigBaseV2"
|
|
architecture "x64"
|
|
startproject "BigBaseV2"
|
|
|
|
configurations
|
|
{
|
|
"Debug",
|
|
"Release",
|
|
"Dist"
|
|
}
|
|
|
|
outputdir = "%{cfg.buildcfg}"
|
|
|
|
IncludeDir = {}
|
|
IncludeDir["fmtlib"] = "vendor/fmtlib/include"
|
|
IncludeDir["json"] = "vendor/json/single_include"
|
|
IncludeDir["MinHook"] = "vendor/MinHook/include"
|
|
IncludeDir["ImGui"] = "vendor/ImGui"
|
|
IncludeDir["ImGuiImpl"] = "vendor/ImGui/examples"
|
|
IncludeDir["StackWalker"] = "vendor/StackWalker/Main/StackWalker/"
|
|
|
|
CppVersion = "C++17"
|
|
MsvcToolset = "v142"
|
|
WindowsSdkVersion = "10.0"
|
|
|
|
function DeclareMSVCOptions()
|
|
filter "system:windows"
|
|
staticruntime "Off"
|
|
systemversion (WindowsSdkVersion)
|
|
toolset (MsvcToolset)
|
|
cppdialect (CppVersion)
|
|
|
|
defines
|
|
{
|
|
"_CRT_SECURE_NO_WARNINGS",
|
|
"NOMINMAX",
|
|
"WIN32_LEAN_AND_MEAN",
|
|
"_WIN32_WINNT=0x601" -- Support Windows 7
|
|
}
|
|
|
|
disablewarnings
|
|
{
|
|
"4100", -- C4100: unreferenced formal parameter
|
|
"4201", -- C4201: nameless struct/union
|
|
"4307" -- C4307: integral constant overflow
|
|
}
|
|
end
|
|
|
|
function DeclareDebugOptions()
|
|
filter "configurations:Debug"
|
|
defines { "_DEBUG" }
|
|
symbols "On"
|
|
filter "not configurations:Debug"
|
|
defines { "NDEBUG" }
|
|
end
|
|
|
|
project "ImGui"
|
|
location "vendor/%{prj.name}"
|
|
kind "StaticLib"
|
|
language "C++"
|
|
|
|
targetdir ("bin/lib/" .. outputdir)
|
|
objdir ("bin/lib/int/" .. outputdir .. "/%{prj.name}")
|
|
|
|
files
|
|
{
|
|
"vendor/%{prj.name}/imgui.cpp",
|
|
"vendor/%{prj.name}/imgui_demo.cpp",
|
|
"vendor/%{prj.name}/imgui_draw.cpp",
|
|
"vendor/%{prj.name}/imgui_widgets.cpp",
|
|
"vendor/%{prj.name}/examples/imgui_impl_dx11.cpp",
|
|
"vendor/%{prj.name}/examples/imgui_impl_win32.cpp"
|
|
}
|
|
|
|
includedirs
|
|
{
|
|
"vendor/%{prj.name}"
|
|
}
|
|
|
|
DeclareMSVCOptions()
|
|
DeclareDebugOptions()
|
|
|
|
project "fmtlib"
|
|
location "vendor/%{prj.name}"
|
|
kind "StaticLib"
|
|
language "C++"
|
|
|
|
targetdir ("bin/lib/" .. outputdir)
|
|
objdir ("bin/lib/int/" .. outputdir .. "/%{prj.name}")
|
|
|
|
files
|
|
{
|
|
"vendor/%{prj.name}/include/**.h",
|
|
"vendor/%{prj.name}/src/**.cc"
|
|
}
|
|
|
|
includedirs
|
|
{
|
|
"vendor/%{prj.name}/include"
|
|
}
|
|
|
|
DeclareMSVCOptions()
|
|
DeclareDebugOptions()
|
|
|
|
project "StackWalker"
|
|
location "vendor/%{prj.name}"
|
|
kind "StaticLib"
|
|
language "C++"
|
|
|
|
targetdir ("bin/lib/" .. outputdir)
|
|
objdir ("bin/lib/int/" .. outputdir .. "/%{prj.name}")
|
|
|
|
files
|
|
{
|
|
"vendor/%{prj.name}/Main/StackWalker/StackWalker.cpp"
|
|
}
|
|
|
|
includedirs
|
|
{
|
|
"vendor/%{prj.name}/include"
|
|
}
|
|
|
|
DeclareMSVCOptions()
|
|
DeclareDebugOptions()
|
|
|
|
project "MinHook"
|
|
location "vendor/%{prj.name}"
|
|
kind "StaticLib"
|
|
language "C"
|
|
|
|
targetdir ("bin/lib/" .. outputdir)
|
|
objdir ("bin/lib/int/" .. outputdir .. "/%{prj.name}")
|
|
|
|
files
|
|
{
|
|
"vendor/%{prj.name}/include/**.h",
|
|
"vendor/%{prj.name}/src/**.h",
|
|
"vendor/%{prj.name}/src/**.c"
|
|
}
|
|
|
|
DeclareMSVCOptions()
|
|
DeclareDebugOptions()
|
|
|
|
project "BigBaseV2"
|
|
location "BigBaseV2"
|
|
kind "SharedLib"
|
|
language "C++"
|
|
|
|
targetdir ("bin/" .. outputdir)
|
|
objdir ("bin/int/" .. outputdir .. "/%{prj.name}")
|
|
|
|
PrecompiledHeaderInclude = "common.hpp"
|
|
PrecompiledHeaderSource = "%{prj.name}/src/common.cpp"
|
|
|
|
files
|
|
{
|
|
"%{prj.name}/src/**.hpp",
|
|
"%{prj.name}/src/**.cpp",
|
|
"%{prj.name}/src/**.asm"
|
|
}
|
|
|
|
includedirs
|
|
{
|
|
"%{IncludeDir.fmtlib}",
|
|
"%{IncludeDir.json}",
|
|
"%{IncludeDir.MinHook}",
|
|
"%{IncludeDir.ImGui}",
|
|
"%{IncludeDir.ImGuiImpl}",
|
|
"%{IncludeDir.StackWalker}",
|
|
"%{prj.name}/src"
|
|
}
|
|
|
|
libdirs
|
|
{
|
|
"bin/lib"
|
|
}
|
|
|
|
links
|
|
{
|
|
"fmtlib",
|
|
"MinHook",
|
|
"ImGui",
|
|
"StackWalker"
|
|
}
|
|
|
|
pchheader "%{PrecompiledHeaderInclude}"
|
|
pchsource "%{PrecompiledHeaderSource}"
|
|
|
|
forceincludes
|
|
{
|
|
"%{PrecompiledHeaderInclude}"
|
|
}
|
|
|
|
DeclareMSVCOptions()
|
|
DeclareDebugOptions()
|
|
|
|
flags { "NoImportLib", "Maps" }
|
|
|
|
filter "configurations:Debug"
|
|
defines { "BIGBASEV2_DEBUG" }
|
|
|
|
filter "configurations:Release"
|
|
defines { "BIGBASEV2_RELEASE" }
|
|
optimize "speed"
|
|
filter "configurations:Dist"
|
|
flags { "LinkTimeOptimization", "FatalCompileWarnings" }
|
|
defines { "BIGBASEV2_DIST" }
|
|
optimize "speed"
|