From 2ec785001bc685dafcd792e49765dcbd2ae9bd38 Mon Sep 17 00:00:00 2001
From: Peter Johansson <trojkan@gmail.com>
Date: Sun, 30 Sep 2012 05:59:33 +0000
Subject: Use 'ls -r' rather than non-portable tool 'tac'. Simplify filepattern in ls expression so dylib (on OSX) are also detected.
---
old
|
new
|
AC_DEFUN([AX_BOOST_SYSTEM], |
83 | 83 | |
84 | 84 | LDFLAGS_SAVE=$LDFLAGS |
85 | 85 | if test "x$ax_boost_user_system_lib" = "x"; then |
86 | | for libextension in `ls $BOOSTLIBDIR/libboost_system*.a* $BOOSTLIBDIR/libboost_system*.so* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^lib\(boost_system.*\)\.\(so\|a\).*$;\1;' | tac` ; do |
| 86 | for libextension in `ls -r $BOOSTLIBDIR/libboost_system* 2>/dev/null | sed 's,.*/lib,,' | sed 's,\..*,,'` ; do |
87 | 87 | ax_lib=${libextension} |
88 | 88 | AC_CHECK_LIB($ax_lib, exit, |
89 | 89 | [BOOST_SYSTEM_LIB="-l$ax_lib"; AC_SUBST(BOOST_SYSTEM_LIB) link_system="yes"; break], |
90 | 90 | [link_system="no"]) |
91 | 91 | done |
92 | 92 | if test "x$link_system" != "xyes"; then |
93 | | for libextension in `ls $BOOSTLIBDIR/boost_system*.{dll,a}* 2>/dev/null | sed 's,.*/,,' | sed -e 's;^\(boost_system.*\)\.\(dll\|a\).*$;\1;' | tac` ; do |
| 93 | for libextension in `ls -r $BOOSTLIBDIR/boost_system* 2>/dev/null | sed 's,.*/,,' | sed -e 's,\..*,,'` ; do |
94 | 94 | ax_lib=${libextension} |
95 | 95 | AC_CHECK_LIB($ax_lib, exit, |
96 | 96 | [BOOST_SYSTEM_LIB="-l$ax_lib"; AC_SUBST(BOOST_SYSTEM_LIB) link_system="yes"; break], |