Re: [Boost-users] Problem detecting python

View: New views
3 Messages — Rating Filter:   Alert me  

Parent Message unknown Re: [Boost-users] Problem detecting python

by Juergen Hunold-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi ,

On Wednesday 30 September 2009, Christian O'Reilly wrote:
> I seem to have a problem similar to the one first spoke about in this
>  thread, however I have it with the version 1.4.0.I try co compile
>  boost_python library with MinGW under XP. Here is the command I use

> Notice that the informations obtained from the command '"E:\Program
> Files\pythonxy\python\python"
> -c "from sys import *; print
> 'version=%d.%d\nplatform=%s\nprefix=%s\nexec_prefix
> =%s\nexecutable=%s' %
> (version_info[0],version_info[1],platform,prefix,exec_pref
> ix,executable)" 2>&1'  are correct.

If you run it from the command line ?

> Any idea how to solve this?

>'"E:\Program Files\pythonxy\python\python"

This path contains spaces, which is most likely the problem here.
The quotes are added by the debug output, so I guess the path is not
quoted correctly.
Try setting up python manually in user-config.jam with

using python : : "E:/Program Files/pythonxy" ;

Note the quotes and the forward slashes.

In case you need more help, just follow up on the Boost.Build mailing
list.

Yours,

Jürgen
--
* Dipl.-Math. Jürgen Hunold       ! Ingenieurgesellschaft für
* voice: ++49 511 262926 57       ! Verkehrs- und Eisenbahnwesen mbH  
* fax  : ++49 511 262926 99       ! Lister Straße 15
* juergen.hunold@...        ! www.ivembh.de
*
* Geschäftsführer:                ! Sitz des Unternehmens: Hannover
* Prof. Dr.-Ing. Thomas Siefer    ! Amtsgericht Hannover, HRB 56965
* PD Dr.-Ing. Alfons Radtke       !

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost-build

Re: [Boost-users] Problem detecting python

by Christian O'Reilly :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message



> Notice that the informations obtained from the command '"E:\Program
> Files\pythonxy\python\python"
> -c "from sys import *; print
> 'version=%d.%d\nplatform=%s\nprefix=%s\nexec_prefix
> =%s\nexecutable=%s' %
> (version_info[0],version_info[1],platform,prefix,exec_pref
> ix,executable)" 2>&1'  are correct.

If you run it from the command line ?

Yes, from command line.

For example:

E:\PySide_dev\pyside-qt4.5+0.2>"E:/Program Files/pythonxy/python/python.exe" -c
"from sys import *; print 'version=%d.%d\nplateform=%s\nprefix=%s\nexec_prefixe=
%s\nexecutable=%s' % (version_info[0], version_info[1], platform, prefix, exec_p
refix, executable)"
version=2.5
plateform=win32
prefix=E:\Program Files\pythonxy\python
exec_prefixe=E:\Program Files\pythonxy\python
executable=E:\Program Files\pythonxy\python\python.exe

However, notice that :

E:\PySide_dev\pyside-qt4.5+0.2>DIR /-C /A:S "E:/Program Files/pythonxy/python/python.exe"
 Volume in drive E is DATA
 Volume Serial Number is E27E-E56C

 Directory of E:\Program Files\pythonxy\python

File Not Found


This path contains spaces, which is most likely the problem here.
The quotes are added by the debug output, so I guess the path is not
quoted correctly.
Try setting up python manually in user-config.jam with

using python : : "E:/Program Files/pythonxy" ;

Note the quotes and the forward slashes.


I tried with

using python : : "E:/Program Files/pythonxy" ;

and then with

using python : : "E:/Program Files/pythonxy/python/python.exe" ;

without any difference. I got as output

notice: Loading user-config configuration file user-config.jam from C:/Documents
 and Settings/chore/user-config.jam .
notice: [python-cfg] Configuring python...
notice: [python-cfg]   user-specified cmd-or-prefix: "E:/Program Files/pythonxy/
python/python.exe"
notice: [python-cfg] Checking interpreter command "E:/Program Files/pythonxy/pyt
hon/python.exe"...
notice: [python-cfg] running command 'DIR /-C /A:S "E:\Program Files\pythonxy\py
thon\python.exe" 2>&1'
notice: [python-cfg] running command '"E:/Program Files/pythonxy/python/python.e
xe" -c "from sys import *; print 'version=%d.%d\nplatform=%s\nprefix=%s\nexec_pr
efix=%s\nexecutable=%s' % (version_info[0],version_info[1],platform,prefix,exec_
prefix,executable)" 2>&1'
notice: [python-cfg] ...does not invoke a working interpreter
notice: [python-cfg] No working Python interpreter found.


Christian O'Reilly

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost-build

Re: [Boost-users] Problem detecting python

by Vladimir Prus :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Wednesday 30 September 2009 Christian O'Reilly wrote:

> I tried with
>
> using python : : "E:/Program Files/pythonxy" ;
>
> and then with
>
> using python : : "E:/Program Files/pythonxy/python/python.exe" ;
>
> without any difference. I got as output
>
> notice: Loading user-config configuration file user-config.jam from
> C:/Documents
>  and Settings/chore/user-config.jam .
> notice: [python-cfg] Configuring python...
> notice: [python-cfg]   user-specified cmd-or-prefix: "E:/Program
> Files/pythonxy/
> python/python.exe"
> notice: [python-cfg] Checking interpreter command "E:/Program
> Files/pythonxy/pyt
> hon/python.exe"...
> notice: [python-cfg] running command 'DIR /-C /A:S "E:\Program
> Files\pythonxy\py
> thon\python.exe" 2>&1'
> notice: [python-cfg] running command '"E:/Program
> Files/pythonxy/python/python.e
> xe" -c "from sys import *; print
> 'version=%d.%d\nplatform=%s\nprefix=%s\nexec_pr
> efix=%s\nexecutable=%s' %
> (version_info[0],version_info[1],platform,prefix,exec_
> prefix,executable)" 2>&1'
> notice: [python-cfg] ...does not invoke a working interpreter
> notice: [python-cfg] No working Python interpreter found.

Can you open tools/build/v2/tools/python.jam, and then find code
that goes like this:

        # Invoke Python and ask it for all those values.
        if [ version.check-jam-version 3 1 17 ] || ( [ os.name ] != NT )
        {
            # Prior to version 3.1.17 Boost Jam's SHELL command did not support
            # quoted commands correctly on Windows. This means that on that
            # platform we do not support using a Python command interpreter
            # executable whose path contains a space character.
            python-cmd = \"$(python-cmd)\" ;
        }

Then, remove it completely, and tell if that improves things. This is wild guess;
it might not help.

- Volodya
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost-build