Print this page
4146 getconf(1) does not support XATTR_ENABLED, XATTR_EXISTS, SATTR_ENABLED, SATTR_EXISTS keys
Reviewed by: Cedric Blancher <cedric.blancher@gmail.com>
Reviewed by: Irek Szczesniak <iszczesniak@gmail.com>
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/cmd/getconf/Makefile
+++ new/usr/src/cmd/getconf/Makefile
1 1 #
2 2 # CDDL HEADER START
3 3 #
4 4 # The contents of this file are subject to the terms of the
5 5 # Common Development and Distribution License, Version 1.0 only
6 6 # (the "License"). You may not use this file except in compliance
7 7 # with the License.
8 8 #
9 9 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 10 # or http://www.opensolaris.org/os/licensing.
11 11 # See the License for the specific language governing permissions
12 12 # and limitations under the License.
13 13 #
14 14 # When distributing Covered Code, include this CDDL HEADER in each
15 15 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 16 # If applicable, add the following below this CDDL HEADER, with the
17 17 # fields enclosed by brackets "[]" replaced with your own identifying
18 18 # information: Portions Copyright [yyyy] [name of copyright owner]
19 19 #
20 20 # CDDL HEADER END
21 21 #
22 22 #
23 23 # Copyright 2006 Sun Microsystems, Inc. All rights reserved.
24 24 # Use is subject to license terms.
25 25 #
26 26
27 27 PROG= getconf
28 28 XPG4PROG= getconf
29 29 XPG6PROG= getconf
↓ open down ↓ |
29 lines elided |
↑ open up ↑ |
30 30 X4= objs.xpg4
31 31 X6= objs.xpg6
32 32 OBJS= getconf.o
33 33 XPG4EXOBJS= $(X4)/getconf.o
34 34 XPG6EXOBJS= $(X6)/getconf.o
35 35
36 36 include ../Makefile.cmd
37 37
38 38 XPG4EXOBJS += values-xpg4.o
39 39 CFLAGS += $(CCVERBOSE)
40 -CERRWARN += -_gcc=-Wno-parentheses
41 40 # XPG4
42 41 $(XPG4) := CFLAGS += -D_XOPEN_SOURCE -I$(SRC)/lib/libc/inc
43 42
44 43 # XPG6MODE: Depending on the version of the compiler, the value of
45 44 # __STDC_VERSION__ may differ even in the presence of the same compilation
46 45 # options. The default compilation mode for Sun compilers that support the
47 46 # C99 standard is -xc99=all,no_lib. C99MODE= is equivalent to -xc99=all,no_lib.
48 47 # This translates to C99 semantics without the C99 library specific behaviors
49 48 # and dependencies.
50 49 #
51 50 # For pre-5.7 compilers (unless patched with 117551-04 or 117552-05), in the
52 51 # default compilation mode, __STDC_VERSION__ was defined to be 199901L. For
53 52 # 5.7 and on compilers, __STDC_VERSION__ defaults to 199409L in order to
54 53 # maintain source compatibility. Neither of these cases results in the
55 54 # importing of /usr/lib/values-xpg6.o, so we need to either manually import
56 55 # it via linking with a local version of the object, or set -xc99=%all which
57 56 # by default imports /usr/lib/values-xpg6.o. C99MODE=C99_ENABLE is equivalent
58 57 # to -xc99=all. If C99_ENABLE is defined and we also attempt to link with a
59 58 # local version of values-xpg6.o, an error will occur due to multiple
60 59 # definitions for __xpg4 and __xpg6. Because /usr/lib/values-xpg6.o was
61 60 # delivered in Solaris 10 and is a stable interface, there is no need to
62 61 # build and link with a local version of the object.
63 62 #
64 63 # The gcc compiler behaves differently and requires -std=gnu99.
65 64 #
66 65 # For XPG4, we need to link with a local version of values-xpg4.o because
67 66 # the compiler only imports this by default (from /usr/lib/values-xpg4.o)
68 67 # if we use the c89 utility as opposed to cc.
69 68
70 69 XPG6MODE = $(C99_ENABLE)
71 70 $(XPG6) := C99MODE = $(XPG6MODE)
72 71 $(XPG6) := CFLAGS += -D_XOPEN_SOURCE=600 -I$(SRC)/lib/libc/inc
73 72
74 73 .KEEP_STATE:
75 74
76 75 all: $(PROG) $(XPG4) $(XPG6)
77 76
78 77 $(PROG): $(OBJS)
79 78 $(LINK.c) -o $@ $(OBJS) $(LDLIBS)
80 79 $(POST_PROCESS)
81 80
82 81 $(XPG4): $(X4) $(XPG4EXOBJS)
83 82 $(LINK.c) -o $@ $(XPG4EXOBJS) $(LDLIBS)
84 83 $(POST_PROCESS)
85 84
86 85 $(XPG6): $(X6) $(XPG6EXOBJS)
87 86 $(LINK.c) -o $@ $(XPG6EXOBJS) $(LDLIBS)
88 87 $(POST_PROCESS)
89 88
90 89
91 90 $(XPG4EXOBJS): $(X4)
92 91
93 92
94 93 $(X4)/%.o: %.c
95 94 $(COMPILE.c) -o $@ $<
96 95
97 96
98 97 $(X4):
99 98 -@mkdir -p $@
100 99
101 100
102 101 $(XPG6EXOBJS): $(X6)
103 102
104 103
105 104 $(X6)/%.o: %.c
106 105 $(COMPILE.c) -o $@ $<
107 106
108 107
109 108 $(X6):
110 109 -@mkdir -p $@
111 110
112 111
113 112 install: all $(ROOTPROG) $(ROOTXPG4PROG) $(ROOTXPG6PROG)
114 113
115 114 values-xpg4.o: ../../lib/common/common/values-xpg4.c
116 115 $(COMPILE.c) -o $@ ../../lib/common/common/values-xpg4.c
117 116
118 117 clean:
119 118 -@rm -rf $(OBJS) $(XPG4EXOBJS) $(XPG6EXOBJS) $(X4) $(X6) \
120 119 $(PROG) $(XPG4) $(XPG6)
121 120
122 121 lint: lint_PROG
123 122
124 123 include ../Makefile.targ
↓ open down ↓ |
74 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX