What does @: (at symbol colon) mean in a Makefile?
What does the following do in a Makefile? rule: $(deps) @: I can’t seem to find this in the make manual. 2 Answers 2
What does the following do in a Makefile? rule: $(deps) @: I can’t seem to find this in the make manual. 2 Answers 2
I have the following makefile for my project, and I’d like to configure it for release and debug builds. In my code, I have lots of #ifdef DEBUG macros in place, so it’s simply a matter of setting this macro and adding the -g3 -gdwarf2 flags to the compilers. How can I do this? $(CC) … Read more
In the GNU Makefile manual, it mentions these prefixes. If .ONESHELL is provided, then only the first line of the recipe will be checked for the special prefix characters (‘@’, ‘-’, and ‘+’). What do these prefixes do, and where are they mentioned? 2 Answers 2
I’m following the instructions of someone whose repository I cloned to my machine. I want to use the make command as part of setting up the code environment, but I’m using Windows. I searched online, but I could only find a make.exe file, a make-4.1.tar.gz file (I don’t know what to do with it next) … Read more
In my GNUmakefile, I would like to have a rule that uses a temporary directory. For example: out.tar: TMP := $(shell mktemp -d) echo hi $(TMP)/hi.txt tar -C $(TMP) cf $@ . rm -rf $(TMP) As written, the above rule creates the temporary directory at the time that the rule is parsed. This means that, … Read more
I have a several Makefiles in app specific directories like this: /project1/apps/app_typeA/Makefile /project1/apps/app_typeB/Makefile /project1/apps/app_typeC/Makefile Each Makefile includes a .inc file in this path one level up: /project1/apps/app_rules.inc Inside app_rules.inc I’m setting the destination of where I want the binaries to be placed when built. I want all binaries to be in their respective app_type path: … Read more
I’ve used rake a bit (a Ruby make program), and it has an option to get a list of all the available targets, eg > rake –tasks rake db:charset # retrieve the charset for your data… rake db:collation # retrieve the collation for your da… rake db:create # Creates the databases defined in y… rake … Read more
In my makefile, I have a variable ‘NDK_PROJECT_PATH’, my question is how can I print it out when it compiles? I read Make file echo displaying “$PATH” string and I tried: @echo $(NDK_PROJECT_PATH) @echo $(value NDK_PROJECT_PATH) Both gives me “build-local.mk:102: *** missing separator. Stop.” Any one knows why it is not working for me? 15 … Read more
I use CMake with GNU Make and would like to see all commands exactly (for example how the compiler is executed, all the flags etc.). GNU make has –debug, but it does not seem to be that helpful are there any other options? Does CMake provide additional flags in the generated Makefile for debugging purpose? … Read more
For example, I have something like this in my makefile: all: cd some_directory But when I typed make I saw only ‘cd some_directory’, like in the echo command. 7 Answers 7