exec Command-line Arguments

http://ant.apache.org/manual/index.html

http://ant.apache.org/manual/using.html#arg

Command-line Arguments

Several tasks take arguments that will be passed to another process on the command line. To make it easier to specify arguments that contain space characters, nested arg elements can be used.

AttributeDescriptionRequired
valuea single command-line argument; can contain space characters.Exactly one of these.
fileThe name of a file as a single command-line argument; will be replaced with the absolute filename of the file.
pathA string that will be treated as a path-like string as a single command-line argument; you can use ; or : as path separators and Ant will convert it to the platform's local conventions.
pathrefReference to a path defined elsewhere. Ant will convert it to the platform's local conventions.
linea space-delimited list of command-line arguments.
prefixA fixed string to be placed in front of the argument. In the case of a line broken into parts, it will be placed in front of every part. Since Ant 1.8.No
suffixA fixed string to be placed immediately after the argument. In the case of a line broken into parts, it will be placed after every part. Since Ant 1.8.No

It is highly recommended to avoid the line version when possible. Ant will try to split the command line in a way similar to what a (Unix) shell would do, but may create something that is very different from what you expect under some circumstances.

Examples
  <arg value="-l -a"/>

is a single command-line argument containing a space character, not separate commands "-l" and "-a".

  <arg line="-l -a"/>

This is a command line with two separate arguments, "-l" and "-a".

  <arg path="/dir;/dir2:\dir3"/>

is a single command-line argument with the value \dir;\dir2;\dir3 on DOS-based systems and /dir:/dir2:/dir3 on Unix-like systems.

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
解读下列编译报错:[OHOS INFO] ERROR at //build/templates/cxx/cxx.gni:242:7: Script returned non-zero exit code. [OHOS INFO] exec_script(external_deps_script, arguments) [OHOS INFO] ^---------- [OHOS INFO] Current dir: /home/huangjianli/kh3.2/out/khdvk_rk3568_a/ [OHOS INFO] Command: /usr/bin/env /home/huangjianli/kh3.2/build/templates/common/external_deps_handler.py --external-deps eventhandler:libeventhandler ces_standard:cesfwk_innerkits hiviewdfx_hilog_native:libhilog --parts-src-flag-file build_configs/parts_src_flag.json --external-deps-temp-file gen/kaihong/communication/kh_iotsdk/src/bonding/kh_iotsdk__bondingtest_external_deps_temp.json --sdk-base-dir ../../sdk/ohos-arm --sdk-dir-name sdk/ohos-arm --current-toolchain //build/toolchain/ohos:ohos_clang_arm --innerkits-adapter-info-file ../../build/ohos/inner_kits_adapter.json [OHOS INFO] Returned 1 and printed out: [OHOS INFO] [OHOS INFO] file '../../sdk/ohos-arm/ces_standard/sdk_info.json' doesn't exist. [OHOS INFO] [OHOS INFO] stderr: [OHOS INFO] [OHOS INFO] Traceback (most recent call last): [OHOS INFO] File "/home/huangjianli/kh3.2/build/templates/common/external_deps_handler.py", line 248, in <module> [OHOS INFO] sys.exit(main()) [OHOS INFO] File "/home/huangjianli/kh3.2/build/templates/common/external_deps_handler.py", line 214, in main [OHOS INFO] sdk_module_info, adapted_ok = _get_external_module_from_sdk( [OHOS INFO] File "/home/huangjianli/kh3.2/build/templates/common/external_deps_handler.py", line 73, in _get_external_module_from_sdk [OHOS INFO] raise Exception("part '{}' doesn't exist in sdk modules.".format( [OHOS INFO] Exception: part 'ces_standard' doesn't exist in sdk modules. [OHOS INFO] [OHOS INFO] See //kaihong/communication/kh_iotsdk/src/bonding/BUILD.gn:16:1: whence it was called. [OHOS INFO] ohos_executable("bondingtest") { [OHOS INFO] ^------------------------------- [OHOS INFO] See //kaihong/communication/kh_iotsdk/BUILD.gn:123:7: which caused the file to be included. [OHOS INFO] "//kaihong/communication/kh_iotsdk/src/bonding:bondingtest", [OHOS INFO] ^----------------------------------------------------------
06-08
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值