| # |
| # $Id$ |
| # |
| |
| BINDEST=/usr/sbin |
| SBINDEST=/sbin |
| MANDIR=/usr/share/man |
| |
| OBJS=ipsend.o ip.o ipsopt.o iplang_y.o iplang_l.o |
| IPFTO=ipft_ef.o ipft_hx.o ipft_pc.o ipft_sn.o ipft_td.o ipft_tx.o |
| ROBJS=ipresend.o ip.o resend.o |
| TOBJS=iptest.o iptests.o ip.o |
| UNIXOBJS=sbpf.o sock.o 44arp.o |
| OBJ=. |
| LIBS=-L$(OBJ) -lipf |
| |
| CC=gcc -Wuninitialized -Wstrict-prototypes -O |
| CFLAGS=-g -I$(TOP) |
| # |
| MFLAGS="BINDEST=$(BINDEST)" "SBINDEST=$(SBINDEST)" "MANDIR=$(MANDIR)" \ |
| 'CFLAGS=$(CFLAGS) $(SOLARIS2)' "IPFLKM=$(IPFLKM)" \ |
| "IPFLOG=$(IPFLOG)" "LOGFAC=$(LOGFAC)" "POLICY=$(POLICY)" \ |
| "SOLARIS2=$(SOLARIS2)" "DEBUG=$(DEBUG)" "DCPU=$(CPU)" \ |
| "CPUDIR=$(CPUDIR)" "LOOKUP=$(LOOKUP)" |
| # |
| build: |
| all bsd-bpf : ipsend ipresend iptest |
| |
| iplang_y.o: $(TOP)/iplang/iplang_y.y |
| (cd $(TOP)/iplang; $(MAKE) ../BSD/$(CPUDIR)/$@ $(MFLAGS) 'DESTDIR=../BSD/$(CPUDIR)' ) |
| |
| iplang_l.o: $(TOP)/iplang/iplang_l.l |
| (cd $(TOP)/iplang; $(MAKE) ../BSD/$(CPUDIR)/$@ $(MFLAGS) 'DESTDIR=../BSD/$(CPUDIR)' ) |
| |
| .c.o: |
| $(CC) $(DEBUG) $(CFLAGS) -c $< -o $@ |
| |
| ipsend: $(OBJS) $(UNIXOBJS) |
| $(CC) $(DEBUG) $(OBJS) $(UNIXOBJS) -o $@ $(LIBS) -ll |
| |
| ipresend: $(ROBJS) $(UNIXOBJS) |
| $(CC) $(DEBUG) $(ROBJS) $(UNIXOBJS) -o $@ $(LIBS) |
| |
| iptest: $(TOBJS) $(UNIXOBJS) |
| $(CC) $(DEBUG) $(TOBJS) $(UNIXOBJS) -o $@ $(LIBS) |
| |
| clean: |
| rm -rf *.o core a.out ipsend ipresend iptest iplang_y.* iplang_l.* |
| |
| ipsend.o: $(TOP)/ipsend/ipsend.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/ipsend.c -o $@ |
| |
| ipsopt.o: $(TOP)/ipsend/ipsopt.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/ipsopt.c -o $@ |
| |
| ipresend.o: $(TOP)/ipsend/ipresend.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/ipresend.c -o $@ |
| |
| ip.o: $(TOP)/ipsend/ip.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/ip.c -o $@ |
| |
| resend.o: $(TOP)/ipsend/resend.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/resend.c -o $@ |
| |
| ipft_sn.o: $(TOP)/ipft_sn.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipft_sn.c -o $@ |
| |
| ipft_pc.o: $(TOP)/ipft_pc.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipft_pc.c -o $@ |
| |
| iptest.o: $(TOP)/ipsend/iptest.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/iptest.c -o $@ |
| |
| iptests.o: $(TOP)/ipsend/iptests.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/iptests.c -o $@ |
| |
| sbpf.o: $(TOP)/ipsend/sbpf.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/sbpf.c -o $@ |
| |
| snit.o: $(TOP)/ipsend/snit.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/snit.c -o $@ |
| |
| sock.o: $(TOP)/ipsend/sock.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/sock.c -o $@ |
| |
| arp.o: $(TOP)/ipsend/arp.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/arp.c -o $@ |
| |
| 44arp.o: $(TOP)/ipsend/44arp.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/44arp.c -o $@ |
| |
| lsock.o: $(TOP)/ipsend/lsock.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/lsock.c -o $@ |
| |
| slinux.o: $(TOP)/ipsend/slinux.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/slinux.c -o $@ |
| |
| larp.o: $(TOP)/ipsend/larp.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/larp.c -o $@ |
| |
| dlcommon.o: $(TOP)/ipsend/dlcommon.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/dlcommon.c -o $@ |
| |
| sdlpi.o: $(TOP)/ipsend/sdlpi.c |
| $(CC) $(DEBUG) $(CFLAGS) -c $(TOP)/ipsend/sdlpi.c -o $@ |
| |
| install: |
| -$(INSTALL) -cs -g wheel -m 755 -o root ipsend ipresend iptest $(BINDEST) |
| |