53 ../common/manifest_hash.po
54
55 include ../../Makefile.cmd
56 include ../../Makefile.ctf
57
58 POFILE = $(PROG)_all.po
59
60 NATIVE_BUILD=$(POUND_SIGN)
61 $(NATIVE_BUILD)NOT_NATIVE=$(POUND_SIGN)
62
63 $(NATIVE_BUILD)PROG = $(MYPROG:%=%-native)
64 $(NATIVE_BUILD)OBJS = $(MYOBJS:%.o=%-native.o)
65
66 # svccfg has a name clash with main() and libl.so.1. However, svccfg must
67 # still export a number of "yy*" (libl) interfaces. Reduce all other symbols
68 # to local scope.
69 MAPFILES += $(MAPFILE.LEX) $(MAPFILE.NGB)
70 MAPOPTS = $(MAPFILES:%=-M%)
71
72 MYCPPFLAGS = -I ../common -I$(ADJUNCT_PROTO)/usr/include/libxml2
73 CPPFLAGS += $(MYCPPFLAGS)
74 LDFLAGS += $(MAPOPTS)
75
76 CERRWARN += -_gcc=-Wno-unused-label
77 CERRWARN += -_gcc=-Wno-implicit-function-declaration
78 CERRWARN += -_gcc=-Wno-switch
79 CERRWARN += -_gcc=-Wno-uninitialized
80 CERRWARN += -_gcc=-Wno-unused-variable
81 CERRWARN += -_gcc=-Wno-parentheses
82
83 LFLAGS = -t
84 YFLAGS = -d
85
86 CLOBBERFILES += svccfg_lex.c svccfg_grammar.c svccfg_grammar.h \
87 $(MYPROG:%=%-native)
88
89 SVCCFG_EXTRA_LIBS = -lxml2 -lscf -ll -luutil -lumem -lmd5 -lnvpair
90 $(NOT_NATIVE)SVCCFG_EXTRA_LIBS += -ltecla
91
92 LIBSCF = $(SRC)/lib/libscf
96 debug := COPTFLAG = -g
97
98 lint := LINTFLAGS = -mux
99 lint := SVCCFG_EXTRA_LIBS = -lscf -ll -luutil -lumem -lmd5 -lnvpair
100
101 LDLIBS += $(SVCCFG_EXTRA_LIBS)
102
103 $(NATIVE_BUILD)CC = $(NATIVECC)
104 $(NATIVE_BUILD)LD = $(NATIVELD)
105 $(NATIVE_BUILD)CFLAGS = $(NATIVE_CFLAGS)
106 $(NATIVE_BUILD)CPPFLAGS = \
107 -DNATIVE_BUILD \
108 $(MYCPPFLAGS) \
109 -I$(LIBSCF)/inc \
110 -I$(LIBTECLA) \
111 -I$(LIBUUTIL)/common
112 $(NATIVE_BUILD)LDFLAGS =
113 $(NATIVE_BUILD)LDLIBS = \
114 -L$(LIBUUTIL)/native -R $(LIBUUTIL)/native \
115 -L$(LIBSCF)/native -R $(LIBSCF)/native \
116 -L$(ADJUNCT_PROTO)/usr/lib -R$(ADJUNCT_PROTO)/usr/lib \
117 $(SVCCFG_EXTRA_LIBS)
118
119 svccfg_lex.o svccfg_grammar.o := CCVERBOSE =
120
121 svccfg_help.po := XGETFLAGS = -a
122
123 .KEEP_STATE:
124 .PARALLEL: $(OBJS) $(LNTS)
125
126 all debug: $(PROG)
127
128 native: FRC
129 @cd $(LIBUUTIL)/native; pwd; $(MAKE) $(MFLAGS) install
130 @cd $(LIBSCF)/native; pwd; $(MAKE) $(MFLAGS) install
131 @NATIVE_BUILD= $(MAKE) $(MFLAGS) all
132
133 $(PROG): $(OBJS) $(MAPFILES)
134 $(LINK.c) -o $@ $(OBJS) $(LDLIBS)
135 $(POST_PROCESS)
136
|
53 ../common/manifest_hash.po
54
55 include ../../Makefile.cmd
56 include ../../Makefile.ctf
57
58 POFILE = $(PROG)_all.po
59
60 NATIVE_BUILD=$(POUND_SIGN)
61 $(NATIVE_BUILD)NOT_NATIVE=$(POUND_SIGN)
62
63 $(NATIVE_BUILD)PROG = $(MYPROG:%=%-native)
64 $(NATIVE_BUILD)OBJS = $(MYOBJS:%.o=%-native.o)
65
66 # svccfg has a name clash with main() and libl.so.1. However, svccfg must
67 # still export a number of "yy*" (libl) interfaces. Reduce all other symbols
68 # to local scope.
69 MAPFILES += $(MAPFILE.LEX) $(MAPFILE.NGB)
70 MAPOPTS = $(MAPFILES:%=-M%)
71
72 MYCPPFLAGS = -I ../common -I$(ADJUNCT_PROTO)/usr/include/libxml2
73 $(NATIVE_BUILD)MYCPPFLAGS = -I ../common \
74 -I$(NATIVE_ADJUNCT)/usr/include/libxml2
75 CPPFLAGS += $(MYCPPFLAGS)
76 LDFLAGS += $(MAPOPTS)
77
78 CERRWARN += -_gcc=-Wno-unused-label
79 CERRWARN += -_gcc=-Wno-implicit-function-declaration
80 CERRWARN += -_gcc=-Wno-switch
81 CERRWARN += -_gcc=-Wno-uninitialized
82 CERRWARN += -_gcc=-Wno-unused-variable
83 CERRWARN += -_gcc=-Wno-parentheses
84
85 LFLAGS = -t
86 YFLAGS = -d
87
88 CLOBBERFILES += svccfg_lex.c svccfg_grammar.c svccfg_grammar.h \
89 $(MYPROG:%=%-native)
90
91 SVCCFG_EXTRA_LIBS = -lxml2 -lscf -ll -luutil -lumem -lmd5 -lnvpair
92 $(NOT_NATIVE)SVCCFG_EXTRA_LIBS += -ltecla
93
94 LIBSCF = $(SRC)/lib/libscf
98 debug := COPTFLAG = -g
99
100 lint := LINTFLAGS = -mux
101 lint := SVCCFG_EXTRA_LIBS = -lscf -ll -luutil -lumem -lmd5 -lnvpair
102
103 LDLIBS += $(SVCCFG_EXTRA_LIBS)
104
105 $(NATIVE_BUILD)CC = $(NATIVECC)
106 $(NATIVE_BUILD)LD = $(NATIVELD)
107 $(NATIVE_BUILD)CFLAGS = $(NATIVE_CFLAGS)
108 $(NATIVE_BUILD)CPPFLAGS = \
109 -DNATIVE_BUILD \
110 $(MYCPPFLAGS) \
111 -I$(LIBSCF)/inc \
112 -I$(LIBTECLA) \
113 -I$(LIBUUTIL)/common
114 $(NATIVE_BUILD)LDFLAGS =
115 $(NATIVE_BUILD)LDLIBS = \
116 -L$(LIBUUTIL)/native -R $(LIBUUTIL)/native \
117 -L$(LIBSCF)/native -R $(LIBSCF)/native \
118 -L$(NATIVE_ADJUNCT)/usr/lib -R$(NATIVE_ADJUNCT)/usr/lib \
119 $(SVCCFG_EXTRA_LIBS)
120
121 svccfg_lex.o svccfg_grammar.o := CCVERBOSE =
122
123 svccfg_help.po := XGETFLAGS = -a
124
125 .KEEP_STATE:
126 .PARALLEL: $(OBJS) $(LNTS)
127
128 all debug: $(PROG)
129
130 native: FRC
131 @cd $(LIBUUTIL)/native; pwd; $(MAKE) $(MFLAGS) install
132 @cd $(LIBSCF)/native; pwd; $(MAKE) $(MFLAGS) install
133 @NATIVE_BUILD= $(MAKE) $(MFLAGS) all
134
135 $(PROG): $(OBJS) $(MAPFILES)
136 $(LINK.c) -o $@ $(OBJS) $(LDLIBS)
137 $(POST_PROCESS)
138
|