aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.drone.yml11
-rw-r--r--Dockerfile3
-rw-r--r--matrix-e2e.c.patch20
3 files changed, 29 insertions, 5 deletions
diff --git a/.drone.yml b/.drone.yml
index bbfaae5..b6c169f 100644
--- a/.drone.yml
+++ b/.drone.yml
@@ -20,10 +20,10 @@ steps:
DOCKER_HOST: tcp://docker:2375
commands:
- sleep 5
- - docker buildx create --use --name docker --node docker --platform linux/amd64 --driver docker-container $DOCKER_HOST
+ - docker run -it --rm --privileged tonistiigi/binfmt --install all
+ - docker buildx create --use --name docker --node docker --platform linux/amd64,linux/arm64,linux/armhf --driver docker-container $DOCKER_HOST
- echo $PASSWORD | docker login --username $USER --password-stdin
- - docker buildx build --load --cache-from ezkrg/cache:bitlbee-libpurple --cache-to ezkrg/cache:bitlbee-libpurple -t ezkrg/bitlbee-libpurple:test --platform linux/amd64 .
- - docker push ezkrg/bitlbee-libpurple:test
+ - docker buildx build --push --cache-from ezkrg/cache:bitlbee-libpurple --cache-to ezkrg/cache:bitlbee-libpurple -t ezkrg/bitlbee-libpurple:dev --platform linux/amd64,linux/arm64,linux/armhf .
- name: release
image: docker:stable
@@ -35,6 +35,7 @@ steps:
DOCKER_HOST: tcp://docker:2375
commands:
- echo $PASSWORD | docker login --username $USER --password-stdin
+ - docker pull ezkrg/bitlbee-libpurple:test
- docker tag ezkrg/bitlbee-libpurple:test ezkrg/bitlbee-libpurple:$DRONE_TAG
- docker push ezkrg/bitlbee-libpurple:$DRONE_TAG
- docker tag ezkrg/bitlbee-libpurple:test ezkrg/bitlbee-libpurple:latest
@@ -44,7 +45,7 @@ steps:
- tag
---
-kind: pipeline
+kind: pipeline
type: docker
name: notification
@@ -71,6 +72,6 @@ depends_on:
---
kind: signature
-hmac: 9c778c50b9cb687fe3e1614048c082db18c4fe6f531aba5c04f0ec950a2814d1
+hmac: 713b5ce1053fe1bd2320eaa28ca0df5784f806d69a730634eddf3c14d08697f7
...
diff --git a/Dockerfile b/Dockerfile
index b98f21b..dcd9f1c 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -267,6 +267,8 @@ ARG MATRIX=1
ARG OLM_VERSION=3.2.4
ARG MATRIX_VERSION=88f9558
+COPY matrix-e2e.c.patch /tmp/matrix-e2e.c.patch
+
RUN echo MATRIX=${MATRIX} > /tmp/status \
&& if [ ${MATRIX} -eq 1 ]; \
then cd /tmp \
@@ -280,6 +282,7 @@ RUN echo MATRIX=${MATRIX} > /tmp/status \
&& git clone -n https://github.com/matrix-org/purple-matrix \
&& cd purple-matrix \
&& git checkout ${MATRIX_VERSION} \
+ && if [ $(uname -m) == "armv7l" ]; then patch < ../matrix-e2e.c.patch; fi \
&& make \
&& make install \
&& strip /usr/lib/purple-2/libmatrix.so; \
diff --git a/matrix-e2e.c.patch b/matrix-e2e.c.patch
new file mode 100644
index 0000000..570e289
--- /dev/null
+++ b/matrix-e2e.c.patch
@@ -0,0 +1,20 @@
+--- matrix-e2e.c
++++ matrix-e2e.c.new
+@@ -949,7 +949,7 @@
+ to_create = (max_keys / 2) - count;
+ need_to_send = TRUE;
+ }
+- purple_debug_info("matrixprpl", "%s: %s: %ld\n",
++ purple_debug_info("matrixprpl", "%s: %s: %lld\n",
+ __func__, key_algo, count);
+ }
+ }
+@@ -1520,7 +1520,7 @@
+ plaintext[pt_len] = '\0';
+ handle_decrypted_olm(pc, conn, cevent_sender, sender_key, plaintext);
+ } else {
+- purple_debug_info("matrixprpl", "%s: Type %zd olm\n", __func__, type);
++ purple_debug_info("matrixprpl", "%s: Type %lld olm\n", __func__, type);
+ }
+ if (plaintext) {
+ clear_mem(plaintext, max_plaintext_len);