xref: /titanic_51/usr/src/cmd/sgs/libconv/Makefile.com (revision 4f680cc668fa6cf678c531083400ade9a9c7934c)
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 2009 Sun Microsystems, Inc.  All rights reserved.
24# Use is subject to license terms.
25#
26
27LIBRARY =	libconv.a
28
29COMOBJS32 =	cap_machelf32.o		dynamic_machelf32.o \
30		globals_machelf32.o 	sections_machelf32.o \
31		symbols_machelf32.o	symbols_sparc_machelf32.o
32
33COMOBJS64 =	cap_machelf64.o		dynamic_machelf64.o \
34		globals_machelf64.o	sections_machelf64.o \
35		symbols_machelf64.o	symbols_sparc_machelf64.o
36
37COMOBJS=	arch.o			c_literal.o \
38		cap.o			config.o \
39		corenote.o 		data.o \
40		deftag.o 		demangle.o \
41		dl.o			dwarf.o \
42		dwarf_ehe.o 		dynamic.o \
43		elf.o			globals.o \
44		group.o 		lddstub.o \
45		phdr.o			relocate.o \
46 		relocate_i386.o 	relocate_amd64.o \
47 		relocate_sparc.o 	sections.o \
48   		segments.o    		symbols.o \
49 		syminfo.o  		tokens.o \
50 		version.o
51
52ELFCAP_OBJS=	elfcap.o
53
54ASOBJS=		vernote.o
55
56BLTOBJS=	arch_msg.o		c_literal_msg.o \
57		cap_msg.o		config_msg.o \
58		corenote_msg.o		data_msg.o \
59		deftag_msg.o		demangle_msg.o \
60		dl_msg.o		dwarf_msg.o \
61		dwarf_ehe_msg.o 	dynamic_msg.o \
62		elf_msg.o 		globals_msg.o \
63		group_msg.o 		lddstub_msg.o \
64		phdr_msg.o 		relocate_amd64_msg.o \
65		relocate_i386_msg.o 	relocate_sparc_msg.o \
66		sections_msg.o 		segments_msg.o \
67		symbols_msg.o 		symbols_sparc_msg.o \
68		syminfo_msg.o 		version_msg.o
69
70
71OBJECTS =	$(COMOBJS) $(COMOBJS32) $(COMOBJS64) $(ELFCAP_OBJS) \
72		$(ASOBJS) $(BLTOBJS)
73
74ELFCAP=		$(SRC)/common/elfcap
75
76#
77# This library is unusual since it's a static archive of PIC objects.
78# Since static archives should never contain CTF data (regardless of
79# whether the object code is position-independent), we disable CTF.
80#
81NOCTFOBJS =	$(OBJECTS)
82CTFMERGE_LIB =	:
83
84include 	$(SRC)/lib/Makefile.lib
85include 	$(SRC)/cmd/sgs/Makefile.com
86
87CTFCONVERT_O=
88
89README_REVISION=../../packages/common/readme_revision
90ONLDREADME=	../../packages/common/SUNWonld-README
91
92PICS=		$(OBJECTS:%=pics/%)
93
94CPPFLAGS +=	-I$(SRCBASE)/lib/libc/inc -I$(ELFCAP) \
95		-I$(SRC)/common/sgsrtcid $(VAR_LIBCONV_CPPFLAGS)
96
97ARFLAGS=	cr
98
99AS_CPPFLAGS=	-P -D_ASM $(CPPFLAGS)
100
101BLTDATA=	$(BLTOBJS:%.o=%.c) $(BLTOBJS:%.o=%.h) report_bufsize.h
102
103SRCS=		../common/llib-lconv
104LINTSRCS=	$(COMOBJS:%.o=../common/%.c) \
105		    $(COMOBJS_NOMSG:%.o=../common/%.c) \
106		    $(ELFCOM_OBJS:%.o=$(ELFCAP)/%.c) ../common/lintsup.c
107LINTSRCS32 =	$(COMOBJS32:%32.o=../common/%.c)
108LINTSRCS64 =	$(COMOBJS64:%64.o=../common/%.c)
109
110# INTERNAL_RELEASE_BUILD is defined by standard full builds (nightly),
111# but not for sgs builds we do for development. The result of these
112# two lines is that dev builds pass -d to the readme_revision script,
113# generating a more detailed version string for the linker components
114# that includes the workspace, user, CR, and date. Official builds get
115# a simpler uncluttered version string.
116VERNOTE_DEBUG= -d
117$(INTERNAL_RELEASE_BUILD)VERNOTE_DEBUG=
118
119SGSMSGTARG=	$(BLTOBJS:%_msg.o=../common/%.msg)
120
121LINTFLAGS +=	-u
122LINTFLAGS64 +=	-u
123
124CLEANFILES +=	$(BLTDATA) $(LINTOUTS) bld_vernote vernote.s
125CLOBBERFILES +=	$(LINTLIBS)
126