summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2014-02-03 13:24:04 +0000
committerRoy Marples <roy@marples.name>2014-02-03 13:24:04 +0000
commit1131df84d52157e678645211ed3259894ff18519 (patch)
tree4bf350c62b05e97656f4bcdb4010ba46f803fdb1 /configure
parent90ada440ecae51f1041e16e54d86f1add7d6d72f (diff)
downloaddhcpcd-1131df84d52157e678645211ed3259894ff18519.tar.xz
Only link to libmd if it lives in /lib
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure4
1 files changed, 3 insertions, 1 deletions
diff --git a/configure b/configure
index e5758cdf..d974f0a4 100755
--- a/configure
+++ b/configure
@@ -638,9 +638,11 @@ int main(void) {
return 0;
}
EOF
+ # We only want to link to libmd if it exists in /lib
+ set -- $(ls /lib/libmd.so.*)
if $XCC _md5.c -o _md5 2>/dev/null; then
MD5=yes
- elif $XCC _md5.c -lmd -o _md5; then
+ elif [ -e "$1" ] && $XCC _md5.c -lmd -o _md5 2>/dev/null; then
MD5="yes (-lmd)"
MD5_LIB=-lmd
else