From 9ef0aae0de36f839c2e27a22a026338941f6543a Mon Sep 17 00:00:00 2001 From: Dmitry Lopatin Date: Mon, 16 Jun 2025 08:51:54 +0300 Subject: [PATCH 1/4] chore(ci): build libibverbs Signed-off-by: Dmitry Lopatin --- component_versions/version_map.yml | 1 + .../binaries/libibverbs/werf.inc.yaml | 53 +++++++++++++++++++ 2 files changed, 54 insertions(+) create mode 100644 images/packages/binaries/libibverbs/werf.inc.yaml diff --git a/component_versions/version_map.yml b/component_versions/version_map.yml index 36ad2d4d75..f3c5ee9cb0 100644 --- a/component_versions/version_map.yml +++ b/component_versions/version_map.yml @@ -30,3 +30,4 @@ package: libgcrypt: libgcrypt-1.10.2 libgpg-error: libgpg-error-1.55 libhogweed: nettle_3.10.1_release_20241230 + libibverbs: 1.0.0 diff --git a/images/packages/binaries/libibverbs/werf.inc.yaml b/images/packages/binaries/libibverbs/werf.inc.yaml new file mode 100644 index 0000000000..20f5d9defd --- /dev/null +++ b/images/packages/binaries/libibverbs/werf.inc.yaml @@ -0,0 +1,53 @@ +--- +image: {{ $.ImageType }}/{{ $.ImageName }} +final: false +fromImage: builder/scratch +import: +- image: {{ $.ImageType }}/{{ $.ImageName }}-builder + add: /out + to: /libibverbs + before: setup + +--- +{{- $version := get $.Package $.ImageName }} +{{- $gitRepoUrl := "gpudirect/libibverbs.git" }} + +{{- $name := print $.ImageName "-dependencies" -}} +{{- define "$name" -}} +packages: +- gcc git make libtool pkg-config libnl-devel +{{- end -}} + +{{ $builderDependencies := include "$name" . | fromYaml }} + +image: {{ $.ImageType }}/{{ $.ImageName }}-builder +final: false +fromImage: builder/alt +secrets: +- id: SOURCE_REPO + value: {{ $.SOURCE_REPO_GIT }} +shell: + beforeInstall: + {{- include "alt packages proxy" . | nindent 2 }} + - | + apt-get install -y \ + {{ $builderDependencies.packages | join " " }} + + {{- include "alt packages clean" . | nindent 2 }} + + install: + - | + OUTDIR=/out + mkdir -p ~/.ssh && echo "StrictHostKeyChecking accept-new" > ~/.ssh/config + + git clone --depth=1 $(cat /run/secrets/SOURCE_REPO)/{{ $gitRepoUrl }} /src + cd /src + ./autogen.sh + ./configure \ + --prefix=/usr \ + --libdir=/usr/lib64 \ + --disable-static \ + CFLAGS="-Wno-error" + make -j$(nproc) + make DESTDIR=$OUTDIR install + From bbb1625b8ff63732e58ace538564cc325d6f3f96 Mon Sep 17 00:00:00 2001 From: Dmitry Lopatin Date: Tue, 17 Jun 2025 09:54:07 +0300 Subject: [PATCH 2/4] fix Signed-off-by: Dmitry Lopatin --- images/packages/binaries/libibverbs/werf.inc.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/images/packages/binaries/libibverbs/werf.inc.yaml b/images/packages/binaries/libibverbs/werf.inc.yaml index 20f5d9defd..64b9d1020e 100644 --- a/images/packages/binaries/libibverbs/werf.inc.yaml +++ b/images/packages/binaries/libibverbs/werf.inc.yaml @@ -15,7 +15,8 @@ import: {{- $name := print $.ImageName "-dependencies" -}} {{- define "$name" -}} packages: -- gcc git make libtool pkg-config libnl-devel +- gcc git make libtool libnl-devel +- tree {{- end -}} {{ $builderDependencies := include "$name" . | fromYaml }} @@ -46,8 +47,10 @@ shell: ./configure \ --prefix=/usr \ --libdir=/usr/lib64 \ + --disable-doc \ --disable-static \ CFLAGS="-Wno-error" make -j$(nproc) make DESTDIR=$OUTDIR install + tree /out From 04982b4a85a15d365f2f784e0b4d7a87147f8d7d Mon Sep 17 00:00:00 2001 From: Dmitry Lopatin Date: Wed, 18 Jun 2025 14:37:36 +0300 Subject: [PATCH 3/4] fix Signed-off-by: Dmitry Lopatin --- images/packages/binaries/libibverbs/werf.inc.yaml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/images/packages/binaries/libibverbs/werf.inc.yaml b/images/packages/binaries/libibverbs/werf.inc.yaml index 64b9d1020e..fa81d07260 100644 --- a/images/packages/binaries/libibverbs/werf.inc.yaml +++ b/images/packages/binaries/libibverbs/werf.inc.yaml @@ -6,6 +6,17 @@ import: - image: {{ $.ImageType }}/{{ $.ImageName }}-builder add: /out to: /libibverbs + includePaths: + - usr/lib64/libibverbs.so + - usr/lib64/libibverbs.so.1 + - usr/lib64/libibverbs.so.1.0.0 + before: setup +- image: {{ $.ImageType }}/{{ $.ImageName }}-builder + add: /out + to: /rdma-core-devel + includePaths: + - usr/include + - usr/lib64/libibverbs.la before: setup --- @@ -51,6 +62,6 @@ shell: --disable-static \ CFLAGS="-Wno-error" make -j$(nproc) - make DESTDIR=$OUTDIR install + make DESTDIR=/out install-libLTLIBRARIES install-libibverbsincludeHEADERS tree /out From 56c770688812aa5c4dbcfdb8a7b1810725358af0 Mon Sep 17 00:00:00 2001 From: Dmitry Lopatin Date: Thu, 19 Jun 2025 19:56:23 +0300 Subject: [PATCH 4/4] fix Signed-off-by: Dmitry Lopatin --- images/packages/binaries/libibverbs/werf.inc.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/images/packages/binaries/libibverbs/werf.inc.yaml b/images/packages/binaries/libibverbs/werf.inc.yaml index fa81d07260..56786d021c 100644 --- a/images/packages/binaries/libibverbs/werf.inc.yaml +++ b/images/packages/binaries/libibverbs/werf.inc.yaml @@ -27,7 +27,6 @@ import: {{- define "$name" -}} packages: - gcc git make libtool libnl-devel -- tree {{- end -}} {{ $builderDependencies := include "$name" . | fromYaml }} @@ -63,5 +62,4 @@ shell: CFLAGS="-Wno-error" make -j$(nproc) make DESTDIR=/out install-libLTLIBRARIES install-libibverbsincludeHEADERS - tree /out