New features
-
add to del_files() Interface to remove some files from the list of added files -
add to rule() , add_rules() The interface implements custom construction rules and improves add_files("src/*.md", {rule = "markdown"}) -
add to os.filesize() Interface -
add to core.ui.xxx And other cui component modules to realize the visual interface of the terminal for short interaction with users -
adopt xmake f --menu Realize visual menu interactive configuration and simplify project compilation and configuration -
add to set_values Interface to option -
Improved option to automatically generate visual configuration menu according to user-defined options in the project -
Add source file location information when calling api to set project configuration and in the configuration menu
improvement
-
Improve cross tool chain configuration, and support unknown compilation tool name configuration by specifying tool aliases to direct to known tool chains, such as: xmake f --cc= gcc@ccmips.exe -
#151 : improve the generation of dynamic libraries under mingw platform -
Improve the generation of makefile plug-ins -
Improved detection error prompt -
improvement add_cxflags Add the force parameter to disable automatic detection and mapping and force the setting of options such as flags api settings: add_cxflags("-DTEST", {force = true}) -
improvement add_files To set the flags of, add the force field, which is used to set the original flags without automatic detection and mapping: add_files("src/*.c", {force = {cxflags = "-DTEST"}}) -
Improve the search project root directory strategy -
Improve vs environment detection and support detection of vs environment under encrypted file system -
Upgrade luajit to the latest 2.1.0-beta3 -
Add support for linux/arm and arm64. You can run xmake on arm linux -
Improved vs201x project generation plug-in and better includedirs setting support
Bugs repair
-
Fix dependent modification compilation and linking issues -
#151 : Repair os.nuldev() There was a problem passing in gcc on mingw -
#150 : Repair the failure problem caused by the long obj list parameter of ar.exe package under Windows -
repair xmake f --cross Unable to configure the problem -
repair os.cd Root path to windows
Introduction to new features
newly added del_files
The interface implementation deletes the specified file from the source file list
target("test") add_files("src/*.c") del_files("src/test.c")
target("test") add_files("src/**.c") del_files("src/test*.c") del_files("src/subdir/*.c|xxx.c") if is_plat("iphoneos") then add_files("xxx.m") end
adopt rule()
The interface implements user-defined compilation rules
--Define the construction rules of a markdown file rule("markdown") set_extensions(".md", ".markdown") on_build(function (target, sourcefile) os.cp(sourcefile, path.join(target:targetdir(), path.basename(sourcefile) .. ".html")) end) target("test") set_kind("binary") --Make the test target support the construction rules of markdown files add_rules("markdown") --Add the construction of markdown file add_files("src/*.md") add_files("src/*.markdown")
target("test") -- ... add_files("src/test/*.md.in", {rule = "markdown"})
rule("man") add_imports("core.project.rule") on_build(function (target, sourcefile) rule.build("markdown", target, sourcefile) end)
rule("man") on_build_all(function (target, sourcefiles) -- build some source files for _, sourcefile in ipairs(sourcefiles) do -- ... end end) target("test") -- ... add_files("src/test/*.doc.in", {rule = "man"})
adopt xmake f --menu
Realize visual menu configuration
-- 'boolean' option option("test1") set_default(true) set_showmenu(true) set_category("root menu/test1") -- 'choice' option with values: "a", "b", "c" option("test2") set_default("a") set_values("a", "b", "c") set_showmenu(true) set_category("root menu/test2") -- 'string' option option("test3") set_default("xx") set_showmenu(true) set_category("root menu/test3/test3") -- 'number' option option("test4") set_default(6) set_showmenu(true) set_category("root menu/test4")
-
root menu -
test1 -
test2 -
test3 -
test3
-
-
test4
-
option("test") set_default("b") set_showmenu(true) set_values("a", "b", "c")