Commit Graph

3 Commits

Author SHA1 Message Date
Oliver Smith cb707e83c8 scripts/kernel-test: fixup for initrd_add_file
The previous versions happened to work too in my testing with
osmo-ggsn. Use the correct loop variable.

Fixes: 0660fc4e ("scripts/kernel-test: adjust to usr-merge")
Change-Id: I0c0ca91116a8cd156b185bb53512371bbcb76515
2023-07-18 14:24:40 +02:00
Oliver Smith 0660fc4e4b scripts/kernel-test: adjust to usr-merge
In debian bookworm, the /usr merge has been implemented:

  /bin → /usr/bin
  /sbin → /usr/sbin
  /lib → /usr/lib
  /lib64 → /usr/lib64

The initramfs filesystem layout is derived from the paths of the
binaries and libraries in the full system. Create the same symlinks and
adjust initrd_add_bin so it does not trip over the symlinks.

I've also considered to change all input for initrd_add_bin to point at
the /usr/… paths. But this is not possible, for example ldd/lddtree will
point at libraries in /lib and /lib64, and this gets passed to
initrd_add_bin.

Without this patch, the init script and all binaries called from it
cannot be executed.

Related: OS#6057
Related: https://wiki.debian.org/UsrMerge
Change-Id: I975d3af0fa88869688673936a08189de800fba29
2023-07-18 14:12:38 +02:00
Oliver Smith 79e48fd3ae ttcn3-ggsn-test: add kernel test
Make it possible to run ttcn3-ggsn-test against osmo-ggsn with the GTP
kernel module. This feature is enabled by environment variables
explained in ttcn3-ggsn-test/jenkins.sh, and can either use the
pre-built kernel from Debian, or build a kernel from source.

The kernel runs inside QEMU inside the usual osmo-ggsn-master docker
image.

Thanks to Pau for providing the kernel config and kernel-test scripts
that this patch is based on! I ended up modifying them quite a bit to
fit the docker use case, and to build the initrd (so we can use the
stock debian kernel).

Related: OS#3208
Change-Id: I54e752048eed2a170a1cf4e0fd410de255b9de5d
2021-02-26 09:32:39 +01:00