x2c / homebridge-ansible-pi

HomeBridge Ansible auto-installer for Raspberry Pi
22 stars 1 forks source link

Fails at libcec #2

Open pr3sidentspence opened 7 years ago

pr3sidentspence commented 7 years ago

This is failing for me at LibCEC with "Local modifications exist in repository (force=no)"

Apparently they changed the default force behaviour to no and people are seeing this now. Should I attempt it with force=yes and, if so, how do I set that?

x2c commented 7 years ago

yes please try setting force=yes and if it works please raise a pull request

pr3sidentspence commented 7 years ago

Where does one set that, I've tried at the command line, and in run-ansible.sh, but generated errors. Sorry, I have no experience at all with ansible.

pr3sidentspence commented 7 years ago

Ok, I put force=yes in main.yml. Now I'm getting:

TASK [pi : Git clone LibCEC Platform] ******************************************
fatal: [192.168.86.198]: FAILED! => {"changed": false, "failed": true, "msg": "Failed to init/update submodules: Cloning into 'support'...
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
Clone of 'git@github.com:Pulse-Eight/libcec-support.git' into submodule path 'support' failed
"}

That repo does exist, I'm not sure why it's doing that.

pr3sidentspence commented 7 years ago

Someone else reported this in Nov, 2016: https://github.com/Pulse-Eight/platform/issues/30

I can't clone it from the commandline outside of ansible either.

pr3sidentspence commented 7 years ago

I told it not to stop when the libcec tasks fail, and it finished. However, there are no instructions for how to proceed to run homebridge. Assuming that it must be the same as for other installation methods, I went back to the homebridge instructions.

I eventually found a homebridge I could run in /usr/local/lib/node_modules/homebridge/bin but it throws an error:

module.js:339
    throw err;
    ^

Error: Cannot find module '../build/Release/dns_sd_bindings'
    at Function.Module._resolveFilename (module.js:337:15)
    at Function.Module._load (module.js:287:25)
    at Module.require (module.js:366:17)
    at require (module.js:385:17)
    at Object.<anonymous> (/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/mdns/lib/dns_sd.js:32:22)
    at Module._compile (module.js:435:26)
    at Object.Module._extensions..js (module.js:442:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:311:12)
    at Module.require (module.js:366:17)

I started trying to resolve this, but dead ended. Others with the same error were given things to try in directories I do not have.

pr3sidentspence commented 7 years ago

I was able to clone the libcec platform and library using the instructions found at https://github.com/Pulse-Eight/libcec/wiki/Raspberry-Pi-set-up:

apt-get update
apt-get install cmake liblockdev1-dev libudev-dev libxrandr-dev python-dev swig
cd
git clone https://github.com/Pulse-Eight/platform.git
mkdir platform/build
cd platform/build
cmake ..
make
sudo make install
cd
git clone https://github.com/Pulse-Eight/libcec.git
mkdir libcec/build
cd libcec/build
cmake -DRPI_INCLUDE_DIR=/opt/vc/include -DRPI_LIB_DIR=/opt/vc/lib ..
make -j4
sudo make install
sudo ldconfig

I wonder if the only difference is the https? I am not knowledgeable enough to say.