2023-08-27 07:01:15 +02:00
|
|
|
SRCDIR = src
|
2023-09-12 20:38:43 +02:00
|
|
|
SRCFILES = $(SRCDIR)/isinetaddr4.c $(SRCDIR)/iscidraddr4.c $(SRCDIR)/isinetaddr6.c
|
2023-08-27 07:01:15 +02:00
|
|
|
INCDIR = include
|
|
|
|
TESTDIR = test
|
2023-08-25 20:57:09 +02:00
|
|
|
|
|
|
|
CC = cc
|
2023-08-26 01:29:47 +02:00
|
|
|
CFLAGS = -fstack-protector-all -I$(INCDIR) -Wall -Wextra -pedantic
|
2023-08-25 20:57:09 +02:00
|
|
|
|
|
|
|
test:
|
2023-09-03 09:49:33 +02:00
|
|
|
@make test4
|
|
|
|
@make test6
|
|
|
|
|
|
|
|
test4:
|
2023-09-12 20:38:43 +02:00
|
|
|
@$(CC) $(CFLAGS) $(SRCFILES) $(TESTDIR)/isinetaddr4_test.c -o $(TESTDIR)/isinetaddr
|
2023-08-26 21:25:52 +02:00
|
|
|
@echo -n test/isinetaddr: ''
|
|
|
|
@$(TESTDIR)/isinetaddr
|
2023-09-12 20:38:43 +02:00
|
|
|
@$(CC) $(CFLAGS) $(SRCFILES) $(TESTDIR)/iscidraddr4_test.c -o $(TESTDIR)/iscidraddr
|
2023-08-26 21:25:52 +02:00
|
|
|
@echo -n test/iscidraddr: ''
|
2023-08-28 03:56:00 +02:00
|
|
|
@$(TESTDIR)/iscidraddr
|
2023-08-25 20:57:09 +02:00
|
|
|
|
2023-09-03 09:49:33 +02:00
|
|
|
test6:
|
|
|
|
@$(CC) $(CFLAGS) $(SRCFILES) $(TESTDIR)/isinetaddr6_test.c -o $(TESTDIR)/isinetaddr6
|
|
|
|
@echo -n test/isinetaddr6: ''
|
|
|
|
@$(TESTDIR)/isinetaddr6
|
|
|
|
|
2023-08-25 20:57:09 +02:00
|
|
|
.PHONY: test
|