packages/libs/apr/patches/002-sys-param-h.patch
Sebastian Kemper 193c3913b6 apr: clean up the patches + enable LFS
- removes 001-autoconf-compat.patch:
  Looks like this was meant as a workaround for a libtool issue. But it
  doesn't appear to be needed anymore.
- removes 101-fix_apr_time_now.patch:
  Mentioned in https://dev.openwrt.org/ticket/9287, meant as a fix, but
  issue was fixed differently in the end (by activating LFS).
- removes 201-upgrade-and-fix-1.5.1.patch:
  This is a cross-compile fix. This patch gets replaced by
  001-cross-compile.patch from buildroot project. The latter was sent
  upstream by buildroot and is in line with the patch used by OpenWrt
  for the apache package.
- adds 002-sys-param-h.patch:
  Fix PATH_MAX detection by including sys/param.h if available. Also
  from buildroot.

Additionally configure variables found in buildroot package are added.
These also enable LFS support. This was previously done (in OpenWrt) by
defining _LARGEFILE64_SOURCE in TARGET_CPPFLAGS. But the configure
variable is cleaner (and easier to follow).

Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
2020-01-26 18:50:06 +01:00

37 lines
972 B
Diff

Fix PATH_MAX detection by including sys/param.h if available
Patch sent upstream:
https://bz.apache.org/bugzilla/show_bug.cgi?id=63782
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
--- a/configure.in
+++ b/configure.in
@@ -1593,6 +1593,7 @@ AC_SUBST(stdlibh)
AC_SUBST(stringh)
AC_SUBST(stringsh)
AC_SUBST(sys_ioctlh)
+AC_SUBST(sys_paramh)
AC_SUBST(sys_sendfileh)
AC_SUBST(sys_signalh)
AC_SUBST(sys_socketh)
--- a/include/apr.h.in
+++ b/include/apr.h.in
@@ -94,6 +94,7 @@
#define APR_HAVE_STRING_H @stringh@
#define APR_HAVE_STRINGS_H @stringsh@
#define APR_HAVE_SYS_IOCTL_H @sys_ioctlh@
+#define APR_HAVE_SYS_PARAM_H @sys_paramh@
#define APR_HAVE_SYS_SENDFILE_H @sys_sendfileh@
#define APR_HAVE_SYS_SIGNAL_H @sys_signalh@
#define APR_HAVE_SYS_SOCKET_H @sys_socketh@
@@ -201,6 +202,9 @@
#ifdef __cplusplus
extern "C" {
#endif
+#if APR_HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
/**
* @addtogroup apr_platform