Merge branch 'makefile'
This commit is contained in:
commit
51c1f319a0
13
Makefile
13
Makefile
@ -22,6 +22,7 @@ bins?= \
|
|||||||
81-deadlock
|
81-deadlock
|
||||||
|
|
||||||
bins_target=$(addprefix ${build_dir}/,${bins})
|
bins_target=$(addprefix ${build_dir}/,${bins})
|
||||||
|
install_bins_targets=$(addprefix ${install_dir}/bin/,${bins})
|
||||||
|
|
||||||
src_dirs=$(sort $(dir $(wildcard ${src_dir}/**/)))
|
src_dirs=$(sort $(dir $(wildcard ${src_dir}/**/)))
|
||||||
includes=$(patsubst %,-I%,${src_dirs})
|
includes=$(patsubst %,-I%,${src_dirs})
|
||||||
@ -35,8 +36,12 @@ objs+=$(patsubst %.c,${build_dir}/%.o,${srcs})
|
|||||||
all: build
|
all: build
|
||||||
|
|
||||||
.PHONY: install
|
.PHONY: install
|
||||||
install: build
|
install: build ${install_bins_targets}
|
||||||
true
|
|
||||||
|
.PHONY: ${install_bins_targets}
|
||||||
|
${install_bins_targets}: ${install_dir}/bin/%: ${build_dir}/%
|
||||||
|
@mkdir -p $(dir $@)
|
||||||
|
install $^ $@
|
||||||
|
|
||||||
.PHONY: graphs
|
.PHONY: graphs
|
||||||
graphs:
|
graphs:
|
||||||
@ -49,6 +54,10 @@ valgrind: build
|
|||||||
.PHONY: build
|
.PHONY: build
|
||||||
build: ${bins_target}
|
build: ${bins_target}
|
||||||
|
|
||||||
|
.PHONY: pthreads
|
||||||
|
pthreads:
|
||||||
|
true
|
||||||
|
|
||||||
.PHONY: check
|
.PHONY: check
|
||||||
check:
|
check:
|
||||||
true
|
true
|
||||||
|
Loading…
x
Reference in New Issue
Block a user