Print this page
lib: move compat links from targetdirs to proper makefiles
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/lib/fm/libfmevent/Makefile.com
+++ new/usr/src/lib/fm/libfmevent/Makefile.com
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 (the "License").
6 6 # You may not use this file except in compliance with the License.
7 7 #
8 8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 9 # or http://www.opensolaris.org/os/licensing.
10 10 # See the License for the specific language governing permissions
11 11 # and limitations under the License.
12 12 #
13 13 # When distributing Covered Code, include this CDDL HEADER in each
14 14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 15 # If applicable, add the following below this CDDL HEADER, with the
16 16 # fields enclosed by brackets "[]" replaced with your own identifying
17 17 # information: Portions Copyright [yyyy] [name of copyright owner]
18 18 #
19 19 # CDDL HEADER END
20 20 #
21 21 #
22 22 # Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
23 23 #
24 24
25 25 LIBRARY = libfmevent.a
26 26 VERS = .1
27 27
28 28 LIBSRCS = fmev_subscribe.c \
29 29 fmev_evaccess.c \
30 30 fmev_errstring.c \
31 31 fmev_util.c \
32 32 fmev_publish.c
33 33
34 34 OBJECTS = $(LIBSRCS:%.c=%.o)
35 35
36 36 include ../../../Makefile.lib
37 37
38 38 # This library must install in /lib/fm since it is a dependency of
39 39 # svc.startd and may be required in early boot. Thus we cannot
40 40 # include ../Makefile.lib - instead we set ROOTFMHDRDIR and
41 41 # ROOTFMHDRS and redefine ROOTLIBDIR and ROOTLIBDIR64 accordingly
42 42
43 43 ROOTFMHDRDIR = $(ROOTHDRDIR)/fm
44 44 ROOTFMHDRS = $(FMHDRS:%=$(ROOTFMHDRDIR)/%)
45 45
46 46 ROOTLIBDIR= $(ROOTFS_LIBDIR)/fm
47 47 ROOTLIBDIR64= $(ROOTFS_LIBDIR)/fm/$(MACH64)
48 48
49 49 SRCS = $(LIBSRCS:%.c=../common/%.c)
50 50 LIBS = $(DYNLIB) $(LINTLIB)
51 51
52 52 SRCDIR = ../common
53 53
54 54 CSTD = $(CSTD_GNU99)
55 55
56 56 CPPFLAGS += -I../common -I.
57 57 $(NOT_RELEASE_BUILD)CPPFLAGS += -DDEBUG
58 58
59 59 CFLAGS += $(CCVERBOSE) $(C_BIGPICFLAGS)
60 60 CFLAGS64 += $(CCVERBOSE) $(C_BIGPICFLAGS)
61 61
62 62 CERRWARN += -_gcc=-Wno-parentheses
63 63 CERRWARN += -_gcc=-Wno-unused-function
64 64 CERRWARN += -_gcc=-Wno-uninitialized
65 65
66 66 FMLIBDIR=usr/lib/fm
67 67 $(BUILD64)FMLIBDIR64=usr/lib/fm/$(MACH64)
68 68
69 69 $(DYNLIB) := LDLIBS += -lumem -lnvpair -luutil -lsysevent \
70 70 -L$(ROOT)/$(FMLIBDIR) -ltopo -lc
71 71
72 72 $(BUILD64)$(DYNLIB) := LDLIBS64 += -lumem -lnvpair -luutil -lsysevent \
73 73 -L$(ROOT)/$(FMLIBDIR64) -ltopo -lc
↓ open down ↓ |
73 lines elided |
↑ open up ↑ |
74 74
75 75 LINTFLAGS = -msux
76 76 LINTFLAGS64 = -msux -m64
77 77
78 78 $(LINTLIB) := SRCS = $(SRCDIR)/$(LINTSRC)
79 79 $(LINTLIB) := LINTFLAGS = -nsvx
80 80 $(LINTLIB) := LINTFLAGS64 = -nsvx -m64
81 81
82 82 CLEANFILES += ../common/fmev_errstring.c
83 83
84 +COMPATLINKS = /usr/lib/fm/$(DYNLIB) /usr/lib/fm/$(LIBLINKS)
85 +COMPATLINKS64 = /usr/lib/fm/$(MACH64)/$(DYNLIB) \
86 + /usr/lib/fm/$(MACH64)/$(LIBLINKS)
87 +
88 +$(ROOT)/usr/lib/fm/libfmevent.so.1 := \
89 + COMPATLINKTARGET=../../../lib/fm/libfmevent.so.1
90 +$(ROOT)/usr/lib/fm/libfmevent.so := \
91 + COMPATLINKTARGET=../../../lib/fm/libfmevent.so.1
92 +$(ROOT)/usr/lib/fm/$(MACH64)/libfmevent.so.1:= \
93 + COMPATLINKTARGET=../../../../lib/fm/$(MACH64)/libfmevent.so.1
94 +$(ROOT)/usr/lib/fm/$(MACH64)/libfmevent.so:= \
95 + COMPATLINKTARGET=../../../../lib/fm/$(MACH64)/libfmevent.so.1
96 +
84 97 .KEEP_STATE:
85 98
86 99 all: $(LIBS)
87 100
88 101 lint: $(LINTLIB) lintcheck
89 102
90 103 pics/%.o: ../$(MACH)/%.c
91 104 $(COMPILE.c) -o $@ $<
92 105 $(POST_PROCESS_O)
93 106
94 107 ../common/fmev_errstring.c: ../common/mkerror.sh ../common/libfmevent.h
95 108 sh ../common/mkerror.sh ../common/libfmevent.h > $@
96 109
97 110 %.o: ../common/%.c
98 111 $(COMPILE.c) -o $@ $<
99 112 $(POST_PROCESS_O)
100 113
101 114 include ../../../Makefile.targ
102 115 include ../../Makefile.targ
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX