New features
- #83: Add
add_csnippet
andadd_cxxsnippet
intooption
for detecting some compiler features. - #83: Add user extension modules to detect program, libraries and files.
- Add
find_program
,find_file
,find_library
,find_tool
andfind_package
module interfaces. - Add
net.*
anddevel.*
extension modules - Add
val()
api to get the value of builtin-variable, .e.gval("host")
,val("env PATH")
,val("shell echo hello")
andval("reg HKEY_LOCAL_MACHINE\\XX;Value")
- Support to compile the microsoft resource file (.rc)
- Add
has_flags
,features
andhas_features
for detect module interfaces. - Add
option.on_check
,option.after_check
andoption.before_check
api - Add
target.on_load
api - #132: Add
add_frameworkdirs
api - Add
lib.detect.has_xxx
andlib.detect.find_xxx
apis. - Add
add_moduledirs
api - Add
includes
api instead ofadd_subdirs
andadd_subfiles
- #133: Improve the project plugin to generate
compile_commands.json
by runxmake project -k compile_commands
- Add
set_pcheader
andset_pcxxheader
to support the precompiled header, support gcc, clang, msvc - Add
xmake f -p cross
platform and support the custom platform
Changes
- #87: Add includes and links from target deps automatically
- Improve
import
to load user extension and global modules - #93: Improve
xmake lua
to run a single line command - Improve to print gcc error and warning info
- Improve
print
interface to dump table - #111: Add
--root
common option to allow run xmake command as root - #113: Privilege manage when running as root, store the root privilege and degrade.
- Improve
xxx_script
inxmake.lua
to support pattern match, .e.gon_build("iphoneos|arm*", function (target) end)
- improve builtin-variables to support to get the value envirnoment and registry
- Improve to detect vstudio sdk and cross toolchains envirnoment
- #71: Improve to detect compiler and linker from env vars
- Improve the option detection (cache and multi-jobs) and increase 70% speed
- #129: Check link deps and cache the target file
- Support
*.asm
source files for vs201x project plugin - Mark
add_bindings
andadd_rbi�ndings
as deprecated - Optimize
xmake rebuild
speed on windows - Move
core.project.task
tocore.base.task
- Move
echo
andapp2ipa
plugins to xmake-plugins repo. - Add new api
set_config_header("config.h", {prefix = ""})
instead ofset_config_h
andset_config_h_prefix
Bugs fixed
- Fix
try-catch-finally
- Fix interpreter bug when parsing multi-level subdirs
- #115: Fix the path problem of the install script
get.sh
- Fix cache bug for import()
新特性
- #83: 添加
add_csnippet
,add_cxxsnippet
到option
来检测一些编译器特性 - #83: 添加用户扩展模块去探测程序,库文件以及其他主机环境
- 添加
find_program
,find_file
,find_library
,find_tool
和find_package
等模块接口 - 添加
net.*
和devel.*
扩展模块 - 添加
val()
接口去获取内置变量,例如:val("host")
,val("env PATH")
,val("shell echo hello")
andval("reg HKEY_LOCAL_MACHINE\\XX;Value")
- 增加对微软.rc资源文件的编译支持,当在windows上编译时,可以增加资源文件了
- 增加
has_flags
,features
和has_features
等探测模块接口 - 添加
option.on_check
,option.after_check
和option.before_check
接口 - 添加
target.on_load
接口 - #132: 添加
add_frameworkdirs
接口 - 添加
lib.detect.has_xxx
和lib.detect.find_xxx
接口 - 添加
add_moduledirs
接口在工程中定义和加载扩展模块 - 添加
includes
接口替换add_subdirs
和add_subfiles
- #133: 改进工程插件,通过运行
xmake project -k compile_commands
来导出compile_commands.json
- 添加
set_pcheader
和set_pcxxheader
去支持跨编译器预编译头文件,支持gcc
,clang
和msvc
- 添加
xmake f -p cross
平台用于交叉编译,并且支持自定义平台名
改进
- #87: 为依赖库目标自动添加:
includes
和links
- 改进
import
接口,去加载用户扩展模块 - #93: 改进
xmake lua
,支持运行单行命令和模块 - 改进编译错误提示信息输出
- 改进
print
接口去更好些显示table数据 - #111: 添加
--root
通用选项去临时支持作为root运行 - #113: 改进权限管理,现在作为root运行也是非常安全的
- 改进
xxx_script
工程描述api,支持多平台模式选择, 例如:on_build("iphoneos|arm*", function (target) end)
- 改进内置变量,支持环境变量和注册表数据的获取
- 改进vstudio环境和交叉工具链的探测
- #71: 改进从环境变量中探测链接器和编译器
- 改进option选项检测,通过多任务检测,提升70%的检测速度
- #129: 检测链接依赖,如果源文件没有改变,就不必重新链接目标文件了
- 在vs201x工程插件中增加对
*.asm
文件的支持 - 标记
add_bindings
和add_rbindings
为废弃接口 - 优化
xmake rebuild
在windows上的构建速度 - 将
core.project.task
模块迁移至core.base.task
- 将
echo
和app2ipa
插件迁移到 xmake-plugins 仓库 - 添加
set_config_header("config.h", {prefix = ""})
代替set_config_h
和set_config_h_prefix
Bugs修复
- 修复
try-catch-finally
- 修复解释器bug,解决当加载多级子目录时,根域属性设置不对
- #115: 修复安装脚本
get.sh
的路径问题 - 修复
import()
导入接口的缓存问题