新建Makefile文件
PROJECT_PATH=/root/shell hello: PROJECT_DIR=$(PROJECT_PATH) bash $(PROJECT_PATH)/hello.sh world: bash /root/shell/world.sh
hello.sh
#!/bin/bash echo "hello"
world.sh
#!/bin/bash echo "world"
执行make hello
输出hello
新建Makefile文件
PROJECT_PATH=/root/shell hello: PROJECT_DIR=$(PROJECT_PATH) bash $(PROJECT_PATH)/hello.sh world: bash /root/shell/world.sh
hello.sh
#!/bin/bash echo "hello"
world.sh
#!/bin/bash echo "world"
执行make hello
输出hello
本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。