31 lines
832 B
Lua
31 lines
832 B
Lua
add_rules("mode.debug", "mode.release")
|
|
set_languages("c++17")
|
|
|
|
if is_plat("windows") then
|
|
add_cxxflags("/source-charset:utf-8", {force = true})
|
|
end
|
|
if is_plat("mingw") then
|
|
add_cxxflags("-Wno-unused-variable -finput-charset=utf-8 -fexec-charset=gbk")
|
|
end
|
|
if is_mode("debug") then
|
|
set_suffixname("d")
|
|
end
|
|
target("lua_fs")
|
|
add_options("boost")
|
|
add_defines("FS_LIB_EXPORT")
|
|
set_kind("shared")
|
|
add_files("*.cxx")
|
|
add_deps("lua")
|
|
if is_plat("mingw") or is_plat("windows") then
|
|
set_filename("lua_fs.dll")
|
|
end
|
|
option("boost")
|
|
set_default(false)
|
|
set_showmenu(true)
|
|
boost_root_dir = os.getenv("BOOST_HEADER_DIR")
|
|
boost_lib_dir = os.getenv("BOOST_LIB_DIR")
|
|
boost_libs = os.getenv("BOOST_LIBS")
|
|
add_includedirs(boost_root_dir)
|
|
add_defines("USE_BOOST_FILESYSTEM")
|
|
add_linkdirs(boost_lib_dir)
|
|
add_links(boost_libs) |