--- a/aclocal.m4
+++ b/aclocal.m4
@@ -99,6 +99,10 @@
     x86_64-apple-darwin)
         soext='.dylib'
         ;;
+    *-linux*)
+        $3="$$3 -Wl,--hash-style=both,--no-copy-dt-needed-entries,--as-needed"
+        $4="$$4 --hash-style=both --no-copy-dt-needed-entries --as-needed"
+        ;;
     esac
 
     BuildPlatform="$BuildArch-$BuildVendor-$BuildOS"
