Libjingle compilation problem

I downloaded and installed libjingle-0.5.2.zip, and according to README, I also downloaded and installed swtoolkit.0.9.1.zip, scons-local-2.1.0.alpha.201011212.tar.gz and expat -2.0.1 .tar.gz, and got nrtp cvs download. After overwriting my Makefile twice, trying to follow a rather poorly written README, I came up with the following Makefile, which almost works:

# First, make sure the SCONS_DIR environment variable is set correctly. SCONS_DIR ?= /usr/src/scons-local/scons-local-2.1.0.alpha.20101125/ #SCONS_DIR ?= /usr/src/scons-local/ export default: build # Second, run talk/third_party/expat-2.0.1/configure... talk/third_party/expat-2.0.1/Makefile: cd talk/third_party/expat-2.0.1 && ./configure # ...and talk/third_party/srtp/configure. talk/third_party/srtp/Makefile: cd talk/third_party/srtp && ./configure # Third, go to the talk/ directory and run $path_to_swtoolkit/hammer.sh. Run # $path_to_swtoolkit/hammer.sh --help for information on how to build for # different modes. build: talk/third_party/expat-2.0.1/Makefile talk/third_party/srtp/Makefile cd talk && ../../swtoolkit/hammer.sh help: ../swtoolkit/hammer.sh --help 

However, make gives me the following errors:

 jcomeau @ intrepid: /usr/src/libjingle-0.5.2$ make
 cd talk && ../../swtoolkit/hammer.sh
 *** Error loading site_init file './../../swtoolkit/site_scons/site_init.py':
 AttributeError: 'Dir' object has no attribute 'endswith':
   File "/usr/src/scons-local/scons-local-2.1.0.alpha.20101125/SCons/Script/Main.py", line 1338:
     _exec_main (parser, values)
   File "/usr/src/scons-local/scons-local-2.1.0.alpha.20101125/SCons/Script/Main.py", line 1302:
     _main (parser)
   File "/usr/src/scons-local/scons-local-2.1.0.alpha.20101125/SCons/Script/Main.py", line 929:
     _load_site_scons_dir (d.path, options.site_dir)
   File "/usr/src/scons-local/scons-local-2.1.0.alpha.20101125/SCons/Script/Main.py", line 719:
     exec fp in site_m
   File "./../../swtoolkit/site_scons/site_init.py", line 455:
     SiteInitMain ()
   File "./../../swtoolkit/site_scons/site_init.py", line 451:
     SCons.Node.FS.get_default_fs (). SConstruct_dir, None)
   File "/usr/src/scons-local/scons-local-2.1.0.alpha.20101125/SCons/Script/Main.py", line 677:
     site_dir = os.path.join (topdir, site_dir_name)
   File "/usr/lib/python2.6/posixpath.py", line 67:
     elif path == '' or path.endswith ('/'):
 make: *** [build] Error 2

I assume that something new (a Dir object where a POSIX path string is expected) in one of the packages breaks the build process, but which one? There are too many steepness layers for me to follow. Of course, I could just try to use the old packages, especially for swtoolkit and scons, but if someone here successfully compiled libjingle and could push me in the right direction, I would appreciate it.

+8
python google-code libjingle
source share
2 answers

I am not familiar with the project, but I think that I have a fix for you to pass by this moment. You need to drop these Dir instances using str() in swtoolkit / site_scons / site_init.py. Thus, they can be safely evaluated using path.endswith('/') . It is strange that such a problem will exist for a very long time in the main part of the construction infrastructure:

Line 330:

 SCons.Script.Main._load_site_scons_dir( str(SCons.Node.FS.get_default_fs().SConstruct_dir), site_dir) 

Line 450:

 SCons.Script.Main._load_site_scons_dir( str(SCons.Node.FS.get_default_fs().SConstruct_dir), None) 
+24
source share

I did the following to create libjingle:

Building LibJingle for Linux

  • How to create

Libjingle is built with swtoolkit ( http://code.google.com/p/swtoolkit/ ), which is a set of extensions to the open source SCS build tool ( http://www.scons.org ).

  • First install Python 2.4 or later http://www.python.org/ . Please note: since swtoolkit only works with Python 2.x, you will not be able to use Python 3.x.

  • Secondly, install the standalone scons-local package 2.0.0 or later from http://www.scons.org/download.php and set the environment variable, SCONS_DIR , to point to the directory containing SCons, for example, /src/libjingle/scons-local/scons-local-2.0.0.final.0/ .

  • Thirdly, install swtoolkit from http://code.google.com/p/swtoolkit/ .

  • Finally, Libjingle depends on two open source projects, expat and srtp. Download expat from http://sourceforge.net/projects/expat/ to talk / THIRD_PARTY / expat 2.0.1 /. Follow the instructions at http://sourceforge.net/projects/srtp/develop to download the latest srtp for talk / THIRD _PARTY / SRTP. Please note that srtp-1.4.4 does not work, as it skips the extensions used by Libjingle. If you put expat or srtp in another directory, you need to edit talk/libjingle.scons accordingly.

2.1 Building Libjingle on Linux or OS X

  • First, make sure the SCONS_DIR environment SCONS_DIR set correctly.
  • Secondly, run talk/third_party/expat-2.0.1/configure and talk/third_party/srtp/configure .
  • Third, go to the talk / folder and run $path_to_swtoolkit/hammer.sh . Run $path_to_swtoolkit/hammer.sh --help for information on how the various modes are.

In addition to the above steps, see the link

Set the path SCONS_DIR

 export SCONS_DIR=/home/esumit/libjingle/libjingle-0.5.2/talk/third_party/scons-local/scons-local-2.0.1 

Install libasound2-dev Lib to compile libJingle, otherwise you will encounter errors.

 sudo apt-get install libasound2-dev 

Download SRTP using the following command. If it asks for passowrd, just press Enter.

 cvs -z3 -d:pserver:anonymous@srtp.cvs.sourceforge.net:/cvsroot/srtp co -P srtp 

Possible components in the LibJingle catalog

 libjingle-0.5.2/talk/third_party$ ls expat-2.0.1 libudev scons-local srtp swtoolkit 

Run the following command to build LibJingle

 libjingle-0.5.2/talk$ ./third_party/swtoolkit/hammer.sh 
+3
source share

All Articles