xref: /illumos-gate/usr/src/cmd/sgs/rtld/sparc/Makefile (revision 5aefb6555731130ca4fd295960123d71f2d21fe8)
17c478bd9Sstevel@tonic-gate#
27c478bd9Sstevel@tonic-gate# CDDL HEADER START
37c478bd9Sstevel@tonic-gate#
47c478bd9Sstevel@tonic-gate# The contents of this file are subject to the terms of the
5*5aefb655Srie# Common Development and Distribution License (the "License").
6*5aefb655Srie# You may not use this file except in compliance with the License.
77c478bd9Sstevel@tonic-gate#
87c478bd9Sstevel@tonic-gate# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
97c478bd9Sstevel@tonic-gate# or http://www.opensolaris.org/os/licensing.
107c478bd9Sstevel@tonic-gate# See the License for the specific language governing permissions
117c478bd9Sstevel@tonic-gate# and limitations under the License.
127c478bd9Sstevel@tonic-gate#
137c478bd9Sstevel@tonic-gate# When distributing Covered Code, include this CDDL HEADER in each
147c478bd9Sstevel@tonic-gate# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
157c478bd9Sstevel@tonic-gate# If applicable, add the following below this CDDL HEADER, with the
167c478bd9Sstevel@tonic-gate# fields enclosed by brackets "[]" replaced with your own identifying
177c478bd9Sstevel@tonic-gate# information: Portions Copyright [yyyy] [name of copyright owner]
187c478bd9Sstevel@tonic-gate#
197c478bd9Sstevel@tonic-gate# CDDL HEADER END
207c478bd9Sstevel@tonic-gate#
21*5aefb655Srie
227c478bd9Sstevel@tonic-gate#
23*5aefb655Srie# Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
247c478bd9Sstevel@tonic-gate# Use is subject to license terms.
257c478bd9Sstevel@tonic-gate#
267c478bd9Sstevel@tonic-gate# ident	"%Z%%M%	%I%	%E% SMI"
277c478bd9Sstevel@tonic-gate#
287c478bd9Sstevel@tonic-gate
297c478bd9Sstevel@tonic-gate# Object lists are organized into primary (most frequently used code) and
307c478bd9Sstevel@tonic-gate# secondary lists (less frequently used code, ie. a.out support).
317c478bd9Sstevel@tonic-gate
327c478bd9Sstevel@tonic-gateP_COMOBJS=	debugdata.o \
337c478bd9Sstevel@tonic-gate		analyze.o	elf.o		globals.o	malloc.o \
347c478bd9Sstevel@tonic-gate		mutex.o		paths.o		setup.o		util.o \
357c478bd9Sstevel@tonic-gate		dlfcns.o	config_elf.o	locale.o	tsort.o \
36*5aefb655Srie		getcwd.o	remove.o	move.o		tls.o \
377c478bd9Sstevel@tonic-gate		cap.o
387c478bd9Sstevel@tonic-gate
397c478bd9Sstevel@tonic-gateS_COMOBJS=	debug.o		audit.o		object.o	cache_a.out.o \
407c478bd9Sstevel@tonic-gate		a.out.o
417c478bd9Sstevel@tonic-gate
427c478bd9Sstevel@tonic-gateG_MACHOBJS=	doreloc.o
437c478bd9Sstevel@tonic-gate
447c478bd9Sstevel@tonic-gateP_MACHOBJS=	sparc_elf.o	_setup.o
457c478bd9Sstevel@tonic-gate
467c478bd9Sstevel@tonic-gateCP_MACHOBJS=	common_sparc.o	dtrace_data.o
477c478bd9Sstevel@tonic-gate
487c478bd9Sstevel@tonic-gateS_MACHOBJS=	sparc_a.out.o
497c478bd9Sstevel@tonic-gate
507c478bd9Sstevel@tonic-gateP_ASOBJS=	boot.o		boot_elf.o	caller.o	zero.o
517c478bd9Sstevel@tonic-gate
527c478bd9Sstevel@tonic-gateS_ASOBJS=	boot_a.out.o
537c478bd9Sstevel@tonic-gate
547c478bd9Sstevel@tonic-gateCRTSRCS=	../../../../lib/common/sparc
557c478bd9Sstevel@tonic-gateCRTI=		pics/crti.o
567c478bd9Sstevel@tonic-gateCRTN=		pics/crtn.o
577c478bd9Sstevel@tonic-gateCRTS=		$(CRTI)		$(CRTN)
587c478bd9Sstevel@tonic-gate
597c478bd9Sstevel@tonic-gateCHKSRCS=	$(SRCBASE)/uts/common/krtld/reloc.h
607c478bd9Sstevel@tonic-gate
617c478bd9Sstevel@tonic-gateBASEPLAT =	sparc
627c478bd9Sstevel@tonic-gate
637c478bd9Sstevel@tonic-gate# __GNUC is overridden in the environment when building with gcc
647c478bd9Sstevel@tonic-gate__GNUC:sh=		echo \\043
657c478bd9Sstevel@tonic-gate
667c478bd9Sstevel@tonic-gate# We build sparc objects with cc by default
677c478bd9Sstevel@tonic-gateMAPFILE-ORDER =		../common/mapfile-order-devpro
687c478bd9Sstevel@tonic-gate$(__GNUC)MAPFILE-ORDER =	../common/mapfile-order-gcc
697c478bd9Sstevel@tonic-gate
707c478bd9Sstevel@tonic-gateinclude		$(SRC)/cmd/sgs/rtld/Makefile.com
717c478bd9Sstevel@tonic-gate
727c478bd9Sstevel@tonic-gate# Add any a.out and machine specific flags.
737c478bd9Sstevel@tonic-gate
747c478bd9Sstevel@tonic-gateCPPFLAGS +=	-I../../../../uts/sparc/krtld -DA_OUT
757c478bd9Sstevel@tonic-gateCFLAGS +=	-xregs=no%appl
767c478bd9Sstevel@tonic-gateASFLAGS +=	-K pic
777c478bd9Sstevel@tonic-gateLINTFLAGS +=	-DA_OUT
787c478bd9Sstevel@tonic-gateADBGENCFLAGS +=	-erroff=%all
797c478bd9Sstevel@tonic-gateADBGENFLAGS +=	-milp32
807c478bd9Sstevel@tonic-gateADBSUB=		$(ADBSUB32)
817c478bd9Sstevel@tonic-gateSONAME=		$(VAR_RTLD_SONAME)
827c478bd9Sstevel@tonic-gate
83*5aefb655SrieMAPFILES +=	../common/mapfile-32-vers
84*5aefb655Srie
857c478bd9Sstevel@tonic-gateSGSMSGTARG +=	$(SGSMSGSPARC) $(SGSMSGSPARC32) $(SGSMSG32)
867c478bd9Sstevel@tonic-gate
877c478bd9Sstevel@tonic-gate.KEEP_STATE:
887c478bd9Sstevel@tonic-gate
897c478bd9Sstevel@tonic-gateall:		$(RTLD)
907c478bd9Sstevel@tonic-gate
917c478bd9Sstevel@tonic-gateinstall:	all $(ROOTDYNLIB) $(VAR_RTLD_ETCDYNLIB)
927c478bd9Sstevel@tonic-gate
937c478bd9Sstevel@tonic-gatelint:		$(LINTOUT32)
947c478bd9Sstevel@tonic-gate
957c478bd9Sstevel@tonic-gateadbmacros:	adb .WAIT $(ADBSCRIPTS)
967c478bd9Sstevel@tonic-gate
977c478bd9Sstevel@tonic-gateadbinstall:	adbmacros .WAIT $(ROOTADB)
987c478bd9Sstevel@tonic-gate
997c478bd9Sstevel@tonic-gateinclude		$(SRC)/cmd/sgs/rtld/Makefile.targ
100