# # 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 # # # Copyright 2007 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # include $(SRC)/Makefile.master SUBDIRS= gen common $(MACH64) all: TARGET= all install: TARGET= install clean: TARGET= clean clobber: TARGET= clobber lint: TARGET= lint package: TARGET= package .KEEP_STATE: all: gen install: $(SUBDIRS) clean lint package: clobber: gen $(SUBDIRS): FRC @cd $@; pwd; $(MAKE) $(TARGET) FRC: # # 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 # # # Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. # include $(SRC)/Makefile.master ROOTDIR= $(ROOT)/usr/lib/ld ROOTDIR64= $(ROOT)/usr/lib/ld/$(MACH64) DIRS= $(ROOTDIR) $(ROOTDIR64) FILES= install: $(DIRS) $(FILES) map.link $(FILES): FILEMODE=444 $(DIRS): DIRMODE=755 map.link: $(RM) $(ROOTDIR64)/map.default \ $(ROOTDIR64)/map.above4G $(ROOTDIR64)/map.below4G $(SYMLINK) ../map.default $(ROOTDIR64)/map.default $(SYMLINK) ../map.above4G $(ROOTDIR64)/map.above4G $(SYMLINK) ../map.below4G $(ROOTDIR64)/map.below4G $(DIRS): $(INS.dir) $(ROOTDIR)/%: % $(INS.file) $(ROOTDIR64)/%: % $(INS.file) # # 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 # # # Copyright (c) 2001, 2010, Oracle and/or its affiliates. All rights reserved. # include $(SRC)/Makefile.master ROOTDIR= $(ROOT)/usr/lib/ld DIRS= $(ROOTDIR) FILES= \ $(ROOTDIR)/map.above4G \ $(ROOTDIR)/map.below4G \ $(ROOTDIR)/map.bssalign \ $(ROOTDIR)/map.execdata \ $(ROOTDIR)/map.default \ $(ROOTDIR)/map.filter \ $(ROOTDIR)/map.noexbss \ $(ROOTDIR)/map.noexdata \ $(ROOTDIR)/map.noexstk \ $(ROOTDIR)/map.pagealign install: $(DIRS) $(FILES) $(FILES): FILEMODE=444 $(DIRS): DIRMODE=755 $(DIRS): $(INS.dir) $(ROOTDIR)/%: % $(INS.file) # # Copyright (c) 1998, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 # # Linker mapfile for loading 64-bit programs above 4 gigabytes. # The linker does not use this file automatically, so one must # use the -M option to cc or ld: # # cc -m64 -M /usr/lib/ld/map.above4G myprogram.c # $mapfile_version 2 $if !_ELF64 $error mapfile is only applicable to 64-bit objects $endif # sparcv9 and amd64 use the same address $if _sparc || _x86 # On sparc (but not amd64), this is equivalent to map.default. LOAD_SEGMENT text { VADDR = 0x100000000 }; $else $error unknown platform $endif # # Copyright (c) 1998, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 # # Linker mapfile for loading 64-bit SPARC programs below 4 gigabytes # The linker does not use this file automatically, so one must use the -M # option to cc or ld: # # cc -m64 -M /usr/lib/ld/map.below4G myprogram.c # $mapfile_version 2 $if !_ELF64 $error mapfile is only applicable to 64-bit objects $endif # sparcv9 and amd64 use the same address $if _sparc LOAD_SEGMENT text { VADDR = 0x80000000 }; $elif _x86 # This is equivalent to map.default. LOAD_SEGMENT text { VADDR = 0x400000 }; $else $error unknown platform $endif # # Copyright (c) 2001, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 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 # specification may be machine-specific, and may lose its benefit on different # hardware platforms. A more flexible means of requesting the most optimal # underlying page size may evolve in future releases. # # 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 # $mapfile_version 2 LOAD_SEGMENT bss { ALIGN = 0x400000; }; # # Copyright (c) 1998, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 # # Linker mapfile that shows how programs are loaded by default. # The linker does not use this file automatically, so one must use the -M # option to cc or ld: # # cc -M /usr/lib/ld/map.default myprogram.c # $mapfile_version 2 $if _sparc $if _ELF32 LOAD_SEGMENT text { VADDR = 0x10000 }; $elif _ELF64 # This is equivalent to map.above4G. LOAD_SEGMENT text { VADDR = 0x100000000 }; $else $error unknown sparc ELFCLASS $endif $else _x86 $if _ELF32 LOAD_SEGMENT text { VADDR = 0x08048000 }; $elif _ELF64 # This is equivalent to map.below4G. LOAD_SEGMENT text { VADDR = 0x400000 }; $else $error unknown x86 ELFCLASS $endif $else $error unknown platform $endif # # Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 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 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 # $mapfile_version 2 LOAD_SEGMENT data { FLAGS = READ WRITE EXECUTE; }; # # Executables can also create a separate executable bss segment. Adding # the following line creates a bss segment. # # LOAD_SEGMENT bss { FLAGS = READ WRITE EXECUTE }; # # See also /usr/lib/ld/map.noexdata. # # Copyright (c) 1993, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 # # A default mapfile for optimizing the creation of a filter shared object. # Creates a single, read-only, executable text segment to catch all loadable # sections. # # Filters that consist solely of a symbol table can be built directly from # ld(1) so that no .init/.fini sections are created. Although the filter can # be constructed as a single read-only segment, the execute attribute of the # segment is maintained to allow for simple .init processing (i.e., .init # processing that requires no relocations), and to accommodate older versions # of dbx that produce warning messages if they find objects without traditional # text segments. # # If a filter is required to execute .init code that references global data # then the filter will require relocation (i.e., it will have to be written to # by ld.so.1). Filters of this sort should *not* use this mapfile. # # This compaction of a filter into a single segment allows ld.so.1 to optimize # its processing of a filter. If the filter is small enough this segment may # be handled in a single page mapping (for example libdl.so.1). # # The assignment of all allocatable sections to this segment insures that the # .dynamic, and any .data or .bss sections, become part of the text. Note that # the compiler has a habit of generating empty .data and .bss sections. # # Override the default alignment so that this single paged object can be mapped # more flexibly. $mapfile_version 2 LOAD_SEGMENT filter { FLAGS = READ EXECUTE; ALIGN = 0x1000; ASSIGN_SECTION { FLAGS = ALLOC; }; }; # # 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 # # # Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved. # $mapfile_version 2 # lex generates a lex.yy.c for use in building applications. A number of # interfaces within this file are intended for libl.so to bind to, and thus # should remain exported from any application using lex.yy.c. SYMBOL_SCOPE { global: yyback; yyextra; yyfnd; yyinput; yyleng; yylex; yylsp; yylstate; yyolsp; yyout; yyprevious; yytext; yyunput; }; # Some applications use the -e option of lex, which generates additional lex # interfaces that are not defined in the generic $(MAPFILE.LEX). Export the # following interfaces to satisfy -e use. #SYMBOL_SCOPE { # global: # yywinput; # yywleng; # yywtext; # yywunput; #}; # # Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 # $mapfile_version 2 LOAD_SEGMENT bss { FLAGS = READ WRITE; }; # See also /usr/lib/ld/map.noexdata. # # Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 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 # # # 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. # # See also /usr/lib/ld/map.execdata. $mapfile_version 2 $if _sparc $error SPARC Procedure Linkage Table (PLT) must remain executable $elif _x86 LOAD_SEGMENT data { FLAGS = READ WRITE }; $else $error unknown platform $endif # # Copyright (c) 2001, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 # # Linker mapfile to create a non-executable stack definition within an # executable. # The linker does not use this file automatically, so one must use the -M # option to cc or ld: # # cc -M /usr/lib/ld/map.noexstk myprogram.c # $mapfile_version 2 STACK { FLAGS = READ WRITE; }; # # Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved. # # 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 # # Linker mapfile to create page-aligned data within an executable. # The linker does not use this file automatically, so one must use the -M # option to cc or ld: # # cc -M /usr/lib/ld/map.pagealign myprogram.c # $mapfile_version 2 $if _sparc LOAD_SEGMENT data { ROUND = 0x2000 }; $elif _x86 LOAD_SEGMENT data { ROUND = 0x1000 }; $else $error unknown platform $endif # # 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 # # # Copyright 2007 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # Copyright 2015 Igor Kozhukhov # include $(SRC)/Makefile.master # Hammerhead: Mapfile generation needs native build settings (no -nodefaultlibs) # to properly link test executables against libc include $(SRC)/Makefile.native include $(SRC)/Makefile.master.64 # Hammerhead: amd64-only - skip 32-bit mapfiles, build only 64-bit FILES= $(MACH64)_gcc_map.noexeglobs NATIVE_LIBS += libc.so LDFLAGS += $(BDIRECT) # Hammerhead: Simple GCC link command for mapfile test executables # - Uses GCC_NATIVE_FLAGS (no -nodefaultlibs) to link against libc # - Uses only -m64 for amd64 target # - Uses LD_ALTEXEC to route through gnu-ld-wrapper for mapfile conversion MAPFILE_LINK64= LD_ALTEXEC=$(BUILD_LD) $(GCC) $(GCC_NATIVE_FLAGS) -m64 SYMS1= syms.1 SYMS2= syms.2 MAIN1= main.1 MAIN2= main.2 TEMPLATE1= map.noexeglobs.1.template TEMPLATE2= map.noexeglobs.2.template all install: $(FILES) clean: $(RM) $(SYMS1) $(SYMS2) $(MAIN1) $(MAIN2) clobber: clean $(RM) $(FILES) # A number of dynamic executables have their own definitions of interfaces that # exist in system libraries. To prevent name-space pollution it is desirable # to demote the interfaces within these executable to locals. However, various # symbols defined by the compiler drivers crt/values files need to remain # global in any dynamic object that includes these files. These symbols # interpose on symbols in libc, or provide call backs for other system # libraries. The various compiler drivers (cc and gcc), and the crt/values # files that these drivers are configured to include, differ between the # various compilations environments (platform, 32/64-bit). Therefore, the # only means of creating a mapfile to demote symbols is to dynamically generate # the mapfile for a specific compilation environment. # # Here, template mapfiles are used to generate a number of compilation specific # mapfiles. These mapfiles are referenced by components of the build through # the MAPFILE.NGB macro defined in Makefile.master. These dynamically created # mapfiles are not delivered into the $ROOT area, and therefore are not # delivered as packaged components of the OSNet. # Hammerhead: Use MAPFILE_LINK64 for proper native linking (amd64-only) $(MACH64)_gcc_map.noexeglobs : LINK = $(MAPFILE_LINK64) # This generic target creates two dynamic executables from an empty "main" # program. These objects are not executed, but are analyzed to determine the # global symbols each provides. # # The first executable demotes a family of known interfaces to local and allows # all other symbol definitions to remain global. This executables provides the # base for discovering all symbol definitions provided by the various # compilation environments. The second executable demotes all symbols to # locals. Within both executables, some symbols remain globals (_end, _etext, # etc.) as the link-editor has special knowledge of these symbols and their # expected visibility requirements. By inspecting the deferences between the # global symbols within the two executables, a mapfile can be generated to # ensure the symbols defined by the compilation environments files remain # global. %map.noexeglobs: main.c $(TEMPLATE1) $(TEMPLATE2) $(LINK) -o $(MAIN1) -Wl,-M$(TEMPLATE1) main.c $(ELFDUMP) -s -N.dynsym $(MAIN1) | $(EGREP) "WEAK|GLOB" | \ $(GREP) -v UNDEF | $(AWK) '{print $$9 }' | $(SORT) > $(SYMS1) $(LINK) -o $(MAIN2) -Wl,-M$(TEMPLATE2) main.c $(ELFDUMP) -s -N.dynsym $(MAIN2) | $(EGREP) "WEAK|GLOB" | \ $(GREP) -v UNDEF | $(AWK) '{print $$9 }' | $(SORT) > $(SYMS2) $(ECHO) "# GENERATED FILE - DO NOT EDIT" > $@ $(GREP) MAP-HEAD $(TEMPLATE2) | \ $(SED) -e "s/ *# MAP-HEAD//" >> $@ $(DIFF) $(SYMS1) $(SYMS2) | $(GREP) "^<" | \ $(SED) -e "s/^< \(.*\)/ \1;/" >> $@ $(GREP) MAP-TAIL $(TEMPLATE2) | \ $(SED) -e "s/ *# MAP-TAIL//" >> $@ $(RM) $(SYMS1) $(SYMS2) $(MAIN1) $(MAIN2) /* * Minimal main for mapfile generation. * This file is used to build test executables that are analyzed * to determine which symbols the compiler's crt/values files provide. */ int main(void) { return (0); } # # 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 # # # Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved. # # Template mapfile for generating a final mapfile to demote all user global # symbols to local within a dynamic executable. # $mapfile_version 2 SYMBOL_SCOPE { local: _fini; _init; _start; main; }; # # 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 # # # Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved. # # Template mapfile for generating a final mapfile to demote all user global # symbols to local within a dynamic executable. This mapfile also provides # the "MAP-" commented entries to select lines for the final mapfile. # $mapfile_version 2 # MAP-HEAD # MAP-HEAD SYMBOL_SCOPE { # MAP-HEAD global: # MAP-HEAD _lib_version; # MAP-HEAD local: # MAP-TAIL *; # MAP-TAIL }; # MAP-TAIL