Skip to content
This repository has been archived by the owner on Aug 9, 2022. It is now read-only.

chef-base-plans/protobuf

Repository files navigation

Build Status

protobuf

Protocol buffers are a language-neutral, platform-neutral extensible mechanism for serializing structured data. See documentation

Maintainers

Type of Package

Binary package

Use as Dependency

Binary packages can be set as runtime or build time dependencies. See Defining your dependencies for more information.

To add core/protobuf as a dependency, you can add one of the following to your plan file.

Buildtime Dependency

pkg_build_deps=(core/protobuf)

Runtime dependency

pkg_deps=(core/protobuf)

Use as Tool

Installation

To install this plan, you should run the following commands to first install, and then link the binaries this plan creates.

hab pkg install core/protobuf --binlink

will add the following binary to the PATH:

  • /bin/protoc

For example:

$ hab pkg install core/protobuf --binlink
» Installing core/protobuf
☁ Determining latest version of core/protobuf in the 'stable' channel
☛ Verifying core/protobuf/3.9.2/20200310022658
...
...
✓ Installed core/protobuf/3.9.2/20200310022658
★ Install of core/protobuf/3.9.2/20200310022658 complete with 4 new packages installed.
» Binlinking protoc from core/protobuf/3.9.2/20200310022658 into /bin
★ Binlinked protoc from core/protobuf/3.9.2/20200310022658 to /bin/protoc

Using an example binary

You can now use the binary as normal. For example:

/bin/protoc --help or protoc --help

$ protoc --help
Usage: protoc [OPTION] PROTO_FILES
Parse PROTO_FILES and generate output based on the options given:
  -IPATH, --proto_path=PATH   Specify the directory in which to search for
                              imports.  May be specified multiple times;
...
...