[Python] rule python-extension unknown
Boost Users, I am trying to build the Hello World python example. When I execute bjam I get the "rule python-extension unknown" error. I believe this to be because my user-config.jam file is never being used. The tutorial states to configure the rules in the user-config.jam file in my home directory. My home directory is "C:\Documents and Settings\robert.machardy". I did not find the file there, and this does not appear to be the place for jam files. I found the file user-config.jam in "C:\Program Files\boost\boost_1_36_0\tools\build\v2", I edited it and copied to my home directory. I configured it for the following: # Configure specific msvc version (searched for in standard locations and PATH). using msvc : 7.1 ; using python : 2.6 : C:\Program Files\Python26; Please help. Thank you, Robert MacHardy
AMDG Robert MacHardy wrote:
I am trying to build the Hello World python example. When I execute bjam I get the “rule python-extension unknown” error. I believe this to be because my user-config.jam file is never being used.
Try running bjam with --debug-configuration. That should tell you which user-config.jam is used. In Christ, Steven Watanabe
Boost Users, I am still getting the rule python-extension unknown error. Bjam is using the user-config.jam file in "C:\Program Files\boost\boost_1_36_0\tools\build\v2". I have the file configured as follows: using msvc : 7.1 ; using python : 2.6 : "C:/Program Files/Python26"; I have tried configuring the file like this with and without the quotation marks, forward slashes, backslashes, a trailing slash in the "using python" line. If I put a directory that doesn't even exist in the "using python" line, nothing changes, which I would hope to see a crash on that. Please help. Thank you, Robert MacHardy -----Original Message----- From: boost-users-bounces@lists.boost.org [mailto:boost-users-bounces@lists.boost.org] On Behalf Of Steven Watanabe Sent: Thursday, October 09, 2008 12:04 PM To: boost-users@lists.boost.org Subject: Re: [Boost-users] [Python] rule python-extension unknown AMDG Robert MacHardy wrote:
I am trying to build the Hello World python example. When I execute bjam I get the "rule python-extension unknown" error. I believe this to be because my user-config.jam file is never being used.
Try running bjam with --debug-configuration. That should tell you which user-config.jam is used. In Christ, Steven Watanabe _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
Robert MacHardy wrote:
Boost Users,
I am still getting the rule python-extension unknown error. Bjam is using the user-config.jam file in "C:\Program Files\boost\boost_1_36_0\tools\build\v2". I have the file configured as follows:
using msvc : 7.1 ; using python : 2.6 : "C:/Program Files/Python26";
I have tried configuring the file like this with and without the quotation marks, forward slashes, backslashes, a trailing slash in the "using python" line. If I put a directory that doesn't even exist in the "using python" line, nothing changes, which I would hope to see a crash on that.
Please help.
Steven gave you a concrete suggestion. Did you follow it? - Volodya
[mailto:boost-users-bounces@lists.boost.org] On Behalf Of Steven Watanabe Try running bjam with --debug-configuration. That should tell you which user-config.jam is used.
AMDG Robert MacHardy wrote:
Boost Users,
I am still getting the rule python-extension unknown error. Bjam is using the user-config.jam file in "C:\Program Files\boost\boost_1_36_0\tools\build\v2". I have the file configured as follows:
using msvc : 7.1 ; using python : 2.6 : "C:/Program Files/Python26";
I have tried configuring the file like this with and without the quotation marks, forward slashes, backslashes, a trailing slash in the "using python" line. If I put a directory that doesn't even exist in the "using python" line, nothing changes, which I would hope to see a crash on that.
I presume that you are running bjam from C:\Program Files\boost\boost_1_36_0\libs\python\example\tutorial What exactly is the command that you are using? Can you post the output with --debug-configuration? The relevant line in my user-config.jam is using python : 2.5 : "C:/Program Files/Python25" ; So your python initialization should work. In Christ, Steven Watanabe
Boost Users, I put bjam.exe in "C:\Program Files\boost\boost_1_36_0\bin" and added that to the PATH environment variable. I have been trying to execute (bjam --debug-configuration). The output is as follows: C:\Program Files\boost\boost_1_36_0\libs\python\example\tutorial>bjam --debug-co nfiguration notice: found boost-build.jam at C:/Program Files/boost/boost_1_36_0/libs/python /example/boost-build.jam notice: loading Boost.Build from C:/Program Files/boost/boost_1_36_0/tools/build /v2 notice: Searching C:\WINDOWS C:\Documents and Settings\robert.machardy C:\Docume nts and Settings\robert.machardy C:\Program Files\boost\boost_1_36_0\libs\python \example\../../../tools/build/v2 C:/Program Files/boost/boost_1_36_0/tools/build /v2/kernel C:/Program Files/boost/boost_1_36_0/tools/build/v2/util C:/Program Fi les/boost/boost_1_36_0/tools/build/v2/build C:/Program Files/boost/boost_1_36_0/ tools/build/v2/tools C:/Program Files/boost/boost_1_36_0/tools/build/v2/contrib C:/Program Files/boost/boost_1_36_0/tools/build/v2/. for site-config configurati on file site-config.jam . notice: Loading site-config configuration file site-config.jam from C:/Program F iles/boost/boost_1_36_0/tools/build/v2/site-config.jam . notice: Searching C:\Documents and Settings\robert.machardy C:\Documents and Set tings\robert.machardy C:\Program Files\boost\boost_1_36_0\libs\python\example\.. /../../tools/build/v2 C:/Program Files/boost/boost_1_36_0/tools/build/v2/kernel C:/Program Files/boost/boost_1_36_0/tools/build/v2/util C:/Program Files/boost/b oost_1_36_0/tools/build/v2/build C:/Program Files/boost/boost_1_36_0/tools/build /v2/tools C:/Program Files/boost/boost_1_36_0/tools/build/v2/contrib C:/Program Files/boost/boost_1_36_0/tools/build/v2/. for user-config configuration file use r-config.jam . notice: Loading user-config configuration file user-config.jam from C:/Program F iles/boost/boost_1_36_0/tools/build/v2/user-config.jam . syntax error at EOF Jamroot:18: in modules.load rule python-extension unknown in module Jamfile. C:/Program Files/boost/boost_1_36_0/tools/build/v2/build\project.jam:309: in loa d-jamfile C:/Program Files/boost/boost_1_36_0/tools/build/v2/build\project.jam:62: in load C:/Program Files/boost/boost_1_36_0/tools/build/v2/build\project.jam:169: in pro ject.find C:/Program Files/boost/boost_1_36_0/tools/build/v2\build-system.jam:521: in load C:\Program Files\boost\boost_1_36_0\libs\python\example\..\..\..\tools\build\v2/ kernel\modules.jam:281: in import C:\Program Files\boost\boost_1_36_0\libs\python\example\..\..\..\tools\build\v2/ kernel/bootstrap.jam:128: in boost-build C:\Program Files\boost\boost_1_36_0\libs\python\example\boost-build.jam:7: in mo dule scope Thank you, Robert MacHardy -----Original Message----- From: boost-users-bounces@lists.boost.org [mailto:boost-users-bounces@lists.boost.org] On Behalf Of Steven Watanabe Sent: Thursday, October 09, 2008 12:54 PM To: boost-users@lists.boost.org Subject: Re: [Boost-users] [Python] rule python-extension unknown AMDG Robert MacHardy wrote:
Boost Users,
I am still getting the rule python-extension unknown error. Bjam is using the user-config.jam file in "C:\Program Files\boost\boost_1_36_0\tools\build\v2". I have the file configured as follows:
using msvc : 7.1 ; using python : 2.6 : "C:/Program Files/Python26";
I have tried configuring the file like this with and without the quotation marks, forward slashes, backslashes, a trailing slash in the "using python" line. If I put a directory that doesn't even exist in the "using python" line, nothing changes, which I would hope to see a crash on that.
I presume that you are running bjam from C:\Program Files\boost\boost_1_36_0\libs\python\example\tutorial What exactly is the command that you are using? Can you post the output with --debug-configuration? The relevant line in my user-config.jam is using python : 2.5 : "C:/Program Files/Python25" ; So your python initialization should work. In Christ, Steven Watanabe _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
Robert MacHardy wrote:
Boost Users,
I put bjam.exe in "C:\Program Files\boost\boost_1_36_0\bin" and added that to the PATH environment variable. I have been trying to execute (bjam --debug-configuration). The output is as follows:
C:\Program Files\boost\boost_1_36_0\libs\python\example\tutorial>bjam --debug-co nfiguration notice: found boost-build.jam at C:/Program Files/boost/boost_1_36_0/libs/python /example/boost-build.jam notice: loading Boost.Build from C:/Program Files/boost/boost_1_36_0/tools/build /v2 notice: Searching C:\WINDOWS C:\Documents and Settings\robert.machardy C:\Docume nts and Settings\robert.machardy C:\Program Files\boost\boost_1_36_0\libs\python \example\../../../tools/build/v2 C:/Program Files/boost/boost_1_36_0/tools/build /v2/kernel C:/Program Files/boost/boost_1_36_0/tools/build/v2/util C:/Program Fi les/boost/boost_1_36_0/tools/build/v2/build C:/Program Files/boost/boost_1_36_0/ tools/build/v2/tools C:/Program Files/boost/boost_1_36_0/tools/build/v2/contrib C:/Program Files/boost/boost_1_36_0/tools/build/v2/. for site-config configurati on file site-config.jam . notice: Loading site-config configuration file site-config.jam from C:/Program F iles/boost/boost_1_36_0/tools/build/v2/site-config.jam . notice: Searching C:\Documents and Settings\robert.machardy C:\Documents and Set tings\robert.machardy C:\Program Files\boost\boost_1_36_0\libs\python\example\.. /../../tools/build/v2 C:/Program Files/boost/boost_1_36_0/tools/build/v2/kernel C:/Program Files/boost/boost_1_36_0/tools/build/v2/util C:/Program Files/boost/b oost_1_36_0/tools/build/v2/build C:/Program Files/boost/boost_1_36_0/tools/build /v2/tools C:/Program Files/boost/boost_1_36_0/tools/build/v2/contrib C:/Program Files/boost/boost_1_36_0/tools/build/v2/. for user-config configuration file use r-config.jam . notice: Loading user-config configuration file user-config.jam from C:/Program F iles/boost/boost_1_36_0/tools/build/v2/user-config.jam . syntax error at EOF
You are told that there's syntax error in your user-config. You have: using msvc : 7.1 ; using python : 2.6 : "C:/Program Files/Python26"; and there's missing space before the semicolon at second line. - Volodya
on Thu Oct 09 2008, "Robert MacHardy"
Boost Users,
I am trying to build the Hello World python example. When I execute bjam I get the “rule python-extension unknown” error. I believe this to be because my user-config.jam file is never being used.
It might be. What happens if you add import python python-extension ; at the top of your Jamroot?
The tutorial states to configure the rules in the user-config.jam file in my home directory. My home directory is “C:\ Documents and Settings\robert.machardy”. I did not find the file there, and this does not appear to be the place for jam files. I found the file user-config.jam in “C:\Program Files\boost\boost_1_36_0\tools\build\v2”, I edited it and copied to my home directory. I configured it for the following:
# Configure specific msvc version (searched for in standard locations and PATH).
using msvc : 7.1 ;
using python : 2.6 : C:\Program Files\Python26;
You need quotes around the path to python, and you either need to double the backslashes, or simply use forward slashes. using python : 2.6 : "C:/Program Files/Python26" would be correct, although to be frank you probably don't need that line at all; Boost.Build's autoconfig should take care of it for you. If that works out for you, try undoing the change I suggested at the top; the less cruft, the better ;-) HTH, -- Dave Abrahams BoostPro Computing http://www.boostpro.com
participants (4)
-
David Abrahams
-
Robert MacHardy
-
Steven Watanabe
-
Vladimir Prus