--- configure.ac        2013-04-05 09:29:24.000000000 -0500
+++ configure.ac        2013-11-21 14:15:13.421756932 -0600
@@ -107,7 +107,7 @@
 ])])
 
 hold_cflags=$CFLAGS
-CFLAGS="$CFLAGS -export-dynamic"
+CFLAGS="$CFLAGS -Wl,-export-dynamic"
 AC_CACHE_CHECK(if we need the -export-dynamic flag, ac_cv_export_dynamic, [
 AC_TRY_LINK(, [int i];, ac_cv_export_dynamic=yes, ac_cv_export_dynamic=no)])
 if test "$ac_cv_export_dynamic" = "no"; then
@@ -116,7 +116,7 @@
 
 AC_CACHE_CHECK(for compiler option to produce PIC,ac_cv_pic,[
 if test "$ac_cv_prog_gcc" = "yes"; then
-       ac_cv_pic="-fPIC -DPIC -shared"
+       ac_cv_pic="-std=gnu89 -fPIC -DPIC -shared"
        case `uname -s` in
                Darwin*[)]
                ac_cv_pic="-bundle -flat_namespace -undefined suppress"
