Merge pull request #350 from nalind/buildtags
Use build tags for bin2img and copyimg
This commit is contained in:
commit
a6c0fcfa57
4 changed files with 9 additions and 8 deletions
10
Makefile
10
Makefile
|
@ -45,19 +45,19 @@ gofmt:
|
|||
@./hack/verify-gofmt.sh
|
||||
|
||||
conmon:
|
||||
make -C $@
|
||||
$(MAKE) -C $@
|
||||
|
||||
pause:
|
||||
make -C $@
|
||||
$(MAKE) -C $@
|
||||
|
||||
bin2img:
|
||||
make -C test/$@
|
||||
$(MAKE) -C test/$@ BUILDTAGS="$(BUILDTAGS)"
|
||||
|
||||
copyimg:
|
||||
make -C test/$@
|
||||
$(MAKE) -C test/$@ BUILDTAGS="$(BUILDTAGS)"
|
||||
|
||||
checkseccomp: check-gopath
|
||||
make -C test/$@
|
||||
$(MAKE) -C test/$@
|
||||
|
||||
ocid: check-gopath
|
||||
$(GO) install \
|
||||
|
|
|
@ -2,10 +2,11 @@
|
|||
tmpdir="$PWD/tmp.$RANDOM"
|
||||
mkdir -p "$tmpdir"
|
||||
trap 'rm -fr "$tmpdir"' EXIT
|
||||
cc -c -o "$tmpdir"/libdm_tag.o -x c - > /dev/null 2> /dev/null << EOF
|
||||
cc -o "$tmpdir"/libdm_tag -ldevmapper -x c - > /dev/null 2> /dev/null << EOF
|
||||
#include <libdevmapper.h>
|
||||
int main() {
|
||||
struct dm_task *task;
|
||||
dm_task_deferred_remove(task);
|
||||
return 0;
|
||||
}
|
||||
EOF
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
bin2img: $(wildcard *.go)
|
||||
go build -o $@
|
||||
go build -tags "$(BUILDTAGS)" -o $@
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
copyimg: $(wildcard *.go)
|
||||
go build -o $@
|
||||
go build -tags "$(BUILDTAGS)" -o $@
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
|
Loading…
Reference in a new issue