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
|
|
|
|
|
|
|
|
bitmrc.includes()
|
|
|
|
end
|
|
|
|
|
|
|
|
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"),
|
2016-08-25 12:17:47 -04:00
|
|
|
}
|
|
|
|
files
|
|
|
|
{
|
2016-08-25 12:38:45 -04:00
|
|
|
path.join(bitmrc.settings.source, "BitMRC/**.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.cpp"),
|
2016-08-25 12:38:45 -04:00
|
|
|
path.join(bitmrc.settings.source, "BitMRC/tests/**"),
|
2016-08-25 12:45:00 -04:00
|
|
|
path.join(bitmrc.settings.source, "BitMRC/Storage/**"),
|
|
|
|
path.join(bitmrc.settings.source, "BitMRC/Debug/**"),
|
2016-08-25 12:17:47 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
-- dependencies
|
|
|
|
libcryptopp.import()
|
|
|
|
|
|
|
|
-- not our code, ignore POSIX usage warnings for now
|
|
|
|
defines { "_SCL_SECURE_NO_WARNINGS" }
|
|
|
|
warnings "Off"
|
|
|
|
|
|
|
|
-- always build as static lib, as we include our custom classes and therefore can't perform shared linking
|
|
|
|
kind "StaticLib"
|
|
|
|
end
|