Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 29 Aug 2008 23:36:33 GMT
From:      Arjan Gijsberts <arjan@liralab.it>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/126960: math/py-numpy - setup fails to locate atlas libraries due to faulty path in site.cfg
Message-ID:  <200808292336.m7TNaXGI052390@www.freebsd.org>
Resent-Message-ID: <200808292340.m7TNe0Du029087@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         126960
>Category:       ports
>Synopsis:       math/py-numpy - setup fails to locate atlas libraries due to faulty path in site.cfg
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Aug 29 23:40:00 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Arjan Gijsberts
>Release:        FreeBSD 7.0
>Organization:
>Environment:
FreeBSD fbsd 7.0-RELEASE-p3 FreeBSD 7.0-RELEASE-p3 #8: Thu Aug 28 00:13:32 CEST 2008     root@fbsd:/usr/obj/usr/src/sys/KCONFIG  i386
>Description:
The math/py-numpy port uses a supplied site.cfg that is used during setup for
the localization of libraries, such as atlas (math/atlas). If WITH_ATLAS is
specified, the port should be build using the atlas libraries.

The supplied site.cfg sets the 'library_dirs' search path for atlas to %%LOCALBASE%%, which defaults to /usr/local. The libraries, however, reside (by default) in /usr/local/lib (i.e. %%LOCALBASE%%/lib). In contrast, the 'library_dirs' search path for lapack is specified correctly.

This minor misconfiguration causes the setup to fail to locate the atlas libraries and to fall back to default blas. This may be tricky for some users, as the port seems to have installed properly at first sight.

>How-To-Repeat:
The problem can be repeated by building math/py-numpy with WITH_ATLAS=yes. Output of the build shows that numpy fails to locate the atlas libraries in %%LOCALBASE%%. Further, it can be verified by listing the dynamic object dependencies for lapack_lite.so (in default configurations: ldd /usr/local/lib/python2.5/site-packages/numpy/linalg/lapack_lite.so).
>Fix:
Substitute %%LOCALBASE%% for %%LOCALBASE%%/lib in the library_dirs variable of the atlas section of site.cfg.

Patch attached with submission follows:

--- site.cfg.original	2007-06-25 18:33:24.000000000 +0200
+++ site.cfg	2008-08-30 01:31:51.000000000 +0200
@@ -6,5 +6,5 @@
 # search static libraries (.a) in preference to shared ones (.so)
 search_static_first = 0
 [atlas]
-library_dirs = %%LOCALBASE%%:%%GCCLIBDIR%%
+library_dirs = %%LOCALBASE%%/lib:%%GCCLIBDIR%%
 atlas_libs = %%ATLASLIBS%%


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200808292336.m7TNaXGI052390>