build: Configure `pkg-config' correctly for static linking.
[catacomb] / configure.ac
index 142b854..af08371 100644 (file)
@@ -240,11 +240,10 @@ AC_CHECK_TYPE([socklen_t], [],
 ])
 
 dnl The maths library.
 ])
 
 dnl The maths library.
-mdw_ORIG_LIBS=$LIBS LIBS=
+mdw_ORIG_LIBS=$LIBS LIBS=$CATACOMB_LIBS
 AC_SEARCH_LIBS([log], [m])
 AC_SEARCH_LIBS([sqrt], [m])
 AC_SEARCH_LIBS([log], [m])
 AC_SEARCH_LIBS([sqrt], [m])
-AC_SUBST([MATHLIBS], [$LIBS])
-LIBS=$mdw_ORIG_LIBS
+CATACOMB_LIBS=$LIBS LIBS=$mdw_ORIG_LIBS
 
 dnl Logging is weird under Termux.  Unfortunately, it involves macros, so we
 dnl have to do this the hard way.
 
 dnl Logging is weird under Termux.  Unfortunately, it involves macros, so we
 dnl have to do this the hard way.