summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authoroxpa <iippolitov@gmail.com>2024-09-17 15:43:32 +0100
committerKonstantin Pavlov <thresh@nginx.com>2024-09-17 12:40:49 -0700
commitdadad1f3acd1a6f07c7102121d44f07b9ca1d6db (patch)
treefe05fdd5db484ce71ed526d402375c0854fe0c9a
parent2417826d8bebf921ee1be102ef8ce702f0683d66 (diff)
downloadunit-dadad1f3acd1a6f07c7102121d44f07b9ca1d6db.tar.gz
unit-dadad1f3acd1a6f07c7102121d44f07b9ca1d6db.tar.bz2
Docker: fix docker builds with wasm
-rw-r--r--pkg/docker/Dockerfile.wasm8
-rw-r--r--pkg/docker/Makefile6
2 files changed, 7 insertions, 7 deletions
diff --git a/pkg/docker/Dockerfile.wasm b/pkg/docker/Dockerfile.wasm
index dcdb3672..567f98a6 100644
--- a/pkg/docker/Dockerfile.wasm
+++ b/pkg/docker/Dockerfile.wasm
@@ -45,7 +45,7 @@ RUN set -ex \
&& make -j $NCPU unitd \
&& install -pm755 build/sbin/unitd /usr/sbin/unitd \
&& make clean \
- && apt-get install --no-install-recommends --no-install-suggests -y libclang-dev \
+ && apt-get install --no-install-recommends --no-install-suggests -y libclang-dev cmake \
&& export RUST_VERSION=1.80.1 \
&& export RUSTUP_HOME=/usr/src/unit/rustup \
&& export CARGO_HOME=/usr/src/unit/cargo \
@@ -66,13 +66,13 @@ RUN set -ex \
&& cargo --version \
&& rustc --version \
&& make -C pkg/contrib .wasmtime \
- && install -pm 755 pkg/contrib/wasmtime/target/release/libwasmtime.so /usr/lib/$(dpkg-architecture -q DEB_HOST_MULTIARCH)/ \
+ && install -pm 755 pkg/contrib/wasmtime/artifacts/lib/libwasmtime.so /usr/lib/$(dpkg-architecture -q DEB_HOST_MULTIARCH)/ \
&& ./configure $CONFIGURE_ARGS_MODULES --cc-opt="$CC_OPT" --modulesdir=/usr/lib/unit/debug-modules --debug \
- && ./configure wasm --include-path=`pwd`/pkg/contrib/wasmtime/crates/c-api/include --lib-path=/usr/lib/$(dpkg-architecture -q DEB_HOST_MULTIARCH)/ && ./configure wasm-wasi-component \
+ && ./configure wasm --include-path=`pwd`/pkg/contrib/wasmtime/artifacts/include --lib-path=/usr/lib/$(dpkg-architecture -q DEB_HOST_MULTIARCH)/ && ./configure wasm-wasi-component \
&& make -j $NCPU wasm-install wasm-wasi-component-install \
&& make clean \
&& ./configure $CONFIGURE_ARGS_MODULES --cc-opt="$CC_OPT" --modulesdir=/usr/lib/unit/modules \
- && ./configure wasm --include-path=`pwd`/pkg/contrib/wasmtime/crates/c-api/include --lib-path=/usr/lib/$(dpkg-architecture -q DEB_HOST_MULTIARCH)/ && ./configure wasm-wasi-component \
+ && ./configure wasm --include-path=`pwd`/pkg/contrib/wasmtime/artifacts/include --lib-path=/usr/lib/$(dpkg-architecture -q DEB_HOST_MULTIARCH)/ && ./configure wasm-wasi-component \
&& make -j $NCPU wasm-install wasm-wasi-component-install \
&& cd \
&& rm -rf /usr/src/unit \
diff --git a/pkg/docker/Makefile b/pkg/docker/Makefile
index 9dbca2d2..6d7726b4 100644
--- a/pkg/docker/Makefile
+++ b/pkg/docker/Makefile
@@ -79,12 +79,12 @@ MODULE_PREBUILD_ruby ?= /bin/true
VERSIONS_wasm ?=
CONTAINER_wasm ?= debian:$(VARIANT)-slim
-CONFIGURE_wasm ?= wasm --include-path=\`pwd\`/pkg/contrib/wasmtime/crates/c-api/include --lib-path=/usr/lib/\$$(dpkg-architecture -q DEB_HOST_MULTIARCH)/ \&\& ./configure wasm-wasi-component
+CONFIGURE_wasm ?= wasm --include-path=\`pwd\`/pkg/contrib/wasmtime/artifacts/include --lib-path=/usr/lib/\$$(dpkg-architecture -q DEB_HOST_MULTIARCH)/ \&\& ./configure wasm-wasi-component
INSTALL_wasm ?= wasm-install wasm-wasi-component-install
RUN_wasm ?= /bin/true
define MODULE_PREBUILD_wasm
-apt-get install --no-install-recommends --no-install-suggests -y libclang-dev \\\n \
+apt-get install --no-install-recommends --no-install-suggests -y libclang-dev cmake \\\n \
\ \ \ \&\& export RUST_VERSION=1.80.1 \\\n \
\ \ \ \&\& export RUSTUP_HOME=/usr/src/unit/rustup \\\n \
\ \ \ \&\& export CARGO_HOME=/usr/src/unit/cargo \\\n \
@@ -105,7 +105,7 @@ apt-get install --no-install-recommends --no-install-suggests -y libclang-dev \\
\ \ \ \&\& cargo --version \\\n \
\ \ \ \&\& rustc --version \\\n \
\ \ \ \&\& make -C pkg/contrib .wasmtime \\\n \
-\ \ \ \&\& install -pm 755 pkg/contrib/wasmtime/target/release/libwasmtime.so /usr/lib/\$$\(dpkg-architecture -q DEB_HOST_MULTIARCH\)/
+\ \ \ \&\& install -pm 755 pkg/contrib/wasmtime/artifacts/lib/libwasmtime.so /usr/lib/\$$\(dpkg-architecture -q DEB_HOST_MULTIARCH\)/
endef
default: