1

I am using Travis-CI which uses an Ubuntu 14.04 Trusty VM to run a script. In order to run correctly the script requires the package protobuf-compiler version 3+ and the corresponding libprotobuf-dev package to be installed. Unfortunately doing the obvious apt-get install protobuf-compiler libprotobuf-dev gives me version 2.5 which is too old to compile the script.

Fortunately there is a PPA that provides version 3.4 for Trusty. I used add-apt-repository ppa:maarten-fonville/protobuf to add the PPA with the appropriate apt-get update but I still got the old version from archive.ubuntu.com, not the PPA version.

I tried giving the PPA a higher priority using this /etc/apt/preferences file as described here but I still got version 2.5.

There is a log of my script with the commands used. Line 506 adds the PPA, line 615 copies the preferences file, line 617 makes the apt update and line 719 installs the (incorrect) packages. Unfolding line 7 shows various system information.

How do I install protobuf-compiler version 3+ on Ubuntu Trusty?

nwp
  • 111

1 Answers1

0

The package is available from the mentioned PPA as of yesterday (1/27/18) from http://ppa.launchpad.net/maarten-fonville/protobuf/ubuntu/pool/main/p/protobuf/ for both the 64-bit and 32-bit versions of trusty. I'm not sure why protobuf-compiler doesn't show as being available on the launchpad page.

However sudo apt install protobuf-compiler will install it and it's dependencies from the PPA. I believe the aforementioned dependencies specifically libprotobuf15 and libprotoc15 are the reason why it wouldn't install standalone with dpkg -i if downloaded directly from http://ppa.launchpad.net/maarten-fonville/protobuf/ubuntu/pool/main/p/protobuf/protobuf-compiler_3.5.1.1-0~maarten0+trusty0_amd64.deb

Sources:

Testing

@nwp comment here

Elder Geek
  • 36,752