3

When compiling libjingle, on running the 'hammer.sh' on the swtoolkit, i get the following import error,

root@den-pc:~/tejesh/libjingle-0.6.14/talk# sh ../../swtoolkit/hammer.sh
Traceback (most recent call last):
File "../../swtoolkit/wrapper.py", line 44, in <module>
import SCons.Script
ImportError: No module named SCons.Script

so how do i fix this import error... any suggestions?

i already setup the environment variables for scons (SCONS_DIR) and have all the libraries installed..

2 Answers2

4

If you have SCons correctly installed, then it sounds like a problem with python not being able to find it. In addition to the SCONS_DIR environment variable, try including the SCons location in the PYTHONPATH environment variable.

Brady
  • 10,207
  • 2
  • 20
  • 59
  • yeah.. ... sorry did'nt see that voting part before :D – wolfgang May 30 '12 at 14:36
  • I don't understand this advice. Are you suggesting create a new environment variable called "PYTHONPATH" and set it to the location of the SCons installation? Who knows... –  Nov 22 '12 at 15:22
  • @infact "PYTHONPATH" is definitely not a new environment variable, but rather something supported by Python to look for modules. The libjingle scripts were not finding SCons, so Im suggesting a standard way to find it: http://docs.python.org/2/tutorial/modules.html#the-module-search-path – Brady Nov 22 '12 at 20:00
  • @infact, I would appreciate a response, please. Was your down vote because you disagree with my answer? (even though my answer actually helped the OP) If so, can you suggest a better way than using the standard PYTHONPATH variable? If not, then please remove the down vote. – Brady Nov 29 '12 at 07:28
0

when you install scons,in the README file,you can use:

 # python setup.py install --standalone-lib

that can make scons modules into pythonpath.

cz000
  • 1
  • 3