Commit Graph

123 Commits

Author SHA1 Message Date
Andreas Eversberg 35f20b1ff7 osmo_io_uring: Run check of tests/osmo_io with io_uring also
Related: OS#5751
Change-Id: I82db9a15bc483a5447d86352512afaafa2bcfbb6
2024-03-20 12:11:08 +01:00
Pau Espin aca2c724ae Bump version: 1.8.0.252-13c29 → 1.9.0
Change-Id: I6f8eccbccb73c6c094f13f2d4bdee931cf5b9010
2023-09-12 13:15:54 +02:00
Oliver Smith 405e7cc971 debian: fix build on ubuntu 20.04 without liburing
Ubuntu 20.04 is based on debian 11, but does not have liburing. Extend
the logic to cover this distribution too, so building packages for it
isn't stuck anymore on libosmocore not being able to resolve the
liburing-dev dependency.

I have verified that this makes libosmocore properly build with/without
liburing on debian 10, 11 and ubuntu 20.04 and 22.04.

Fixes: e486e012 ("debian: depend on liburing-dev for debian >= 11")
Change-Id: If18d6543fae9537c8b188e90499491bda3fdfe59
2023-08-31 14:48:49 +02:00
Oliver Smith e486e012c8 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
2023-08-24 15:24:33 +00:00
Oliver Smith 779ff09fc9 debian: set compat level to 10
Related: OS#5958
Change-Id: I6ee4aace6bf7c246338408c41f790189d75d5488
2023-04-27 12:28:12 +00:00
Harald Welte b394d6fc85 New osmo-gsmtap-logsend utility
This utility can be used to "pipe" stdin or some file as log lines
via GSMTAP logging.

Change-Id: Ida96e87d84e0c349c5069edc67fec1c3cf19d1ab
2023-03-15 11:53:08 +00:00
Vadim Yanitskiy 94e0af0a6d doxygen: also generate documentation for libosmo{sim,usb}
We do have API documentation for all libraries, excepte these two.

Change-Id: I2ec5803bc219b9ceaf0d52d41a03ab78f580e689
2023-02-27 11:14:40 +00:00
Vadim Yanitskiy 85e24a6410 debian/control: fix typo
Change-Id: Ia9f99016dcf2a9584b59a253d19f391e8f5e5abb
2023-02-27 11:14:40 +00:00
Vadim Yanitskiy dbd61f077f debian/control: make libosmocore-doc depend on libosmo{ctrl,gb}-doc
Change-Id: Icd84afcd035bdca9aabb4ea2b91c1227c4786da7
2023-02-27 11:14:40 +00:00
Pau Espin 5f15e4199c Bump version: 1.7.0.119-b31a-dirty → 1.8.0
Change-Id: I5e953cedc041371a9c192f58348b673a787f542e
2023-02-07 11:20:42 +01:00
Pau Espin 672e8d1041 debian/rules: Fix moved path crc*gen.c
Fixes: d4c3dc8d59
Change-Id: I89b4e77e3a7e2de9ec56af4dc348ec060df8da4d
2023-02-07 11:16:09 +01:00
Oliver Smith 8d92d9cdbe d/control: libosmocore-dev: depend on libmnl-dev
Let libosmocore-dev depend on libmnl-dev, as we build the debian package
without --disable-libmnl and so libosmocore.pc lists libmnl in requires.
This patch should fix the following error when trying to build any
debien package depending on libosmocore-dev:

  Package 'libmnl', required by 'libosmocore', not found

A similar change in the rpm spec is not be needed, as rpm adds depends
from pc files automatically.

Fixes: 4eb89afa ("configure --enable-libmnl: Add libmnl to libosmocore.pc.in Requires")
Change-Id: I7fd578fcc22c0ea6ac04bdc26dc1741e4e26767c
2023-01-26 09:19:29 +01:00
Harald Welte d55a209d1c create libosmoisdn sub-library
There are some parts of libosmogsm which are not really GSM specific,
but rather ISDN bits that were inherited by GSM.  This includes the
I.460 multiplex as well as the core LAPD protocol.

Let's move those bits to its own libosmoisdn library, before we add
more ISDN specific bits to the wrong place.

Backwards-compatibility is created by making libosmogsm depend on
libosmoisdn, and by providing wrapper include files for source
compatibility.

Change-Id: Ib1a6c762322fd5047be3188b1df22408ef06aa50
2023-01-21 22:41:57 +01:00
Pau Espin d4c3dc8d59 Move src/*.{c,h} to src/core/
This way we have all libosmocore.so in an own subdir instead of having
lots of files in the parent dir, which also contains subdirs to other
libraries.
This also matches the schema under include/osmocom/.

Change-Id: I6c76fafebdd5e961aed88bbecd2c16bc69d580e2
2023-01-18 17:14:06 +01:00
Pau Espin a1584d237b Bump version: 1.6.0.132-0239-dirty → 1.7.0
Change-Id: Idb0d20aa4336a69cb100e140fb1fa9e7ac25b984
2022-06-28 17:00:51 +02:00
Harald Welte 0239620bd1 update git URLs (git -> https; gitea)
Change-Id: I22bc1dd5c8a33fbccc8cc6d0d8daf7f558f17f44
2022-06-17 23:20:26 +02:00
Harald Welte a47eefee56 debian/control: libosmocore-dev must depend on libsctp-dev and libusb-1.0-0-dev
As our pkg-config files now 'Require' libsctp, we are seeing build
failures as libsctp-dev is not installed when building
libosmocore-dependant packages.  Let's add the missing dependency.

Change-Id: I5d61149cd5b571586d426d1d6bf929e73a322fff
Fixes: I2ab1fe8e4bbfc120b471d6c9f2312a89dbc7d42b
2022-03-25 10:39:39 +01:00
Vadim Yanitskiy 8ee1dfe3c0 debian/control: minimum version of libtalloc-dev must be >= 2.1.0
Change-Id: Id20871b76c4a5801defb4f534fad635b7f079a13
2021-11-17 20:13:36 +00:00
Pau Espin c7deaf28aa Bump version: 1.5.1.282-ab5e-dirty → 1.6.0
Change-Id: Ia3ac0a36b9e898996f596c6d2787e03cd59bfc11
2021-11-16 13:08:23 +01:00
Harald Welte 8602106224 utils: osmo-aka-verify to verify UMTS AKA (SIM side)
This new utility implements the UMTS AKA procedures of the SIM
side.  It can be used to manually verify the correctness of
authentication tuples received from the network.

Change-Id: I497747fbf09f633dcd7c592bd9af7fca9a820645
2021-03-20 11:00:27 +00:00
Harald Welte 4bedb53b34 Bump version: 1.5.0.3-45cf → 1.5.1
Change-Id: I6eea93d9723f7e6ffd1f9eb3d260a5b666cb2124
2021-02-24 09:35:21 +01:00
Pau Espin Pedrol f286fdc87e Bump version: 1.4.0.535-e387-dirty → 1.5.0
Change-Id: I3bc0826c0000be4d76235ed6b5be86d216ea2e4d
2021-02-23 14:03:31 +01:00
Harald Welte 700822b305 Enable systemd-journald log target in debian + rpm packaging
Given that all the distributions we support are shipping systemd
anyway, this will not really introduce any additional runtime package
dependencies.

Change-Id: Ib3af918cd4cc8d0ca6d228a0f2c8338534374d46
2021-02-03 14:56:17 +01:00
Harald Welte 53a2fde368 Integrate libmnl (minimal netlink) library with libosmocore select loop
This adds an easy way to listen to netlink events form the Linux kernel
from within libosmocore applications.

The new dependency can be disabled via the "--disable-lbimnl" configure flag.

Change-Id: I4f787ee68f0d6d04f0a5655eb57d55b3b326a42f
2020-12-02 21:04:51 +00:00
Pau Espin 16b076cd15 tests: Split SCTP tests to its own file and run them conditionally
Some systmes (like the ones available in OBS) don't support creating
SCTP sockets, so we need to skip those tests there.

Change-Id: I1d16280674625877ec22cc60cbc5deb67868a656
2020-08-25 14:22:03 +02:00
Vadim Yanitskiy 441dd32e89 debian/control: change maintainer to the Osmocom team / mailing list
Change-Id: Ia340c28169c8bfd07c37d320c3f5386a06e4c092
2020-08-13 15:00:34 +00:00
Harald Welte 5c5713e869 Bump version: 1.3.0.173-51974 → 1.4.0
Change-Id: I4fc6dd4f727c8ff5a64865bbb87e1d9feb7c5174
2020-08-13 11:06:36 +02:00
Maksim Aristov 7bdb94b760 debian: Change python3 dependency to native arch
This small fix enables cross compilation using dpkg-buildpackage on multiarch:
https://wiki.debian.org/CrossCompiling#Building_with_dpkg-buildpackage

`apt build-dep -a<arch>` incorrectly installed non-native python for building

Change-Id: I85994447657cda757348855c3ee9978e8c7c2377
2020-03-17 00:39:45 +00:00
Pau Espin 2862f9082e Bump version: 1.2.0.108-c6a8-dirty → 1.3.0
Change-Id: I5698bfe45467a8b0e44549105aaf27b8da500de8
2020-01-02 18:42:30 +01:00
Pau Espin dddeaa9868 Drop empty file debian/patches/series
Change-Id: I1a4aa5d6785aa7ff7dc454930a84d73fe1114726
2020-01-02 18:35:50 +01:00
Harald Welte 22c7ec3b60 debian/control: Add missing libusb-1.0-0-dev dependency
In Change-Id I656a1a38cbb5b1f3a9145d2869d3b4d0adefcae3 we introduced
USB support and also updated debian pacakaging informatio for this
new package - however, I missed to add a realted Build-Depends line :(

Change-Id: Ib0446510c8ba49623914b6103ea9cfa88c208d50
Related: #4299
2019-12-17 13:49:28 +01:00
Harald Welte da432cdc35 libosmocore libusb integration
Osmocom applications typically use libosmocore select.[ch] event loop
code as their main event dispatch mechanism.  When they want to deal
with libusb in a non-blocking/asynchronous way, they need to integrate
libusb into that select().

The new libosmousb is doing exactly that: Providing a shared utility
library for Osmocom programs that wish to use libusb.  This is useful
for example in simtrace2 host utilitie as well as osmo-e1d.

Change-Id: I656a1a38cbb5b1f3a9145d2869d3b4d0adefcae3
Closes: OS#4299
2019-12-16 00:17:27 +01:00
Oliver Smith a47d37c946 debian, utils: switch to python 3
Make build and external tests work with python3, so we can drop
the python2 dependency.

This should be merged shortly after osmo-python-tests was migrated to
python3, and the jenkins build slaves were (automatically) updated to
have the new osmo-python-tests installed.

Related: OS#2819
Depends: osmo-python-tests I3ffc3519bf6c22536a49dad7a966188ddad351a7
Change-Id: I84ef43f700e125c7a65f92347f12844e07e65655
2019-12-12 09:24:04 +00:00
Vasil Velichkov 499510bd52 Add code coverage support
The coverage report shows what code is covered by tests and what is not
and the ratio could be tracked over time. These reports will allow us
to identify code that is not being tested and improve the test suites.

To enable the reports configure with --enable-code-coverage and execute
"make check-code-coverage". The HTML report will be generated in a
subdirectory with name libosmocore-$(PACKAGE_VERSION)-coverage/index.html

The report is generated using gcov, lcov and lcov_cobertura tools and
the OSMO_AC_CODE_COVERAGE macro. The osmo_ax_code_coverage.m4 is a copy of
ax_code_coverage.m4 taken from autoconf-archive v2018.03.13. It was
copied to avoid the additional external dependency and renamed to avoid
overwriting it in case autoconf-archive is already installed as we are
going to install it in $(datadir)/aclocal in order to be reused in other
osmocom's projects.

Closes: OS#1987
Change-Id: I6f4ffb91bd7f3dd070aa09dd16d5ad1faf130a4c
2019-11-30 02:17:23 +00:00
Pau Espin 3f464fc007 socket: Introduce API osmo_sock_init2_multiaddr()
This API will be used by libosmo-netif's osmo_stream for SCTP sockets,
which in turn will be used by libosmo-sccp to support multi-homed
connections.

Related: OS#3608
Change-Id: Ic8681d9e093216c99c6bca4be81c31ef83688ed1
2019-10-18 09:21:48 +00:00
Pau Espin 922d276035 Bump version: 1.1.0.107-afce-dirty → 1.2.0
Change-Id: I05dd1f2725e05f856f1d27c9201a0005de101b8f
2019-08-06 18:02:02 +02:00
Pau Espin 1fcdd0d1b8 Bump version: 1.0.1.143-cc72c → 1.1.0
Change-Id: I351411ca5913c8b40f23287ec7c9ebfe11bd2bb0
2019-05-07 18:36:51 +02:00
Harald Welte 3927cc4368 Bump version: 1.0.0 → 1.0.1
Change-Id: I51696a3ace219ab69c294b0e3637371c5460291f
2019-01-21 17:40:34 +00:00
Harald Welte a0c1cba28a Bump version: 0.12.0.128-8dfde → 1.0.0
Change-Id: I1bd973754b1ebc42283f6a07defa60f58523f5a3
2019-01-19 22:07:56 +01:00
Harald Welte 81bfef931a Add new osmo-config-merge utility
This utility allows you to merge an incremental config "patch"
into an osmocom-style config file.

The patch file follows the same syntax as the original config file.

It works by appending the leaf nodes of the patch file to the respective
nodes of the input config file.

This process allows configuration file changes/updates to be performed
in a more stable/reliable way than by means of [unified] diff files,
as they break every time the context lines break.

osmo-config-merge doesn't suffer from this problem, as it understands
the tree-like nature of VTY config files.

NITE: This only works with configuration files that have proper
indenting, i.e. every level in the hierarchy must be indented excatly
one character, not multiple.

Change-Id: I61997a3668cc3a40d12ca023272f6d782e6fbefe
2018-09-25 20:05:02 +02:00
Harald Welte d14eccd1a7 debian/rules: Don't overwrite .tarball-version
The .tarball-version file should contain the *source version* uniquely
identifying the git commit, and not the Debian package name.

With https://gerrit.osmocom.org/#/c/osmo-ci/+/10343/ there is a correct
.tarball-version file in the .tar.xz of the nightly source packages.

Change-Id: Ibeb6d273e2d26f37a36cbde4a948ce95395491f8
Related: OS#3449
2018-08-06 11:09:40 +02:00
Pau Espin 924ef0bc72 Bump version: 0.11.0.91-9d4a3-dirty → 0.12.0
Change-Id: I7e66432f37e13fd4c31389e3d89593fa0981e58f
2018-07-27 17:31:47 +02:00
Harald Welte 572fc2d344 debian: Add libosmoctrl-doc sub-package
This fixes the debian package builds for libosmocore.git

Change-Id: I454e3c0175ab5a89e8925e036a3644299367df0f
2018-05-28 17:55:51 +02:00
Pau Espin 13154ffabd Bump version: 0.10.2.284-bc47-dirty → 0.11.0
Remark: For libosmogb and libosmogsm, LIBVERSION was
already bumped in c4fce1425e.

Change-Id: Ib4fa53a9bb9954ae48d0a610ba9a81dd8e8b4ef6
2018-05-03 15:47:11 +02:00
Pau Espin 456081dd0d debian/changelog: Fix typo in maintainer e-mail
Change-Id: I74bef283090fd7601491c9fef9637f845853d032
2018-05-03 15:39:11 +02:00
Pau Espin 93288d76da debian: libosmoctrl: Use correct library version in pkg name
The number used in debian packaging is actually current-age, which is
still 0 in this case after it was bumped a while ago.

As a result, we had a libosmoctrl1_*.deb package installing a
libosmoctrl.so.0 file.

Fixes: OS#3175

Change-Id: I771f6c68570bc3b2bab68e1165c7284fd43e904d
2018-05-03 15:35:40 +02:00
Neels Hofmeyr c4fce1425e implement support for 3-digit MNC with leading zeros
Enable representing three-digit MNC with leading zeros. The MNCs 23 and 023 are
actually different; so far we treated both as 23. Re-encode an incoming BCD or
string of 023 as it were, i.e. not dropping the leading zero as 23.

Break ABI compatibility by changing the size and ordering of structs
gprs_ra_id, osmo_plmn_id, osmo_cell_global_id, ... by adding an mnc_3_digits
flag.

Change ordering in gprs_ra_id because the canonical oder is {Mobile Country
Code, Mobile Network Code}, so have the mcc member first.

ABI compatibility cannot be maintained for struct gprs_ra_id, since it is a
direct member of structs bssgp_bvc_ctx and bssgp_paging_info, and even just
adding a flag to the end would cause ABI changes of those structs. Similarly,
osmo_plmn_id is a direct member of osmo_location_area_id, and so forth.

Add new API to set and read this additional flag to preserve leading zeros:
- osmo_plmn_to_bcd(), osmo_plmn_from_bcd() after
  gsm48_mcc_mnc_to_bcd() and gsm48_mcc_mnc_from_bcd().
- gsm48_decode_lai2(), gsm48_generate_lai2() after
  gsm48_decode_lai(), gsm48_generate_lai().
- gsm0808_create_layer3_2() after gsm0808_create_layer3() and gsm0808_create_layer3_aoip().
- various osmo_*_name() functions in gsm23003.h (osmo_rai_name() still in
  gsm48.h close to struct gprs_ra_id definition). The amount and duplication of
  these may seem a bit overboard, but IMO they do make sense in this way.
  Though most code will soon see patches unifying the data structures used, in
  some cases (vty, ctrl) they are required singled out. Without these
  functions, the formatting ("%0*u", mnc_3_digits ?  3 : 2, mnc) would be
  duplicated all over our diverse repositories.

In various log output, include the leading MNC zeros.

Mark one TODO in card_fs_sim.c, I am not sure how to communicate a leading zero
to/from a SIM card FS. The focus here is on the core network / BSS.

To indicate ABI incompatibility, bump libosmogsm and libosmogb LIBVERSIONs;
adjust debian files accordingly.

Implementation choices:

- The default behavior upon zero-initialization will be the mnc_3_digits flag
  set to false, which yields exactly the previous behavior.

- I decided against packing the mnc with the mnc_3_digits field into a
  sub-struct because it would immediately break all builds of dependent
  projects: it would require immediate merging of numerous patches in other
  repositories, and it would make compiling older code against a newer
  libosmocore unneccessarily hard.

Change-Id: Id2240f7f518494c9df6c8bda52c0d5092f90f221
2018-02-28 19:26:33 +01:00
Harald Welte 4bfa171e92 debian/control: Fix Vcs-Browser URL
Change-Id: I89bff8fcb8e0b7c0a0e415d4eee1636c21b8f8de
2018-02-09 12:12:03 +01:00
Harald Welte 4e4521b3d5 Revert "Use python 3 for utilities"
This reverts commit 76c6c50405, which broke the obs builds. I'm really starting to get annoyed by ongoing python related breakage without ever fixing any bugs!

Change-Id: I4d76e897d4f746ff9ea4e06f2efc708a12cc2944
2018-02-09 08:49:26 +00:00
Max 76c6c50405 Use python 3 for utilities
There're no python2-specific code in there so we can switch right away
without waiting till 2020 for python 2 deprecation.

Related: OS#2819
Change-Id: I8d34aed124b00c5dd2ab1bcc84bbfa8c620282cc
2018-02-08 09:31:04 +00:00