linux try-run分析
来源:互联网 发布:网络销售彩票诈骗流程 编辑:程序博客网 时间:2024/05/02 20:50
文件scripts/Kbuild.include中:
TMPOUT := $(if $(KBUILD_EXTMOD),$(firstword $(KBUILD_EXTMOD))/)
try-run = $(shell set -e; \
TMP="$(TMPOUT).$$$$.tmp";\TMPO="$(TMPOUT).$$$$.o";\
TMPSU="$(TMPOUT).$$$$.su";\
if ($(1)) >/dev/null 2>&1;\
then echo "$(2)";\
else echo "$(3)";\
fi; \
rm -f "$$TMP" "$$TMPO" "$$TMPSU")
分析:
bash Conditional Constructs :
if test-commands; then
consequent-commands;
[elif more-test-commands; then
more-consequents;]
[else alternate-consequents;]
fi
If test-commands returns a non-zero
status, each elif list is executed in turn, and if its exit status is zero, the
corresponding more-consequents is executed and the command completes.
if ($(1)) >/dev/null 2>&1;中
test-commands 是 ($(1)) >/dev/null 2>&1,执行$(1)即第一个参数中的语句,标准输出和标准错误输出到/dev/null;
如果执行成功返回第二个参数,否则返回第三个参数。
0 0
- linux try-run分析
- Linux Makefile try-run
- Try disabling Instant Run
- Intsant run深度分析
- Linux学习35_ Linux ssh 无法登录:Permission denied, please try again 案例分析
- Linux first try
- try...catch...finally分析总结
- linux run level
- linux run java application
- Linux Run Levels
- Jar run in linux
- LINUX--run文件
- Linux的run-level:
- LINUX执行 .run文件
- linux-run command background
- 1182566 - Error: "RUN-050406 Bad system" when you try to run jobs on the server
- Application的run方法分析
- spring boot run启动分析
- CreateEvent WaitForSingleObject
- i2c-test tool summary
- 网络图片加载库 Fresco 的使用
- 基于ngx_lua的动态服务路由方案
- Java中遍历Map对象的4种方法
- linux try-run分析
- Fork/Join(3):ForkJoinPool之API翻译
- Request.Form.GetValues
- 命令行创建maven项目卡住的解决办法
- ITelephony.aidl 在android studio中的使用
- java字符校验
- 【软件测试】常规性能测试、压力测试、负载测试、可靠性测试
- 树莓派-更新源
- 树莓派换源(用的是阿里的源)亲测!!