All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] logrotate: bump to version 3.11.0
@ 2017-02-07 14:04 Adam Duskett
  2017-02-07 14:04 ` [Buildroot] [PATCH 2/2] logrotate: enable selinux support Adam Duskett
  2017-02-07 16:42 ` [Buildroot] [PATCH 1/2] logrotate: bump to version 3.11.0 Thomas Petazzoni
  0 siblings, 2 replies; 4+ messages in thread
From: Adam Duskett @ 2017-02-07 14:04 UTC (permalink / raw)
  To: buildroot

Also removed both patches as they have been added to this release.
Aslo removed reference to github patch in makefile as it has been
added to this release as well.

Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
---
 package/logrotate/0001-make-autoreconfable.patch   | 20 -------
 ...-autoconf-checks-for-strndup-and-asprintf.patch | 61 ----------------------
 package/logrotate/logrotate.hash                   |  3 +-
 package/logrotate/logrotate.mk                     |  3 +-
 4 files changed, 2 insertions(+), 85 deletions(-)
 delete mode 100644 package/logrotate/0001-make-autoreconfable.patch
 delete mode 100644 package/logrotate/0002-Use-autoconf-checks-for-strndup-and-asprintf.patch

diff --git a/package/logrotate/0001-make-autoreconfable.patch b/package/logrotate/0001-make-autoreconfable.patch
deleted file mode 100644
index 89759d0..0000000
--- a/package/logrotate/0001-make-autoreconfable.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-Make the package autoreconfigurable
-
-Adjust a minor detail in configure.ac in order to make the package
-compatible with the autoconf/automake versions we are using in
-Buildroot.
-
-Signed-off-by: Beno?t Th?baudeau <benoit.thebaudeau.dev@gmail.com>
-
-Index: b/configure.ac
-===================================================================
---- a/configure.ac
-+++ b/configure.ac
-@@ -1,6 +1,6 @@
- AC_INIT([logrotate],[3.8.9])
- 
--AM_INIT_AUTOMAKE
-+AM_INIT_AUTOMAKE([foreign])
- AC_DEFINE(_GNU_SOURCE)
- 
- AM_EXTRA_RECURSIVE_TARGETS([test])
diff --git a/package/logrotate/0002-Use-autoconf-checks-for-strndup-and-asprintf.patch b/package/logrotate/0002-Use-autoconf-checks-for-strndup-and-asprintf.patch
deleted file mode 100644
index 14efc1d..0000000
--- a/package/logrotate/0002-Use-autoconf-checks-for-strndup-and-asprintf.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From e626f4ca5169036a0042e55e58aca2bb5cc19ad7 Mon Sep 17 00:00:00 2001
-From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-Date: Fri, 19 Aug 2016 22:39:17 +0200
-Subject: [PATCH] Use autoconf checks for strndup and asprintf
-
-The current code in config.c can provide its own implementation of
-asprintf() and strndup() if not provided by the system. However, in
-order to decide if they should be provided, the check done is:
-
- #if !defined(name_of_function)
-
-which only works if the function is actually defined as a macro, which
-is not necessarily the case.
-
-Therefore, we replace this logic by a proper AC_CHECK_FUNCS() check in
-the configure script.
-
-Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
----
- config.c     | 4 ++--
- configure.ac | 2 ++
- 2 files changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/config.c b/config.c
-index 8731348..8741e48 100644
---- a/config.c
-+++ b/config.c
-@@ -45,7 +45,7 @@
- #include "asprintf.c"
- #endif
- 
--#if !defined(asprintf) && !defined(_FORTIFY_SOURCE)
-+#if !defined(HAVE_ASPRINTF) && !defined(_FORTIFY_SOURCE)
- #include <stdarg.h>
- 
- int asprintf(char **string_ptr, const char *format, ...)
-@@ -78,7 +78,7 @@ int asprintf(char **string_ptr, const char *format, ...)
- 
- #endif
- 
--#if !defined(strndup)
-+#if !defined(HAVE_STRNDUP)
- char *strndup(const char *s, size_t n)
- {
-        size_t nAvail;
-diff --git a/configure.ac b/configure.ac
-index 5c83d20..51da52a 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -18,6 +18,8 @@ AC_SYS_LARGEFILE
- AC_CHECK_LIB([popt],[poptParseArgvString],,
-   AC_MSG_ERROR([libpopt required but not found]))
- 
-+AC_CHECK_FUNCS([strndup asprintf])
-+
- dnl Needed for out-of-source builds
- mkdir -p test
- 
--- 
-2.7.4
-
diff --git a/package/logrotate/logrotate.hash b/package/logrotate/logrotate.hash
index 3003d42..4985a17 100644
--- a/package/logrotate/logrotate.hash
+++ b/package/logrotate/logrotate.hash
@@ -1,3 +1,2 @@
 # Locally calculated
-sha256 db63b5932190cba941357c029b595a7fddf43539943aa1e0ca53a96136e4c5d9 logrotate-3.10.0.tar.gz
-sha256 e0d360908ac506e02f08fa1ad70e17d6985045d8640f383fef8f322886d6e1e1 6a36c105587b07ad14fc937f3ee6e2eb402621a2.patch
+sha256 62aa0229cfd34c7b6ea6a6736d569983bf4a3dd1f3c9e9c2efe2ffe2a0a55cf2 logrotate-3.11.0.tar.gz
diff --git a/package/logrotate/logrotate.mk b/package/logrotate/logrotate.mk
index 14d0693..7828870 100644
--- a/package/logrotate/logrotate.mk
+++ b/package/logrotate/logrotate.mk
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-LOGROTATE_VERSION = 3.10.0
+LOGROTATE_VERSION = 3.11.0
 LOGROTATE_SITE = $(call github,logrotate,logrotate,$(LOGROTATE_VERSION))
 LOGROTATE_LICENSE = GPLv2+
 LOGROTATE_LICENSE_FILES = COPYING
@@ -13,7 +13,6 @@ LOGROTATE_DEPENDENCIES = popt host-pkgconf
 LOGROTATE_AUTORECONF = YES
 LOGROTATE_CONF_ENV = LIBS="`$(PKG_CONFIG_HOST_BINARY) --libs popt`"
 LOGROTATE_CONF_OPTS = --without-selinux
-LOGROTATE_PATCH = https://github.com/logrotate/logrotate/commit/6a36c105587b07ad14fc937f3ee6e2eb402621a2.patch
 
 ifeq ($(BR2_PACKAGE_ACL),y)
 LOGROTATE_DEPENDENCIES += acl
-- 
2.9.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [Buildroot] [PATCH 2/2] logrotate: enable selinux support.
  2017-02-07 14:04 [Buildroot] [PATCH 1/2] logrotate: bump to version 3.11.0 Adam Duskett
@ 2017-02-07 14:04 ` Adam Duskett
  2017-02-07 16:43   ` Thomas Petazzoni
  2017-02-07 16:42 ` [Buildroot] [PATCH 1/2] logrotate: bump to version 3.11.0 Thomas Petazzoni
  1 sibling, 1 reply; 4+ messages in thread
From: Adam Duskett @ 2017-02-07 14:04 UTC (permalink / raw)
  To: buildroot

Selinux is currently disabled staticly in logrotate. This patch
fixes this by checking for libselinux and adding it as a dependecy
if it has been selected.  The configure script is set to check for
libselinux by default, so I only set --without-selinux implicitly
if libselinux hasn't been selected, otherwise it's left alone.

Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
---
 package/logrotate/logrotate.mk | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/package/logrotate/logrotate.mk b/package/logrotate/logrotate.mk
index 7828870..673e452 100644
--- a/package/logrotate/logrotate.mk
+++ b/package/logrotate/logrotate.mk
@@ -12,7 +12,12 @@ LOGROTATE_DEPENDENCIES = popt host-pkgconf
 # tarball does not have a generated configure script
 LOGROTATE_AUTORECONF = YES
 LOGROTATE_CONF_ENV = LIBS="`$(PKG_CONFIG_HOST_BINARY) --libs popt`"
-LOGROTATE_CONF_OPTS = --without-selinux
+
+ifeq ($(BR2_PACKAGE_LIBSELINUX),y)
+LOGROTATE_DEPENDENCIES += libselinux
+else
+LOGROTATE_CONF_OPTS += --without-selinux
+endif
 
 ifeq ($(BR2_PACKAGE_ACL),y)
 LOGROTATE_DEPENDENCIES += acl
-- 
2.9.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [Buildroot] [PATCH 1/2] logrotate: bump to version 3.11.0
  2017-02-07 14:04 [Buildroot] [PATCH 1/2] logrotate: bump to version 3.11.0 Adam Duskett
  2017-02-07 14:04 ` [Buildroot] [PATCH 2/2] logrotate: enable selinux support Adam Duskett
@ 2017-02-07 16:42 ` Thomas Petazzoni
  1 sibling, 0 replies; 4+ messages in thread
From: Thomas Petazzoni @ 2017-02-07 16:42 UTC (permalink / raw)
  To: buildroot

Hello,

On Tue,  7 Feb 2017 09:04:10 -0500, Adam Duskett wrote:
> Also removed both patches as they have been added to this release.
> Aslo removed reference to github patch in makefile as it has been
> added to this release as well.
> 
> Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
> ---
>  package/logrotate/0001-make-autoreconfable.patch   | 20 -------
>  ...-autoconf-checks-for-strndup-and-asprintf.patch | 61 ----------------------
>  package/logrotate/logrotate.hash                   |  3 +-
>  package/logrotate/logrotate.mk                     |  3 +-
>  4 files changed, 2 insertions(+), 85 deletions(-)
>  delete mode 100644 package/logrotate/0001-make-autoreconfable.patch
>  delete mode 100644 package/logrotate/0002-Use-autoconf-checks-for-strndup-and-asprintf.patch

Applied to master, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Buildroot] [PATCH 2/2] logrotate: enable selinux support.
  2017-02-07 14:04 ` [Buildroot] [PATCH 2/2] logrotate: enable selinux support Adam Duskett
@ 2017-02-07 16:43   ` Thomas Petazzoni
  0 siblings, 0 replies; 4+ messages in thread
From: Thomas Petazzoni @ 2017-02-07 16:43 UTC (permalink / raw)
  To: buildroot

Hello,

On Tue,  7 Feb 2017 09:04:11 -0500, Adam Duskett wrote:
> Selinux is currently disabled staticly in logrotate. This patch
> fixes this by checking for libselinux and adding it as a dependecy
> if it has been selected.  The configure script is set to check for
> libselinux by default, so I only set --without-selinux implicitly
> if libselinux hasn't been selected, otherwise it's left alone.

No, we really want --with-selinux. If you don't pass --with-selinux,
then the default beaviour of this configure is to "check", which means
that if it finds SELinux support, it enables it, otherwise it moves on
with SELinux disabled.

But in Buildroot, if we enable SELinux support, we really want it. We
don't want package to silently ignore it if there's some kind of error.
Which is why for all optional dependencies, we always explicitly
enable/disable it.

I've fixed that up and applied.

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-02-07 16:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-02-07 14:04 [Buildroot] [PATCH 1/2] logrotate: bump to version 3.11.0 Adam Duskett
2017-02-07 14:04 ` [Buildroot] [PATCH 2/2] logrotate: enable selinux support Adam Duskett
2017-02-07 16:43   ` Thomas Petazzoni
2017-02-07 16:42 ` [Buildroot] [PATCH 1/2] logrotate: bump to version 3.11.0 Thomas Petazzoni

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.