changeset 3922:03d8d1eaaf6d

7033957: Library built without a mapfile: libxinerama.so Reviewed-by: ksrini
author ohair
date Tue, 12 Apr 2011 14:23:37 -0700
parents eaca823dd3fe
children 0069845a086c
files make/common/shared/Defs-solaris.gmk
diffstat 1 files changed, 18 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/make/common/shared/Defs-solaris.gmk	Thu Apr 07 19:59:28 2011 -0700
+++ b/make/common/shared/Defs-solaris.gmk	Tue Apr 12 14:23:37 2011 -0700
@@ -194,13 +194,30 @@
 MAPFILE_WARNING-=WARNING
 MAPFILE_WARNING=$(MAPFILE_WARNING-$(VARIANT))
 
+# Some libraries do not have mapfiles for multiple reasons.
+#   These libraries for sparc and sparcv9 are exceptions to the mapfile rule:
+#     libjdgaSUNWafb.so
+#     libjdgaSUNWcg6.so
+#     libjdgaSUNWffb.so
+#     libjdgaSUNWm64.so
+#     libxinerama.so
+#   The library libJdbcOdbc.so has also been given an exception.
+#   The JNI/JVMTI demo libraries are also missing mapfiles, no exceptions yet.
+ifeq ($(ARCH_FAMILY),sparc)
+  MAPFILE_EXCEPTIONS = \
+    (libJdbcOdbc|libjdgaSUNWafb|libjdgaSUNWcg6|libjdgaSUNWffb|libjdgaSUNWm64|libxinerama)
+else
+  MAPFILE_EXCEPTIONS = (libJdbcOdbc)
+endif
+
 # Macro to check it's input file for banned dependencies and verify the
 #   binary built properly. Relies on process exit code.
 ifndef CROSS_COMPILE_ARCH
 define binary_file_verification # binary_file
 ( \
   $(ECHO) "Checking for mapfile use in: $1" && \
-  if [ "`$(NM) -g -D $1 | $(EGREP) -v 'UNDEF' | $(EGREP) 'SUNWprivate'`" = "" ] ; then \
+  if [ "`$(ECHO) $(basename $(notdir $1)) | $(EGREP) '$(MAPFILE_EXCEPTIONS)'`" = "" \
+       -a "`$(NM) -g -D $1 | $(EGREP) -v 'UNDEF' | $(EGREP) 'SUNWprivate'`" = "" ] ; then \
     $(ECHO) "$(MAPFILE_WARNING): File was not built with a mapfile: $1"; \
   fi && \
   $(ECHO) "Library loads for: $1" && \