dmake: do not set MAKEFLAGS=k
[unleashed/tickless.git] / usr / src / cmd / cmd-inet / usr.sbin / in.routed / Makefile
blob0646a5fd2c47f966a8c4403dcd89ae913b0e30d6
3 # Copyright 2009 Sun Microsystems, Inc. All rights reserved.
4 # Use is subject to license terms.
7 ROUTEDPROG= in.routed
8 ROUTEDOBJS= common.o if.o input.o main.o output.o parms.o radix.o \
9 rdisc.o table.o trace.o
10 ROUTEDSRCS= $(ROUTEDOBJS:.o=.c)
11 RTQUERYPROG= rtquery
12 RTQUERYOBJS= common.o rtquery.o
13 RTQUERYSRCS= $(RTQUERYOBJS:.o=.c)
14 POFILEOBJS= $(ROUTEDOBJS) $(RTQUERYOBJS)
16 PROG= $(ROUTEDPROG) $(RTQUERYPROG)
17 SRCS= $(ROUTEDSRCS) $(RTQUERYSRCS)
19 MANIFEST= route.xml
21 include ../../../Makefile.cmd
23 ROOTMANIFESTDIR= $(ROOTSVCNETWORKROUTING)
26 # in.routed uses ancillary data features available through
27 # the Open Group's Networking Services standard. The following
28 # pre-processor definitions enable these features.
30 _D_XOPEN_EXTN = -D_XOPEN_SOURCE=500 -D__EXTENSIONS__
32 CPPFLAGS += $(_D_XOPEN_EXTN)
33 CERRWARN += -Wno-parentheses
34 CERRWARN += -Wno-uninitialized
35 LDLIBS += -lmd
36 CLEAN_FILES += $(ROUTEDOBJS) $(RTQUERYOBJS)
37 CLOBBERFILES += $(ROUTEDPROG) $(RTQUERYPROG)
39 # Message catalog
41 POFILE= in.routed.po
42 POFILES= $(POFILEOBJS:.o=.po)
44 $(ROUTEDPROG):= LDLIBS += -lkstat
46 # This needs to be done because of SPARC/x86 differences. On x86,
47 # double has required alignment of only 4 bytes, but on SPARC it's 8
48 # bytes. This means that sockaddr_in can be casted to
49 # sockaddr_storage without complaint on x86, but requires a
50 # suppression directive on SPARC.
52 CTFCONVERT_HOOK = && $(CTFCONVERT_O)
53 CTFMERGE_HOOK = && $(CTFMERGE) -L VERSION -o $@ $(ROUTEDOBJS)
54 $(ROUTEDOBJS) := CFLAGS += $(CTF_FLAGS)
55 $(RTQUERYOBJS) := CFLAGS += $(CTF_FLAGS)
57 .KEEP_STATE:
59 .PARALLEL: $(ROUTEDPROG) $(RTQUERYOBJS)
61 all: $(PROG)
63 $(POFILE): $(POFILES)
64 $(RM) $@
65 cat $(POFILES) > $@
67 $(ROUTEDPROG): $(ROUTEDOBJS)
68 $(LINK.c) -o $@ $(ROUTEDOBJS) $(LDLIBS) $(CTFMERGE_HOOK)
69 $(POST_PROCESS)
71 $(RTQUERYPROG): $(RTQUERYOBJS)
72 $(LINK.c) -o $@ $(RTQUERYOBJS) $(LDLIBS) -lresolv $(CTFMERGE_HOOK)
73 $(POST_PROCESS)
75 install: all $(ROOTUSRSBINPROG) $(ROOTMANIFEST)
77 check: $(CHKMANIFEST)
79 clean:
80 $(RM) $(CLEAN_FILES)
82 include ../../../Makefile.targ