University of Southern CaliforniaUSC
USC ICT TwitterUSC ICT FacebookUSC ICT YouTube

Ubuntu 16.04 build make failes 'vhmsg.cpp.o' | General SmartBody Discussion | Forum

Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
Ubuntu 16.04 build make failes 'vhmsg.cpp.o'
August 23, 2017
12:25 am
Avatar
New Member
Members
Forum Posts: 1
Member Since:
August 23, 2017
sp_UserOfflineSmall Offline

I'm trying to make SmartBody, but `make install` is failing:

make install
Scanning dependencies of target vhcl
[ 0%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/Pow2Assert.cpp.o
[ 0%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/vhcl_audio.cpp.o
[ 0%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/vhcl_crash.cpp.o
[ 0%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/vhcl_log.cpp.o
[ 0%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/vhcl_math.cpp.o
[ 0%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/vhcl_memory.cpp.o
[ 1%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/vhcl_socket.cpp.o
[ 1%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/vhcl_string.cpp.o
[ 1%] Building CXX object src/vhcl/CMakeFiles/vhcl.dir/vhcl_timer.cpp.o
[ 1%] Linking CXX static library libvhcl.a
[ 1%] Built target vhcl
Scanning dependencies of target vhmsg
[ 1%] Building CXX object src/vhmsg/CMakeFiles/vhmsg.dir/HttpUtility.cpp.o
[ 1%] Building CXX object src/vhmsg/CMakeFiles/vhmsg.dir/vhmsg.cpp.o
/home/user/smartbody/src/vhmsg/vhmsg.cpp:45:42: fatal error: activemq/library/ActiveMQCPP.h: No such file or directory
#include <activemq/library/ActiveMQCPP.h>
^
compilation terminated.
src/vhmsg/CMakeFiles/vhmsg.dir/build.make:86: recipe for target 'src/vhmsg/CMakeFiles/vhmsg.dir/vhmsg.cpp.o' failed
make[2]: *** [src/vhmsg/CMakeFiles/vhmsg.dir/vhmsg.cpp.o] Error 1
CMakeFiles/Makefile2:182: recipe for target 'src/vhmsg/CMakeFiles/vhmsg.dir/all' failed
make[1]: *** [src/vhmsg/CMakeFiles/vhmsg.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

 

What I did so far:
I downloaded `SmartBodySDK-r6296-linux.tar.gz` from here:
https://sourceforge.net/projects/smartbody/files/?source=navbar

First I followed the instructions from here:
http://smartbody.ict.usc.edu/HTML/documentation/SB/Building-SmartBody-for-Linux_8552488.html

I installed Ogre through the Ubuntu Software Center as a snap by searching with `ogre`, version 1.10.7 (current latest version, except for 2.1, which made some big changes).

But I found out that the `README.txt` in `SmartBodySDK-r6296-linux.tar.gz` was slightly newer.
I ran the following commands (as instructed and I didn't change the file `src/CMakeLists.txt`):

./linuxlibsbuild.sh
mkdir mybuild
cd mybuild
cmake ..
make install

 

# EDIT

I tried `sudo apt-get install activemq`, which installed something, but doing again:
cmake ..
make install
Didn't help

I'm trying to follow the instructions from here:
http://smartbody.ict.usc.edu/forum/general/building-error-on-both-ubuntu-12-0432bits-and-12-1064bits

However, I don't have a `vhmsg` folder in `lib/vhmsg/vhmsg-c/CMakeList.txt`.

# EDIT 2

Apparently `sudo apt-get install activemq` installed activemq v5.13.2,
but included in the dependencies in SmartBody is v3.9.0 (smartbody/dependencies/activemq-cpp-library-3.9.0).
Maybe this is too old for Ubuntu 16.04?

 

Any insights in why this is failing is greatly appreciated.

 

# EDIT 3 SOLVED vhmsg, but next problem protoc

When only building activemq (comment everything out in linuxlibsbuild.sh except activemq), there appears an OpenSSL error:
https://pastebin.com/bMvuVC4n

This is solved by doing (which installs openssl-dev):
sudo apt-get install libssl-dev

# protec

Scanning dependencies of target assimp
[ 9%] Building CXX object src/assimp-3.1.1/CMakeFiles/assimp.dir/code/3DSConverter.cpp.o
...
[ 29%] Building CXX object src/assimp-3.1.1/CMakeFiles/assimp.dir/contrib/poly2tri/poly2tri/sweep/sweep.cc.o
[ 29%] Building CXX object src/assimp-3.1.1/CMakeFiles/assimp.dir/contrib/poly2tri/poly2tri/sweep/sweep_context.cc.o
[ 29%] Linking CXX static library libassimp.a
[ 29%] Built target assimp
Scanning dependencies of target protoctarget
/bin/sh: 1: protoc: not found
src/SmartBody/CMakeFiles/protoctarget.dir/build.make:57: recipe for target 'src/SmartBody/CMakeFiles/protoctarget' failed
make[2]: *** [src/SmartBody/CMakeFiles/protoctarget] Error 127
CMakeFiles/Makefile2:458: recipe for target 'src/SmartBody/CMakeFiles/protoctarget.dir/all' failed
make[1]: *** [src/SmartBody/CMakeFiles/protoctarget.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

 

# EDIT 4 protec solved - new error SBMotion.cpp.o

sudo apt-get install protobuf-compiler

# next error

[ 76%] Building CXX object src/SmartBody/CMakeFiles/SmartBody.dir/sb/SBMotion.cpp.o
In file included from /home/user/smartbody/src/SmartBody/sb/SBMotion.cpp:28:0:
/home/user/smartbody/src/SmartBody/./protocols/sbmotion.pb.h:12:2: error: #error This file was generated by a newer version of protoc which is
#error This file was generated by a newer version of protoc which is
^
/home/user/smartbody/src/SmartBody/./protocols/sbmotion.pb.h:13:2: error: #error incompatible with your Protocol Buffer headers. Please update
#error incompatible with your Protocol Buffer headers. Please update
^
/home/user/smartbody/src/SmartBody/./protocols/sbmotion.pb.h:14:2: error: #error your headers.
#error your headers.

Full error: https://pastebin.com/XiLyhwU1

which seems to be the same error as:
http://smartbody.ict.usc.edu/forum/general/cmake-error-sbassethandlerskb-cpp-missing#p1314 (EDIT 5: correct link)
which has not been solved yet.

----- EDIT 5: BUILD SUCCESSFUL!

Looking into 'linuxlibsbuild.sh', I found a reference to protobuf-2.5.0, and when I ran 'protoc --version' it showed me that 'sudo apt-get install protobuf-compiler' installed 'libprotoc 2.6.1'. Therefore I installed 2.5.0 with:

conda create --name smartbody # new anaconda environment to have different versions of protobuf on the same system
source activate smartbody
anaconda search -t conda protobuf # find available channels for protobuf
anaconda show distributions/protobuf
anaconda show distributions/libprotobuf
conda install --channel https://conda.anaconda.org/distributions protobuf
conda install --channel https://conda.anaconda.org/distributions libprotobuf
protoc --version  # libprotoc 2.5.0

If you don't see 'libprotoc 2.5.0' in your activated conda environment, play around with 'sudo apt-get remove libprotobuf' outside your activated env.