Commit graph

28 commits

Author SHA1 Message Date
Vadym Kochan c69a88190a Revert "keepalived: needs headers >= 3.4"
This reverts commit d01b0bbad0.

Original commit  made restriction for Linux headers < 3.4 which was
related to keepalived version 1.3.5, but it compiles fine now at least
with a toolchain based on 3.2 headers and keepalived 2.0.15 together
with ipset enabled.

Probably it was fixed by this commit:

    5a7f895bb7

Signed-off-by: Vadym Kochan <vadym.kochan@plvision.eu>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2020-11-03 23:44:20 +01:00
Thomas Petazzoni 97b3e2be0c package/keepalived: ipset support only makes sense when iptables is enabled
In keepalived, ipset is only used when iptables support is
enabled. The configure.ac script is quite convoluted, but one can
clearly see:

AS_IF([test .$enable_iptables != .no],
  [
   ... testing for iptables ...
    if test $USE_IPTABLES = Yes; then
      dnl ----[Check for ipset libraries]----
      SAV_CPPFLAGS="$CPPFLAGS"
      CPPFLAGS="$CPPFLAGS $kernelinc"
      if test "${enable_libipset}" != no; then
      ... testing for libipset ...
    fi
  ]

So, the libipset library is only tested and used if iptables is
enabled. This is also visible by the code that shows at the end of the
configure script which features are enabled:

echo "Use iptables             : ${USE_IPTABLES}"
if test .$USE_IPTABLES = .Yes; then
  echo "Use libipset             : ${USE_LIBIPSET}"
fi

Once again, the libipset support only makes sense when iptables is
enabled.

However, the configure.ac script also has some logic to detect if a
--<something>-libipset option is passed while iptables is enabled:

AS_IF([test .$enable_iptables = .no],
    AS_IF([test .$enable_libipset != .], [AC_MSG_ERROR([disable-libipset requires vrrp and iptables])])
  )

The error message is quite misleading because it is in fact displayed
as soon as a --<something>-libipset is passed not just
--disable-libipset.

In the context of Buildroot, we are always passing a
--<something>-libipset, regardless of whether iptables support is
enabled or not, which makes the build error out:

configure: error: disable-libipset requires vrrp and iptables

This commit fixes that by enclosing the libipset logic inside the
iptables condition. When iptables is not available, we pass
--disable-iptables and that's it, nothing else is needed. When
iptables is available, we pass --enable-iptables *and*
--enable-libipset or --disable-libipset depending on the availability
of libipset.

This has been tested successfully with the following combinations:

 - keepalived, without iptables or libipset
 - keepalived, with iptables, but without libipset
 - keepalived, without iptables, but with libipset. In this case
   libipset is obviously not used.
 - keepalived, with iptables and with libipset. Both are used. Note
   that you will not see the keepalived binary linked with libipset.so
   in "readelf -d" because keepalived dlopen()s the libipset.so
   library by default.

Fixes:

  http://autobuild.buildroot.org/results/a1712b2cc3ad878e6876325ec7d4c434d0d9d11b/
  (case with --disable-libipset --disable-iptables)

  http://autobuild.buildroot.net/results/4567e3b0a0510e8a615781178ff5bbbd835a92c3/
  (case with --enable-libipset --disable-iptables)

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2020-08-15 22:39:37 +02:00
Fabrice Fontaine 5fcee496df package/keepalived: drop --{en, dis}able-libiptc option
--{en,dis}able-libiptc has been dropped since version 2.1.0 and
05443e1efa

So replace it by --{en,dis}able-iptables

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2020-07-14 15:16:23 +02:00
Fabrice Fontaine 7eb5c221fd package/keepalived: bump to version 2.1.4
This will fix a build failure with kernel 4.15 thanks to:
d47ae3b1c8

Fixes:
 - http://autobuild.buildroot.org/results/db7f149f63e9180b22460caa74850673362aa17c

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2020-07-12 23:39:12 +02:00
Fabrice Fontaine f466a7dbc1 package/keepalived: bump to version 2.1.2
- Drop patch (already in version) and so autoreconf
- Update indentation in hash file (two spaces)

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2020-06-21 23:04:50 +02:00
Fabrice Fontaine 6c002feeb6 package/keepalived: fix build with -Os
Fixes:
 - http://autobuild.buildroot.org/results/955aef1c25b977d6697fdf8cd1e710f40c7e60a3

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2019-05-25 13:58:42 +02:00
Fabrice Fontaine e45fe7259e package/keepalived: bump to version 2.0.15
Remove patch (already in version)

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-04-22 22:26:11 +02:00
Fabrice Fontaine ab3673d99b package/keepalived: add optional libnftnl dependency
nftables support has been added since version 2.0.11 and
aa12175ea6

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-27 20:10:50 +01:00
Fabrice Fontaine 432b2da126 package/keepalived: fix build with kernel < 4.1
Fixes:
 - http://autobuild.buildroot.org/results/a33433abeb122cfb15f7f21ab777e84040bdcb8b

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2019-03-24 09:09:04 +01:00
Fabrice Fontaine 5068a68381 package/keepalived: drop autoreconf
Commit 78d4ddbf3b removed all patches so
autoreconf is not needed anymore

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-18 22:58:59 +01:00
Fabrice Fontaine 78d4ddbf3b package/keepalived: bump to version 2.0.13
Remove patches (already in version)

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-17 17:28:48 +01:00
Fabrice Fontaine 3fb3de58fd package/keepalived: fix if.h namespace collision
Fixes:
 - http://autobuild.buildroot.org/results/d229602f2e477499c86567e0e8a3535513d322e8

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-01-13 13:55:42 +01:00
Fabrice Fontaine 6b0176cc7d package/keepalived: fix build with uclibc
Retrieve patch from upstream to fix build on uclibc

Fixes:
 - http://autobuild.buildroot.org/results/067ef9ae106b3e0740a70f6f9591b9da00d3da6a

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-11-25 09:39:20 +01:00
Fabrice Fontaine 75d2073e03 keepalived: bump to version 2.0.10
- This version adds support for ipset version 7, see:
  b7a98f9265
- Remove patch and AUTORECONF = YES, an alternative solution has been
  implemented, see:
  9bd10d8168
- Disable hardening option (enabled by default):
  5a65e1eb55

Fixes:
 - http://autobuild.buildroot.org/results/b730e8b25c1d3343b7a6d73f6d3b82b13692578b

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-11-23 21:58:24 +01:00
Fabrice Fontaine fcb77d51d4 keepalived: add libglib2 optional dependency
gio from libglib2 is used for dbus support

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-11-19 21:42:43 +01:00
Fabrice Fontaine 6748f35f3d keepalive: add optional json-c dependency
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-11-19 21:42:34 +01:00
Fabrice Fontaine eded5cecc9 keepalived: remove popt dependency
popt is not needed since version 1.3.1 and:
3452517c4f

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-11-19 21:42:26 +01:00
Thomas Petazzoni e509e04ded keepalived: add patch to disable PIE
PIE breaks the build on m68k and Microblaze, so let's add a patch that
disables using PIE by default in keepalived. Obviously, when we start
seriously testing the BR2_RELRO_FULL option, we will realize that it
is broken on some architectures, and will probably disable it on m68k
and Microblaze.

Fixes:

  http://autobuild.buildroot.net/results/a536f5947b3b70fdaecad1af5542572c504ad046/
  http://autobuild.buildroot.net/results/0ffbf1e8d181c9463847a5b2be6f9baa18face24/

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2018-04-05 23:31:44 +02:00
Thomas Petazzoni 7e4d219495 keepalived: bump to 1.4.2
We can drop 0001-Fix-build-with-Linux-kernel-headers-v4.15.patch as it
has been merged upstream, as of commit
a5457d3a1f.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2018-04-05 23:31:34 +02:00
Peter Korsgaard 92b8bd0879 Merge branch 'next'
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2018-03-05 21:04:14 +01:00
Baruch Siach 6320325eba keepalived: bump to version 1.4.1
Add license file hash.

Cc: Ilias Apalodimas <apalos@gmail.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-02-14 22:05:16 +01:00
Baruch Siach 242abb4b21 keepalived: fix build with 4.15+ kernel headers
Kernel version 4.15 change the logic of libc-compat.h in a way that
introduced libc/kernel network headers collision. Add a patch for fixing
that.

Fixes:
http://autobuild.buildroot.net/results/000/000293275076c59e298d235e93ce9a92b66360e7/
http://autobuild.buildroot.net/results/2ba/2ba8722a42aa9b92f5194595f53130c97647b9b8/
http://autobuild.buildroot.net/results/114/114136447c9b18436ff9b2804c440a2e37576452/

Cc: Ilias Apalodimas <apalos@gmail.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-02-10 08:59:40 +01:00
Ilias Apalodimas d01b0bbad0 keepalived: needs headers >= 3.4
keepalived fails to build on toolchains with headers older than 3.4,
because of a namespace clash between the xt_set.h header from the
kernel and the linux_ip_set.h header installed by ipset.

Even though keepalived does check for pre-3.4 headers, the check
somehow fails to work correctly.

We fix that by making keepalived depend on headers 3.4 or later.

Fixes:
http://autobuild.buildroot.org/results/770/770d8fd2f3bacbdbe233da1b4d6e64e20a84d5a5/
http://autobuild.buildroot.org/results/1ad/1adb710b915427f681eae37452a0942833ce533e/
http://autobuild.buildroot.org/results/70b/70b31547e51ec7213372d2ef07bec34c5df77560/
[...]

Signed-off-by: Ilias Apalodimas <apalos@gmail.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-05-27 17:10:21 +02:00
Rahul Bedarkar af31c309e7 boot, linux, package: use SPDX short identifier for GPLv2/GPLv2+
We want to use SPDX identifier for license strings as much as possible.
SPDX short identifier for GPLv2/GPLv2+ is GPL-2.0/GPL-2.0+.

This change is done by using following command.
find . -name "*.mk" | xargs sed -ri '/LICENSE( )?[\+:]?=/s/\<GPLv2\>/GPL-2.0/g'

Signed-off-by: Rahul Bedarkar <rahulbedarkar89@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-04-01 15:16:38 +02:00
Baruch Siach a429a3803d keepalived: bump to version 1.3.5
The configure script now supports --{enable,disable}-libnl, use them.

Cc: Ilias Apalodimas <apalos@gmail.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-03-20 21:55:32 +01:00
Baruch Siach e64f876bab keepalived: fix libnl optional dependency
List libnl as a dependency when it is enabled. Make sure that
libnfnetlink is actually enabled when listing it as a dependency.

Cc: Ilias Apalodimas <apalos@gmail.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-03-20 21:55:29 +01:00
Baruch Siach 4744ff0173 keepalived: fix build with musl
Apply upstream patch ("keepalived/ip_vs: fix integer types") removing non
standard integer types that musl does not provide.

Fixes:
http://autobuild.buildroot.net/results/503/5038874be985ad2b6588150071ced0d6589af601/
http://autobuild.buildroot.net/results/6e9/6e9f5885de99847a24cc1c3a17adf0cd1606b316/
http://autobuild.buildroot.net/results/b61/b61c2cfa949c2a20f0702522857d78651207e6d2/

Cc: Ilias Apalodimas <apalos@gmail.com>
Cc: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-03-14 21:47:19 +01:00
Ilias Apalodimas 9a7ac39605 keepalived: new package
Signed-off-by: Ilias Apalodimas <apalos@gmail.com>
[Thomas:
 - rewrap Config.in help text
 - add dependency on !BR2_STATIC_LIBS since the code uses libdl.]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-02-20 22:44:08 +01:00