svn commit: r326768 - head/Mk
Maxim Sobolev
sobomax at FreeBSD.org
Sun Sep 8 19:28:30 UTC 2013
Author: sobomax
Date: Sun Sep 8 19:28:29 2013
New Revision: 326768
URL: http://svnweb.freebsd.org/changeset/ports/326768
Log:
Don't rely on `file -L' to follow symlinks and find type of the file
they point to. It only works if symlink points to the file directly and
fails if there are more than one level of symlinks. Use realpath(1) to
drill out the actual path to the shared lib and feed it to file(1)
then.
This fixes issue with cerain LIB_DEPENDS, such as databases/db42.
Approved by: portmgr (bapt)
Modified:
head/Mk/bsd.port.mk
Modified: head/Mk/bsd.port.mk
==============================================================================
--- head/Mk/bsd.port.mk Sun Sep 8 18:32:38 2013 (r326767)
+++ head/Mk/bsd.port.mk Sun Sep 8 19:28:29 2013 (r326768)
@@ -5049,7 +5049,8 @@ lib-depends:
for libdir in $$dirs; do \
test -f $${libdir}/$${lib} || continue; \
if [ -x /usr/bin/file ]; then \
- [ `file -b -L --mime-type $${libdir}/$${lib}` = "application/x-sharedlib" ] || continue ; \
+ _LIB_FILE=`realpath $${libdir}/$${lib}`; \
+ [ `file -b -L --mime-type $${_LIB_FILE}` = "application/x-sharedlib" ] || continue ; \
fi ; \
found=1 ; \
${ECHO_MSG} " - found"; \
More information about the svn-ports-all
mailing list