Skip to content

Commit

Permalink
build: drop gcrypt dependency
Browse files Browse the repository at this point in the history
Closes: https://issues.redhat.com/browse/RHEL-22011

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
  • Loading branch information
giuseppe committed Jan 22, 2024
1 parent 5221ca8 commit 8d96f08
Show file tree
Hide file tree
Showing 12 changed files with 12 additions and 17 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ These dependencies are required for the build:

```console
$ sudo dnf install -y make python git gcc automake autoconf libcap-devel \
systemd-devel yajl-devel libseccomp-devel pkg-config libgcrypt-devel \
systemd-devel yajl-devel libseccomp-devel pkg-config \
go-md2man glibc-static python3-libmount libtool
```

Expand All @@ -69,7 +69,7 @@ $ sudo dnf install -y make python git gcc automake autoconf libcap-devel \
```console
$ sudo yum --enablerepo='*' --disablerepo='media-*' install -y make automake \
autoconf gettext \
libtool gcc libcap-devel systemd-devel yajl-devel libgcrypt-devel \
libtool gcc libcap-devel systemd-devel yajl-devel \
glibc-static libseccomp-devel python36 git
```

Expand All @@ -89,7 +89,7 @@ $ export PATH=$PATH:$GOPATH/bin
```console
$ sudo apt-get install -y make git gcc build-essential pkgconf libtool \
libsystemd-dev libprotobuf-c-dev libcap-dev libseccomp-dev libyajl-dev \
libgcrypt20-dev go-md2man autoconf python3 automake
go-md2man autoconf python3 automake
```

### Alpine
Expand Down
3 changes: 0 additions & 3 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,6 @@ AS_IF([test "x$enable_caps" != "xno"], [
])
])

dnl libgcrypt
AC_SEARCH_LIBS([gcry_check_version], [gcrypt], [AC_DEFINE([HAVE_GCRYPT], 1, [Define if gcrypt is available])], [])

dnl dl
AC_ARG_ENABLE([dl], AS_HELP_STRING([--disable-dl], [Disable dynamic libraries support]))
AS_IF([test "x$enable_dl" != "xno"], [
Expand Down
3 changes: 1 addition & 2 deletions nix/derivation.nix
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ with pkgs; stdenv.mkDerivation {
which
];
buildInputs = [
gcrypt
glibc
glibc.static
libcap
Expand All @@ -32,7 +31,7 @@ with pkgs; stdenv.mkDerivation {
export LDFLAGS='-s -w -static-libgcc -static'
export EXTRA_LDFLAGS='-s -w -linkmode external -extldflags "-static -lm"'
export CRUN_LDFLAGS='-all-static'
export LIBS='${lib.optionalString enableCriu "${criu}/lib/libcriu.a"} ${glibc.static}/lib/libc.a ${glibc.static}/lib/libpthread.a ${glibc.static}/lib/librt.a ${lib.getLib libcap}/lib/libcap.a ${lib.getLib libseccomp}/lib/libseccomp.a ${lib.optionalString enableSystemd "${lib.getLib libsystemd}/lib/libsystemd.a"} ${yajl}/lib/libyajl.a ${gcrypt}/lib/libgcrypt.a'
export LIBS='${lib.optionalString enableCriu "${criu}/lib/libcriu.a"} ${glibc.static}/lib/libc.a ${glibc.static}/lib/libpthread.a ${glibc.static}/lib/librt.a ${lib.getLib libcap}/lib/libcap.a ${lib.getLib libseccomp}/lib/libseccomp.a ${lib.optionalString enableSystemd "${lib.getLib libsystemd}/lib/libsystemd.a"} ${yajl}/lib/libyajl.a'
'';
buildPhase = ''
patchShebangs .
Expand Down
1 change: 0 additions & 1 deletion nix/overlay.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ in
self: super:
{
criu = (static super.criu);
gcrypt = (static super.libgcrypt);
gpgme = (static super.gpgme);
libassuan = (static super.libassuan);
libgpgerror = (static super.libgpgerror);
Expand Down
2 changes: 1 addition & 1 deletion tests/alpine-build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM alpine

RUN apk add gcc automake autoconf libtool gettext pkgconf git make musl-dev \
python3 libcap-dev libgcrypt-dev libseccomp-dev yajl-dev argp-standalone go-md2man
python3 libcap-dev libseccomp-dev yajl-dev argp-standalone go-md2man

COPY run-tests.sh /usr/local/bin

Expand Down
2 changes: 1 addition & 1 deletion tests/centos8-build/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM quay.io/centos/centos:stream8

RUN yum --enablerepo='powertools' install -y make automake autoconf gettext \
criu-devel libtool gcc libcap-devel systemd-devel yajl-devel \
libgcrypt-devel libseccomp-devel python36 libtool git
libseccomp-devel python36 libtool git

COPY run-tests.sh /usr/local/bin

Expand Down
2 changes: 1 addition & 1 deletion tests/centos9-build/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM quay.io/centos/centos:stream9

RUN yum --enablerepo='appstream' --enablerepo='baseos' --enablerepo='crb' install -y make \
automake autoconf gettext criu-devel libtool gcc libcap-devel systemd-devel yajl-devel \
libgcrypt-devel libseccomp-devel python3 libtool git protobuf-c protobuf-c-devel
libseccomp-devel python3 libtool git protobuf-c protobuf-c-devel

COPY run-tests.sh /usr/local/bin

Expand Down
2 changes: 1 addition & 1 deletion tests/containerd/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ ENV PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/go/b
RUN apt-get update \
&& apt-get -y upgrade \
&& apt-get install -y bash golang-1.19 libbtrfs-dev libnl-3-dev libnet1-dev \
protobuf-c-compiler libgcrypt20-dev libcap-dev libaio-dev \
protobuf-c-compiler libcap-dev libaio-dev \
curl libprotobuf-c-dev libprotobuf-dev socat libseccomp-dev \
pigz lsof make git gcc build-essential pkgconf libtool \
libsystemd-dev libcap-dev libyajl-dev \
Expand Down
2 changes: 1 addition & 1 deletion tests/cri-o/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ ENV PATH=/usr/bin:/usr/sbin:/root/go/bin:/usr/local/bin::/usr/local/sbin
RUN yum install -y python git gcc automake autoconf libcap-devel \
systemd-devel yajl-devel libseccomp-devel go-md2man conntrack-tools which \
glibc-static python3-libmount libtool make podman xz nmap-ncat jq bats \
libgcrypt-devel iproute openssl iputils socat criu-libs irqbalance && \
iproute openssl iputils socat criu-libs irqbalance && \
dnf install -y 'dnf-command(builddep)' && dnf builddep -y podman && \
dnf remove -y golang && \
sudo dnf update -y && \
Expand Down
2 changes: 1 addition & 1 deletion tests/fuzzing/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM fedora:latest

RUN yum install -y golang python git automake autoconf libcap-devel \
libgcrypt-devel systemd-devel yajl-devel libseccomp-devel go-md2man \
systemd-devel yajl-devel libseccomp-devel go-md2man \
glibc-static python3-libmount libtool make honggfuzz git

RUN git clone https://github.com/giuseppe/containers-fuzzing-corpus /testcases
Expand Down
2 changes: 1 addition & 1 deletion tests/podman/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ ENV GOPATH=/root/go
ENV PATH=/usr/bin:/usr/sbin:/root/go/bin:/usr/local/bin::/usr/local/sbin

RUN dnf install -y golang python git gcc automake autoconf libcap-devel \
systemd-devel yajl-devel libseccomp-devel go-md2man libgcrypt-devel \
systemd-devel yajl-devel libseccomp-devel go-md2man \
glibc-static python3-libmount libtool make podman xz nmap-ncat procps-ng \
device-mapper-devel containernetworking-plugins 'dnf-command(builddep)' && \
dnf builddep -y podman && \
Expand Down
2 changes: 1 addition & 1 deletion tests/wasmedge-build/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ ARG WASM_EDGE_VERSION="0.11.0"
# Install the deps for building crun
RUN dnf update -y && dnf install -y make python git gcc automake autoconf libcap-devel \
systemd-devel yajl-devel libseccomp-devel pkg-config diffutils \
libgcrypt-devel systemd-devel yajl-devel libseccomp-devel pkg-config \
systemd-devel yajl-devel libseccomp-devel pkg-config \
go-md2man glibc-static python3-libmount libtool buildah podman which

# Install WasmEdge
Expand Down

0 comments on commit 8d96f08

Please sign in to comment.