xref: /titanic_44/usr/src/cmd/sgs/libconv/Makefile.com (revision 628e3cbed6489fa1db545d8524a06cd6535af456)
1#
2# CDDL HEADER START
3#
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.
7#
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.
12#
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]
18#
19# CDDL HEADER END
20#
21
22#
23# Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
24# Use is subject to license terms.
25#
26# ident	"%Z%%M%	%I%	%E% SMI"
27#
28
29LIBRARY =	libconv.a
30
31COMOBJS32 =	cap32.o			dynamic32.o \
32		elf32.o			globals32.o \
33		phdr32.o		\
34		relocate_i38632.o	relocate_amd6432.o \
35		relocate_sparc32.o	sections32.o \
36		symbols32.o		symbols_sparc32.o \
37		syminfo32.o
38
39COMOBJS64 =	cap64.o			dynamic64.o \
40		elf64.o			globals64.o \
41		phdr64.o		\
42		relocate_i38664.o	relocate_amd6464.o \
43		relocate_sparc64.o	sections64.o \
44		symbols64.o		symbols_sparc64.o \
45		syminfo64.o
46
47COMOBJS=	arch.o			c_literal.o \
48		config.o		corenote.o \
49		data.o			deftag.o \
50		demangle.o		dl.o \
51		dwarf_ehe.o		group.o	\
52		lddstub.o		segments.o \
53		version.o
54
55COMOBJS_NOMSG =	tokens.o
56
57COMOBJS_NOMSG32 = \
58		relocate32.o
59COMOBJS_NOMSG64 = \
60		relocate64.o
61
62ELFCAP_OBJS=	elfcap.o
63
64ASOBJS=		vernote.o
65
66OBJECTS =	$(COMOBJS) $(COMOBJS32) $(COMOBJS64) $(COMOBJS_NOMSG) \
67		$(COMOBJS_NOMSG32) $(COMOBJS_NOMSG64) $(ELFCAP_OBJS) $(ASOBJS)
68
69ELFCAP=		$(SRC)/common/elfcap
70
71#
72# This library is unusual since it's a static archive of PIC objects.
73# Since static archives should never contain CTF data (regardless of
74# whether the object code is position-independent), we disable CTF.
75#
76NOCTFOBJS =	$(OBJECTS)
77CTFMERGE_LIB =	:
78
79include 	$(SRC)/lib/Makefile.lib
80include 	$(SRC)/cmd/sgs/Makefile.com
81
82CTFCONVERT_O=
83
84README_REVISION=../../packages/common/readme_revision
85ONLDREADME=	../../packages/common/SUNWonld-README
86
87PICS=		$(OBJECTS:%=pics/%)
88
89CPPFLAGS +=	-I$(SRCBASE)/lib/libc/inc -I$(ELFCAP) \
90		-I$(SRC)/common/sgsrtcid $(VAR_LIBCONV_CPPFLAGS)
91
92ARFLAGS=	cr
93
94AS_CPPFLAGS=	-P -D_ASM $(CPPFLAGS)
95
96BLTDATA=	$(COMOBJS:%.o=%_msg.h) \
97		    $(COMOBJS32:%.o=%_msg.h) $(COMOBJS64:%.o=%_msg.h)
98
99SRCS=		../common/llib-lconv
100LINTSRCS=	$(COMOBJS:%.o=../common/%.c) \
101		    $(COMOBJS_NOMSG:%.o=../common/%.c) \
102		    $(ELFCOM_OBJS:%.o=$(ELFCAP)/%.c) ../common/lintsup.c
103LINTSRCS32 =	$(COMOBJS32:%32.o=../common/%.c)
104LINTSRCS64 =	$(COMOBJS64:%64.o=../common/%.c)
105
106# INTERNAL_RELEASE_BUILD is defined by standard full builds (nightly),
107# but not for sgs builds we do for development. The result of these
108# two lines is that dev builds pass -d to the readme_revision script,
109# generating a more detailed version string for the linker components
110# that includes the workspace, user, CR, and date. Official builds get
111# a simpler uncluttered version string.
112VERNOTE_DEBUG= -d
113$(INTERNAL_RELEASE_BUILD)VERNOTE_DEBUG=
114
115SGSMSGTARG=	$(COMOBJS:%.o=../common/%.msg) \
116		    $(COMOBJS32:%32.o=../common/%.msg) \
117		    $(COMOBJS64:%64.o=../common/%.msg)
118
119LINTFLAGS +=	-u
120LINTFLAGS64 +=	-u
121
122CLEANFILES +=	$(BLTDATA) $(LINTOUTS) bld_vernote vernote.s
123CLOBBERFILES +=	$(LINTLIBS)
124