illumos ld does not support --as-needed and --gc-sections.

--- libcanberra-0.30/configure.ac.orig
+++ libcanberra-0.30/configure.ac
@@ -114,9 +114,6 @@
         -fdata-sections])
 AC_SUBST([WARNINGFLAGS], $with_cflags)
 
-CC_CHECK_FLAGS_APPEND([with_ldflags], [LDFLAGS], [\
-        -Wl,--as-needed \
-        -Wl,--gc-sections])
 AC_SUBST([GCLDFLAGS], $with_ldflags)
 
 #### libtool stuff ####