mirror of
https://github.com/linuxkit/linuxkit.git
synced 2026-01-17 14:57:53 +00:00
Linux xargs calls the command with no arguments if it gets no inputs, which `docker rmi` complains about. It provides -r / --no-run-if-empty to prevent this but unfortunately this isn't supported on OSX. Ignore errors from `docker rmi` so that `make clean` will keep going and clean up later stuff. Signed-off-by: Ian Campbell <ian.campbell@docker.com>
16 lines
319 B
Makefile
16 lines
319 B
Makefile
.PHONY: all
|
|
|
|
DEPS=nc-vsock.c
|
|
|
|
all: Dockerfile $(DEPS)
|
|
docker build -t nc-vsock:build .
|
|
docker run --rm nc-vsock:build cat nc-vsock > nc-vsock
|
|
chmod 755 nc-vsock
|
|
|
|
nc-vsock: $(DEPS)
|
|
gcc -Wall -Werror -o nc-vsock nc-vsock.c -luuid
|
|
|
|
clean:
|
|
rm -f nc-vsock
|
|
docker images -q nc-vsock:build | xargs docker rmi -f || true
|