[master] Added SunOS support to configure.ac and Makefile.am

but configure and Makefile.in were not updated.
diff --git a/ANNOUNCE b/ANNOUNCE
index 135d4b5..7138a18 100644
--- a/ANNOUNCE
+++ b/ANNOUNCE
@@ -1,5 +1,5 @@
 
-Libpng 1.4.9beta01 - July 12, 2011
+Libpng 1.4.9beta01 - September 2, 2011
 
 This is not intended to be a public release.  It will be replaced
 within a few weeks by a public version or by another test version.
@@ -26,9 +26,11 @@
 
 Changes since the last public release (1.4.8):
 
-version 1.4.9beta01 [July 12, 2011]
+version 1.4.9beta01 [September 2, 2011]
   Added vstudio/* and CMakeLists to EXTRA_DIST in Makefile.in and Makefile.am
   Updated contrib/pngminus/makefile.std (Samuli Souminen)
+  Added SunOS support to configure.ac and Makefile.am (but configure and
+    Makefile.in were not updated)
 
 Send comments/corrections/commendations to glennrp at users.sourceforge.net
 or to png-mng-implement at lists.sf.net (subscription required; visit
diff --git a/CHANGES b/CHANGES
index b3e9686..5c30c35 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,4 @@
 #if 0
-libpng_changes(){ /*
 CHANGES - changes for libpng
 
 version 0.2
@@ -2826,14 +2825,15 @@
 version 1.4.8 [July 7, 2011]
   No changes.
 
-version 1.4.9beta01 [July 12, 2011]
+version 1.4.9beta01 [September 2, 2011]
   Added vstudio/* and CMakeLists to EXTRA_DIST in Makefile.in and Makefile.am
   Updated contrib/pngminus/makefile.std (Samuli Souminen)
+  Added SunOS support to configure.ac and Makefile.am (but configure and
+    Makefile.in were not updated)
 
 Send comments/corrections/commendations to glennrp at users.sourceforge.net
 or to png-mng-implement at lists.sf.net (subscription required; visit
 https://lists.sourceforge.net/lists/listinfo/png-mng-implement).
 
 Glenn R-P
-*/ }
 #endif
diff --git a/Makefile.am b/Makefile.am
index bae1d1d..ca6041c 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -38,7 +38,13 @@
 
 if HAVE_LD_VERSION_SCRIPT
   # Versioned symbols and restricted exports
+
+if HAVE_SOLARIS_LD
+  libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_LDFLAGS += -Wl,-M Wl,libpng.vers
+else
   libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_LDFLAGS += -Wl,--version-script=libpng.vers
+endif
+
   libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_DEPENDENCIES = libpng.vers
 else
   # Only restricted exports when possible
diff --git a/configure.ac b/configure.ac
index ae65c04..8c9c7c9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -77,7 +77,24 @@
     AC_MSG_RESULT(no)
 ;;
 * )
-GLD=`$LD --help < /dev/null 2>/dev/null | grep version-script`
+
+AC_MSG_CHECKING([if using Solaris linker])
+SLD=`$LD --version 2>&1 | grep Solaris`
+if test "$SLD"; then
+    have_solaris_ld=yes
+    AC_MSG_RESULT(yes)
+else
+    have_solaris_ld=no
+    AC_MSG_RESULT(no)
+fi
+AM_CONDITIONAL(HAVE_SOLARIS_LD, test "$have_solaris_ld" = "yes")
+
+if test "$have_solaris_ld" = "yes"; then
+    GLD=`$LD --help < /dev/null 2>&1 | grep 'M mapfile'`
+else
+    GLD=`$LD --help < /dev/null 2>/dev/null | grep version-script`
+fi
+
 if test "$GLD"; then
     have_ld_version_script=yes
     AC_MSG_RESULT(yes)