The error codes aren't from make: make is reporting the return status of the command that failed. You need to look at the documentation of each command to know what each status value means. Most commands don't bother with distinctions other than 0 = success, anything else = failure.
In each of your examples, ./dpp
cannot be executed. When this happens, the shell that tried to invoke it exits with status code 126 (this is standard behavior). The instance of make that was running that shell detects a failed command (the shell) and exits, showing you Error 126
. That instance of make is itself a command executed by a parent instance of make, and the make
utility returns 2 on error, so the parent make reports Error 2
.
The failure of your build is likely to stem from test: too many arguments
. This could be a syntax error in the makefile, or it could be due to relying on bash-specific features when you have a /bin/sh
that isn't bash. Try running make SHELL=/bin/bash target
or make SHELL=/bin/ksh target
; if that doesn't work, you need to fix your makefile.
Problem:
You problem is that make
doesn't know about your targets.
You can run your above Makefile with make stackoverflow.markdown
for example and it will work.
make
only, however, will fail, since you only specified how to create your targets, but not which.
As leiaz point's out the above pattern rule is called an implicit rule.
Makefile:
SRC = $(wildcard *.html)
TAR = $(SRC:.html=.markdown)
.PHONY: all clean
all: $(TAR)
%.markdown: %.html
pandoc -o $< $@
clean:
rm -f $(TAR)
Explanation:
SRC
get's all source files (those ending in .html
) via Makefile's wildcard
.
TAR substitutes each source file listed in SRC
with a target ending with .markdown
instead of .html
.
.PHONY lists non-physical targets that are always out-of-date and are therefore always executed - these are often all
and clean
.
The target all
has as dependency (files listed on the right side of the :
) all *.markdown
files. This means all these targets are executed.
%.markdown: %.html
pandoc -o $< $@
This snippet says: Each target ending with .markdown
is depended on a file with the same name, except that the dependency is ending with .html
. The wildcard %
is to be seen as a *
like in shell. The %
on the right side, however, is compared to the match on the left side. Source.
Note that the whitespace sequence infront of pandoc
is a TAB, since make
defines that as a standard.
Finally, the phony clean
target depicts how to clean your system from the files you've created with this Makefile. In this case, it's deleting all targets (those files that were named *.markdown
.
Best Answer
You need libuuid-devel , this package provide libraries for compiling .
libuuid provide libraries fro running