Skip to content

Commit bcd621e

Browse files
committed
buildsys: improve cross-build for freebsd and openbsd
on FreeBSD and OpenBSD, the most 3rd-party libs are installed in /usr/local/lib directory, we need to manully add -L/usr/local/lib to LDFLAGS only when do native build. Signed-off-by: leleliu008 <[email protected]>
1 parent fae067a commit bcd621e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

configure.ac

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,10 @@ case $host in
4545
fi
4646
;;
4747
*freebsd*|*openbsd*)
48-
# https://github.com/universal-ctags/ctags/issues/3338
49-
export LDFLAGS="$LDFLAGS -L/usr/local/lib"
48+
if test "$cross_compiling" = "no" ; then
49+
# https://github.com/universal-ctags/ctags/issues/3338
50+
export LDFLAGS="$LDFLAGS -L/usr/local/lib"
51+
fi
5052
;;
5153
esac
5254

0 commit comments

Comments
 (0)