C300DIR:=$(shell pwd|sed 's/\(.*\)\(c300\).*/\1\2/')
这句话可以把这字符串
/opt/only/com/c300/vap/VAPI/linux/gtlcsm
变成
/opt/only/com/c300
可以用echo $(pwd|sed 's/\(.*\)\(c300\).*/\1\2/') 来在shell里面测试结果
makefile里使用sed
最新推荐文章于 2018-07-08 13:03:53 发布
C300DIR:=$(shell pwd|sed 's/\(.*\)\(c300\).*/\1\2/')
这句话可以把这字符串
/opt/only/com/c300/vap/VAPI/linux/gtlcsm
变成
/opt/only/com/c300
可以用echo $(pwd|sed 's/\(.*\)\(c300\).*/\1\2/') 来在shell里面测试结果