Makefile revision cd3e933325e68e23516a196a8fea7f49b1e497c3
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews#
297be3708069ef31814d6d75c0d71a50a78feb03Mark Andrews# CDDL HEADER START
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews#
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# The contents of this file are subject to the terms of the
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# Common Development and Distribution License (the "License").
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# You may not use this file except in compliance with the License.
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews#
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# or http://www.opensolaris.org/os/licensing.
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# See the License for the specific language governing permissions
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# and limitations under the License.
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews#
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# When distributing Covered Code, include this CDDL HEADER in each
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# If applicable, add the following below this CDDL HEADER, with the
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# fields enclosed by brackets "[]" replaced with your own identifying
2a31bd531072824ef252c18303859d6af7451b00Francis Dupont# information: Portions Copyright [yyyy] [name of copyright owner]
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews#
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# CDDL HEADER END
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews#
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
e21a2904f02a03fa06b6db04d348f65fe9c67b2bMark Andrews#
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews#
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsBASEPLAT = amd64
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# Object lists are organized into primary (most frequently used code) and
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# secondary lists (less frequently used code, ie. a.out support).
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsP_COMOBJS= debugdata.o \
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews analyze.o elf.o external.o globals.o \
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews malloc.o paths.o setup.o util.o \
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews dlfcns.o config_elf.o locale.o tsort.o \
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews remove.o move.o tls.o cap.o
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsS_COMOBJS= debug.o audit.o object.o
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsG_MACHOBJS= doreloc.o
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsP_MACHOBJS= amd64_elf.o _setup.o dlamd64getunwind.o
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
cedb0bd0c1e3c461b7e479a16d3adfd5b150f1f4Mark AndrewsCP_MACHOBJS=
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsS_MACHOBJS=
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsP_ASOBJS= boot.o boot_elf.o caller.o
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsS_ASOBJS=
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsCRTSRCS= ../../../../lib/common/amd64
71c66a876ecca77923638d3f94cc0783152b2f03Mark AndrewsCRTI= pics/crti.o
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsCRTN= pics/crtn.o
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsCRTS= $(CRTI) $(CRTN)
71c66a876ecca77923638d3f94cc0783152b2f03Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewsinclude $(SRC)/cmd/sgs/rtld/Makefile.com
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewsinclude $(SRC)/lib/Makefile.lib.64
2a31bd531072824ef252c18303859d6af7451b00Francis Dupont
2a31bd531072824ef252c18303859d6af7451b00Francis Dupont# We build 64-bit objects with gcc by default
2a31bd531072824ef252c18303859d6af7451b00Francis DupontMAPFILE-ORDER = ../common/mapfile-order-devpro
71c66a876ecca77923638d3f94cc0783152b2f03Mark Andrews$(__GNUC64)MAPFILE-ORDER = ../common/mapfile-order-gcc
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews# Add any machine specific flags.
71c66a876ecca77923638d3f94cc0783152b2f03Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsCFLAGS += -xregs=no%appl
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsASFLAGS += -D__amd64 -D_ELF64 $(amd64_ASFLAGS)
71c66a876ecca77923638d3f94cc0783152b2f03Mark AndrewsADBGENFLAGS += -mlp64
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsADBGENCFLAGS += -erroff=%all
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsADBSUB= $(ADBSUB64)
71c66a876ecca77923638d3f94cc0783152b2f03Mark AndrewsCPPFLAGS += -D_ELF64
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsLINTFLAGS64 += $(VAR_LINTFLAGS64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsSONAME= /lib/amd64/ld.so.1
71c66a876ecca77923638d3f94cc0783152b2f03Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsSGSMSGTARG += $(SGSMSGINTEL) $(SGSMSGINTEL64) $(SGSMSG64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
71c66a876ecca77923638d3f94cc0783152b2f03Mark AndrewsLDLIB = -L ../../libld/$(MACH64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsRTLDLIB = -L ../../librtld/$(MACH64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
71c66a876ecca77923638d3f94cc0783152b2f03Mark AndrewsCPICLIB = $(CPICLIB64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsLDDBGLIBDIR = $(LDDBGLIBDIR64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark AndrewsCONVLIBDIR = $(CONVLIBDIR64)
71c66a876ecca77923638d3f94cc0783152b2f03Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews.KEEP_STATE:
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewsall: $(RTLD)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewsinstall: all $(ROOTDYNLIB64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewslint: $(LINTOUT64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewsadbmacros: adb .WAIT $(ADBSCRIPTS)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewsadbinstall: adbmacros .WAIT $(ROOTADB64)
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewsinclude $(SRC)/cmd/sgs/rtld/Makefile.targ
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrewsinclude ../../Makefile.sub.64
5a4557e8de2951a2796676b5ec4b6a90caa5be14Mark Andrews