SHA256
1
0
forked from pool/libgtpnl

libgtpnl 1.3.1

This commit is contained in:
Jan Engelhardt 2024-10-26 15:33:11 +02:00
parent 06acfb6569
commit 82dddaf053
6 changed files with 7 additions and 140 deletions

View File

@ -1,94 +0,0 @@
From fba3ca48d9de918b117b42105db751c87ee0dfd8 Mon Sep 17 00:00:00 2001
From: Jan Engelhardt <jengelh@inai.de>
Date: Mon, 21 Oct 2024 00:11:52 +0200
Subject: [PATCH 1/2] Revert `configure: regular_C(PP)FLAGS -> C(PP)FLAGS`
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
This commit reverts dd335ef8fc41567e324a3d26f1ec30d04c69a0bb.
Observed:
```
$ configure && make CPPFLAGS=-DNDEBUG
gcc -DHAVE_CONFIG_H -I. -I.. -DNDEBUG -I../include -I/usr/include/libmnl -DNDEBUG -Wall -Waggregate-return -Wmissing-declarations -Wmissing-prototypes -Wshadow -Wstrict-prototypes -Wformat=2 -pipe -std=gnu11 -fvisibility=hidden -Wall -Waggregate-return -Wmissing-declarations -Wmissing-prototypes -Wshadow -Wstrict-prototypes -Wformat=2 -pipe -std=gnu11 -MT gtp-tunnel.o -MD -MP -MF $depbase.Tpo -c -o gtp-tunnel.o gtp-tunnel.c &&\
```
Expected:
```
gcc -DHAVE_CONFIG_H -I. -I.. -D_FILE_OFFSET_BITS=64 -D_REENTRANT -I../include -I/usr/include/libmnl -D_FILE_OFFSET_BITS=64 -D_REENTRANT -Wall -Waggregate-return -Wmissing-declarations -Wmissing-prototypes -Wshadow -Wstrict-prototypes -Wformat=2 -pipe -std=gnu11 -fvisibility=hidden -Wall -Waggregate-return -Wmissing-declarations -Wmissing-prototypes -Wshadow -Wstrict-prototypes -Wformat=2 -pipe -std=gnu11 -MT gtp-tunnel.o -MD -MP -MF $depbase.Tpo -c -o gtp-tunnel.o gtp-tunnel.c &&\
```
Including ${CFLAGS} in AM_CFLAGS (which is totally wrong)
is the cause for the double apperance of -DNDEBUG.
_FILE_OFFSET_BITS is lost because dd335 violated one core principle
of autoconf/automake: configure MUST run idempotent and not touch
CPPFLAGS and CFLAGS, pursuant to automake.info §3.6 "User variables".
---
Make_global.am | 4 ++--
configure.ac | 16 ++++++++--------
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/Make_global.am b/Make_global.am
index 9a3d5b2..f2cb36c 100644
--- a/Make_global.am
+++ b/Make_global.am
@@ -1,2 +1,2 @@
-AM_CPPFLAGS = ${CPPFLAGS} -I${top_srcdir}/include ${LIBMNL_CFLAGS}
-AM_CFLAGS = ${CFLAGS} ${GCC_FVISIBILITY_HIDDEN}
+AM_CPPFLAGS = ${regular_CPPFLAGS} -I${top_srcdir}/include ${LIBMNL_CFLAGS}
+AM_CFLAGS = ${regular_CFLAGS} ${GCC_FVISIBILITY_HIDDEN}
diff --git a/configure.ac b/configure.ac
index 90e4dce..6eabd32 100644
--- a/configure.ac
+++ b/configure.ac
@@ -9,8 +9,8 @@ AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_HEADERS([config.h])
AM_INIT_AUTOMAKE([foreign tar-pax no-dist-gzip dist-bzip2 1.6 subdir-objects])
-CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=64 -D_REENTRANT"
-CFLAGS="$CFLAGS -Wall -Waggregate-return -Wmissing-declarations \
+regular_CPPFLAGS="-D_FILE_OFFSET_BITS=64 -D_REENTRANT"
+regular_CFLAGS="-Wall -Waggregate-return -Wmissing-declarations \
-Wmissing-prototypes -Wshadow -Wstrict-prototypes \
-Wformat=2 -pipe"
@@ -55,8 +55,8 @@ AC_ARG_ENABLE(sanitize,
[sanitize=$enableval], [sanitize="no"])
if test x"$sanitize" = x"yes"
then
- CFLAGS="$CFLAGS -fsanitize=address -fsanitize=undefined"
- CPPFLAGS="$CPPFLAGS -fsanitize=address -fsanitize=undefined"
+ regular_CFLAGS="-fsanitize=address -fsanitize=undefined"
+ regular_CPPFLAGS="-fsanitize=address -fsanitize=undefined"
fi
AC_ARG_ENABLE(werror,
@@ -74,8 +74,8 @@ then
WERROR_FLAGS+=" -Werror=implicit-int -Werror=int-conversion -Werror=old-style-definition"
WERROR_FLAGS+=" -Wno-error=deprecated -Wno-error=deprecated-declarations"
WERROR_FLAGS+=" -Wno-error=cpp" # "#warning"
- CFLAGS="$CFLAGS $WERROR_FLAGS"
- CPPFLAGS="$CPPFLAGS $WERROR_FLAGS"
+ regular_CFLAGS="$WERROR_FLAGS"
+ regular_CPPFLAGS="$WERROR_FLAGS"
fi
AC_ARG_ENABLE(qemu_tests,
@@ -91,8 +91,8 @@ if test x"$qemu_tests" = x"yes" && ! $srcdir/tests/qemu/check-depends.sh; then
AC_MSG_ERROR([missing programs for --enable-qemu-tests])
fi
-AC_SUBST([CPPFLAGS])
-AC_SUBST([CFLAGS])
+AC_SUBST([regular_CPPFLAGS])
+AC_SUBST([regular_CFLAGS])
AC_CONFIG_FILES([
Makefile
include/Makefile
--
2.47.0

View File

@ -1,34 +0,0 @@
From a715dea96006914b46b6eb108db36a25d8ea3f24 Mon Sep 17 00:00:00 2001
From: Jan Engelhardt <jengelh@inai.de>
Date: Mon, 21 Oct 2024 00:13:46 +0200
Subject: [PATCH 2/2] build: fix bashims in configure.ac
$ foo=bar
$ foo+=zzz
dash: 2: foo+=zzz: not found
Fixes: 1.2.5-6-g0bd1e0d
---
configure.ac | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/configure.ac b/configure.ac
index 6eabd32..24658a4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -71,9 +71,9 @@ AC_ARG_ENABLE(werror,
if test x"$werror" = x"yes"
then
WERROR_FLAGS="-Werror"
- WERROR_FLAGS+=" -Werror=implicit-int -Werror=int-conversion -Werror=old-style-definition"
- WERROR_FLAGS+=" -Wno-error=deprecated -Wno-error=deprecated-declarations"
- WERROR_FLAGS+=" -Wno-error=cpp" # "#warning"
+ WERROR_FLAGS="$WERROR_FLAGS -Werror=implicit-int -Werror=int-conversion -Werror=old-style-definition"
+ WERROR_FLAGS="$WERROR_FLAGS -Wno-error=deprecated -Wno-error=deprecated-declarations"
+ WERROR_FLAGS="$WERROR_FLAGS -Wno-error=cpp" # "#warning"
regular_CFLAGS="$WERROR_FLAGS"
regular_CPPFLAGS="$WERROR_FLAGS"
fi
--
2.47.0

BIN
1.3.0.tar.gz (Stored with Git LFS)

Binary file not shown.

BIN
1.3.1.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -1,10 +1,8 @@
-------------------------------------------------------------------
Sun Oct 20 22:03:07 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
Sat Oct 26 13:32:40 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
- Update to release 1.3.0
- Update to release 1.3.1
* Add IPv6 support
- Add 0001-Revert-configure-regular_C-PP-FLAGS-C-PP-FLAGS.patch,
0002-build-fix-bashims-in-configure.ac.patch
-------------------------------------------------------------------
Wed Nov 1 18:20:21 UTC 2023 - Jan Engelhardt <jengelh@inai.de>

View File

@ -17,15 +17,13 @@
Name: libgtpnl
Version: 1.3.0
Version: 1.3.1
Release: 0
Summary: GPRS tunnel configuration library
License: GPL-2.0-or-later AND LGPL-2.1-or-later
Group: Development/Libraries/C and C++
URL: https://osmocom.org/projects/linux-kernel-gtp-u/wiki
Source: https://github.com/osmocom/libgtpnl/archive/%version.tar.gz
Patch1: 0001-Revert-configure-regular_C-PP-FLAGS-C-PP-FLAGS.patch
Patch2: 0002-build-fix-bashims-in-configure.ac.patch
BuildRequires: libtool >= 2
BuildRequires: pkg-config
BuildRequires: pkgconfig(libmnl) >= 1.0.0
@ -81,8 +79,7 @@ rm -f "%buildroot/%_libdir"/*.la
%check
%make_build check
%post -n libgtpnl0 -p /sbin/ldconfig
%postun -n libgtpnl0 -p /sbin/ldconfig
%ldconfig_scriptlets -n libgtpnl0
%files -n libgtpnl0
%_libdir/libgtpnl.so.0*