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 55aefb655Srie# Common Development and Distribution License (the "License"). 65aefb655Srie# 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# 215aefb655Srie 225aefb655Srie# 23cd3e9333SAli Bahrami# Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. 245aefb655Srie# 257c478bd9Sstevel@tonic-gate# Note: This mapfile is used to place r_debug as the 267c478bd9Sstevel@tonic-gate# very first data item inside of the run-time linker. 277c478bd9Sstevel@tonic-gate# This is required for the ld.so.1 <--> rtld_db bootstraping 287c478bd9Sstevel@tonic-gate# for debuggers. 297c478bd9Sstevel@tonic-gate# 30*8c426718SRichard Lowe# The issue with this is that different compilers may not agree on the name of 31*8c426718SRichard Lowe# the section this data will be placed in. So we must have a mapfile for 32*8c426718SRichard Lowe# each, though at present GCC is the only compiler. 337c478bd9Sstevel@tonic-gate# 347c478bd9Sstevel@tonic-gate 35cd3e9333SAli Bahrami$mapfile_version 2 36cd3e9333SAli Bahrami 37cd3e9333SAli BahramiLOAD_SEGMENT data { 38cd3e9333SAli Bahrami FLAGS = READ WRITE EXECUTE; 39cd3e9333SAli Bahrami 40cd3e9333SAli Bahrami # .data.rel sections from pics/debugdata.o go to data segment 41cd3e9333SAli Bahrami ASSIGN_SECTION dbg_data { 42cd3e9333SAli Bahrami IS_NAME = .data.rel; 43cd3e9333SAli Bahrami FILE_PATH = pics/debugdata.o; 44cd3e9333SAli Bahrami }; 45cd3e9333SAli Bahrami 46cd3e9333SAli Bahrami # Put .data.rel sections from pics/debugdata.o ahead of any other 47cd3e9333SAli Bahrami # .data.rel input sections in the .data.rel output section. 48cd3e9333SAli Bahrami IS_ORDER = dbg_data; 49cd3e9333SAli Bahrami 50cd3e9333SAli Bahrami # Put .data.rel output section at top of data segment 51cd3e9333SAli Bahrami OS_ORDER = .data.rel; 52cd3e9333SAli Bahrami}; 53