From c7edb142017affe384851d7837f1a08418dda8a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A1bor=20Cs=C3=A1rdi?= Date: Mon, 11 Dec 2023 12:09:11 +0100 Subject: [PATCH 1/3] Improve installation advice in configure for Linux Installing libgrpc-dev is not enough, unfortunately. I think for some of these packages it is enough the library, and the `-dev` package is not needed, but then we need to consider that the library packages have different names on different distro versions, so it is simpler to list the `-dev` package. --- configure | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/configure b/configure index 9019693..d215477 100755 --- a/configure +++ b/configure @@ -6,9 +6,9 @@ # Library settings PKG_CONFIG_NAME="protobuf grpc++" -PKG_DEB_NAME="libgrpc-dev" -PKG_RPM_NAME="grpc-devel" -PKG_BREW_NAME="grpc" +PKG_DEB_NAME="libprotobuf-dev protobuf-compiler-grpc libgrpc++-dev libc-ares-dev libre2-dev pkg-config" +PKG_RPM_NAME="protobuf-devel protobuf-compiler grpc-devel c-ares-devel re2-devel pkgconf" +PKG_BREW_NAME="grpc pkg-config" PKG_TEST_HEADER="" PKG_LIBS="-lgrpc++ -lgrpc -lprotobuf" PKG_CFLAGS="" From 624e7569302aed655c39df5fe13f86e2851469b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A1bor=20Cs=C3=A1rdi?= Date: Mon, 11 Dec 2023 13:16:58 +0100 Subject: [PATCH 2/3] Adjust DEB requirements --- README.Rmd | 3 +-- README.md | 3 +-- configure | 2 +- tools/build/linux/Dockerfile-debian-12 | 11 +++++------ tools/build/linux/Dockerfile-ubuntu-22.04 | 11 +++++------ 5 files changed, 13 insertions(+), 17 deletions(-) diff --git a/README.Rmd b/README.Rmd index 044fd70..2e7e51f 100644 --- a/README.Rmd +++ b/README.Rmd @@ -53,8 +53,7 @@ remotes::install_github("meztez/bigrquerystorage") ```sh # install protoc and grpc -apt-get install -y libprotobuf-dev protobuf-compiler-grpc \ - libgrpc++-dev libc-ares-dev libre2-dev \ +apt-get install -y libgrpc++-dev libprotobuf-dev protobuf-compiler-grpc \ pkg-config ``` diff --git a/README.md b/README.md index bc6e8fb..dbc2ddc 100644 --- a/README.md +++ b/README.md @@ -52,8 +52,7 @@ remotes::install_github("meztez/bigrquerystorage") ``` sh # install protoc and grpc -apt-get install -y libprotobuf-dev protobuf-compiler-grpc \ - libgrpc++-dev libc-ares-dev libre2-dev \ +apt-get install -y libgrpc++-dev libprotobuf-dev protobuf-compiler-grpc \ pkg-config ``` diff --git a/configure b/configure index d215477..380a616 100755 --- a/configure +++ b/configure @@ -6,7 +6,7 @@ # Library settings PKG_CONFIG_NAME="protobuf grpc++" -PKG_DEB_NAME="libprotobuf-dev protobuf-compiler-grpc libgrpc++-dev libc-ares-dev libre2-dev pkg-config" +PKG_DEB_NAME="libgrpc++-dev libprotobuf-dev protobuf-compiler-grpc pkg-config" PKG_RPM_NAME="protobuf-devel protobuf-compiler grpc-devel c-ares-devel re2-devel pkgconf" PKG_BREW_NAME="grpc pkg-config" PKG_TEST_HEADER="" diff --git a/tools/build/linux/Dockerfile-debian-12 b/tools/build/linux/Dockerfile-debian-12 index 6143c83..df61a1b 100644 --- a/tools/build/linux/Dockerfile-debian-12 +++ b/tools/build/linux/Dockerfile-debian-12 @@ -12,12 +12,6 @@ RUN echo "deb http://rig.r-pkg.org/deb rig main" > \ apt-get install -y r-rig && \ rig add release -# ------------------------------------------------------------------------- -# FIXME: We don't need this once grpc is in the system requirements db -RUN apt-get install -y libprotobuf-dev protobuf-compiler-grpc \ - libgrpc++-dev libc-ares-dev \ - libre2-dev pkg-config - # ------------------------------------------------------------------------- # Only copy DESCRIPTION, so Docker can cache the dependency install RUN mkdir /root/bigrquerystorage @@ -26,6 +20,11 @@ WORKDIR /root/bigrquerystorage # No upgrade, to always install binary packages, in case P3M is behind RUN R -q -e 'pak::local_install_deps(upgrade = FALSE)' +# ------------------------------------------------------------------------- +# FIXME: We don't need this once grpc is in the system requirements db +RUN apt-get install -y libgrpc++-dev libprotobuf-dev protobuf-compiler-grpc \ + pkg-config + # ------------------------------------------------------------------------- # Call R CMD build first, so we get rid of Makevars, .o, .so, etc. # Change file ownership, otherwise git complains diff --git a/tools/build/linux/Dockerfile-ubuntu-22.04 b/tools/build/linux/Dockerfile-ubuntu-22.04 index 6829efb..c5b7e2f 100644 --- a/tools/build/linux/Dockerfile-ubuntu-22.04 +++ b/tools/build/linux/Dockerfile-ubuntu-22.04 @@ -12,12 +12,6 @@ RUN echo "deb http://rig.r-pkg.org/deb rig main" > \ apt-get install -y r-rig && \ rig add release -# ------------------------------------------------------------------------- -# FIXME: We don't need this once grpc is in the system requirements db -RUN apt-get install -y libprotobuf-dev protobuf-compiler-grpc \ - libgrpc++-dev libc-ares-dev libre2-dev \ - pkg-config - # ------------------------------------------------------------------------- # Only copy DESCRIPTION first, so Docker can cache the dependency install RUN mkdir /root/bigrquerystorage @@ -26,6 +20,11 @@ WORKDIR /root/bigrquerystorage # No upgrade, to always install binary packages, in case P3M is behind RUN R -q -e 'pak::local_install_deps(upgrade = FALSE)' +# ------------------------------------------------------------------------- +# FIXME: We don't need this once grpc is in the system requirements db +RUN apt-get install -y libgrpc++-dev libprotobuf-dev protobuf-compiler-grpc \ + pkg-config + # ------------------------------------------------------------------------- # Call R CMD build first, so we get rid of Makevars, .o, .so, etc. # Change file ownership, otherwise git complains From a860454567bd73939b35a2cae0781a7eb2ad6200 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A1bor=20Cs=C3=A1rdi?= Date: Mon, 11 Dec 2023 13:36:29 +0100 Subject: [PATCH 3/3] Update RPM (Fedora 38) requirements --- README.Rmd | 6 ++---- README.md | 6 ++---- configure | 2 +- tools/build/linux/Dockerfile-fedora-38 | 10 ++++------ 4 files changed, 9 insertions(+), 15 deletions(-) diff --git a/README.Rmd b/README.Rmd index 2e7e51f..370ffba 100644 --- a/README.Rmd +++ b/README.Rmd @@ -60,10 +60,8 @@ apt-get install -y libgrpc++-dev libprotobuf-dev protobuf-compiler-grpc \ #### Fedora 38 ```sh -# install protoc and grpc -dnf install -y protobuf-devel protobuf-compiler \ - grpc-devel c-ares-devel \ - re2-devel pkgconf +# install grpc, protoc is automatically installed +dnf install -y grpc-devel pkgconf ``` #### macOS diff --git a/README.md b/README.md index dbc2ddc..eda2405 100644 --- a/README.md +++ b/README.md @@ -59,10 +59,8 @@ apt-get install -y libgrpc++-dev libprotobuf-dev protobuf-compiler-grpc \ #### Fedora 38 ``` sh -# install protoc and grpc -dnf install -y protobuf-devel protobuf-compiler \ - grpc-devel c-ares-devel \ - re2-devel pkgconf +# install grpc, protoc is automatically installed +dnf install -y grpc-devel pkgconf ``` #### macOS diff --git a/configure b/configure index 380a616..8a61d72 100755 --- a/configure +++ b/configure @@ -7,7 +7,7 @@ # Library settings PKG_CONFIG_NAME="protobuf grpc++" PKG_DEB_NAME="libgrpc++-dev libprotobuf-dev protobuf-compiler-grpc pkg-config" -PKG_RPM_NAME="protobuf-devel protobuf-compiler grpc-devel c-ares-devel re2-devel pkgconf" +PKG_RPM_NAME="grpc-devel pkgconf" PKG_BREW_NAME="grpc pkg-config" PKG_TEST_HEADER="" PKG_LIBS="-lgrpc++ -lgrpc -lprotobuf" diff --git a/tools/build/linux/Dockerfile-fedora-38 b/tools/build/linux/Dockerfile-fedora-38 index 1ca5d96..6b5c491 100644 --- a/tools/build/linux/Dockerfile-fedora-38 +++ b/tools/build/linux/Dockerfile-fedora-38 @@ -7,12 +7,6 @@ RUN yum install -y \ https://github.com/r-lib/rig/releases/download/latest/r-rig-latest-1.$(arch).rpm && \ rig add devel -# ------------------------------------------------------------------------- -# FIXME: We don't need this once grpc is in the system requirements db -RUN dnf install -y protobuf-devel protobuf-compiler \ - grpc-devel c-ares-devel \ - re2-devel pkgconf - # ------------------------------------------------------------------------- # Only copy DESCRIPTION, so Docker can cache the dependency install RUN mkdir /root/bigrquerystorage @@ -21,6 +15,10 @@ WORKDIR /root/bigrquerystorage # No upgrade, to always install binary packages, in case P3M is behind RUN R -q -e 'pak::local_install_deps(upgrade = FALSE)' +# ------------------------------------------------------------------------- +# FIXME: We don't need this once grpc is in the system requirements db +RUN dnf install -y grpc-devel pkgconf + # ------------------------------------------------------------------------- # Call R CMD build first, so we get rid of Makevars, .o, .so, etc. # Change file ownership, otherwise git complains