Hi Yuri,

The configure script is actually determining first if it should use the
module sysconfig or the module distutils.sysconfig depending on python
version and platform.
For version 3 it uses the former.
This gives an incorrect location.
I have edited the configure script to always choose distutils.sysconfig.
However this gives /usr/local/lib/python3/dist-packages
 whereas sys.path contains /usr/local/lib/python3.5/dist-packages. I have
added a symlink from/usr/local/lib/python3 to /usr/local/lib/python3.5

What a mess. I will consider virtualenv next time.

Thank you,

On Sun, Mar 6, 2016 at 4:06 PM, Yury V. Zaytsev <y...@shurup.com> wrote:

> On Sun, 6 Mar 2016, Bernard GODARD wrote:
>
> If there is a configure option to specify this, I would be happy to learn
>> it, but it is not --prefix.
>>
>
> Hi,
>
> Sorry, I haven't read your original message attentively enough and
> completely misinterpreted the nature of your question / complaint. I can
> see now that you're talking about the great Debian-specific 'dist-packages'
> hack and not the default prefix not being /usr.
>
> To be honest, I can't tell why it isn't working for you, because actually
> the build system of nlopt calls AM_PATH_PYTHON macro to find out what the
> $(pyexecdir) should be by querying the python interpreter you asked it to,
> which in essence works like this:
>
>     python -c "import sys; from distutils import
> sysconfig;python_lib(1,0,prefix='/usr/local'))"
>
> On my old Debian machine it correctly returns for system Python 2.6
>
>     /usr/local/lib/python2.6/dist-packages
>
> Obviously, it doesn't work for you though, but either way, it must be
> caused by Debian patches or a bug in the autotools macro, not a problem
> with nlopt build system itself.
>
> If you want to get to the bottom of it, you have to find out why
> $(pyexecdir) is set incorrectly. Or, you can forget about all this
> Debian-specific pain and just use virtualenv.
>
> P.S. Just to make it clear, I'm not a developer of nlopt.
>
>
> --
> Sincerely yours,
> Yury V. Zaytsev
>
_______________________________________________
NLopt-discuss mailing list
NLopt-discuss@ab-initio.mit.edu
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/nlopt-discuss

Reply via email to