osmith has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/libosmocore/+/34188 )


Change subject: debian: depend on liburing-dev for debian >= 11
......................................................................

debian: depend on liburing-dev for debian >= 11

Prepare for the io_uring backend, by conditionally depending on
liburing-dev on debian >= 11 based distributions. On debian 10 based
distributions, set --disable-uring as configure flag.

Closes: OS#6143
Related: https://askubuntu.com/a/761943
Change-Id: If7832baec0bddbe0bbbbfe07f77bba3deb328d5c
---
M debian/control
M debian/rules
2 files changed, 28 insertions(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/88/34188/1

diff --git a/debian/control b/debian/control
index b5b357f..1f1975e 100644
--- a/debian/control
+++ b/debian/control
@@ -19,6 +19,7 @@
                libusb-1.0-0-dev,
                libmnl-dev,
                libsystemd-dev,
+               base-files (<< 11) | liburing-dev,
                python3:native
 Standards-Version: 3.9.8
 Vcs-Git: https://gitea.osmocom.org/osmocom/libosmocore
diff --git a/debian/rules b/debian/rules
index 91d5678..efa5adc 100755
--- a/debian/rules
+++ b/debian/rules
@@ -25,8 +25,19 @@
 override_dh_auto_test:
        dh_auto_test || (find . -name testsuite.log -exec cat {} \; ; false)

+# Set --disable-uring for debian < 11 based distributions
 override_dh_auto_configure:
-       dh_auto_configure -- --enable-static --disable-sctp-tests 
--enable-systemd-logging
+       set -x && \
+       CONFIGURE_FLAGS=" \
+               --disable-sctp-tests \
+               --enable-static \
+               --enable-systemd-logging \
+       "; \
+       base_ver="$$(dpkg -l base-files | grep "^ii" | awk '{print $$3}')"; \
+       if dpkg --compare-versions "$$base_ver" lt 11; then \
+               CONFIGURE_FLAGS="$$CONFIGURE_FLAGS --disable-uring"; \
+       fi; \
+       dh_auto_configure -- $$CONFIGURE_FLAGS

 override_dh_clean:
        dh_clean

--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/34188
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: If7832baec0bddbe0bbbbfe07f77bba3deb328d5c
Gerrit-Change-Number: 34188
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <[email protected]>
Gerrit-MessageType: newchange

Reply via email to