diff --git a/Makefile b/Makefile index 59cb86b..b28f680 100644 --- a/Makefile +++ b/Makefile @@ -12,7 +12,7 @@ shell_lib.a: $(objects) test: build - ./client www.google.com + ./client clean: rm client diff --git a/Makefile.musl b/Makefile.musl new file mode 100644 index 0000000..b575d7e --- /dev/null +++ b/Makefile.musl @@ -0,0 +1,20 @@ +CC = musl-gcc +CFLAGS = -g -Wall -static + +objects = client.o dns_c.h socket_utils.o constructor.o c_utils.o parser.o + + +build: shell_lib.a + $(CC) $(CFLAGS) -o client client.c dns_client.a + +shell_lib.a: $(objects) + ar -r dns_client.a $(objects) + + +test: build + ./client + +clean: + rm client + rm -f *.o + rm -f dns_client.a