iw4x-client/premake/bitmrc.lua

63 lines
1.3 KiB
Lua
Raw Normal View History

2016-08-25 12:17:47 -04:00
bitmrc = {
settings = nil,
}
function bitmrc.setup(settings)
if not settings.source then error("Missing source.") end
bitmrc.settings = settings
end
function bitmrc.import()
if not bitmrc.settings then error("Run bitmrc.setup first") end
sqlite3.links()
libcryptopp.links()
bitmrc.links()
2016-08-25 12:17:47 -04:00
bitmrc.includes()
end
function bitmrc.links()
links { "bitmrc" }
end
2016-08-25 12:17:47 -04:00
function bitmrc.includes()
if not bitmrc.settings then error("Run bitmrc.setup first") end
includedirs { path.join(bitmrc.settings.source, "BitMRC/include") }
end
function bitmrc.project()
if not bitmrc.settings then error("Run bitmrc.setup first") end
project "bitmrc"
language "C++"
includedirs
{
2016-08-25 12:38:45 -04:00
path.join(bitmrc.settings.source, "BitMRC/include"),
path.join(bitmrc.settings.source, "BitMRC/Storage/include"),
2016-08-25 12:17:47 -04:00
}
files
{
path.join(bitmrc.settings.source, "BitMRC/*.cpp"),
path.join(bitmrc.settings.source, "BitMRC/Storage/*.cpp"),
2016-08-25 12:17:47 -04:00
}
removefiles
{
-- path.join(bitmrc.settings.source, "src/**/*test.cc"),
path.join(bitmrc.settings.source, "BitMRC/main.*"),
path.join(bitmrc.settings.source, "BitMRC/class.*"),
2016-08-25 12:38:45 -04:00
path.join(bitmrc.settings.source, "BitMRC/tests/**"),
2016-08-25 12:17:47 -04:00
}
-- dependencies
sqlite3.import()
2016-08-25 12:17:47 -04:00
libcryptopp.import()
defines { "_SCL_SECURE_NO_WARNINGS" }
warnings "Off"
kind "StaticLib"
end