Mercurial > illumos > illumos-gate
changeset 10590:43ff5881adbb
6843010 /usr/lib/ld/map.noexbss should be provided
author | Rod Evans <Rod.Evans@Sun.COM> |
---|---|
date | Mon, 21 Sep 2009 08:42:30 -0700 |
parents | 7b05736960d1 |
children | 2e4b69967f09 |
files | exception_lists/mapfilechk usr/src/common/mapfiles/common/Makefile usr/src/common/mapfiles/common/map.bssalign usr/src/common/mapfiles/common/map.execdata usr/src/common/mapfiles/common/map.noexbss usr/src/common/mapfiles/i386/map.noexdata usr/src/pkgdefs/SUNWtoo/prototype_com |
diffstat | 7 files changed, 79 insertions(+), 45 deletions(-) [+] |
line wrap: on
line diff
--- a/exception_lists/mapfilechk Mon Sep 21 23:17:43 2009 +0800 +++ b/exception_lists/mapfilechk Mon Sep 21 08:42:30 2009 -0700 @@ -35,7 +35,8 @@ usr/src/cmd/mdb/common/kmdb/mapfile_skel usr/src/cmd/sgs/rtld/common/mapfile-order-* usr/src/common/bignum/*/cap_mapfile -usr/src/common/mapfiles/*/Makefile +usr/src/common/mapfiles/* +usr/src/common/mapfiles/*/* usr/src/lib/README.mapfiles usr/src/lib/libc/*_hwcap*/mapfile usr/src/lib/libc/sparc_hwcap1/sparc*/mapfile
--- a/usr/src/common/mapfiles/common/Makefile Mon Sep 21 23:17:43 2009 +0800 +++ b/usr/src/common/mapfiles/common/Makefile Mon Sep 21 08:42:30 2009 -0700 @@ -33,6 +33,7 @@ $(ROOTDIR)/map.execdata \ $(ROOTDIR)/map.filter \ $(ROOTDIR)/map.bssalign \ + $(ROOTDIR)/map.noexbss \ $(ROOTDIR)/map.noexstk install: $(DIRS) $(FILES)
--- a/usr/src/common/mapfiles/common/map.bssalign Mon Sep 21 23:17:43 2009 +0800 +++ b/usr/src/common/mapfiles/common/map.bssalign Mon Sep 21 08:42:30 2009 -0700 @@ -1,15 +1,12 @@ # -# ident "%Z%%M% %I% %E% SMI" -# -# Copyright 2005 Sun Microsystems, Inc. All rights reserved. +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. # # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE # or http://www.opensolaris.org/os/licensing. @@ -24,7 +21,7 @@ # # CDDL HEADER END # -# Linker mapfile that enables the creation of a 'bss' segment, and aligns +# Link-editor mapfile that enables the creation of a bss segment, and aligns # the segment at 4Mb. This effectively provides an appropriate alignment for # large page mapping of the heap, and thus can be useful when building dynamic # executables. See ppgsz(1). Users are cautioned that an alignment @@ -32,8 +29,8 @@ # hardware platforms. A more flexible means of requesting the most optimal # underlying page size may evolve in future releases. # -# The linker does not use this file automatically, so one must use the -M -# option to cc or ld: +# The link-editor does not use this file automatically, so one must use the +# -M option to cc or ld: # # cc -M /usr/lib/ld/map.bssalign myprogram.c #
--- a/usr/src/common/mapfiles/common/map.execdata Mon Sep 21 23:17:43 2009 +0800 +++ b/usr/src/common/mapfiles/common/map.execdata Mon Sep 21 08:42:30 2009 -0700 @@ -1,15 +1,12 @@ # -#ident "%Z%%M% %I% %E% SMI" -# -# Copyright 2005 Sun Microsystems, Inc. All rights reserved. +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. # # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE # or http://www.opensolaris.org/os/licensing. @@ -24,20 +21,22 @@ # # CDDL HEADER END # -# Linker mapfile to create an executable data segment definition within +# Link-editor mapfile to create an executable data segment definition within # an executable for applications which rely on this. This is the default # for 32 bit x86 executable and all SPARC executables; this mapfile is # provided to facilitate an executable data segment for AMD64 executables. -# The linker does not use this file automatically, so one must use the -M -# option to cc or ld: +# +# The link-editor does not use this file automatically, so one must use the +# -M option to cc or ld: # # cc -M /usr/lib/ld/map.execdata myprogram.c # data = ?RWX; + # -# For programs with a separate BSS segment add a line for the BSS; just -# adding the line creates a BSS segment so it is commented out. +# Executables can also create a separate executable bss segment. Adding +# the following line creates a bss segment. # # bss = ?RWX; # -# See also /usr/lib/ld/map.noexdata +# See also /usr/lib/ld/map.noexdata.
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/usr/src/common/mapfiles/common/map.noexbss Mon Sep 21 08:42:30 2009 -0700 @@ -0,0 +1,40 @@ +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# Use is subject to license terms. +# +# CDDL HEADER START +# +# The contents of this file are subject to the terms of the +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. +# +# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE +# or http://www.opensolaris.org/os/licensing. +# See the License for the specific language governing permissions +# and limitations under the License. +# +# When distributing Covered Code, include this CDDL HEADER in each +# file and include the License file at usr/src/OPENSOLARIS.LICENSE. +# If applicable, add the following below this CDDL HEADER, with the +# fields enclosed by brackets "[]" replaced with your own identifying +# information: Portions Copyright [yyyy] [name of copyright owner] +# +# CDDL HEADER END +# +# Link-editor mapfile to create a non-executable bss segment definition +# within an executable. This mapfile is similar to map.noexdata that +# can be used on x86 architectures to create a non-executable data +# segment. On SPARC, the data segment contains a Procedure Linkage +# Table (PLT) that must remain executable. +# +# As the bss segment is extended by sbrk(2) to enlarge the heap, a +# non-executable bss segment also results in a non-exutable heap. +# +# The link-editor does not use this file automatically, so one must +# use the -M option to cc or ld: +# +# cc -M /usr/lib/ld/map.noexbss myprogram.c +# +bss = ?RW; + +# See also /usr/lib/ld/map.noexdata.
--- a/usr/src/common/mapfiles/i386/map.noexdata Mon Sep 21 23:17:43 2009 +0800 +++ b/usr/src/common/mapfiles/i386/map.noexdata Mon Sep 21 08:42:30 2009 -0700 @@ -1,15 +1,12 @@ # -#ident "%Z%%M% %I% %E% SMI" -# -# Copyright 2005 Sun Microsystems, Inc. All rights reserved. +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. # # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE # or http://www.opensolaris.org/os/licensing. @@ -24,24 +21,24 @@ # # CDDL HEADER END # -# Linker mapfile to create a non-executable data segment -# definition within an executable. Note that this only functions -# properly on the x86 architecture as on SPARC the PLT contains -# executable code; it lives at the start of the data segment. -# The linker does not use this file automatically, so one must use the -M -# option to cc or ld: +# Link-editor mapfile to create a non-executable data segment definition +# within an executable. Note that this only functions properly on the +# x86 architecture. On SPARC, the data segment contains a Procedure Linkage +# Table (PLT) that must remain executable. +# +# As the data segment is extended by sbrk(2) to enlarge the heap, a +# non-executable data segment also results in a non-exutable heap. +# +# The link-editor does not use this file automatically, so one must use the +# -M option to cc or ld: # # cc -M /usr/lib/ld/map.noexdata myprogram.c # - data = ?RW; # -# For programs with a separate bss segment, add a line for the bss. -# Just adding such a line causes a bss to be created; this causes -# some extra wasted memory. A mapfile with just the line below -# can be safely used on SPARC. +# Executables can also create a separate non-executable bss segment. +# This segment may use additional memory, but also results in a +# non-executable heap. See /usr/lib/ld/map.noexbss. # -# bss = ?RW; -# -# See also /usr/lib/ld/map.execdata +# See also /usr/lib/ld/map.execdata.
--- a/usr/src/pkgdefs/SUNWtoo/prototype_com Mon Sep 21 23:17:43 2009 +0800 +++ b/usr/src/pkgdefs/SUNWtoo/prototype_com Mon Sep 21 08:42:30 2009 -0700 @@ -19,11 +19,9 @@ # CDDL HEADER END # # -# Copyright 2008 Sun Microsystems, Inc. All rights reserved. +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # -# ident "%Z%%M% %I% %E% SMI" -# # This required package information file contains a list of package contents. # The 'pkgmk' command uses this file to identify the contents of a package @@ -74,6 +72,7 @@ f none usr/lib/ld/map.execdata 444 root bin f none usr/lib/ld/map.filter 444 root bin f none usr/lib/ld/map.default 444 root bin +f none usr/lib/ld/map.noexbss 444 root bin f none usr/lib/ld/map.noexstk 444 root bin f none usr/lib/ld/map.pagealign 444 root bin f none usr/lib/lddstub 555 root bin