4 # The contents of this file are subject to the terms of the
5 # Common Development and Distribution License (the "License").
6 # You may not use this file except in compliance with the License.
8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 # or http://www.opensolaris.org/os/licensing.
10 # See the License for the specific language governing permissions
11 # and limitations under the License.
13 # When distributing Covered Code, include this CDDL HEADER in each
14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 # If applicable, add the following below this CDDL HEADER, with the
16 # fields enclosed by brackets "[]" replaced with your own identifying
17 # information: Portions Copyright [yyyy] [name of copyright owner]
22 # Copyright (c) 2001, 2010, Oracle and/or its affiliates. All rights reserved.
26 TESTS
= conftest globtest kwtest luttest optstest
27 OBJS
= conf.o err.o fn.o glob.o kw.o lut.o main.o opts.o
28 TESTOBJS
= $(TESTS
:%=%.o
)
30 POFILES
= $(OBJS
:%.o
=%.po
)
31 CONFIGFILE
= logadm.conf
33 include ..
/Makefile.cmd
35 CPPFLAGS
+= -D_FILE_OFFSET_BITS
=64
36 CERRWARN
+= -_gcc
=-Wno-parentheses
37 CERRWARN
+= -_gcc
=-Wno-clobbered
38 CERRWARN
+= -_gcc
=-Wno-uninitialized
39 XGETFLAGS
+= -a
-x logadm.xcl
41 $(ROOTETC
)/$(CONFIGFILE
):= FILEMODE
= 644
43 CLOBBERFILES
+= $(TESTS
)
45 LOGADMDIR
= $(ROOT
)/etc
/logadm.d
47 MFSTFILES
= logadm-upgrade.xml
48 MANIFESTDIR
= $(ROOT
)/lib
/svc
/manifest
/system
49 MANIFEST
= $(MFSTFILES
:%=$(MANIFESTDIR
)/%)
50 $(MANIFEST
) := FILEMODE
= 0444
52 METHODFILES
= logadm-upgrade
53 METHODDIR
= $(ROOT
)/lib
/svc
/method
54 METHOD
= $(METHODFILES
:%=$(METHODDIR
)/%)
55 $(METHOD
) := FILEMODE
= 0555
61 test: $(TESTS
) $(PROG
)
62 $(PERL
) -w .
/tester
`pwd`
65 $(LINK.c
) -o
$@
$(OBJS
) $(LDLIBS
)
68 install: all $(ROOTUSRSBINPROG
) $(ROOTETC
)/$(CONFIGFILE
) $(LOGADMDIR
) \
69 $(MANIFESTDIR
) $(MANIFEST
) $(METHODDIR
) $(METHOD
)
91 $(RM
) $(OBJS
) $(TESTOBJS
)
95 include ..
/Makefile.targ
98 # dependencies for various test programs built from same source
101 $(COMPILE.c
) -DTESTMODULE
-o
$@
$<
104 conftest
: conftest.o err.o fn.o lut.o opts.o
105 $(LINK.c
) -o conftest conftest.o err.o fn.o lut.o opts.o
$(LDLIBS
)
108 globtest
: globtest.o lut.o err.o fn.o
109 $(LINK.c
) -o globtest globtest.o lut.o err.o fn.o
$(LDLIBS
)
112 kwtest
: kwtest.o err.o fn.o lut.o
113 $(LINK.c
) -o kwtest kwtest.o err.o fn.o lut.o
$(LDLIBS
)
116 luttest
: luttest.o err.o
117 $(LINK.c
) -o luttest luttest.o err.o
$(LDLIBS
)
120 optstest
: optstest.o err.o fn.o lut.o
121 $(LINK.c
) -o optstest optstest.o err.o fn.o lut.o
$(LDLIBS
)