I would like to create a Makefile that also creates a simple script to run a compiled application.
I have something like the following:
@touch $(SCRIPT) @echo LD_LIBRARY_PATH=$(LIB_DIR) $(APP_DIR)/$(APP) $1 $2 $3 $4 $5 $6 > $(SCRIPT) @chmod +x $(SCRIPT) @echo Script successfully created.
And I want $ 1 $ 2 ... to appear in the script just like $ 1 $ 2 ... to represent script command line arguments. I can't get it to work because the Makefile uses $ 1 $ 2 as its own variables. How can i do this?
source share