问题
I have the following PHONY target in Makefile
install:
echo /usr/bin/shelldecrypt must be writable
cp shelldecrypt /usr/bin
When I run the target it displays the command it is executing
prompt> make install
OUTPUT IS
echo /usr/bin/shelldecrypt must be writable
/usr/bin/shelldecrypt must be writable
cp shelldecrypt /usr/bin
OUTPUT AS I WOULD LIKE IT
/usr/bin/shelldecrypt must be writable
cp shelldecrypt /usr/bin
回答1:
you could add "@" before your command to surpress that echo
install:
@echo /usr/bin/shelldecrypt must be writable
cp shelldecrypt /usr/bin
来源:https://stackoverflow.com/questions/867077/how-to-suppress-echos-in-makefile