diff --git a/support/config.rpath b/support/config.rpath
index fc5913d..7380d54 100755
--- a/support/config.rpath
+++ b/support/config.rpath
@@ -517,6 +517,10 @@ case "$host_os" in
     library_names_spec='$libname.a'
     ;;
   aix[4-9]*)
+    # .so must not be used without -brtl.
+    if test $aix_use_runtimelinking = no; then
+      shrext=.a
+    fi
     library_names_spec='$libname$shrext'
     ;;
   amigaos*)
