Skip to content

Error: Error installing package 'protolite': #172

@benjcowley

Description

@benjcowley

Hi, seem to have an issue when trying to build using renv, I've had a google around but the only fixes I've seen seem to apply to fixing this on a local machine rather than with this build pack. Any ideas how to go about fixing this?

` - Installing protolite ... FAILED
Error: Error installing package 'protolite':
=====================================

   * installing *source* package ‘protolite’ ...
   ** package ‘protolite’ successfully unpacked and MD5 sums checked
   ** using staged installation
   Package protobuf was not found in the pkg-config search path.
   Perhaps you should add the directory containing `protobuf.pc'
   to the PKG_CONFIG_PATH environment variable
   No package 'protobuf' found
   Using PKG_CFLAGS=
   Using PKG_LIBS=-lprotobuf
   Found C++17 compiler: g++ -std=gnu++17 -g -O2
   ------------------------------[ ANTICONF ]-----------------------------
   Configuration failed to find protobuf. Try installing:
    * deb: libprotobuf-dev (Debian, Ubuntu, etc)
    * rpm: protobuf-devel (Fedora, EPEL)
    * brew: protobuf (OSX)
   If protobuf is already installed, check that 'pkg-config' is in your
   PATH and PKG_CONFIG_PATH contains a protobuf.pc file. If pkg-config
   is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
   R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
   ----------------------------[ ERROR MESSAGE ]----------------------------
   <stdin>:1:10: fatal error: google/protobuf/message.h: No such file or directory
   compilation terminated.
   ------------------------------------------------------------------------
   ERROR: configuration failed for package ‘protolite’
   * removing ‘/app/renv/staging/1/protolite’
   install of package 'protolite' failed [error code 1]
   Traceback (most recent calls last):
   13: renv::restore()
   12: renv_restore_run_actions(project, diff, current, lockfile, rebuild)
   11: renv_install_impl(records)
   10: renv_install_staged(records)
    9: renv_install_default(records)
    8: handler(package, renv_install_package(record))
    7: renv_install_package(record)
    6: withCallingHandlers(renv_install_package_impl(record), error = function(e) writef("FAILED"))
    5: renv_install_package_impl(record)
    4: r_cmd_install(package, path)
    3: r_exec_error(package, output, "install", status)
    2: abort(all)
    1: stop(fallback)
   Execution halted

! Push rejected, failed to compile R (shiny) app.
! Push failed`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions