I want to achieve the following syntax using a makefile:
make install program1
make install program2
Right now i have a simple makefile:
install:
#installing program1...
What is the cleanest way to achieve the syntax i want?
I want to achieve the following syntax using a makefile:
make install program1
make install program2
Right now i have a simple makefile:
install:
#installing program1...
What is the cleanest way to achieve the syntax i want?
You can have a variable called PROGRAM=... in your Makefile and your target install would look like :
install:
#installing $(PROGRAM)
Then you could call make like this :
make install PROGRAM=program1