0

I'm trying to build jsoncpp library in redhat with scons. I follow the instructions but get no result. I first install scons, then download the library source, decompress it and enter the directory.

Once in the library folder I've tried several options: 1)

jsoncpp-src-0.5.0 > scons SConstruct platform=linux-gcc
scons: Reading SConscript files ...
Using platform 'linux-gcc-4.8.1'
LD_LIBRARY_PATH = /work/gcsadm/ext/ACE+TAO/lib/linux:/work/dguerra/tests/lib/linux:/work/dguerra/examples/lib/linux:/work/dguerra/lib/linux:/work/gcsadm/lib/linux:/usr/local/lib64:/usr/lib64:/work/gcsadm/ext/CorbaScript/lib:/usr/local/ostoreBase/ostore/lib:/work/gcsadm/ext/gsl/lib/linux:/work/gcsadm/ext/fitsio/lib/linux:/work/gcsadm/ext/sla/lib/linux:/work/gcsadm/ext/wcs/lib/linux:/work/gcsadm/ext/xpa/lib/linux:/work/gcsadm/ext/tcsPK/lib/linux:/work/gcsadm/ext/jsoncpp/lib/linux:/work/gcsadm/ext/mysql-connector/lib/linux:/usr/local/bin:libs/linux-gcc-4.8.1
Building using PLATFORM = linux-gcc-4.8.1
scons: done reading SConscript files.
scons: Building targets ...
scons: Nothing to be done for `SConstruct'.
scons: done building targets.

2)

jsoncpp-src-0.5.0 > scons platform=linux-gcc
scons: Reading SConscript files ...
Using platform 'linux-gcc-4.8.1'
LD_LIBRARY_PATH = /work/gcsadm/ext/ACE+TAO/lib/linux:/work/dguerra/tests/lib/linux:/work/dguerra/examples/lib/linux:/work/dguerra/lib/linux:/work/gcsadm/lib/linux:/usr/local/lib64:/usr/lib64:/work/gcsadm/ext/CorbaScript/lib:/usr/local/ostoreBase/ostore/lib:/work/gcsadm/ext/gsl/lib/linux:/work/gcsadm/ext/fitsio/lib/linux:/work/gcsadm/ext/sla/lib/linux:/work/gcsadm/ext/wcs/lib/linux:/work/gcsadm/ext/xpa/lib/linux:/work/gcsadm/ext/tcsPK/lib/linux:/work/gcsadm/ext/jsoncpp/lib/linux:/work/gcsadm/ext/mysql-connector/lib/linux:/usr/local/bin:libs/linux-gcc-4.8.1
Building using PLATFORM = linux-gcc-4.8.1
scons: done reading SConscript files.
scons: Building targets ...
g++ -o buildscons/linux-gcc-4.8.1/src/jsontestrunner/main.o -c - W a l l -Iinclude -I. src/jsontestrunner/main.cpp
g++: error: W: No such file or directory
g++: error: a: No such file or directory
g++: error: l: No such file or directory
g++: error: l: No such file or directory
scons: *** [buildscons/linux-gcc-4.8.1/src/jsontestrunner/main.o] Error 1
scons: building terminated because of errors.

Any help would be greatly appreciated.

  • What version of Python are you using? The problem is a simple one, but Im not sure what would cause it: The compiler arg '-W a l l' is being used, when it should be '-Wall' (no spaces) I remember seeing something similar due to using an old Python version. – Brady Dec 18 '13 at 10:58
  • I'm using Python 2.7.5 – dguerra Dec 18 '13 at 11:01
  • Just in case someone stumble upon the same problem. You may want to try the CMake build instead of scons (in svn trunk). It is what is being used by the continuous integration on Travis-CI: https://travis-ci.org/blep/jsoncpp-mirror Intall cmake tool in your machine. Check out the last version of jsoncpp from the above repository. Enter jsoncpp directory, to create Makefile, write: cmake . After that, open CMakeCache.txt for edition, and set ON the following: //Build jsoncpp_lib as a shared library. JSONCPP_LIB_BUILD_SHARED:BOOL=ON And finally build the library: make – dguerra Dec 18 '13 at 15:58

1 Answers1

0

The '- W a l l' indicates that some string with content '-Wall' should have been passed as a array [ '-Wall' ]

vrdhn
  • 4,024
  • 3
  • 31
  • 39