xref: /illumos-gate/usr/src/cmd/sgs/rtld/common/mapfile-vers (revision a530dbfeb9a5dac77444604360c346085f7c7a04)
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) 1992, 2010, Oracle and/or its affiliates. All rights reserved.
245aefb655Srie#
257c478bd9Sstevel@tonic-gate# Generic interface definition for usr/src/cmd/sgs/rtld.
267c478bd9Sstevel@tonic-gate#
27bfed486aSAli Bahrami
287c478bd9Sstevel@tonic-gate#
29bfed486aSAli Bahrami# MAPFILE HEADER START
30bfed486aSAli Bahrami#
31bfed486aSAli Bahrami# WARNING:  STOP NOW.  DO NOT MODIFY THIS FILE.
32bfed486aSAli Bahrami# Object versioning must comply with the rules detailed in
33bfed486aSAli Bahrami#
34bfed486aSAli Bahrami#	usr/src/lib/README.mapfiles
35bfed486aSAli Bahrami#
36bfed486aSAli Bahrami# You should not be making modifications here until you've read the most current
37bfed486aSAli Bahrami# copy of that file. If you need help, contact a gatekeeper for guidance.
38bfed486aSAli Bahrami#
39bfed486aSAli Bahrami# MAPFILE HEADER END
40bfed486aSAli Bahrami#
41bfed486aSAli Bahrami
42cd3e9333SAli Bahrami$mapfile_version 2
43cd3e9333SAli Bahrami
447c478bd9Sstevel@tonic-gate#
457c478bd9Sstevel@tonic-gate# All symbols in ld.so.1 are private as no-one should bind to these directly.
46bfed486aSAli Bahrami#
47cd3e9333SAli BahramiSYMBOL_VERSION SUNWprivate_1.3 {
489a411307Srie    protected:
497257d1b4Sraf	dladdr;	# Standard dlopen(3x) family
507c478bd9Sstevel@tonic-gate	dladdr1;
517c478bd9Sstevel@tonic-gate	dldump;
527c478bd9Sstevel@tonic-gate	dlclose;
537c478bd9Sstevel@tonic-gate	dlerror;
547c478bd9Sstevel@tonic-gate	dlinfo;
557c478bd9Sstevel@tonic-gate	dlopen;
567c478bd9Sstevel@tonic-gate	dlmopen;
577c478bd9Sstevel@tonic-gate	dlsym;
587c478bd9Sstevel@tonic-gate
597257d1b4Sraf	_dladdr;	# these should not exist
607257d1b4Sraf	_dladdr1;
617257d1b4Sraf	_dldump;
627257d1b4Sraf	_dlclose;
637257d1b4Sraf	_dlerror;
647257d1b4Sraf	_dlinfo;
657257d1b4Sraf	_dlopen;
667257d1b4Sraf	_dlmopen;
677257d1b4Sraf	_dlsym;
687257d1b4Sraf
697c478bd9Sstevel@tonic-gate	_ld_libc;	# provides libc initialization
707c478bd9Sstevel@tonic-gate
717c478bd9Sstevel@tonic-gate	_elf_rtbndr;	# dbx expects to find these
727c478bd9Sstevel@tonic-gate	elf_rtbndr;
737c478bd9Sstevel@tonic-gate	_rt_boot;	# Provides basic adb symbol offsets
747c478bd9Sstevel@tonic-gate
757c478bd9Sstevel@tonic-gate	rtld_db_dlactivity;	# Required to support librtld_db
767c478bd9Sstevel@tonic-gate	rtld_db_preinit;
777c478bd9Sstevel@tonic-gate	rtld_db_postinit;
788222814eSRichard Lowe	r_debug		{
798222814eSRichard Lowe			  ASSERT = {
808222814eSRichard Lowe				  TYPE = OBJECT;
818222814eSRichard Lowe$if _x86 && _ELF32
828222814eSRichard Lowe				  SIZE = 44;
838222814eSRichard Lowe$elif _x86 && _ELF64
848222814eSRichard Lowe				  SIZE = 80;
857e85189aSToomas Soome$elif _sparc && _ELF32
867e85189aSToomas Soome				  SIZE = 44;
877e85189aSToomas Soome$elif _sparc && _ELF64
887e85189aSToomas Soome				  SIZE = 80;
898222814eSRichard Lowe$else
908222814eSRichard Lowe$error Unknown platform
918222814eSRichard Lowe$endif
928222814eSRichard Lowe				};
938222814eSRichard Lowe			};
947c478bd9Sstevel@tonic-gate
957c478bd9Sstevel@tonic-gate	elf_plt_write;
967c478bd9Sstevel@tonic-gate	is_so_loaded;
978222814eSRichard Lowe	lml_main	{
988222814eSRichard Lowe			  ASSERT = {
998222814eSRichard Lowe				  TYPE = OBJECT;
1007e85189aSToomas Soome$if _ELF32
1018222814eSRichard Lowe				  SIZE = addrsize[41];
1027e85189aSToomas Soome$elif _ELF64
1038222814eSRichard Lowe				  SIZE = addrsize[38];
1048222814eSRichard Lowe$else
1058222814eSRichard Lowe$error Unknown platform
1068222814eSRichard Lowe$endif
1078222814eSRichard Lowe				};
1088222814eSRichard Lowe			};
1097c478bd9Sstevel@tonic-gate	lookup_sym;
1107c478bd9Sstevel@tonic-gate
1112926dd2eSrie	alist_append;	# librtld support
1128222814eSRichard Lowe	ld_entry_cnt	{ ASSERT = { TYPE = OBJECT; SIZE = addrsize; }; };
1138222814eSRichard Lowe	# Diagnostic support
1148222814eSRichard Lowe	dbg_desc	{ ASSERT = { TYPE = OBJECT; SIZE = addrsize; }; };
1157c478bd9Sstevel@tonic-gate	dbg_print;
1167c478bd9Sstevel@tonic-gate	eprintf;	# Error message printing
1171007fd6fSAli Bahrami	veprintf;
1187c478bd9Sstevel@tonic-gate
1197257d1b4Sraf	dgettext;	# Messaging support
1207c478bd9Sstevel@tonic-gate	strerror;
1217c478bd9Sstevel@tonic-gate
1227c478bd9Sstevel@tonic-gate	calloc;	# Memory management (mapmalloc).
1237c478bd9Sstevel@tonic-gate	free;
1247c478bd9Sstevel@tonic-gate	malloc;
1257c478bd9Sstevel@tonic-gate	realloc;
1267c478bd9Sstevel@tonic-gate
1278222814eSRichard Lowe	# PLT tracing getenv() support.
1288222814eSRichard Lowe	_environ	{ ASSERT = { TYPE = OBJECT; SIZE = addrsize; }; };
1298222814eSRichard Lowe	environ		{
1308222814eSRichard Lowe			  ASSERT = {
1318222814eSRichard Lowe				  BINDING = WEAK;
1328222814eSRichard Lowe				  ALIAS = _environ;
1338222814eSRichard Lowe				};
1348222814eSRichard Lowe			};
1357c478bd9Sstevel@tonic-gate
136a574db85Sraf	memcpy;	# Some routines are useful for support
137a574db85Sraf	snprintf;	# libraries such as liblddbg.
138a574db85Sraf	sprintf;	# Note that some of these functions
139a574db85Sraf	strcat;	# (like sprintf) may have reduced
140a574db85Sraf	strcmp;	# functionality over libc, as a simpler
141a574db85Sraf	strcpy;	# implementation is provided in ld.so.1.
142a574db85Sraf	strlen;
143a574db85Sraf	strrchr;
144a574db85Sraf	strtok_r;
1457c478bd9Sstevel@tonic-gate	___errno;
1467c478bd9Sstevel@tonic-gate	qsort;
14720272c2eSAli Bahrami	dl_iterate_phdr;
148cd3e9333SAli Bahrami
149cd3e9333SAli Bahrami$if _x86 && _ELF64
150cd3e9333SAli Bahrami	# amd64 ABI exception unwinding
151cd3e9333SAli Bahrami	_dlamd64getunwind;
152cd3e9333SAli Bahrami	dlamd64getunwind;
153cd3e9333SAli Bahrami$endif
154cd3e9333SAli Bahrami
155cd3e9333SAli Bahrami	# doXX_reloc_rtld and relocXX_table are required to
156cd3e9333SAli Bahrami	# support librtld.so.
157cd3e9333SAli Bahrami$if _ELF32
158cd3e9333SAli Bahrami	do32_reloc_rtld;
1598222814eSRichard Lowe	reloc32_table	{
1608222814eSRichard Lowe			  ASSERT = {
1618222814eSRichard Lowe				  TYPE = OBJECT;
1627e85189aSToomas Soome$if _x86
163*a530dbfeSRichard Lowe				  SIZE = addrsize[132];
1647e85189aSToomas Soome$elif _sparc
1657e85189aSToomas Soome				  SIZE = addrsize[264];
1667e85189aSToomas Soome$else
1677e85189aSToomas Soome$error Unknown architecture
1687e85189aSToomas Soome$endif
1698222814eSRichard Lowe				};
1708222814eSRichard Lowe			};
171cd3e9333SAli Bahrami$elif _ELF64
172cd3e9333SAli Bahrami	do64_reloc_rtld;
1738222814eSRichard Lowe	reloc64_table	{
1748222814eSRichard Lowe			  ASSERT = {
1758222814eSRichard Lowe				  TYPE = OBJECT;
1767e85189aSToomas Soome$if _x86
177*a530dbfeSRichard Lowe				  SIZE = addrsize[86];
1787e85189aSToomas Soome$elif _sparc
1797e85189aSToomas Soome				  SIZE = addrsize[176];
1807e85189aSToomas Soome$else
1817e85189aSToomas Soome$error Unknown architecture
1827e85189aSToomas Soome$endif
1838222814eSRichard Lowe				};
1848222814eSRichard Lowe			};
185cd3e9333SAli Bahrami$else
186cd3e9333SAli Bahrami$error unknown ELFCLASS
187cd3e9333SAli Bahrami$endif
1887c478bd9Sstevel@tonic-gate    local:
1897c478bd9Sstevel@tonic-gate	*;
1907c478bd9Sstevel@tonic-gate};
191