Skip to content

scons install display=1 failed against latest code  #109

Open
@wanghaisheng

Description

@wanghaisheng
data-clear@dataclear:~/dev/ocr/clstm$ scons
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
g++ --std=c++11 -Wno-unused-result -o clstmfilter.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstmfilter.cc
g++ --std=c++11 -Wno-unused-result -o clstm.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstm.cc
g++ --std=c++11 -Wno-unused-result -o ctc.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 ctc.cc
protoc(["clstm", "clstm.pb.cc", "clstm.pb.h"], ["clstm.proto"])
g++ --std=c++11 -Wno-unused-result -o clstm_proto.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstm_proto.cc
g++ --std=c++11 -Wno-unused-result -o clstm_prefab.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstm_prefab.cc
g++ --std=c++11 -Wno-unused-result -o tensor.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 tensor.cc
g++ --std=c++11 -Wno-unused-result -o batches.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 batches.cc
g++ --std=c++11 -Wno-unused-result -o extras.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 extras.cc
g++ --std=c++11 -Wno-unused-result -o clstm.pb.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstm.pb.cc
g++ --std=c++11 -Wno-unused-result -o clstm_compute.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstm_compute.cc
ar rc libclstm.a clstm.o ctc.o clstm_proto.o clstm_prefab.o tensor.o batches.o extras.o clstm.pb.o clstm_compute.o
ranlib libclstm.a
g++ --std=c++11 -Wno-unused-result -o clstmfilter clstmfilter.o libclstm.a -lpng -lprotobuf
g++ --std=c++11 -Wno-unused-result -o clstmfiltertrain.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstmfiltertrain.cc
g++ --std=c++11 -Wno-unused-result -o clstmfiltertrain clstmfiltertrain.o libclstm.a -lpng -lprotobuf
g++ --std=c++11 -Wno-unused-result -o clstmocr.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstmocr.cc
g++ --std=c++11 -Wno-unused-result -o clstmocr clstmocr.o libclstm.a -lpng -lprotobuf
g++ --std=c++11 -Wno-unused-result -o clstmocrtrain.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstmocrtrain.cc
g++ --std=c++11 -Wno-unused-result -o clstmocrtrain clstmocrtrain.o libclstm.a -lpng -lprotobuf
scons: done building targets.
data-clear@dataclear:~/dev/ocr/clstm$ sudo scons install  display=1
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
g++ --std=c++11 -Wno-unused-result -o clstm.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DTHROW=throw -DTRY=try -Dadd_raw=add -I/usr/local/include/eigen3 clstm.cc
g++ --std=c++11 -Wno-unused-result -o ctc.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DTHROW=throw -DTRY=try -Dadd_raw=add -I/usr/local/include/eigen3 ctc.cc
protoc(["clstm", "clstm.pb.cc", "clstm.pb.h"], ["clstm.proto"])
g++ --std=c++11 -Wno-unused-result -o clstm_proto.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DTHROW=throw -DTRY=try -Dadd_raw=add -I/usr/local/include/eigen3 clstm_proto.cc
g++ --std=c++11 -Wno-unused-result -o clstm_prefab.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DTHROW=throw -DTRY=try -Dadd_raw=add -I/usr/local/include/eigen3 clstm_prefab.cc
g++ --std=c++11 -Wno-unused-result -o tensor.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DTHROW=throw -DTRY=try -Dadd_raw=add -I/usr/local/include/eigen3 tensor.cc
g++ --std=c++11 -Wno-unused-result -o batches.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DTHROW=throw -DTRY=try -Dadd_raw=add -I/usr/local/include/eigen3 batches.cc
g++ --std=c++11 -Wno-unused-result -o extras.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DTHROW=throw -DTRY=try -Dadd_raw=add -I/usr/local/include/eigen3 extras.cc
In file included from extras.cc:42:0:
pytensor.h: In member function 'void pytensor::PyServer::plot(pytensor::Tensor<float, 1ul>&, std::__cxx11::string)':
pytensor.h:155:54: error: no matching function for call to 'pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<float, 1ul>&)'
     eval(stringf("plot(farg(1)%s)", extra.c_str()), v);
                                                      ^
pytensor.h:88:10: note: candidate: std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string)
   string eval(string s) {
          ^
pytensor.h:88:10: note:   candidate expects 1 argument, 2 provided
pytensor.h:108:10: note: candidate: template<class T, long unsigned int n> std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<T, n>&)
   string eval(string s, Tensor<T, n> &a) {
          ^
pytensor.h:108:10: note:   template argument deduction/substitution failed:
pytensor.h:155:54: note:   mismatched types 'long unsigned int' and 'int'
     eval(stringf("plot(farg(1)%s)", extra.c_str()), v);
                                                      ^
pytensor.h:155:54: note:   'pytensor::Tensor<float, 1ul> {aka Eigen::Tensor<float, 1>}' is not derived from 'pytensor::Tensor<T, n>'
pytensor.h:124:10: note: candidate: template<class T, long unsigned int n, class S, long unsigned int m> std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<T, n>&, pytensor::Tensor<S, m>&)
   string eval(string s, Tensor<T, n> &a, Tensor<S, m> &b) {
          ^
pytensor.h:124:10: note:   template argument deduction/substitution failed:
pytensor.h:155:54: note:   mismatched types 'long unsigned int' and 'int'
     eval(stringf("plot(farg(1)%s)", extra.c_str()), v);
                                                      ^
pytensor.h:155:54: note:   'pytensor::Tensor<float, 1ul> {aka Eigen::Tensor<float, 1>}' is not derived from 'pytensor::Tensor<T, n>'
pytensor.h: In member function 'void pytensor::PyServer::plot2(pytensor::Tensor<float, 1ul>&, pytensor::Tensor<float, 1ul>&, std::__cxx11::string)':
pytensor.h:161:65: error: no matching function for call to 'pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<float, 1ul>&, pytensor::Tensor<float, 1ul>&)'
     eval(stringf("plot(farg(1),farg(2)%s)", extra.c_str()), u, v);
                                                                 ^
pytensor.h:88:10: note: candidate: std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string)
   string eval(string s) {
          ^
pytensor.h:88:10: note:   candidate expects 1 argument, 3 provided
pytensor.h:108:10: note: candidate: template<class T, long unsigned int n> std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<T, n>&)
   string eval(string s, Tensor<T, n> &a) {
          ^
pytensor.h:108:10: note:   template argument deduction/substitution failed:
pytensor.h:161:65: note:   mismatched types 'long unsigned int' and 'int'
     eval(stringf("plot(farg(1),farg(2)%s)", extra.c_str()), u, v);
                                                                 ^
pytensor.h:161:65: note:   'pytensor::Tensor<float, 1ul> {aka Eigen::Tensor<float, 1>}' is not derived from 'pytensor::Tensor<T, n>'
pytensor.h:124:10: note: candidate: template<class T, long unsigned int n, class S, long unsigned int m> std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<T, n>&, pytensor::Tensor<S, m>&)
   string eval(string s, Tensor<T, n> &a, Tensor<S, m> &b) {
          ^
pytensor.h:124:10: note:   template argument deduction/substitution failed:
pytensor.h:161:65: note:   mismatched types 'long unsigned int' and 'int'
     eval(stringf("plot(farg(1),farg(2)%s)", extra.c_str()), u, v);
                                                                 ^
pytensor.h:161:65: note:   'pytensor::Tensor<float, 1ul> {aka Eigen::Tensor<float, 1>}' is not derived from 'pytensor::Tensor<T, n>'
pytensor.h: In member function 'void pytensor::PyServer::imshow(pytensor::Tensor<float, 2ul>&, std::__cxx11::string)':
pytensor.h:167:11: error: no matching function for call to 'pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<float, 2ul>&)'
          a);
           ^
pytensor.h:88:10: note: candidate: std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string)
   string eval(string s) {
          ^
pytensor.h:88:10: note:   candidate expects 1 argument, 2 provided
pytensor.h:108:10: note: candidate: template<class T, long unsigned int n> std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<T, n>&)
   string eval(string s, Tensor<T, n> &a) {
          ^
pytensor.h:108:10: note:   template argument deduction/substitution failed:
pytensor.h:167:11: note:   mismatched types 'long unsigned int' and 'int'
          a);
           ^
pytensor.h:167:11: note:   'pytensor::Tensor<float, 2ul> {aka Eigen::Tensor<float, 2>}' is not derived from 'pytensor::Tensor<T, n>'
pytensor.h:124:10: note: candidate: template<class T, long unsigned int n, class S, long unsigned int m> std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<T, n>&, pytensor::Tensor<S, m>&)
   string eval(string s, Tensor<T, n> &a, Tensor<S, m> &b) {
          ^
pytensor.h:124:10: note:   template argument deduction/substitution failed:
pytensor.h:167:11: note:   mismatched types 'long unsigned int' and 'int'
          a);
           ^
pytensor.h:167:11: note:   'pytensor::Tensor<float, 2ul> {aka Eigen::Tensor<float, 2>}' is not derived from 'pytensor::Tensor<T, n>'
pytensor.h: In member function 'void pytensor::PyServer::imshowT(pytensor::Tensor<float, 2ul>&, std::__cxx11::string)':
pytensor.h:173:11: error: no matching function for call to 'pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<float, 2ul>&)'
          a);
           ^
pytensor.h:88:10: note: candidate: std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string)
   string eval(string s) {
          ^
pytensor.h:88:10: note:   candidate expects 1 argument, 2 provided
pytensor.h:108:10: note: candidate: template<class T, long unsigned int n> std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<T, n>&)
   string eval(string s, Tensor<T, n> &a) {
          ^
pytensor.h:108:10: note:   template argument deduction/substitution failed:
pytensor.h:173:11: note:   mismatched types 'long unsigned int' and 'int'
          a);
           ^
pytensor.h:173:11: note:   'pytensor::Tensor<float, 2ul> {aka Eigen::Tensor<float, 2>}' is not derived from 'pytensor::Tensor<T, n>'
pytensor.h:124:10: note: candidate: template<class T, long unsigned int n, class S, long unsigned int m> std::__cxx11::string pytensor::PyServer::eval(std::__cxx11::string, pytensor::Tensor<T, n>&, pytensor::Tensor<S, m>&)
   string eval(string s, Tensor<T, n> &a, Tensor<S, m> &b) {
          ^
pytensor.h:124:10: note:   template argument deduction/substitution failed:
pytensor.h:173:11: note:   mismatched types 'long unsigned int' and 'int'
          a);
           ^
pytensor.h:173:11: note:   'pytensor::Tensor<float, 2ul> {aka Eigen::Tensor<float, 2>}' is not derived from 'pytensor::Tensor<T, n>'
scons: *** [extras.o] Error 1
scons: building terminated because of errors.

but **scons install ** is ok

data-clear@dataclear:~/dev/ocr/clstm$ python setup.py build
PY_CORE_CFLAGS -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security   -I. -IInclude -I../Include -fPIC -DPy_BUILD_CORE
LDCXXSHARED c++ -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions
BLDSHARED x86_64-linux-gnu-gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-Bsymbolic-functions -Wl,-z,relro -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security  
LDFLAGS -Wl,-Bsymbolic-functions -Wl,-z,relro
TESTPYTHON LD_LIBRARY_PATH=/build/python2.7-M_HuAO/python2.7-2.7.12/build-shared ./python -Wd -3 -E -tt
CONFIG_ARGS '--enable-shared' '--prefix=/usr' '--enable-ipv6' '--enable-unicode=ucs4' '--with-dbmliborder=bdb:gdbm' '--with-system-expat' '--with-computed-gotos' '--with-system-ffi' '--with-fpectl' 'CC=x86_64-linux-gnu-gcc' 'CFLAGS=-Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security ' 'LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro'
CONFIGURE_CFLAGS -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security
LDSHARED x86_64-linux-gnu-gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-Bsymbolic-functions -Wl,-z,relro -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security  
CONFIGURE_LDFLAGS -Wl,-Bsymbolic-functions -Wl,-z,relro
OPT -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
PY_LDFLAGS -Wl,-Bsymbolic-functions -Wl,-z,relro
LINKFORSHARED -Xlinker -export-dynamic -Wl,-O1 -Wl,-Bsymbolic-functions
PY_CFLAGS -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security  
CFLAGS -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security  
sh: 1: swig: not found
running build
running build_py
file clstm.py (for module clstm) not found
file clstm.py (for module clstm) not found
running build_ext
building '_clstm' extension
swigging clstm.i to clstm_wrap.cpp
swig -python -c++ -I/usr/include/eigen3 -I/usr/local/include/eigen3 -I/usr/local/include -I/usr/include/hdf5/serial -I/usr/lib/python2.7/dist-packages/numpy/core/include -o clstm_wrap.cpp clstm.i
unable to execute 'swig': No such file or directory
error: command 'swig' failed with exit status 1
data-clear@dataclear:~/dev/ocr/clstm$ sudo scons install  
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
g++ --std=c++11 -Wno-unused-result -o clstm.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstm.cc
g++ --std=c++11 -Wno-unused-result -o ctc.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 ctc.cc
protoc(["clstm", "clstm.pb.cc", "clstm.pb.h"], ["clstm.proto"])
g++ --std=c++11 -Wno-unused-result -o clstm_proto.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstm_proto.cc
g++ --std=c++11 -Wno-unused-result -o clstm_prefab.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 clstm_prefab.cc
g++ --std=c++11 -Wno-unused-result -o tensor.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 tensor.cc
g++ --std=c++11 -Wno-unused-result -o batches.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 batches.cc
g++ --std=c++11 -Wno-unused-result -o extras.o -c -g -O3 -DEIGEN_NO_DEBUG -DCATCH=catch -DCLSTM_ALL_TENSOR=1 -DNODISPLAY=1 -DTHROW=throw -DTRY=try -I/usr/local/include/eigen3 extras.cc
Install file: "libclstm.a" as "/usr/local/lib/libclstm.a"
Install file: "clstm.h" as "/usr/local/include/clstm.h"
scons: done building targets.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions