Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dependences for building BtEmbedded are not clear #1

Open
unixbigot opened this issue Nov 28, 2015 · 2 comments
Open

Dependences for building BtEmbedded are not clear #1

unixbigot opened this issue Nov 28, 2015 · 2 comments

Comments

@unixbigot
Copy link

I've gotten your binary distro of the gateway working on a pi v1 (but pin numbers are different).

I want to work on it to try to tune performance and change pins.

I figured out I needed to apt-get install rake... but then

rake aborted!
cannot load such file -- net/ssh

So, several iterations of build-fail-install-retry, you need these dependencies

apt-get install rake ruby-net-ssh ruby-net-scp

(Aside: As an long time unix 'make' user I'm stumped, where is the actual problem among all that spew?)

./build_all

*******************************
  host_debug
*******************************

rake configuration=host_debug project=3rdParty,BtCore,BtMqttSnGateway pi_run_ssh=true
/home/chris/src/robotics/BtEmbedded
configuration is host_debug
load configuration host_debug from /home/chris/src/robotics/BtEmbedded/BtBuildFramework/source/configuration/host_debug.config.rb
platform is linux
load platform linux from /home/chris/src/robotics/BtEmbedded/BtBuildFramework/source/platform/linux.platform.rb
@current_project 3rdParty 3rdParty/build.rb
@current_project BtCore BtCore/build.rb
@current_project BtMqttSnGateway BtMqttSnGateway/build.rb
project to build ["3rdParty", "BtCore", "BtMqttSnGateway"]
** Invoke default (first_time)
** Invoke 3rdParty (first_time)
** Invoke 3rdParty@CompileNinja (first_time)
** Invoke 3rdParty@GenerateNinja (first_time)
** Invoke /home/chris/src/robotics/BtEmbedded/3rdParty/target/host_debug (first_time, not_needed)
** Execute 3rdParty@GenerateNinja
artefact for gmock @ /home/chris/src/robotics/BtEmbedded/3rdParty
artefact for mqtt @ /home/chris/src/robotics/BtEmbedded/3rdParty
** Execute 3rdParty@CompileNinja
ninja -v -j8 -f target/host_debug/build.ninja
rake aborted!
Command failed with status (127): [ninja -v -j8 -f target/host_debug/build.ninja]
/home/chris/src/robotics/BtEmbedded/BtBuildFramework/source/builder.rb:105:in `block in run_sh'
/usr/lib/ruby/vendor_ruby/rake/file_utils.rb:45:in `call'
/usr/lib/ruby/vendor_ruby/rake/file_utils.rb:45:in `sh'
/usr/lib/ruby/vendor_ruby/rake/file_utils_ext.rb:39:in `sh'
/home/chris/src/robotics/BtEmbedded/BtBuildFramework/source/builder.rb:104:in `run_sh'
/home/chris/src/robotics/BtEmbedded/BtBuildFramework/source/builder.rb:50:in `block in generate_project'
/home/chris/src/robotics/BtEmbedded/BtBuildFramework/source/build_framework.rb:95:in `block in bttask'
/usr/lib/ruby/vendor_ruby/rake/task.rb:203:in `call'
/usr/lib/ruby/vendor_ruby/rake/task.rb:203:in `block in execute'
/usr/lib/ruby/vendor_ruby/rake/task.rb:200:in `each'
/usr/lib/ruby/vendor_ruby/rake/task.rb:200:in `execute'
/usr/lib/ruby/vendor_ruby/rake/task.rb:158:in `block in invoke_with_call_chain'
/usr/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
/usr/lib/ruby/vendor_ruby/rake/task.rb:151:in `invoke_with_call_chain'
/usr/lib/ruby/vendor_ruby/rake/task.rb:176:in `block in invoke_prerequisites'
/usr/lib/ruby/vendor_ruby/rake/task.rb:174:in `each'
/usr/lib/ruby/vendor_ruby/rake/task.rb:174:in `invoke_prerequisites'
/usr/lib/ruby/vendor_ruby/rake/task.rb:157:in `block in invoke_with_call_chain'
/usr/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
/usr/lib/ruby/vendor_ruby/rake/task.rb:151:in `invoke_with_call_chain'
/usr/lib/ruby/vendor_ruby/rake/task.rb:176:in `block in invoke_prerequisites'
/usr/lib/ruby/vendor_ruby/rake/task.rb:174:in `each'
/usr/lib/ruby/vendor_ruby/rake/task.rb:174:in `invoke_prerequisites'
/usr/lib/ruby/vendor_ruby/rake/task.rb:157:in `block in invoke_with_call_chain'
/usr/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
/usr/lib/ruby/vendor_ruby/rake/task.rb:151:in `invoke_with_call_chain'
/usr/lib/ruby/vendor_ruby/rake/task.rb:144:in `invoke'
/usr/lib/ruby/vendor_ruby/rake/application.rb:116:in `invoke_task'
/usr/lib/ruby/vendor_ruby/rake/application.rb:94:in `block (2 levels) in top_level'
/usr/lib/ruby/vendor_ruby/rake/application.rb:94:in `each'
/usr/lib/ruby/vendor_ruby/rake/application.rb:94:in `block in top_level'
/usr/lib/ruby/vendor_ruby/rake/application.rb:133:in `standard_exception_handling'
/usr/lib/ruby/vendor_ruby/rake/application.rb:88:in `top_level'
/usr/lib/ruby/vendor_ruby/rake/application.rb:66:in `block in run'
/usr/lib/ruby/vendor_ruby/rake/application.rb:133:in `standard_exception_handling'
/usr/lib/ruby/vendor_ruby/rake/application.rb:63:in `run'
/usr/bin/rake:27:in `<main>'
Tasks: TOP => default => 3rdParty => 3rdParty@CompileNinja
./build_all:24:in `block (2 levels) in <main>': Build of configuration host_debug failed with status (1): [rake configuration=host_debug project=3rdParty,BtCore,BtMqttSnGateway pi_run_ssh=true] (RuntimeError)
    from /usr/lib/ruby/vendor_ruby/rake/file_utils.rb:45:in `call'
    from /usr/lib/ruby/vendor_ruby/rake/file_utils.rb:45:in `sh'
    from /usr/lib/ruby/vendor_ruby/rake/file_utils_ext.rb:39:in `sh'
    from ./build_all:23:in `block in <main>'
    from ./build_all:11:in `each'
    from ./build_all:11:in `<main>'
@unixbigot
Copy link
Author

Okay, some progress

sudo apt-get install ninja
./build_all
# errors about must run as root

start ninja demon

sudo /etc/init.d/ninja start
./build_all

Same error. Wait, what are you trying to install and run ninja yourself rather than use the system package?

Does your build process expet to run as root??

~/src/robotics/BtEmbedded/BtCore$ rake
(in /home/chris/src/robotics/BtEmbedded)
/home/chris/src/robotics/BtEmbedded
configuration is host_debug
load configuration host_debug from /home/chris/src/robotics/BtEmbedded/BtBuildFramework/source/configuration/host_debug.config.rb
platform is linux
load platform linux from /home/chris/src/robotics/BtEmbedded/BtBuildFramework/source/platform/linux.platform.rb
@current_project 3rdParty 3rdParty/build.rb
@current_project BtCore BtCore/build.rb
@current_project BtMqttSnGateway BtMqttSnGateway/build.rb
project to build ["3rdParty", "BtCore", "BtMqttSnGateway"]
** Invoke default (first_time)
** Invoke 3rdParty (first_time)
** Invoke 3rdParty@CompileNinja (first_time)
** Invoke 3rdParty@GenerateNinja (first_time)
** Invoke /home/chris/src/robotics/BtEmbedded/3rdParty/target/host_debug (first_time, not_needed)
** Execute 3rdParty@GenerateNinja
artefact for gmock @ /home/chris/src/robotics/BtEmbedded/3rdParty
artefact for mqtt @ /home/chris/src/robotics/BtEmbedded/3rdParty
** Execute 3rdParty@CompileNinja
ninja -v -j8 -f target/host_debug/build.ninja
log: ninja version 0.1.3 initializing
die: error: must run as root
rake aborted!
Command failed with status (1): [ninja -v -j8 -f target/host_debug/build.ninja]

@bittailor
Copy link
Owner

The build system only worked on a mac os x machine 😞.

I now added a Vagrant configuration for a ubuntu box that installs the dependecies and sets up the cross compile stuff also for a linux. I had to fix some stuff in the build but it should work now.

You now should be able to compile in the vagrant box or get inspired by the Vagrantfile to install the dependencies on your machine.

By the way, its the ninja-build package and it does not need root to build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants