mapfiles.patch revision 98
258N/A# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
258N/A# Use subject to license terms.
258N/A#
258N/A# Permission is hereby granted, free of charge, to any person obtaining a
258N/A# copy of this software and associated documentation files (the
258N/A# "Software"), to deal in the Software without restriction, including
258N/A# without limitation the rights to use, copy, modify, merge, publish,
258N/A# distribute, and/or sell copies of the Software, and to permit persons
258N/A# to whom the Software is furnished to do so, provided that the above
258N/A# copyright notice(s) and this permission notice appear in all copies of
258N/A# the Software and that both the above copyright notice(s) and this
258N/A# permission notice appear in supporting documentation.
258N/A#
258N/A# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
258N/A# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
258N/A# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
258N/A# OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
258N/A# HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL
258N/A# INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING
258N/A# FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
258N/A# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
258N/A# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
258N/A#
258N/A# Except as contained in this notice, the name of a copyright holder
258N/A# shall not be used in advertising or otherwise to promote the sale, use
258N/A# or other dealings in this Software without prior written authorization
258N/A# of the copyright holder.
258N/A
258N/A--- src/Makefile.am 2007-01-10 19:12:16.281143000 -0800
258N/A+++ src/Makefile.am 2007-01-10 19:24:44.193611000 -0800
258N/A@@ -56,3 +56,42 @@
258N/A lg_i2c.c \
258N/A lg_xaa.c \
258N/A lg_xaa.h
258N/A+
258N/A+
258N/A+# Generate linker mapfiles for symbols found in other modules and use them
258N/A+# and library flag additions to make sure all symbols are resolvable
258N/A+
258N/A+MAPFILES = \
258N/A+ mapfile-cirrus_drv-external \
258N/A+ mapfile-cirrus_alpine-external \
258N/A+ mapfile-cirrus_laguna-external
258N/A+
258N/A+BUILT_SOURCES = $(MAPFILES)
258N/A+
258N/A+cirrus_drv_la_LDFLAGS += \
258N/A+ -Wl,-M,mapfile-cirrus_alpine-external \
258N/A+ -Wl,-M,mapfile-cirrus_laguna-external \
+ -lddc -li2c -lint10 -lvgahw -lvbe
+
+cirrus_alpine_la_LDFLAGS += \
+ -Wl,-M,mapfile-cirrus_drv-external \
+ -lddc -lfb -li2c -lint10 -lramdac -lshadowfb -lvgahw -lxaa \
+ -lxf1bpp -lxf4bpp -lXfont
+
+cirrus_laguna_la_LDFLAGS += \
+ -Wl,-M,mapfile-cirrus_drv-external \
+ -lddc -lfb -li2c -lint10 -lramdac -lvgahw -lxaa
+
+mapfiles: $(MAPFILES)
+
+mapfile-cirrus_drv-external: $(cirrus_drv_la_OBJECTS)
+mapfile-cirrus_alpine-external: $(cirrus_alpine_la_OBJECTS)
+mapfile-cirrus_laguna-external: $(cirrus_laguna_la_OBJECTS)
+
+mapfile-%-external:
+ -rm -f $@
+ printf '# Functions exported to loadable modules\n\n' > $@
+ printf '{\n global:\n' >> $@
+ /usr/ccs/bin/nm -g $? | grep -v UNDEF | sed -n -e 's/^.*\|FUNC \|GLOB \|.*\|\(.*\)$$/ \1 = FUNCTION extern;/p' -e 's/^.*\|OBJT \|GLOB \|.*\|\(.*\)$$/ \1 = DATA extern;/p' >> $@
+ printf '};\n' >> $@
+