mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 15:38:40 +01:00
Merge pull request #11281 from micmac1/apache-19.07-up
[19.07] apr/apr-util/apache/subversion: sync with master
This commit is contained in:
+119
-33
@@ -9,75 +9,161 @@ include $(TOPDIR)/rules.mk
|
|||||||
|
|
||||||
PKG_NAME:=apr-util
|
PKG_NAME:=apr-util
|
||||||
PKG_VERSION:=1.6.1
|
PKG_VERSION:=1.6.1
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||||
PKG_SOURCE_URL:=@APACHE/apr/
|
PKG_SOURCE_URL:=@APACHE/apr/
|
||||||
PKG_HASH:=d3e12f7b6ad12687572a3a39475545a072608f4ba03a6ce8a3778f607dd0035b
|
PKG_HASH:=d3e12f7b6ad12687572a3a39475545a072608f4ba03a6ce8a3778f607dd0035b
|
||||||
PKG_MAINTAINER:=Thomas Heil <heil@terminal-consulting.de>
|
PKG_MAINTAINER:=Thomas Heil <heil@terminal-consulting.de>, \
|
||||||
PKG_LICENSE:=Apache License
|
Sebastian Kemper <sebastian_ml@gmx.net>
|
||||||
|
|
||||||
|
PKG_LICENSE:=Apache-2.0
|
||||||
|
PKG_LICENSE_FILES:=LICENSE
|
||||||
|
|
||||||
PKG_CPE_ID:=cpe:/a:apache:apr-util
|
PKG_CPE_ID:=cpe:/a:apache:apr-util
|
||||||
|
|
||||||
|
PKG_BUILD_PARALLEL:=1
|
||||||
|
|
||||||
|
PKG_CONFIG_DEPENDS := \
|
||||||
|
CONFIG_PACKAGE_libaprutil-crypto-openssl \
|
||||||
|
CONFIG_PACKAGE_libaprutil-dbd-mysql \
|
||||||
|
CONFIG_PACKAGE_libaprutil-dbd-odbc \
|
||||||
|
CONFIG_PACKAGE_libaprutil-dbd-pgsql \
|
||||||
|
CONFIG_PACKAGE_libaprutil-dbd-sqlite3 \
|
||||||
|
CONFIG_PACKAGE_libaprutil-dbm-gdbm \
|
||||||
|
CONFIG_PACKAGE_libaprutil-ldap
|
||||||
|
|
||||||
PKG_FIXUP:=autoreconf
|
PKG_FIXUP:=autoreconf
|
||||||
PKG_REMOVE_FILES:=aclocal.m4 build/ltmain.sh
|
|
||||||
|
|
||||||
PKG_INSTALL:=1
|
PKG_INSTALL:=1
|
||||||
|
|
||||||
include $(INCLUDE_DIR)/package.mk
|
include $(INCLUDE_DIR)/package.mk
|
||||||
include $(INCLUDE_DIR)/nls.mk
|
include $(INCLUDE_DIR)/nls.mk
|
||||||
|
|
||||||
define Package/libaprutil
|
define Package/libaprutil/Default
|
||||||
SECTION:=libs
|
SECTION:=libs
|
||||||
CATEGORY:=Libraries
|
CATEGORY:=Libraries
|
||||||
DEPENDS:=+libapr +libexpat +libsqlite3 +libuuid $(ICONV_DEPENDS)
|
|
||||||
TITLE:=Apache Portable Runtime Utility Library
|
|
||||||
URL:=http://apr.apache.org/
|
URL:=http://apr.apache.org/
|
||||||
endef
|
endef
|
||||||
|
|
||||||
TARGET_CFLAGS += $(FPIC)
|
define Package/libaprutil
|
||||||
TARGET_CPPFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE
|
$(call Package/libaprutil/Default)
|
||||||
|
DEPENDS:=+libapr +libexpat +libuuid $(ICONV_DEPENDS)
|
||||||
|
TITLE:=Apache Portable Runtime Utility Library
|
||||||
|
endef
|
||||||
|
|
||||||
CONFIGURE_ARGS += \
|
CONFIGURE_ARGS += \
|
||||||
--with-pgsql=no \
|
|
||||||
--with-apr="$(STAGING_DIR)/usr/bin/apr-1-config" \
|
--with-apr="$(STAGING_DIR)/usr/bin/apr-1-config" \
|
||||||
--with-expat="$(STAGING_DIR)/usr" \
|
--with-expat="$(STAGING_DIR)/usr" \
|
||||||
--without-sqlite2 \
|
--with-iconv="$(ICONV_PREFIX)" \
|
||||||
--with-sqlite3="$(STAGING_DIR)/usr"
|
--without-sqlite2
|
||||||
|
|
||||||
ifdef $(CONFIG_BUILD_NLS)
|
ifneq ($(CONFIG_PACKAGE_libaprutil-crypto-openssl),)
|
||||||
CONFIGURE_ARGS += --with-iconv="$(ICONV_PREFIX)"
|
CONFIGURE_ARGS += --with-crypto --with-openssl="$(STAGING_DIR)/usr"
|
||||||
else
|
else
|
||||||
CONFIGURE_ARGS += --without-iconv
|
CONFIGURE_ARGS += --without-crypto
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_libaprutil-dbd-mysql),)
|
||||||
|
CONFIGURE_ARGS += --with-mysql="$(STAGING_DIR)/usr"
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS += --without-mysql
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_libaprutil-dbd-odbc),)
|
||||||
|
CONFIGURE_ARGS += --with-odbc="$(STAGING_DIR)/usr"
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS += --without-odbc
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_libaprutil-dbd-pgsql),)
|
||||||
|
CONFIGURE_ARGS += --with-pgsql="$(STAGING_DIR)/usr"
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS += --without-pgsql
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_libaprutil-dbd-sqlite3),)
|
||||||
|
CONFIGURE_ARGS += --with-sqlite3="$(STAGING_DIR)/usr"
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS += --without-sqlite3
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_libaprutil-dbm-gdbm),)
|
||||||
|
CONFIGURE_ARGS += --with-gdbm="$(STAGING_DIR)/usr"
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS += --without-gdbm
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_libaprutil-ldap),)
|
||||||
|
CONFIGURE_ARGS += \
|
||||||
|
--with-ldap \
|
||||||
|
--with-ldap-include="$(STAGING_DIR)/usr/include" \
|
||||||
|
--with-ldap-lib="$(STAGING_DIR)/usr/lib"
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS += \
|
||||||
|
--without-ldap
|
||||||
endif
|
endif
|
||||||
|
|
||||||
CONFIGURE_VARS += \
|
CONFIGURE_VARS += \
|
||||||
ac_cv_file_dbd_apr_dbd_mysql_c=no \
|
|
||||||
ac_cv_path_ODBC_CONFIG= \
|
ac_cv_path_ODBC_CONFIG= \
|
||||||
|
apu_cv_weak_symbols=yes \
|
||||||
APR_BUILD_DIR="$(STAGING_DIR)/usr/share/build-1"
|
APR_BUILD_DIR="$(STAGING_DIR)/usr/share/build-1"
|
||||||
|
|
||||||
MAKE_FLAGS += \
|
ifeq ($(CONFIG_USE_GLIBC)$(CONFIG_USE_MUSL),y)
|
||||||
APRUTIL_LIBS="-lsqlite3 $(TARGET_LDFLAGS) -lexpat $(if $(ICONV_FULL),-liconv) -lapr-1 -luuid -lm -lcrypt"
|
CONFIGURE_VARS += \
|
||||||
|
apu_cv_explicit_bzero=yes
|
||||||
|
endif
|
||||||
|
|
||||||
|
define Package/libaprutil/install/driver
|
||||||
|
$(INSTALL_DIR) $(1)/usr/lib/apr-util-1
|
||||||
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/apr-util-1/apr_$(2)*.so \
|
||||||
|
$(1)/usr/lib/apr-util-1
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/libaprutil/Driver
|
||||||
|
define Package/libaprutil-$(subst _,-,$(1))
|
||||||
|
$(call Package/libaprutil/Default)
|
||||||
|
TITLE:=libaprutil - $(2) driver
|
||||||
|
DEPENDS:=libaprutil $(patsubst +%,+PACKAGE_libaprutil-$(subst _,-,$(1)):%,$(3))
|
||||||
|
endef
|
||||||
|
define Package/libaprutil-$(subst _,-,$(1))/install
|
||||||
|
$(foreach d,$(1),$(call Package/libaprutil/install/driver,$$(1),$(d));)
|
||||||
|
endef
|
||||||
|
$$(eval $$(call BuildPackage,libaprutil-$(subst _,-,$(1))))
|
||||||
|
endef
|
||||||
|
|
||||||
|
# PKG_CONFIG_DEPENDS trigger configure, but the compile afterward may be
|
||||||
|
# incomplete if the build directory is not cleaned before. This is not a
|
||||||
|
# general observation, yet it is valid for apr-util :/
|
||||||
|
define Build/Compile
|
||||||
|
$(call Build/Compile/Default,clean all)
|
||||||
|
endef
|
||||||
|
|
||||||
define Build/InstallDev
|
define Build/InstallDev
|
||||||
$(INSTALL_DIR) $(1)/usr/bin $(1)/usr/include/apr-1/ $(1)/usr/lib $(1)/usr/lib/pkgconfig/
|
$(INSTALL_DIR) $(1)/usr/bin $(1)/usr/include/apr-1 \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/apu-1-config \
|
$(1)/usr/lib/apr-util-1 $(1)/usr/lib/pkgconfig
|
||||||
$(1)/usr/bin/
|
$(CP) $(PKG_INSTALL_DIR)/usr/bin/apu-1-config $(1)/usr/bin
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/apr-1/* \
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/apr-1/* $(1)/usr/include/apr-1
|
||||||
$(1)/usr/include/apr-1/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/apr-util-1/apr_*.{a,so} \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libaprutil-1.{la,a,so*} \
|
$(1)/usr/lib/apr-util-1 2>/dev/null || :
|
||||||
$(1)/usr/lib/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libaprutil-1.{a,so*} \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/apr-util-1.pc \
|
$(1)/usr/lib
|
||||||
$(1)/usr/lib/pkgconfig/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/apr-util-1.pc \
|
||||||
$(SED) 's, -e \"s -I$$$$prefix/lib g\",,g' $(1)/usr/bin/apu-1-config
|
$(1)/usr/lib/pkgconfig
|
||||||
$(SED) 's,^libdir=\"$$$${exec_prefix}/lib,libdir=\"$(STAGING_DIR)/usr/lib,g' $(1)/usr/bin/apu-1-config
|
$(SED) '/^prefix=\|^exec_prefix=/s|/usr|$(STAGING_DIR)/usr|' \
|
||||||
$(SED) 's,^includedir=\"$$$${prefix}/include/,includedir=\"$(STAGING_DIR)/usr/include/,g' $(1)/usr/bin/apu-1-config
|
$(1)/usr/bin/apu-1-config
|
||||||
$(SED) 's,-L$$$$libdir,,g' $(1)/usr/bin/apu-1-config
|
|
||||||
$(SED) 's,-R$$$$libdir,,g' $(1)/usr/bin/apu-1-config
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/libaprutil/install
|
define Package/libaprutil/install
|
||||||
$(INSTALL_DIR) $(1)/usr/lib
|
$(INSTALL_DIR) $(1)/usr/lib
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libaprutil-1.so.* $(1)/usr/lib/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libaprutil-1.so.* $(1)/usr/lib
|
||||||
endef
|
endef
|
||||||
|
|
||||||
$(eval $(call BuildPackage,libaprutil))
|
$(eval $(call BuildPackage,libaprutil))
|
||||||
|
$(eval $(call Package/libaprutil/Driver,crypto_openssl,OpenSSL,+libopenssl))
|
||||||
|
$(eval $(call Package/libaprutil/Driver,dbd_mysql,MySQL,+libmariadb))
|
||||||
|
$(eval $(call Package/libaprutil/Driver,dbd_odbc,ODBC,+unixodbc))
|
||||||
|
$(eval $(call Package/libaprutil/Driver,dbd_pgsql,PostgreSQL,+libpq))
|
||||||
|
$(eval $(call Package/libaprutil/Driver,dbd_sqlite3,SQLite3,+libsqlite3))
|
||||||
|
$(eval $(call Package/libaprutil/Driver,dbm_gdbm,GDBM dbm,+libgdbm))
|
||||||
|
$(eval $(call Package/libaprutil/Driver,ldap,LDAP,+libopenldap))
|
||||||
|
|||||||
@@ -1,21 +0,0 @@
|
|||||||
--- a/Makefile.in
|
|
||||||
+++ b/Makefile.in
|
|
||||||
@@ -8,6 +8,7 @@ APRUTIL_MAJOR_VERSION=@APRUTIL_MAJOR_VER
|
|
||||||
APRUTIL_DOTTED_VERSION=@APRUTIL_DOTTED_VERSION@
|
|
||||||
|
|
||||||
srcdir = @srcdir@
|
|
||||||
+top_builddir = @top_builddir@
|
|
||||||
VPATH = @srcdir@
|
|
||||||
|
|
||||||
INCLUDES = @APRUTIL_PRIV_INCLUDES@ @APR_INCLUDES@ @APRUTIL_INCLUDES@
|
|
||||||
--- a/configure.in
|
|
||||||
+++ b/configure.in
|
|
||||||
@@ -41,6 +41,8 @@ AC_SUBST(APU_CONFIG_LOCATION)
|
|
||||||
AC_CANONICAL_SYSTEM
|
|
||||||
|
|
||||||
AC_PROG_INSTALL
|
|
||||||
+AC_PROG_LIBTOOL
|
|
||||||
+LT_INIT
|
|
||||||
|
|
||||||
# Use -no-install or -no-fast-install to link the test
|
|
||||||
# programs on all platforms but Darwin, where it would cause
|
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=889170
|
||||||
|
# needs to be submitted upstream
|
||||||
|
--- apr-util.orig/dbm/apr_dbm_gdbm.c
|
||||||
|
+++ apr-util/dbm/apr_dbm_gdbm.c
|
||||||
|
@@ -36,13 +36,22 @@
|
||||||
|
static apr_status_t g2s(int gerr)
|
||||||
|
{
|
||||||
|
if (gerr == -1) {
|
||||||
|
- /* ### need to fix this */
|
||||||
|
- return APR_EGENERAL;
|
||||||
|
+ return APR_OS_START_USEERR + gdbm_errno;
|
||||||
|
}
|
||||||
|
|
||||||
|
return APR_SUCCESS;
|
||||||
|
}
|
||||||
|
|
||||||
|
+static apr_status_t gdat2s(datum d)
|
||||||
|
+{
|
||||||
|
+ if (d.dptr == NULL) {
|
||||||
|
+ return APR_OS_START_USEERR + gdbm_errno;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ return APR_SUCCESS;
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+
|
||||||
|
static apr_status_t datum_cleanup(void *dptr)
|
||||||
|
{
|
||||||
|
if (dptr)
|
||||||
|
@@ -55,19 +64,15 @@ static apr_status_t set_error(apr_dbm_t
|
||||||
|
{
|
||||||
|
apr_status_t rv = APR_SUCCESS;
|
||||||
|
|
||||||
|
- /* ### ignore whatever the DBM said (dbm_said); ask it explicitly */
|
||||||
|
-
|
||||||
|
- if ((dbm->errcode = gdbm_errno) == GDBM_NO_ERROR) {
|
||||||
|
+ if (dbm_said == APR_SUCCESS) {
|
||||||
|
+ dbm->errcode = GDBM_NO_ERROR;
|
||||||
|
dbm->errmsg = NULL;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
+ dbm->errcode = dbm_said;
|
||||||
|
dbm->errmsg = gdbm_strerror(gdbm_errno);
|
||||||
|
- rv = APR_EGENERAL; /* ### need something better */
|
||||||
|
}
|
||||||
|
|
||||||
|
- /* captured it. clear it now. */
|
||||||
|
- gdbm_errno = GDBM_NO_ERROR;
|
||||||
|
-
|
||||||
|
return rv;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -144,7 +149,7 @@ static apr_status_t vt_gdbm_fetch(apr_db
|
||||||
|
|
||||||
|
/* store the error info into DBM, and return a status code. Also, note
|
||||||
|
that *pvalue should have been cleared on error. */
|
||||||
|
- return set_error(dbm, APR_SUCCESS);
|
||||||
|
+ return set_error(dbm, gdat2s(rd));
|
||||||
|
}
|
||||||
|
|
||||||
|
static apr_status_t vt_gdbm_store(apr_dbm_t *dbm, apr_datum_t key,
|
||||||
|
@@ -203,7 +208,7 @@ static apr_status_t vt_gdbm_firstkey(apr
|
||||||
|
apr_pool_cleanup_null);
|
||||||
|
|
||||||
|
/* store any error info into DBM, and return a status code. */
|
||||||
|
- return set_error(dbm, APR_SUCCESS);
|
||||||
|
+ return set_error(dbm, gdat2s(rd));
|
||||||
|
}
|
||||||
|
|
||||||
|
static apr_status_t vt_gdbm_nextkey(apr_dbm_t *dbm, apr_datum_t *pkey)
|
||||||
|
@@ -223,7 +228,7 @@ static apr_status_t vt_gdbm_nextkey(apr_
|
||||||
|
apr_pool_cleanup_null);
|
||||||
|
|
||||||
|
/* store any error info into DBM, and return a status code. */
|
||||||
|
- return set_error(dbm, APR_SUCCESS);
|
||||||
|
+ return set_error(dbm, gdat2s(rd));
|
||||||
|
}
|
||||||
|
|
||||||
|
static void vt_gdbm_freedatum(apr_dbm_t *dbm, apr_datum_t data)
|
||||||
@@ -0,0 +1,125 @@
|
|||||||
|
# patch by Kris Karas fom
|
||||||
|
# https://bz.apache.org/bugzilla/attachment.cgi?id=35326&action=diff
|
||||||
|
--- a/build/dbd.m4
|
||||||
|
+++ b/build/dbd.m4
|
||||||
|
@@ -163,10 +163,15 @@ AC_DEFUN([APU_CHECK_DBD_MYSQL], [
|
||||||
|
old_cppflags="$CPPFLAGS"
|
||||||
|
old_ldflags="$LDFLAGS"
|
||||||
|
|
||||||
|
+ my_library="mysqlclient"
|
||||||
|
+
|
||||||
|
AC_ARG_WITH([mysql], APR_HELP_STRING([--with-mysql=DIR], [enable MySQL DBD driver]),
|
||||||
|
[
|
||||||
|
if test "$withval" = "yes"; then
|
||||||
|
AC_PATH_PROG([MYSQL_CONFIG],[mysql_config])
|
||||||
|
+ if test "x$MYSQL_CONFIG" = "x"; then
|
||||||
|
+ AC_PATH_PROG([MYSQL_CONFIG],[mariadb_config])
|
||||||
|
+ fi
|
||||||
|
if test "x$MYSQL_CONFIG" != 'x'; then
|
||||||
|
mysql_CPPFLAGS="`$MYSQL_CONFIG --include`"
|
||||||
|
mysql_LDFLAGS="`$MYSQL_CONFIG --libs_r | sed -e 's/-l[[^ ]]\+//g'`"
|
||||||
|
@@ -174,32 +179,40 @@ AC_DEFUN([APU_CHECK_DBD_MYSQL], [
|
||||||
|
|
||||||
|
APR_ADDTO(CPPFLAGS, [$mysql_CPPFLAGS])
|
||||||
|
APR_ADDTO(LIBS, [$mysql_LIBS])
|
||||||
|
+
|
||||||
|
+ if $MYSQL_CONFIG --libs_r | grep -q mariadb; then
|
||||||
|
+ my_library="mariadb"
|
||||||
|
+ fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
- AC_CHECK_HEADERS([mysql.h my_global.h my_sys.h],
|
||||||
|
- AC_CHECK_LIB(mysqlclient, mysql_init, [apu_have_mysql=1]),
|
||||||
|
- [apu_have_mysql=0; break],
|
||||||
|
- [#include <my_global.h>])
|
||||||
|
- if test "$apu_have_mysql" = "0"; then
|
||||||
|
- AC_CHECK_HEADERS([mysql/mysql.h mysql/my_global.h mysql/my_sys.h],
|
||||||
|
- AC_CHECK_LIB(mysqlclient, mysql_init, [apu_have_mysql=1]),
|
||||||
|
- [apu_have_mysql=0; break],
|
||||||
|
- [#include <mysql/my_global.h>])
|
||||||
|
+ AC_CHECK_HEADERS([mysql.h errmsg.h], [apu_have_mysql=1], [apu_have_mysql=0; break])
|
||||||
|
+ if test "$apr_have_mysql" = "0"; then
|
||||||
|
+ AC_CHECK_HEADERS([mysql/mysql.h mysql/errmsg.h], [apu_have_mysql=1], [apu_have_mysql=0; break])
|
||||||
|
fi
|
||||||
|
- if test "$apu_have_mysql" != "0" && test "x$MYSQL_CONFIG" != 'x'; then
|
||||||
|
- APR_ADDTO(APRUTIL_PRIV_INCLUDES, [$mysql_CPPFLAGS])
|
||||||
|
+ if test "$apr_have_mysql" = "1"; then
|
||||||
|
+ AC_CHECK_HEADERS([my_global.h my_sys.h mysql/my_global.h mysql/my_sys.h])
|
||||||
|
+ AC_CHECK_LIB($my_library, mysql_init,, [apu_have_mysql=0])
|
||||||
|
+ fi
|
||||||
|
+ if test "$apu_have_mysql" = "1" && test "x$MYSQL_CONFIG" != 'x'; then
|
||||||
|
+ APR_ADDTO(APRUTIL_PRIV_INCLUDES, [$mysql_CPPFLAGS])
|
||||||
|
fi
|
||||||
|
elif test "$withval" = "no"; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
AC_PATH_PROG([MYSQL_CONFIG],[mysql_config],,[$withval/bin])
|
||||||
|
+ if test "x$MYSQL_CONFIG" = "x"; then
|
||||||
|
+ AC_PATH_PROG([MYSQL_CONFIG],[mariadb_config],,[$withval/bin])
|
||||||
|
+ fi
|
||||||
|
if test "x$MYSQL_CONFIG" != 'x'; then
|
||||||
|
- mysql_CPPFLAGS="`$MYSQL_CONFIG --include`"
|
||||||
|
- mysql_LDFLAGS="`$MYSQL_CONFIG --libs_r | sed -e 's/-l[[^ ]]\+//g'`"
|
||||||
|
- mysql_LIBS="`$MYSQL_CONFIG --libs_r`"
|
||||||
|
+ mysql_CPPFLAGS="`$MYSQL_CONFIG --include`"
|
||||||
|
+ mysql_LDFLAGS="`$MYSQL_CONFIG --libs_r | sed -e 's/-l[[^ ]]\+//g'`"
|
||||||
|
+ mysql_LIBS="`$MYSQL_CONFIG --libs_r`"
|
||||||
|
+ if $MYSQL_CONFIG --libs_r | grep -q mariadb; then
|
||||||
|
+ my_library="mariadb"
|
||||||
|
+ fi
|
||||||
|
else
|
||||||
|
- mysql_CPPFLAGS="-I$withval/include"
|
||||||
|
- mysql_LDFLAGS="-L$withval/lib "
|
||||||
|
+ mysql_CPPFLAGS="-I$withval/include"
|
||||||
|
+ mysql_LDFLAGS="-L$withval/lib "
|
||||||
|
fi
|
||||||
|
|
||||||
|
APR_ADDTO(CPPFLAGS, [$mysql_CPPFLAGS])
|
||||||
|
@@ -207,18 +220,15 @@ AC_DEFUN([APU_CHECK_DBD_MYSQL], [
|
||||||
|
APR_ADDTO(LIBS, [$mysql_LIBS])
|
||||||
|
|
||||||
|
AC_MSG_NOTICE(checking for mysql in $withval)
|
||||||
|
- AC_CHECK_HEADERS([mysql.h my_global.h my_sys.h],
|
||||||
|
- AC_CHECK_LIB(mysqlclient, mysql_init, [apu_have_mysql=1]),
|
||||||
|
- [apu_have_mysql=0; break],
|
||||||
|
- [#include <my_global.h>])
|
||||||
|
-
|
||||||
|
- if test "$apu_have_mysql" != "1"; then
|
||||||
|
- AC_CHECK_HEADERS([mysql/mysql.h mysql/my_global.h mysql/my_sys.h],
|
||||||
|
- AC_CHECK_LIB(mysqlclient, mysql_init, [apu_have_mysql=1]),
|
||||||
|
- [apu_have_mysql=0; break],
|
||||||
|
- [#include <mysql/my_global.h>])
|
||||||
|
+ AC_CHECK_HEADERS([mysql.h errmsg.h], [apu_have_mysql=1], [apu_have_mysql=0; break])
|
||||||
|
+ if test "$apr_have_mysql" = "0"; then
|
||||||
|
+ AC_CHECK_HEADERS([mysql/mysql.h mysql/errmsg.h], [apu_have_mysql=1], [apu_have_mysql=0; break])
|
||||||
|
+ fi
|
||||||
|
+ if test "$apr_have_mysql" = "1"; then
|
||||||
|
+ AC_CHECK_HEADERS([my_global.h my_sys.h mysql/my_global.h mysql/my_sys.h])
|
||||||
|
+ AC_CHECK_LIB($my_library, mysql_init,, [apu_have_mysql=0])
|
||||||
|
fi
|
||||||
|
- if test "$apu_have_mysql" != "0"; then
|
||||||
|
+ if test "$apu_have_mysql" = "1"; then
|
||||||
|
APR_ADDTO(APRUTIL_PRIV_INCLUDES, [$mysql_CPPFLAGS])
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
@@ -229,7 +239,7 @@ AC_DEFUN([APU_CHECK_DBD_MYSQL], [
|
||||||
|
dnl Since we have already done the AC_CHECK_LIB tests, if we have it,
|
||||||
|
dnl we know the library is there.
|
||||||
|
if test "$apu_have_mysql" = "1"; then
|
||||||
|
- APR_ADDTO(LDADD_dbd_mysql, [$mysql_LDFLAGS -lmysqlclient $mysql_LIBS])
|
||||||
|
+ APR_ADDTO(LDADD_dbd_mysql, [$mysql_LDFLAGS -l$my_library $mysql_LIBS])
|
||||||
|
fi
|
||||||
|
AC_SUBST(LDADD_dbd_mysql)
|
||||||
|
|
||||||
|
--- a/dbd/apr_dbd_mysql.c
|
||||||
|
+++ b/dbd/apr_dbd_mysql.c
|
||||||
|
@@ -1262,7 +1262,9 @@ static apr_status_t thread_end(void *dat
|
||||||
|
|
||||||
|
static void dbd_mysql_init(apr_pool_t *pool)
|
||||||
|
{
|
||||||
|
+#if MYSQL_VERSION_ID < 100000
|
||||||
|
my_init();
|
||||||
|
+#endif
|
||||||
|
mysql_thread_init();
|
||||||
|
|
||||||
|
/* FIXME: this is a guess; find out what it really does */
|
||||||
@@ -0,0 +1,34 @@
|
|||||||
|
From: Ryan Niebur <ryanryan52@gmail.com>
|
||||||
|
Subject: by default --avoid-ldap since apache2 is the only user, and we don't
|
||||||
|
want to add extra dependencies to other apr-utils rdepends
|
||||||
|
|
||||||
|
--- a/apu-config.in
|
||||||
|
+++ b/apu-config.in
|
||||||
|
@@ -30,7 +30,8 @@ includedir="@includedir@"
|
||||||
|
LIBS="@APRUTIL_EXPORT_LIBS@"
|
||||||
|
INCLUDES="@APRUTIL_INCLUDES@"
|
||||||
|
LDFLAGS="@APRUTIL_LDFLAGS@"
|
||||||
|
-LDAP_LIBS="@LDADD_ldap@"
|
||||||
|
+ORIG_LDAP_LIBS="@LDADD_ldap@"
|
||||||
|
+LDAP_LIBS=""
|
||||||
|
DBM_LIBS="@LDADD_dbm_db@ @LDADD_dbm_gdbm@ @LDADD_dbm_ndbm@"
|
||||||
|
|
||||||
|
APRUTIL_LIBNAME="@APRUTIL_LIBNAME@"
|
||||||
|
@@ -55,7 +56,7 @@ Known values for OPTION are:
|
||||||
|
--includedir print location where headers are installed
|
||||||
|
--ldflags print linker flags
|
||||||
|
--libs print library information
|
||||||
|
- --avoid-ldap do not include ldap library information with --libs
|
||||||
|
+ --avoid-ldap do not include ldap library information with --libs (default on OpenWrt)
|
||||||
|
--ldap-libs print library information to link with ldap
|
||||||
|
--avoid-dbm do not include DBM library information with --libs
|
||||||
|
--dbm-libs print additional library information to link with DBM
|
||||||
|
@@ -121,7 +122,7 @@ while test $# -gt 0; do
|
||||||
|
flags="$flags $LDAP_LIBS $DBM_LIBS $LIBS"
|
||||||
|
;;
|
||||||
|
--ldap-libs)
|
||||||
|
- flags="$flags $LDAP_LIBS"
|
||||||
|
+ flags="$flags $ORIG_LDAP_LIBS"
|
||||||
|
;;
|
||||||
|
--dbm-libs)
|
||||||
|
flags="$flags $DBM_LIBS"
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
From: Peter Samuelson <peter@p12n.org>
|
||||||
|
Subject: Prevent recursive linking of dependent libraries by apr-util users.
|
||||||
|
|
||||||
|
---
|
||||||
|
apr-util.pc.in | 5 +++--
|
||||||
|
apu-config.in | 2 +-
|
||||||
|
2 files changed, 4 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
--- a/apr-util.pc.in
|
||||||
|
+++ b/apr-util.pc.in
|
||||||
|
@@ -8,6 +8,7 @@ Name: APR Utils
|
||||||
|
Description: Companion library for APR
|
||||||
|
Version: @APRUTIL_DOTTED_VERSION@
|
||||||
|
# assume that apr-util requires libapr of same major version
|
||||||
|
-Requires: apr-@APRUTIL_MAJOR_VERSION@
|
||||||
|
-Libs: -L${libdir} -l@APRUTIL_LIBNAME@ @LDADD_ldap@ @APRUTIL_EXPORT_LIBS@
|
||||||
|
+Requires.private: apr-@APRUTIL_MAJOR_VERSION@
|
||||||
|
+Libs: -L${libdir} -l@APRUTIL_LIBNAME@ @LDADD_ldap@
|
||||||
|
+Libs.private: @APRUTIL_EXPORT_LIBS@
|
||||||
|
Cflags: -I${includedir}
|
||||||
|
--- a/apu-config.in
|
||||||
|
+++ b/apu-config.in
|
||||||
|
@@ -27,7 +27,7 @@ bindir="@bindir@"
|
||||||
|
libdir="@libdir@"
|
||||||
|
includedir="@includedir@"
|
||||||
|
|
||||||
|
-LIBS="@APRUTIL_EXPORT_LIBS@"
|
||||||
|
+LIBS=
|
||||||
|
INCLUDES="@APRUTIL_INCLUDES@"
|
||||||
|
LDFLAGS="@APRUTIL_LDFLAGS@"
|
||||||
|
ORIG_LDAP_LIBS="@LDADD_ldap@"
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
From: Stefan Fritsch <sf@debian.org>
|
||||||
|
Subject: Make apu-config not output dbm libs by default. See #622081
|
||||||
|
|
||||||
|
--- a/apu-config.in
|
||||||
|
+++ b/apu-config.in
|
||||||
|
@@ -32,7 +32,8 @@ INCLUDES="@APRUTIL_INCLUDES@"
|
||||||
|
LDFLAGS="@APRUTIL_LDFLAGS@"
|
||||||
|
ORIG_LDAP_LIBS="@LDADD_ldap@"
|
||||||
|
LDAP_LIBS=""
|
||||||
|
-DBM_LIBS="@LDADD_dbm_db@ @LDADD_dbm_gdbm@ @LDADD_dbm_ndbm@"
|
||||||
|
+ORIG_DBM_LIBS="@LDADD_dbm_db@ @LDADD_dbm_gdbm@ @LDADD_dbm_ndbm@"
|
||||||
|
+DBM_LIBS=""
|
||||||
|
|
||||||
|
APRUTIL_LIBNAME="@APRUTIL_LIBNAME@"
|
||||||
|
|
||||||
|
@@ -58,8 +59,8 @@ Known values for OPTION are:
|
||||||
|
--libs print library information
|
||||||
|
--avoid-ldap do not include ldap library information with --libs (default on OpenWrt)
|
||||||
|
--ldap-libs print library information to link with ldap
|
||||||
|
- --avoid-dbm do not include DBM library information with --libs
|
||||||
|
- --dbm-libs print additional library information to link with DBM
|
||||||
|
+ --avoid-dbm do not include DBM library information with --libs (default on OpenWrt)
|
||||||
|
+ --dbm-libs print library information to link with DBM
|
||||||
|
--srcdir print APR-util source directory
|
||||||
|
--link-ld print link switch(es) for linking to APR-util
|
||||||
|
--link-libtool print the libtool inputs for linking to APR-util
|
||||||
|
@@ -125,7 +126,7 @@ while test $# -gt 0; do
|
||||||
|
flags="$flags $ORIG_LDAP_LIBS"
|
||||||
|
;;
|
||||||
|
--dbm-libs)
|
||||||
|
- flags="$flags $DBM_LIBS"
|
||||||
|
+ flags="$flags $ORIG_DBM_LIBS"
|
||||||
|
;;
|
||||||
|
--includedir)
|
||||||
|
if test "$location" = "installed"; then
|
||||||
+54
-37
@@ -8,18 +8,24 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=apr
|
PKG_NAME:=apr
|
||||||
PKG_VERSION:=1.6.5
|
PKG_VERSION:=1.7.0
|
||||||
PKG_RELEASE:=3
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||||
PKG_SOURCE_URL:=@APACHE/apr/
|
PKG_SOURCE_URL:=@APACHE/apr/
|
||||||
PKG_HASH:=a67ca9fcf9c4ff59bce7f428a323c8b5e18667fdea7b0ebad47d194371b0a105
|
PKG_HASH:=e2e148f0b2e99b8e5c6caa09f6d4fb4dd3e83f744aa72a952f94f5a14436f7ea
|
||||||
|
|
||||||
|
PKG_MAINTAINER:=Thomas Heil <heil@terminal-consulting.de>, \
|
||||||
|
Sebastian Kemper <sebastian_ml@gmx.net>
|
||||||
|
|
||||||
PKG_MAINTAINER:=Thomas Heil <heil@terminal-consulting.de>
|
|
||||||
PKG_LICENSE:=Apache-2.0
|
PKG_LICENSE:=Apache-2.0
|
||||||
|
PKG_LICENSE_FILES:=LICENSE
|
||||||
|
|
||||||
|
PKG_CPE_ID:=cpe:/a:apache:apr
|
||||||
|
|
||||||
|
PKG_BUILD_PARALLEL:=1
|
||||||
|
|
||||||
PKG_FIXUP:=autoreconf
|
PKG_FIXUP:=autoreconf
|
||||||
PKG_REMOVE_FILES:=aclocal.m4 build/ltmain.sh
|
|
||||||
|
|
||||||
PKG_INSTALL:=1
|
PKG_INSTALL:=1
|
||||||
|
|
||||||
@@ -33,53 +39,64 @@ define Package/libapr
|
|||||||
URL:=https://apr.apache.org/
|
URL:=https://apr.apache.org/
|
||||||
endef
|
endef
|
||||||
|
|
||||||
TARGET_CFLAGS += $(FPIC)
|
|
||||||
|
|
||||||
CONFIGURE_ARGS += \
|
CONFIGURE_ARGS += \
|
||||||
--without-pic \
|
|
||||||
--with-devrandom=/dev/urandom \
|
--with-devrandom=/dev/urandom \
|
||||||
$(call autoconf_bool,CONFIG_IPV6,ipv6)
|
$(call autoconf_bool,CONFIG_IPV6,ipv6)
|
||||||
|
|
||||||
# XXX: ac_cv_sizeof_struct_iovec=1 is just to trick configure
|
# XXX: ac_cv_sizeof_struct_iovec=1 is just to trick configure
|
||||||
|
# XXX: don't set apr_cv_use_lfs64=yes, see
|
||||||
|
# https://www.openwall.com/lists/musl/2020/02/03/18
|
||||||
|
# XXX: the atomic builtins used require 8-byte intrinsics, which are available
|
||||||
|
# on all 64-bit architectures and some arm as well as x86 32-bit platforms
|
||||||
CONFIGURE_VARS += \
|
CONFIGURE_VARS += \
|
||||||
|
ap_cv_atomic_builtins=$(if $(CONFIG_ARCH_64BIT),yes,no) \
|
||||||
|
ac_cv_file__dev_zero=yes \
|
||||||
|
ac_cv_func_pthread_mutexattr_setpshared=yes \
|
||||||
|
ac_cv_func_sem_open=yes \
|
||||||
|
ac_cv_func_setpgrp_void=yes \
|
||||||
|
ac_cv_mmap__dev_zero=yes \
|
||||||
|
ac_cv_negative_eai=yes \
|
||||||
|
ac_cv_o_nonblock_inherited=no \
|
||||||
ac_cv_sizeof_struct_iovec=1 \
|
ac_cv_sizeof_struct_iovec=1 \
|
||||||
ac_cv_struct_rlimit=yes \
|
ac_cv_struct_rlimit=yes \
|
||||||
ac_cv_func_sem_open=yes \
|
apr_cv_accept4=yes \
|
||||||
ac_cv_func_pthread_mutexattr_setpshared=yes \
|
|
||||||
apr_cv_mutex_robust_shared=yes \
|
|
||||||
apr_cv_tcp_nodelay_with_cork=yes \
|
|
||||||
apr_cv_sock_cloexec=yes \
|
|
||||||
apr_cv_process_shared_works=yes \
|
|
||||||
apr_cv_mutex_recursive=yes \
|
|
||||||
apr_cv_epoll_create1=yes \
|
|
||||||
apr_cv_epoll=yes \
|
|
||||||
apr_cv_dup3=yes \
|
apr_cv_dup3=yes \
|
||||||
apr_cv_accept4=yes
|
apr_cv_epoll=yes \
|
||||||
|
apr_cv_epoll_create1=yes \
|
||||||
|
apr_cv_gai_addrconfig=yes \
|
||||||
|
apr_cv_mutex_recursive=yes \
|
||||||
|
apr_cv_mutex_robust_shared=yes \
|
||||||
|
apr_cv_process_shared_works=yes \
|
||||||
|
apr_cv_pthreads_lib=-lpthread \
|
||||||
|
apr_cv_sock_cloexec=yes \
|
||||||
|
apr_cv_tcp_nodelay_with_cork=yes
|
||||||
|
|
||||||
|
ifeq ($(call qstrip,$(CONFIG_LIBC)),musl)
|
||||||
|
CONFIGURE_VARS += \
|
||||||
|
ac_cv_strerror_r_rc_int=yes
|
||||||
|
endif
|
||||||
|
|
||||||
define Build/InstallDev
|
define Build/InstallDev
|
||||||
$(INSTALL_DIR) $(1)/usr/bin $(1)/usr/include/apr-1 $(1)/usr/lib $(1)/usr/lib/pkgconfig $(1)/usr/share/build-1
|
$(INSTALL_DIR) $(1)/usr/bin $(1)/usr/include/apr-1 \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/apr-1-config \
|
$(1)/usr/lib/pkgconfig $(1)/usr/share/build-1
|
||||||
$(1)/usr/bin/
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/apr-1-config \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/apr-1/* \
|
$(1)/usr/bin
|
||||||
$(1)/usr/include/apr-1/
|
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/apr-1/* \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libapr-1.{la,a,so*} \
|
$(1)/usr/include/apr-1
|
||||||
$(1)/usr/lib/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libapr-1.{a,so*} $(1)/usr/lib
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/apr-1.pc \
|
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/apr-1.pc \
|
||||||
$(1)/usr/lib/pkgconfig/
|
$(1)/usr/lib/pkgconfig
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/share/build-1/* \
|
$(CP) $(PKG_INSTALL_DIR)/usr/share/build-1/* $(1)/usr/share/build-1
|
||||||
$(1)/usr/share/build-1/
|
$(SED) '/^prefix=\|^exec_prefix=/s|/usr|$(STAGING_DIR)/usr|' \
|
||||||
$(SED) 's,^datadir=\"/usr/share\",datadir=\"$(STAGING_DIR)/usr/share\",g' $(1)/usr/bin/apr-1-config
|
$(1)/usr/bin/apr-1-config
|
||||||
$(SED) 's,^installbuilddir=\"/usr/share/build-1\",installbuilddir=\"$(STAGING_DIR)/usr/share/build-1\",g' $(1)/usr/bin/apr-1-config
|
$(SED) '/^datadir=/s|/usr|$$$${prefix}|' $(1)/usr/bin/apr-1-config
|
||||||
$(SED) 's,^libdir=\"$$$${exec_prefix}/lib,libdir=\"$(STAGING_DIR)/usr/lib,g' $(1)/usr/bin/apr-1-config
|
$(SED) 's,/usr/share/build-1,$(STAGING_DIR)/usr/share/build-1,g' \
|
||||||
$(SED) 's,^includedir=\"$$$${prefix}/include/,includedir=\"$(STAGING_DIR)/usr/include/,g' $(1)/usr/bin/apr-1-config
|
$(1)/usr/share/build-1/apr_rules.mk
|
||||||
$(SED) 's,-L$$$$libdir,,g' $(1)/usr/bin/apr-1-config
|
|
||||||
$(SED) 's,-R$$$$libdir,,g' $(1)/usr/bin/apr-1-config
|
|
||||||
$(SED) 's,/usr/share/build-1,$(STAGING_DIR)/usr/share/build-1,g' $(1)/usr/share/build-1/apr_rules.mk
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/libapr/install
|
define Package/libapr/install
|
||||||
$(INSTALL_DIR) $(1)/usr/lib
|
$(INSTALL_DIR) $(1)/usr/lib
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libapr-1.so.* $(1)/usr/lib/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libapr-1.so.* $(1)/usr/lib
|
||||||
endef
|
endef
|
||||||
|
|
||||||
$(eval $(call BuildPackage,libapr))
|
$(eval $(call BuildPackage,libapr))
|
||||||
|
|||||||
@@ -1,26 +0,0 @@
|
|||||||
Index: apr-1.5.2/Makefile.in
|
|
||||||
===================================================================
|
|
||||||
--- apr-1.5.2.orig/Makefile.in
|
|
||||||
+++ apr-1.5.2/Makefile.in
|
|
||||||
@@ -3,6 +3,7 @@ srcdir=@srcdir@
|
|
||||||
VPATH=@srcdir@
|
|
||||||
top_srcdir=@apr_srcdir@
|
|
||||||
top_blddir=@apr_builddir@
|
|
||||||
+top_builddir=@top_builddir@
|
|
||||||
|
|
||||||
#
|
|
||||||
# APR (Apache Portable Runtime) library Makefile.
|
|
||||||
Index: apr-1.5.2/configure.in
|
|
||||||
===================================================================
|
|
||||||
--- apr-1.5.2.orig/configure.in
|
|
||||||
+++ apr-1.5.2/configure.in
|
|
||||||
@@ -245,9 +245,6 @@ case $host in
|
|
||||||
gcc $CFLAGS $CPPFLAGS -o $LIBTOOL.exe $LIBTOOL.c
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
- if test "x$LTFLAGS" = "x"; then
|
|
||||||
- LTFLAGS='--silent'
|
|
||||||
- fi
|
|
||||||
if test "$experimental_libtool" = "yes"; then
|
|
||||||
# Use a custom-made libtool replacement
|
|
||||||
echo "using jlibtool"
|
|
||||||
@@ -0,0 +1,56 @@
|
|||||||
|
Fix cross-compilation
|
||||||
|
|
||||||
|
Patch was backported from Apache httpd:
|
||||||
|
http://svn.apache.org/viewvc?view=revision&revision=1327907
|
||||||
|
http://svn.apache.org/viewvc?view=revision&revision=1328390
|
||||||
|
http://svn.apache.org/viewvc?view=revision&revision=1328714
|
||||||
|
|
||||||
|
Patch submitted upstream:
|
||||||
|
https://issues.apache.org/bugzilla/show_bug.cgi?id=57058
|
||||||
|
|
||||||
|
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
|
||||||
|
|
||||||
|
--- a/configure.in
|
||||||
|
+++ b/configure.in
|
||||||
|
@@ -118,6 +118,16 @@ AC_CANONICAL_SYSTEM
|
||||||
|
echo "Configuring APR library"
|
||||||
|
echo "Platform: $host"
|
||||||
|
|
||||||
|
+dnl In case of cross compilation we set CC_FOR_BUILD to cc unless
|
||||||
|
+dnl we got already CC_FOR_BUILD from environment.
|
||||||
|
+if test "x${build_alias}" != "x${host_alias}"; then
|
||||||
|
+ if test "x${CC_FOR_BUILD}" = "x"; then
|
||||||
|
+ CC_FOR_BUILD=cc
|
||||||
|
+ fi
|
||||||
|
+fi
|
||||||
|
+AC_SUBST(CC_FOR_BUILD)
|
||||||
|
+AC_SUBST(CFLAGS_FOR_BUILD)
|
||||||
|
+
|
||||||
|
dnl Some initial steps for configuration. We setup the default directory
|
||||||
|
dnl and which files are to be configured.
|
||||||
|
|
||||||
|
--- a/Makefile.in
|
||||||
|
+++ b/Makefile.in
|
||||||
|
@@ -8,6 +8,8 @@ top_blddir=@apr_builddir@
|
||||||
|
# APR (Apache Portable Runtime) library Makefile.
|
||||||
|
#
|
||||||
|
CPP = @CPP@
|
||||||
|
+CC_FOR_BUILD = @CC_FOR_BUILD@
|
||||||
|
+CFLAGS_FOR_BUILD = @CFLAGS_FOR_BUILD@
|
||||||
|
|
||||||
|
# get substituted into some targets
|
||||||
|
APR_MAJOR_VERSION=@APR_MAJOR_VERSION@
|
||||||
|
@@ -136,8 +138,13 @@ tools/gen_test_char.lo: tools/gen_test_c
|
||||||
|
$(APR_MKDIR) tools
|
||||||
|
$(LT_COMPILE)
|
||||||
|
|
||||||
|
+ifdef CC_FOR_BUILD
|
||||||
|
+tools/gen_test_char@EXEEXT@: tools/gen_test_char.c $(LOCAL_LIBS)
|
||||||
|
+ $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) -DCROSS_COMPILE -o $@ $<
|
||||||
|
+else
|
||||||
|
tools/gen_test_char@EXEEXT@: $(OBJECTS_gen_test_char)
|
||||||
|
$(LINK_PROG) $(OBJECTS_gen_test_char) $(ALL_LIBS)
|
||||||
|
+endif
|
||||||
|
|
||||||
|
include/private/apr_escape_test_char.h: tools/gen_test_char@EXEEXT@
|
||||||
|
$(APR_MKDIR) include/private
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
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
|
||||||
|
@@ -1596,6 +1596,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
|
||||||
|
@@ -95,6 +95,7 @@
|
||||||
|
#define APR_HAVE_STRINGS_H @stringsh@
|
||||||
|
#define APR_HAVE_INTTYPES_H @inttypesh@
|
||||||
|
#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@
|
||||||
|
@@ -218,6 +219,9 @@
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
+#if APR_HAVE_SYS_PARAM_H
|
||||||
|
+#include <sys/param.h>
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @addtogroup apr_platform
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
https://dev.openwrt.org/ticket/9287
|
|
||||||
|
|
||||||
--- a/time/unix/time.c
|
|
||||||
+++ b/time/unix/time.c
|
|
||||||
@@ -75,7 +75,7 @@ APR_DECLARE(apr_time_t) apr_time_now(voi
|
|
||||||
{
|
|
||||||
struct timeval tv;
|
|
||||||
gettimeofday(&tv, NULL);
|
|
||||||
- return tv.tv_sec * APR_USEC_PER_SEC + tv.tv_usec;
|
|
||||||
+ return tv.tv_sec * (apr_time_t)APR_USEC_PER_SEC + (apr_time_t)tv.tv_usec;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void explode_time(apr_time_exp_t *xt, apr_time_t t,
|
|
||||||
@@ -1,51 +0,0 @@
|
|||||||
Makefile.in: fix cross compiling failed
|
|
||||||
|
|
||||||
The tools/gen_test_char was invoked at build time,
|
|
||||||
and it didn't work for the cross compiling, so we
|
|
||||||
compile it with $BUILDCC.
|
|
||||||
|
|
||||||
Remove the 'tools' dir creation, it always existed.
|
|
||||||
And it caused gen_test_char unexpected rebuilt at
|
|
||||||
do_install time.
|
|
||||||
|
|
||||||
Upstream-Status: inappropriate [oe specific]
|
|
||||||
|
|
||||||
Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
|
|
||||||
---
|
|
||||||
Makefile.in | 10 ++--------
|
|
||||||
1 file changed, 2 insertions(+), 8 deletions(-)
|
|
||||||
|
|
||||||
Index: apr-1.5.2/Makefile.in
|
|
||||||
===================================================================
|
|
||||||
--- apr-1.5.2.orig/Makefile.in
|
|
||||||
+++ apr-1.5.2/Makefile.in
|
|
||||||
@@ -20,7 +20,7 @@ INCDIR=./include
|
|
||||||
OSDIR=$(top_srcdir)/include/arch/@OSDIR@
|
|
||||||
DEFOSDIR=$(INCDIR)/arch/@DEFAULT_OSDIR@
|
|
||||||
INCLUDES=-I$(INCDIR) -I$(OSDIR) -I$(DEFOSDIR) -I$(top_srcdir)/include/arch/@DEFAULT_OSDIR@ -I$(top_srcdir)/include -I$(top_srcdir)/include/private -I$(top_blddir)/include/private
|
|
||||||
-
|
|
||||||
+BUILDCC=gcc
|
|
||||||
#
|
|
||||||
# Macros for target determination
|
|
||||||
#
|
|
||||||
@@ -47,7 +47,6 @@ LT_VERSION = @LT_VERSION@
|
|
||||||
|
|
||||||
CLEAN_TARGETS = apr-config.out apr.exp exports.c export_vars.c .make.dirs \
|
|
||||||
build/apr_rules.out tools/gen_test_char@EXEEXT@ \
|
|
||||||
- tools/gen_test_char.o tools/gen_test_char.lo \
|
|
||||||
include/private/apr_escape_test_char.h
|
|
||||||
DISTCLEAN_TARGETS = config.cache config.log config.status \
|
|
||||||
include/apr.h include/arch/unix/apr_private.h \
|
|
||||||
@@ -138,9 +137,9 @@ tools/gen_test_char.lo: tools/gen_test_c
|
|
||||||
$(APR_MKDIR) tools
|
|
||||||
$(LT_COMPILE)
|
|
||||||
|
|
||||||
-tools/gen_test_char@EXEEXT@: $(OBJECTS_gen_test_char)
|
|
||||||
- $(LINK_PROG) $(OBJECTS_gen_test_char) $(ALL_LIBS)
|
|
||||||
-
|
|
||||||
+tools/gen_test_char@EXEEXT@: tools/gen_test_char.c
|
|
||||||
+ $(BUILDCC) $(CFLAGS_FOR_BUILD) $< -o $@
|
|
||||||
+
|
|
||||||
include/private/apr_escape_test_char.h: tools/gen_test_char@EXEEXT@
|
|
||||||
$(APR_MKDIR) include/private
|
|
||||||
tools/gen_test_char@EXEEXT@ > $@
|
|
||||||
@@ -33,11 +33,9 @@ Upstream-Status: Pending
|
|||||||
configure.in | 8 ++++----
|
configure.in | 8 ++++----
|
||||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||||
|
|
||||||
diff --git a/configure.in b/configure.in
|
|
||||||
index 3b10422..a227e72 100644
|
|
||||||
--- a/configure.in
|
--- a/configure.in
|
||||||
+++ b/configure.in
|
+++ b/configure.in
|
||||||
@@ -1771,7 +1771,7 @@ else
|
@@ -1809,7 +1809,7 @@ else
|
||||||
socklen_t_value="int"
|
socklen_t_value="int"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -46,25 +44,25 @@ index 3b10422..a227e72 100644
|
|||||||
|
|
||||||
if test "$ac_cv_sizeof_pid_t" = "$ac_cv_sizeof_short"; then
|
if test "$ac_cv_sizeof_pid_t" = "$ac_cv_sizeof_short"; then
|
||||||
pid_t_fmt='#define APR_PID_T_FMT "hd"'
|
pid_t_fmt='#define APR_PID_T_FMT "hd"'
|
||||||
@@ -1840,7 +1840,7 @@ APR_CHECK_TYPES_COMPATIBLE(ssize_t, long, [ssize_t_fmt="ld"])
|
@@ -1881,7 +1881,7 @@ APR_CHECK_TYPES_FMT_COMPATIBLE(size_t, u
|
||||||
APR_CHECK_TYPES_COMPATIBLE(size_t, unsigned int, [size_t_fmt="u"])
|
APR_CHECK_TYPES_FMT_COMPATIBLE(size_t, unsigned int, u, [size_t_fmt="u"])
|
||||||
APR_CHECK_TYPES_COMPATIBLE(size_t, unsigned long, [size_t_fmt="lu"])
|
])
|
||||||
|
|
||||||
-APR_CHECK_SIZEOF_EXTENDED([#include <sys/types.h>], ssize_t, 8)
|
-APR_CHECK_SIZEOF_EXTENDED([#include <sys/types.h>], ssize_t, 8)
|
||||||
+AC_CHECK_SIZEOF(ssize_t)
|
+AC_CHECK_SIZEOF(ssize_t)
|
||||||
|
|
||||||
|
dnl the else cases below should no longer occur;
|
||||||
AC_MSG_CHECKING([which format to use for apr_ssize_t])
|
AC_MSG_CHECKING([which format to use for apr_ssize_t])
|
||||||
if test -n "$ssize_t_fmt"; then
|
@@ -1899,7 +1899,7 @@ fi
|
||||||
@@ -1857,7 +1857,7 @@ fi
|
|
||||||
|
|
||||||
ssize_t_fmt="#define APR_SSIZE_T_FMT \"$ssize_t_fmt\""
|
ssize_t_fmt="#define APR_SSIZE_T_FMT \"$ssize_t_fmt\""
|
||||||
|
|
||||||
-APR_CHECK_SIZEOF_EXTENDED([#include <stddef.h>], size_t, 8)
|
-APR_CHECK_SIZEOF_EXTENDED([#include <stddef.h>], size_t, 8)
|
||||||
+AC_CHECK_SIZEOF(size_t)
|
+AC_CHECK_SIZEOF(size_t)
|
||||||
|
|
||||||
|
# else cases below should no longer occur;
|
||||||
AC_MSG_CHECKING([which format to use for apr_size_t])
|
AC_MSG_CHECKING([which format to use for apr_size_t])
|
||||||
if test -n "$size_t_fmt"; then
|
@@ -1917,7 +1917,7 @@ fi
|
||||||
@@ -1874,7 +1874,7 @@ fi
|
|
||||||
|
|
||||||
size_t_fmt="#define APR_SIZE_T_FMT \"$size_t_fmt\""
|
size_t_fmt="#define APR_SIZE_T_FMT \"$size_t_fmt\""
|
||||||
|
|
||||||
@@ -73,6 +71,3 @@ index 3b10422..a227e72 100644
|
|||||||
|
|
||||||
if test "${ac_cv_sizeof_off_t}${apr_cv_use_lfs64}" = "4yes"; then
|
if test "${ac_cv_sizeof_off_t}${apr_cv_use_lfs64}" = "4yes"; then
|
||||||
# Enable LFS
|
# Enable LFS
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,30 @@
|
|||||||
|
--- a/build/apr_common.m4
|
||||||
|
+++ b/build/apr_common.m4
|
||||||
|
@@ -526,8 +526,9 @@ dnl string.
|
||||||
|
dnl
|
||||||
|
dnl
|
||||||
|
AC_DEFUN([APR_CHECK_STRERROR_R_RC], [
|
||||||
|
-AC_MSG_CHECKING(for type of return code from strerror_r)
|
||||||
|
-AC_TRY_RUN([
|
||||||
|
+AC_CACHE_CHECK([whether return code from strerror_r has type int],
|
||||||
|
+[ac_cv_strerror_r_rc_int],
|
||||||
|
+[AC_TRY_RUN([
|
||||||
|
#include <errno.h>
|
||||||
|
#include <string.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
@@ -543,14 +544,10 @@ main()
|
||||||
|
}], [
|
||||||
|
ac_cv_strerror_r_rc_int=yes ], [
|
||||||
|
ac_cv_strerror_r_rc_int=no ], [
|
||||||
|
- ac_cv_strerror_r_rc_int=no ] )
|
||||||
|
+ ac_cv_strerror_r_rc_int=no ] ) ] )
|
||||||
|
if test "x$ac_cv_strerror_r_rc_int" = xyes; then
|
||||||
|
AC_DEFINE(STRERROR_R_RC_INT, 1, [Define if strerror returns int])
|
||||||
|
- msg="int"
|
||||||
|
-else
|
||||||
|
- msg="pointer"
|
||||||
|
fi
|
||||||
|
-AC_MSG_RESULT([$msg])
|
||||||
|
] )
|
||||||
|
|
||||||
|
dnl
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
--- a/configure.in
|
||||||
|
+++ b/configure.in
|
||||||
|
@@ -1191,8 +1191,9 @@ AC_CHECK_FILE(/dev/zero)
|
||||||
|
# Not all systems can mmap /dev/zero (such as HP-UX). Check for that.
|
||||||
|
if test "$ac_cv_func_mmap" = "yes" &&
|
||||||
|
test "$ac_cv_file__dev_zero" = "yes"; then
|
||||||
|
- AC_MSG_CHECKING(for mmap that can map /dev/zero)
|
||||||
|
- AC_TRY_RUN([
|
||||||
|
+ AC_CACHE_CHECK([for mmap that can map /dev/zero],
|
||||||
|
+ [ac_cv_mmap__dev_zero],
|
||||||
|
+ [AC_TRY_RUN([
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/stat.h>
|
||||||
|
#include <fcntl.h>
|
||||||
|
@@ -1215,9 +1216,7 @@ if test "$ac_cv_func_mmap" = "yes" &&
|
||||||
|
return 3;
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
- }], [], [ac_cv_file__dev_zero=no], [ac_cv_file__dev_zero=no])
|
||||||
|
-
|
||||||
|
- AC_MSG_RESULT($ac_cv_file__dev_zero)
|
||||||
|
+ }], [], [ac_cv_file__dev_zero=no], [ac_cv_file__dev_zero=no])])
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Now we determine which one is our anonymous shmem preference.
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
menu "Configuration"
|
|
||||||
depends on PACKAGE_apache
|
|
||||||
|
|
||||||
config APACHE_HTTP2
|
|
||||||
bool
|
|
||||||
prompt "Enable HTTP2"
|
|
||||||
help
|
|
||||||
Enable HTTPS2 support.
|
|
||||||
default n
|
|
||||||
|
|
||||||
endmenu
|
|
||||||
+330
-121
@@ -8,34 +8,47 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=apache
|
PKG_NAME:=apache
|
||||||
PKG_VERSION:=2.4.37
|
PKG_VERSION:=2.4.41
|
||||||
PKG_RELEASE:=2
|
PKG_RELEASE:=1
|
||||||
PKG_SOURCE_NAME:=httpd
|
PKG_SOURCE_NAME:=httpd
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_SOURCE_NAME)-$(PKG_VERSION).tar.bz2
|
PKG_SOURCE:=$(PKG_SOURCE_NAME)-$(PKG_VERSION).tar.bz2
|
||||||
PKG_SOURCE_URL:=@APACHE/httpd/
|
PKG_SOURCE_URL:=@APACHE/httpd/
|
||||||
PKG_HASH:=3498dc5c6772fac2eb7307dc7963122ffe243b5e806e0be4fb51974ff759d726
|
PKG_HASH:=133d48298fe5315ae9366a0ec66282fa4040efa5d566174481077ade7d18ea40
|
||||||
|
|
||||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_SOURCE_NAME)-$(PKG_VERSION)
|
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_SOURCE_NAME)-$(PKG_VERSION)
|
||||||
|
|
||||||
PKG_MAINTAINER:=Thomas Heil <heil@terminal-consulting.de>
|
PKG_MAINTAINER:=Thomas Heil <heil@terminal-consulting.de>, \
|
||||||
PKG_LICENSE:=Apache License
|
Sebastian Kemper <sebastian_ml@gmx.net>
|
||||||
|
PKG_LICENSE:=Apache-2.0
|
||||||
|
PKG_LICENSE_FILES:=LICENSE
|
||||||
|
|
||||||
PKG_CPE_ID:=cpe:/a:apache:http_server
|
PKG_CPE_ID:=cpe:/a:apache:http_server
|
||||||
|
|
||||||
|
PKG_BUILD_DEPENDS:=openssl
|
||||||
|
|
||||||
|
PKG_BUILD_PARALLEL:=1
|
||||||
|
|
||||||
|
PKG_CONFIG_DEPENDS:= \
|
||||||
|
CONFIG_PACKAGE_apache-mod-deflate \
|
||||||
|
CONFIG_PACKAGE_apache-mod-http2 \
|
||||||
|
CONFIG_PACKAGE_apache-mod-ldap \
|
||||||
|
CONFIG_PACKAGE_apache-mod-lua \
|
||||||
|
CONFIG_PACKAGE_apache-mod-md \
|
||||||
|
CONFIG_PACKAGE_apache-mod-proxy \
|
||||||
|
CONFIG_PACKAGE_apache-mod-proxy-html \
|
||||||
|
CONFIG_PACKAGE_apache-mod-session-crypto \
|
||||||
|
CONFIG_PACKAGE_apache-mod-suexec \
|
||||||
|
CONFIG_PACKAGE_apache-mod-webdav \
|
||||||
|
CONFIG_PACKAGE_apache-suexec
|
||||||
|
|
||||||
|
PKG_FIXUP:=autoreconf
|
||||||
|
|
||||||
PKG_INSTALL:=1
|
PKG_INSTALL:=1
|
||||||
|
|
||||||
PKG_CONFIG_DEPENDS:= \
|
|
||||||
CONFIG_APACHE_HTTP2
|
|
||||||
|
|
||||||
ADDITIONAL_MODULES:=
|
|
||||||
ifeq ($(CONFIG_APACHE_HTTP2),y)
|
|
||||||
ADDITIONAL_MODULES += --enable-http2
|
|
||||||
endif
|
|
||||||
ifneq ($(CONFIG_APACHE_HTTP2),y)
|
|
||||||
ADDITIONAL_MODULES += --enable-http2=no
|
|
||||||
endif
|
|
||||||
|
|
||||||
include $(INCLUDE_DIR)/package.mk
|
include $(INCLUDE_DIR)/package.mk
|
||||||
|
# without nls.mk mod_xml2enc might not find the iconv headers
|
||||||
|
include $(INCLUDE_DIR)/nls.mk
|
||||||
|
|
||||||
define Package/apache/Default
|
define Package/apache/Default
|
||||||
SECTION:=net
|
SECTION:=net
|
||||||
@@ -46,51 +59,85 @@ define Package/apache/Default
|
|||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/apache/Default/description
|
define Package/apache/Default/description
|
||||||
The Apache Web Server is a powerful and flexible HTTP/1.1 compliant
|
The Apache HTTP Server Project is a collaborative software development
|
||||||
web server. Originally designed as a replacement for the NCSA HTTP
|
effort aimed at creating a robust, commercial-grade, featureful, and
|
||||||
Server, it has grown to be the most popular web server on the Internet.
|
freely-available source code implementation of an HTTP (Web) server.
|
||||||
endef
|
|
||||||
|
|
||||||
define Package/apache/config
|
|
||||||
source "$(SOURCE)/Config.in"
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/apache
|
define Package/apache
|
||||||
$(call Package/apache/Default)
|
$(call Package/apache/Default)
|
||||||
DEPENDS:=+libapr +libaprutil +libpcre +libopenssl +unixodbc +zlib +APACHE_HTTP2:libnghttp2
|
USERID:=apache=377:apache=377
|
||||||
|
DEPENDS:=+libapr +libaprutil +libpcre
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/apache/description
|
define Package/apache/description
|
||||||
$(call Package/apache/Default/description)
|
$(call Package/apache/Default/description)
|
||||||
.
|
|
||||||
This package contains the Apache web server and utility programs.
|
This package contains the Apache web server and utility programs.
|
||||||
.
|
|
||||||
Take care that you don't include apache at the moment into your image
|
|
||||||
please select it only as module because busybox will override
|
|
||||||
/usr/sbin/httpd. It'll be solved soon. If you need to include this
|
|
||||||
package in the image anyway, remove httpd from busybox
|
|
||||||
(Base system --> Configuration --> Networking Utilities --> httpd).
|
|
||||||
Also you should take care for the initscripts, apache's httpd isn't
|
|
||||||
compatible with the one from busybox, so if you want to use apache
|
|
||||||
for running your webif, you'll need to change the parameters in the
|
|
||||||
scripts and configure the rest in /etc/httpd.conf.
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/apache/conffiles
|
define Package/apache/conffiles
|
||||||
/etc/apache/httpd.conf
|
/etc/apache2/apache2.conf
|
||||||
/etc/apache/extra/httpd-autoindex.conf
|
/etc/apache2/extra/httpd-autoindex.conf
|
||||||
/etc/apache/extra/httpd-dav.conf
|
/etc/apache2/extra/httpd-dav.conf
|
||||||
/etc/apache/extra/httpd-default.conf
|
/etc/apache2/extra/httpd-default.conf
|
||||||
/etc/apache/extra/httpd-info.conf
|
/etc/apache2/extra/httpd-info.conf
|
||||||
/etc/apache/extra/httpd-languages.conf
|
/etc/apache2/extra/httpd-languages.conf
|
||||||
/etc/apache/extra/httpd-manual.conf
|
/etc/apache2/extra/httpd-manual.conf
|
||||||
/etc/apache/extra/httpd-mpm.conf
|
/etc/apache2/extra/httpd-mpm.conf
|
||||||
/etc/apache/extra/httpd-multilang-errordoc.conf
|
/etc/apache2/extra/httpd-multilang-errordoc.conf
|
||||||
/etc/apache/extra/httpd-ssl.conf
|
/etc/apache2/extra/httpd-ssl.conf
|
||||||
/etc/apache/extra/httpd-userdir.conf
|
/etc/apache2/extra/httpd-userdir.conf
|
||||||
/etc/apache/extra/httpd-vhosts.conf
|
/etc/apache2/extra/httpd-vhosts.conf
|
||||||
/etc/apache/magic
|
/etc/apache2/extra/proxy-html.conf
|
||||||
/etc/apache/mime.types
|
/etc/apache2/magic
|
||||||
|
/etc/apache2/mime.types
|
||||||
|
/etc/init.d/apache2
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/apache/postinst
|
||||||
|
#!/bin/sh
|
||||||
|
if [ -z "$${IPKG_INSTROOT}" ]; then
|
||||||
|
echo
|
||||||
|
echo "o-------------------------------------------------------------------o"
|
||||||
|
echo "| Apache package changes |"
|
||||||
|
echo "o-------------------------------------------------------------------o"
|
||||||
|
echo "| - The server binary was renamed from httpd to apache2 |"
|
||||||
|
echo "| - A simple init script is installed (/etc/init.d/apache2) |"
|
||||||
|
echo "| - The server runs as user apache by default now |"
|
||||||
|
echo "| - Configuration resides in /etc/apache2 instead of /etc/apache |"
|
||||||
|
echo "| - Modules are installed to /usr/lib/apache2 |"
|
||||||
|
echo "o-------------------------------------------------------------=^_^=-o"
|
||||||
|
echo
|
||||||
|
fi
|
||||||
|
exit 0
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/apache-ab
|
||||||
|
$(call Package/apache/Default)
|
||||||
|
TITLE:=Apache benchmark utility
|
||||||
|
DEPENDS:=apache +libopenssl
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/apache-ab/description
|
||||||
|
$(call Package/apache/Default/description)
|
||||||
|
|
||||||
|
Apache server benchmarking utility.
|
||||||
|
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/apache-error
|
||||||
|
$(call Package/apache/Default)
|
||||||
|
TITLE:=Error documents
|
||||||
|
DEPENDS:=apache
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/apache-error/description
|
||||||
|
$(call Package/apache/Default/description)
|
||||||
|
|
||||||
|
Apache multi language custom error documents.
|
||||||
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/apache-icons
|
define Package/apache-icons
|
||||||
@@ -101,92 +148,254 @@ endef
|
|||||||
|
|
||||||
define Package/apache-icons/description
|
define Package/apache-icons/description
|
||||||
$(call Package/apache/Default/description)
|
$(call Package/apache/Default/description)
|
||||||
.
|
|
||||||
This package contains the icons from Apache.
|
This package contains the icons from Apache.
|
||||||
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
TARGET_CFLAGS += $(FPIC) -Wno-error
|
define Package/apache-suexec
|
||||||
TARGET_CPPFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE
|
$(call Package/apache/Default)
|
||||||
TARGET_LDFLAGS += -lpthread
|
TITLE:=Apache suEXEC
|
||||||
|
DEPENDS:=apache
|
||||||
|
endef
|
||||||
|
|
||||||
define Build/Configure
|
define Package/apache-suexec/description
|
||||||
$(call Build/Configure/Default, \
|
$(call Package/apache/Default/description)
|
||||||
--with-apr="$(STAGING_DIR)/usr/bin/apr-1-config" \
|
|
||||||
--with-apr-util="$(STAGING_DIR)/usr/bin/apu-1-config" \
|
This package contains the suEXEC utility from Apache.
|
||||||
--with-pcre="$(STAGING_DIR)/usr/bin/pcre-config" \
|
|
||||||
$(ADDITIONAL_MODULES) \
|
endef
|
||||||
--enable-http \
|
|
||||||
--with-crypto \
|
define Package/apache-utils
|
||||||
--with-sqlit3="$(STAGING_DIR)/usr" \
|
$(call Package/apache/Default)
|
||||||
--with-openssl="$(STAGING_DIR)/usr" \
|
TITLE:=Apache utilities
|
||||||
--enable-ssl \
|
DEPENDS:=apache
|
||||||
--enable-proxy \
|
endef
|
||||||
--disable-md \
|
|
||||||
--disable-disk-cache \
|
define Package/apache-utils/description
|
||||||
--enable-maintainer-mode \
|
$(call Package/apache/Default/description)
|
||||||
--with-mpm=prefork \
|
|
||||||
--with-mpm=worker \
|
Apache utility programs for webservers.
|
||||||
--enable-mime-magic \
|
|
||||||
--without-suexec-bin \
|
endef
|
||||||
--sysconfdir=/etc/apache \
|
|
||||||
ap_cv_void_ptr_lt_long=no \
|
define Package/apache/install/mod
|
||||||
logfiledir="/var/log" \
|
$(INSTALL_DIR) $(1)/usr/lib/apache2
|
||||||
runtimedir="/var/run" \
|
$(INSTALL_BIN) \
|
||||||
EXTRA_LIBS="-ldl -lpthread -lcrypto -lrt -lssl" \
|
$(PKG_INSTALL_DIR)/usr/lib/apache2/mod_$(2).so \
|
||||||
)
|
$(1)/usr/lib/apache2
|
||||||
|
endef
|
||||||
|
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--$(if $(CONFIG_PACKAGE_apache-mod-http2),en,dis)able-http2 \
|
||||||
|
--$(if $(CONFIG_PACKAGE_apache-mod-lua),en,dis)able-lua \
|
||||||
|
--$(if $(CONFIG_PACKAGE_apache-mod-md),en,dis)able-md \
|
||||||
|
--$(if $(CONFIG_PACKAGE_apache-mod-proxy),en,dis)able-proxy \
|
||||||
|
--$(if $(CONFIG_PACKAGE_apache-mod-session-crypto),en,dis)able-session-crypto \
|
||||||
|
--$(if $(CONFIG_PACKAGE_apache-mod-ssl),en,dis)able-ssl \
|
||||||
|
--datadir=/usr/share/apache2 \
|
||||||
|
--disable-imagemap \
|
||||||
|
--disable-luajit \
|
||||||
|
--enable-authn-alias \
|
||||||
|
--enable-authn-anon \
|
||||||
|
--enable-cache \
|
||||||
|
--enable-cgi \
|
||||||
|
--enable-cgid \
|
||||||
|
--enable-dbd \
|
||||||
|
--enable-disk-cache \
|
||||||
|
--enable-exception-hook \
|
||||||
|
--enable-file-cache \
|
||||||
|
--enable-layout=OpenWrt \
|
||||||
|
--enable-mem-cache \
|
||||||
|
--enable-mods-shared=all \
|
||||||
|
--enable-mpms-shared=all \
|
||||||
|
--enable-so \
|
||||||
|
--libexecdir=/usr/lib/apache2 \
|
||||||
|
--sysconfdir=/etc/apache2 \
|
||||||
|
--with-apr-util="$(STAGING_DIR)/usr/bin/apu-1-config" \
|
||||||
|
--with-apr="$(STAGING_DIR)/usr/bin/apr-1-config" \
|
||||||
|
--with-mpm=prefork \
|
||||||
|
--with-pcre="$(STAGING_DIR)/usr/bin/pcre-config" \
|
||||||
|
--with-program-name=apache2 \
|
||||||
|
--with-ssl
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_apache-mod-deflate),)
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--enable-deflate \
|
||||||
|
--with-z="$(STAGING_DIR)/usr"
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--disable-deflate \
|
||||||
|
--without-z
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_apache-mod-ldap),)
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--enable-authnz-ldap \
|
||||||
|
--enable-ldap
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--disable-authnz-ldap \
|
||||||
|
--disable-ldap
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_apache-mod-proxy),)
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--enable-proxy \
|
||||||
|
--enable-proxy-connect \
|
||||||
|
--enable-proxy-ftp \
|
||||||
|
--enable-proxy-http
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--disable-proxy
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_apache-mod-proxy-html),)
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--enable-proxy-html \
|
||||||
|
--enable-xml2enc \
|
||||||
|
--with-libxml2="$(STAGING_DIR)/usr"
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--disable-proxy-html \
|
||||||
|
--disable-xml2enc
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_apache-mod-suexec)$(CONFIG_PACKAGE_apache-suexec),)
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--enable-suexec \
|
||||||
|
--with-suexec-bin=/usr/sbin/suexec \
|
||||||
|
--with-suexec-caller=apache \
|
||||||
|
--with-suexec-docroot=/var/www \
|
||||||
|
--with-suexec-logfile=/var/log/apache2/suexec.log \
|
||||||
|
--with-suexec-uidmin=99 \
|
||||||
|
--with-suexec-gidmin=99
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--disable-suexec
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_PACKAGE_apache-mod-webdav),)
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--enable-dav \
|
||||||
|
--enable-dav-fs \
|
||||||
|
--enable-dav-lock
|
||||||
|
else
|
||||||
|
CONFIGURE_ARGS+= \
|
||||||
|
--disable-dav
|
||||||
|
endif
|
||||||
|
|
||||||
|
CONFIGURE_VARS += \
|
||||||
|
ac_cv_gettid=yes \
|
||||||
|
ap_cv_void_ptr_lt_long=no
|
||||||
|
|
||||||
|
define Build/Prepare
|
||||||
|
$(call Build/Prepare/Default)
|
||||||
|
$(INSTALL_DATA) ./files/openwrt.layout $(PKG_BUILD_DIR)/config.layout
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Build/InstallDev
|
define Build/InstallDev
|
||||||
rm -rf $(PKG_INSTALL_DIR)/usr/man/ \
|
$(INSTALL_DIR) $(1)/usr/bin
|
||||||
$(PKG_INSTALL_DIR)/usr/share/manual/
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/apxs $(1)/usr/bin
|
||||||
# if you need docs take a look into the build-dir :)
|
$(INSTALL_DIR) $(1)/usr/include/apache2
|
||||||
$(INSTALL_DIR) $(1)/etc
|
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/apache2/* \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/etc/* \
|
$(1)/usr/include/apache2
|
||||||
$(1)/etc
|
$(INSTALL_DIR) $(1)/usr/lib/apache2
|
||||||
$(INSTALL_DIR) $(1)/usr/include/apache
|
$(INSTALL_DIR) $(1)/usr/share/apache2/build
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/* \
|
$(CP) $(PKG_INSTALL_DIR)/usr/share/apache2/build/* \
|
||||||
$(1)/usr/include/apache
|
$(1)/usr/share/apache2/build
|
||||||
$(INSTALL_DIR) $(1)/usr/lib
|
$(SED) 's%/usr/share/apache2/build%$(STAGING_DIR)/usr/share/apache2/build%' \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/httpd.exp \
|
$(1)/usr/bin/apxs
|
||||||
$(1)/usr/lib
|
$(SED) 's%^prefix =.*%prefix = $(STAGING_DIR)/usr%' \
|
||||||
$(INSTALL_DIR) $(1)/usr/sbin
|
$(1)/usr/share/apache2/build/config_vars.mk
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/sbin/* \
|
|
||||||
$(1)/usr/sbin
|
|
||||||
$(INSTALL_DIR) $(1)/usr/share
|
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/share/* \
|
|
||||||
$(1)/usr/share
|
|
||||||
endef
|
|
||||||
|
|
||||||
define Package/apache/preinst
|
|
||||||
rm /usr/sbin/httpd
|
|
||||||
echo -e "You should take a look in the initscripts, busybox's httpd \n\
|
|
||||||
uses some parameters which are maybe unsupported by apache."
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/apache/install
|
define Package/apache/install
|
||||||
$(INSTALL_DIR) $(1)/usr/sbin
|
$(INSTALL_DIR) $(1)/etc/apache2/extra
|
||||||
# we don't need apxs on the router, it's just for building apache modules.
|
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/etc/apache2/extra/* \
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{ab,dbmmanage,htdbm,htdigest,htpasswd,httxt2dbm,logresolve} $(1)/usr/sbin/
|
$(1)/etc/apache2/extra
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/{apachectl,checkgid,envvars,envvars-std,htcacheclean,httpd,rotatelogs} $(1)/usr/sbin/
|
$(SED) '/^LoadModule session_crypto_module/s/^/#/' \
|
||||||
$(INSTALL_DIR) $(1)/usr/lib
|
$(PKG_INSTALL_DIR)/etc/apache2/apache2.conf
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/httpd.exp $(1)/usr/lib/
|
$(INSTALL_DATA) \
|
||||||
$(INSTALL_DIR) $(1)/usr/share
|
$(PKG_INSTALL_DIR)/etc/apache2/{apache2.conf,magic,mime.types} \
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/share/{error,htdocs,cgi-bin,build} $(1)/usr/share/
|
$(1)/etc/apache2
|
||||||
$(INSTALL_DIR) $(1)/etc/apache
|
$(INSTALL_DIR) $(1)/etc/init.d
|
||||||
$(CP) $(PKG_INSTALL_DIR)/etc/apache/{httpd.conf,magic,mime.types,extra} $(1)/etc/apache/
|
$(INSTALL_BIN) ./files/apache2.init $(1)/etc/init.d/apache2
|
||||||
|
$(INSTALL_DIR) $(1)/usr/lib/apache2
|
||||||
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/apache2/*.so \
|
||||||
|
$(1)/usr/lib/apache2
|
||||||
|
rm -f $(1)/usr/lib/apache2/mod_{*ldap,dav*,deflate,http2,lbmethod_*,lua,md,proxy*,proxy_html,session_crypto,ssl,suexec,xml2enc}.so
|
||||||
|
$(INSTALL_DIR) $(1)/usr/share/apache2/{cgi-bin,htdocs}
|
||||||
|
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/apache2/cgi-bin/* \
|
||||||
|
$(1)/usr/share/apache2/cgi-bin
|
||||||
|
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/apache2/htdocs/* \
|
||||||
|
$(1)/usr/share/apache2/htdocs
|
||||||
|
$(INSTALL_DIR) $(1)/usr/{,s}bin
|
||||||
|
$(INSTALL_BIN) \
|
||||||
|
$(PKG_INSTALL_DIR)/usr/bin/{dbmmanage,htdbm,htdigest,htpasswd,httxt2dbm,logresolve} \
|
||||||
|
$(1)/usr/bin
|
||||||
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/{apachectl,apache2} \
|
||||||
|
$(1)/usr/sbin
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/apache/postrm
|
define Package/apache-ab/install
|
||||||
rm -rf /usr/sbin/httpd
|
$(INSTALL_DIR) $(1)/usr/bin
|
||||||
ln -s /bin/busybox /usr/sbin/httpd
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/ab $(1)/usr/bin
|
||||||
echo -e "You may need to change your initscripts back for the use \n\
|
endef
|
||||||
with busybox's httpd."
|
|
||||||
|
define Package/apache-error/install
|
||||||
|
$(INSTALL_DIR) $(1)/usr/share/apache2/error
|
||||||
|
$(CP) $(PKG_INSTALL_DIR)/usr/share/apache2/error/* \
|
||||||
|
$(1)/usr/share/apache2/error
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/apache-icons/install
|
define Package/apache-icons/install
|
||||||
$(INSTALL_DIR) $(1)/usr/share
|
$(INSTALL_DIR) $(1)/usr/share/apache2
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/share/icons $(1)/usr/share/
|
$(CP) $(PKG_INSTALL_DIR)/usr/share/apache2/icons \
|
||||||
|
$(1)/usr/share/apache2
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/apache-suexec/install
|
||||||
|
$(INSTALL_DIR) $(1)/usr/sbin
|
||||||
|
$(CP) $(PKG_INSTALL_DIR)/usr/sbin/suexec $(1)/usr/sbin
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/apache-utils/install
|
||||||
|
$(INSTALL_DIR) $(1)/usr/sbin
|
||||||
|
$(INSTALL_BIN) \
|
||||||
|
$(PKG_INSTALL_DIR)/usr/sbin/{checkgid,envvars*,htcacheclean,rotatelogs} \
|
||||||
|
$(1)/usr/sbin
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/apache/Module
|
||||||
|
define Package/apache-mod-$(1)
|
||||||
|
$(call Package/apache/Default)
|
||||||
|
TITLE:=$(2) module
|
||||||
|
DEPENDS:=apache $(patsubst +%,+PACKAGE_apache-mod-$(1):%,$(4))
|
||||||
|
endef
|
||||||
|
define Package/apache-mod-$(1)/description
|
||||||
|
$(subst \n,$(newline),$(3))
|
||||||
|
endef
|
||||||
|
define Package/apache-mod-$(1)/install
|
||||||
|
$(foreach m,$(5),$(call Package/apache/install/mod,$$(1),$(m));)
|
||||||
|
endef
|
||||||
|
$$(eval $$(call BuildPackage,apache-mod-$(1)))
|
||||||
endef
|
endef
|
||||||
|
|
||||||
$(eval $(call BuildPackage,apache))
|
$(eval $(call BuildPackage,apache))
|
||||||
|
$(eval $(call BuildPackage,apache-ab))
|
||||||
|
$(eval $(call BuildPackage,apache-error))
|
||||||
$(eval $(call BuildPackage,apache-icons))
|
$(eval $(call BuildPackage,apache-icons))
|
||||||
|
$(eval $(call BuildPackage,apache-suexec))
|
||||||
|
$(eval $(call BuildPackage,apache-utils))
|
||||||
|
$(eval $(call Package/apache/Module,deflate,Deflate,Deflate support for the Apache HTTP server.,+zlib,deflate))
|
||||||
|
$(eval $(call Package/apache/Module,http2,HTTP2,HTTP/2 transport layer for the Apache HTTP Server.,+libnghttp2 +libopenssl,http2))
|
||||||
|
$(eval $(call Package/apache/Module,ldap,LDAP,LDAP authentication/authorization module for the Apache HTTP Server.,+libaprutil-ldap,authnz_ldap ldap))
|
||||||
|
$(eval $(call Package/apache/Module,lua,Lua,Lua support for the Apache HTTP server.,+liblua,lua))
|
||||||
|
$(eval $(call Package/apache/Module,md,Managed Domain handling,Managed Domain handling.,+libcurl +jansson +libopenssl,md))
|
||||||
|
$(eval $(call Package/apache/Module,proxy,Proxy,Proxy modules for the Apache HTTP Server.,,proxy proxy_ajp proxy_balancer proxy_connect proxy_express proxy_fcgi proxy_fdpass proxy_ftp proxy_hcheck proxy_http proxy_scgi proxy_uwsgi proxy_wstunnel lbmethod_byrequests lbmethod_heartbeat lbmethod_bytraffic lbmethod_bybusyness))
|
||||||
|
$(eval $(call Package/apache/Module,proxy-html,Proxy HTML,HTML and XML content filters for the Apache HTTP Server.,+apache-mod-proxy +libxml2,proxy_html xml2enc))
|
||||||
|
$(eval $(call Package/apache/Module,session-crypto,Session crypto,Session encryption support for the Apache HTTP Server.,+libaprutil-crypto-openssl,session_crypto))
|
||||||
|
$(eval $(call Package/apache/Module,ssl,SSL/TLS,SSL/TLS module for the Apache HTTP Server.,+libopenssl,ssl))
|
||||||
|
$(eval $(call Package/apache/Module,suexec,suEXEC,suEXEC module for the Apache HTTP Server.,+apache-suexec,suexec))
|
||||||
|
$(eval $(call Package/apache/Module,webdav,WebDAV,WebDAV support for the Apache HTTP Server.,,dav dav_fs dav_lock))
|
||||||
|
|||||||
@@ -0,0 +1,20 @@
|
|||||||
|
#!/bin/sh /etc/rc.common
|
||||||
|
|
||||||
|
START=99
|
||||||
|
|
||||||
|
reload() {
|
||||||
|
apachectl -k restart
|
||||||
|
}
|
||||||
|
|
||||||
|
restart() {
|
||||||
|
apachectl -k restart
|
||||||
|
}
|
||||||
|
|
||||||
|
start() {
|
||||||
|
mkdir -p /var/log/apache2 /var/run/apache2
|
||||||
|
apachectl -k start
|
||||||
|
}
|
||||||
|
|
||||||
|
stop() {
|
||||||
|
apachectl -k stop
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
|
||||||
|
<Layout OpenWrt>
|
||||||
|
prefix: /usr
|
||||||
|
exec_prefix: ${prefix}
|
||||||
|
bindir: ${prefix}/bin
|
||||||
|
sbindir: ${prefix}/sbin
|
||||||
|
libdir: ${prefix}/lib
|
||||||
|
libexecdir: ${prefix}/lib+
|
||||||
|
mandir: ${prefix}/share/man
|
||||||
|
sysconfdir: /etc+
|
||||||
|
datadir: ${prefix}/share+
|
||||||
|
installbuilddir: ${datadir}/build
|
||||||
|
errordir: ${datadir}/error
|
||||||
|
iconsdir: ${datadir}/icons
|
||||||
|
htdocsdir: ${datadir}/htdocs
|
||||||
|
manualdir: /usr/share/doc/apache2/manual
|
||||||
|
cgidir: ${datadir}/cgi-bin
|
||||||
|
includedir: ${prefix}/include+
|
||||||
|
localstatedir: /var
|
||||||
|
runtimedir: ${localstatedir}/run+
|
||||||
|
logfiledir: ${localstatedir}/log+
|
||||||
|
proxycachedir: ${localstatedir}/cache/apache2
|
||||||
|
</Layout>
|
||||||
|
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
--- a/server/Makefile.in
|
|
||||||
+++ b/server/Makefile.in
|
|
||||||
@@ -29,7 +29,10 @@ gen_test_char: $(gen_test_char_OBJECTS)
|
|
||||||
$(LINK) $(EXTRA_LDFLAGS) $(gen_test_char_OBJECTS) $(EXTRA_LIBS)
|
|
||||||
|
|
||||||
test_char.h: gen_test_char
|
|
||||||
- ./gen_test_char > test_char.h
|
|
||||||
+ true
|
|
||||||
+# ./gen_test_char > test_char.h
|
|
||||||
+# doesn't matter if you run it on the buildhost or on an wl500gd,
|
|
||||||
+# same output on both, so i just patched in the test_char.h :).
|
|
||||||
|
|
||||||
util.lo: test_char.h
|
|
||||||
|
|
||||||
@@ -0,0 +1,57 @@
|
|||||||
|
Fix cross-compilation
|
||||||
|
|
||||||
|
Fetched httpd-2.4.x-cross_compile.diff from upstream bugtracker:
|
||||||
|
https://issues.apache.org/bugzilla/show_bug.cgi?id=51257#c6
|
||||||
|
|
||||||
|
which is a bundle of upstream revisions:
|
||||||
|
http://svn.apache.org/viewvc?view=revision&revision=1327907
|
||||||
|
http://svn.apache.org/viewvc?view=revision&revision=1328390
|
||||||
|
http://svn.apache.org/viewvc?view=revision&revision=1328714
|
||||||
|
|
||||||
|
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
|
||||||
|
|
||||||
|
--- a/server/Makefile.in
|
||||||
|
+++ b/server/Makefile.in
|
||||||
|
@@ -24,9 +24,14 @@ TARGETS = delete-exports $(LTLIBRARY_NAM
|
||||||
|
include $(top_builddir)/build/rules.mk
|
||||||
|
include $(top_srcdir)/build/library.mk
|
||||||
|
|
||||||
|
+ifdef CC_FOR_BUILD
|
||||||
|
+gen_test_char: gen_test_char.c
|
||||||
|
+ $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) -DCROSS_COMPILE -o $@ $<
|
||||||
|
+else
|
||||||
|
gen_test_char_OBJECTS = gen_test_char.lo
|
||||||
|
gen_test_char: $(gen_test_char_OBJECTS)
|
||||||
|
$(LINK) $(EXTRA_LDFLAGS) $(gen_test_char_OBJECTS) $(EXTRA_LIBS)
|
||||||
|
+endif
|
||||||
|
|
||||||
|
test_char.h: gen_test_char
|
||||||
|
./gen_test_char > test_char.h
|
||||||
|
--- a/configure.in
|
||||||
|
+++ b/configure.in
|
||||||
|
@@ -206,6 +206,14 @@ AC_PROG_CPP
|
||||||
|
dnl Try to get c99 support for variadic macros
|
||||||
|
ifdef([AC_PROG_CC_C99], [AC_PROG_CC_C99])
|
||||||
|
|
||||||
|
+dnl In case of cross compilation we set CC_FOR_BUILD to cc unless
|
||||||
|
+dnl we got already CC_FOR_BUILD from environment.
|
||||||
|
+if test "x${build_alias}" != "x${host_alias}"; then
|
||||||
|
+ if test "x${CC_FOR_BUILD}" = "x"; then
|
||||||
|
+ CC_FOR_BUILD=cc
|
||||||
|
+ fi
|
||||||
|
+fi
|
||||||
|
+
|
||||||
|
if test "x${cache_file}" = "x/dev/null"; then
|
||||||
|
# Likewise, ensure that CC and CPP are passed through to the pcre
|
||||||
|
# configure script iff caching is disabled (the autoconf 2.5x default).
|
||||||
|
--- a/acinclude.m4
|
||||||
|
+++ b/acinclude.m4
|
||||||
|
@@ -55,6 +55,8 @@ AC_DEFUN([APACHE_GEN_CONFIG_VARS],[
|
||||||
|
APACHE_SUBST(CPPFLAGS)
|
||||||
|
APACHE_SUBST(CFLAGS)
|
||||||
|
APACHE_SUBST(CXXFLAGS)
|
||||||
|
+ APACHE_SUBST(CC_FOR_BUILD)
|
||||||
|
+ APACHE_SUBST(CFLAGS_FOR_BUILD)
|
||||||
|
APACHE_SUBST(LTFLAGS)
|
||||||
|
APACHE_SUBST(LDFLAGS)
|
||||||
|
APACHE_SUBST(LT_LDFLAGS)
|
||||||
@@ -1,49 +0,0 @@
|
|||||||
Index: httpd-2.4.25/server/test_char.h
|
|
||||||
===================================================================
|
|
||||||
--- /dev/null
|
|
||||||
+++ httpd-2.4.25/server/test_char.h
|
|
||||||
@@ -0,0 +1,23 @@
|
|
||||||
+/* this file is automatically generated by gen_test_char, do not edit */
|
|
||||||
+#define T_ESCAPE_SHELL_CMD (1)
|
|
||||||
+#define T_ESCAPE_PATH_SEGMENT (2)
|
|
||||||
+#define T_OS_ESCAPE_PATH (4)
|
|
||||||
+#define T_HTTP_TOKEN_STOP (8)
|
|
||||||
+#define T_ESCAPE_LOGITEM (16)
|
|
||||||
+#define T_ESCAPE_FORENSIC (32)
|
|
||||||
+
|
|
||||||
+static const unsigned char test_char_table[256] = {
|
|
||||||
+ 32,62,62,62,62,62,62,62,62,62,63,62,62,62,62,62,62,62,62,62,
|
|
||||||
+ 62,62,62,62,62,62,62,62,62,62,62,62,14,0,23,6,1,38,1,1,
|
|
||||||
+ 9,9,1,0,8,0,0,10,0,0,0,0,0,0,0,0,0,0,40,15,
|
|
||||||
+ 15,8,15,15,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
|
||||||
+ 0,0,0,0,0,0,0,0,0,0,0,15,31,15,7,0,7,0,0,0,
|
|
||||||
+ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
|
||||||
+ 0,0,0,15,39,15,1,62,54,54,54,54,54,54,54,54,54,54,54,54,
|
|
||||||
+ 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,
|
|
||||||
+ 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,
|
|
||||||
+ 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,
|
|
||||||
+ 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,
|
|
||||||
+ 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,
|
|
||||||
+ 54,54,54,54,54,54,54,54,54,54,54,54,54,54,54,54
|
|
||||||
+};
|
|
||||||
Index: httpd-2.4.25/server/util.c
|
|
||||||
===================================================================
|
|
||||||
--- httpd-2.4.25.orig/server/util.c
|
|
||||||
+++ httpd-2.4.25/server/util.c
|
|
||||||
@@ -96,6 +96,16 @@
|
|
||||||
#undef APLOG_MODULE_INDEX
|
|
||||||
#define APLOG_MODULE_INDEX AP_CORE_MODULE_INDEX
|
|
||||||
|
|
||||||
+#define T_ESCAPE_SHELL_CMD (0x01)
|
|
||||||
+#define T_ESCAPE_PATH_SEGMENT (0x02)
|
|
||||||
+#define T_OS_ESCAPE_PATH (0x04)
|
|
||||||
+#define T_HTTP_TOKEN_STOP (0x08)
|
|
||||||
+#define T_ESCAPE_LOGITEM (0x10)
|
|
||||||
+#define T_ESCAPE_FORENSIC (0x20)
|
|
||||||
+#define T_ESCAPE_URLENCODED (0x40)
|
|
||||||
+#define T_HTTP_CTRLS (0x80)
|
|
||||||
+#define T_VCHAR_OBSTEXT (0x100)
|
|
||||||
+
|
|
||||||
/*
|
|
||||||
* Examine a field value (such as a media-/content-type) string and return
|
|
||||||
* it sans any parameters; e.g., strip off any ';charset=foo' and the like.
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
Index: httpd-2.4.25/build/mkconfNW.awk
|
|
||||||
===================================================================
|
|
||||||
--- httpd-2.4.25.orig/build/mkconfNW.awk
|
|
||||||
+++ httpd-2.4.25/build/mkconfNW.awk
|
|
||||||
@@ -23,7 +23,7 @@ BEGIN {
|
|
||||||
A["sysconfdir"] = "conf"
|
|
||||||
A["iconsdir"] = "icons"
|
|
||||||
A["manualdir"] = "manual"
|
|
||||||
- A["runtimedir"] = "logs"
|
|
||||||
+ A["runtimedir"] = "log"
|
|
||||||
A["errordir"] = "error"
|
|
||||||
A["proxycachedir"] = "proxy"
|
|
||||||
|
|
||||||
Index: httpd-2.4.25/config.layout
|
|
||||||
===================================================================
|
|
||||||
--- httpd-2.4.25.orig/config.layout
|
|
||||||
+++ httpd-2.4.25/config.layout
|
|
||||||
@@ -28,8 +28,8 @@
|
|
||||||
cgidir: ${datadir}/cgi-bin
|
|
||||||
includedir: ${prefix}/include
|
|
||||||
localstatedir: ${prefix}
|
|
||||||
- runtimedir: ${localstatedir}/logs
|
|
||||||
- logfiledir: ${localstatedir}/logs
|
|
||||||
+ runtimedir: ${localstatedir}/log
|
|
||||||
+ logfiledir: ${localstatedir}/log
|
|
||||||
proxycachedir: ${localstatedir}/proxy
|
|
||||||
</Layout>
|
|
||||||
|
|
||||||
@@ -174,7 +174,7 @@
|
|
||||||
includedir: ${prefix}/include
|
|
||||||
localstatedir: /var${prefix}
|
|
||||||
runtimedir: ${localstatedir}/run
|
|
||||||
- logfiledir: ${localstatedir}/logs
|
|
||||||
+ logfiledir: ${localstatedir}/log
|
|
||||||
proxycachedir: ${localstatedir}/proxy
|
|
||||||
</Layout>
|
|
||||||
|
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
--- a/include/scoreboard.h
|
||||||
|
+++ b/include/scoreboard.h
|
||||||
|
@@ -40,7 +40,7 @@ extern "C" {
|
||||||
|
|
||||||
|
/* Scoreboard file, if there is one */
|
||||||
|
#ifndef DEFAULT_SCOREBOARD
|
||||||
|
-#define DEFAULT_SCOREBOARD "logs/apache_runtime_status"
|
||||||
|
+#define DEFAULT_SCOREBOARD "log/apache2/apache_runtime_status"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Scoreboard info on a process is, for now, kept very brief ---
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
Index: httpd-2.4.25/include/scoreboard.h
|
|
||||||
===================================================================
|
|
||||||
--- httpd-2.4.25.orig/include/scoreboard.h
|
|
||||||
+++ httpd-2.4.25/include/scoreboard.h
|
|
||||||
@@ -40,7 +40,7 @@ extern "C" {
|
|
||||||
|
|
||||||
/* Scoreboard file, if there is one */
|
|
||||||
#ifndef DEFAULT_SCOREBOARD
|
|
||||||
-#define DEFAULT_SCOREBOARD "logs/apache_runtime_status"
|
|
||||||
+#define DEFAULT_SCOREBOARD "log/apache_runtime_status"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Scoreboard info on a process is, for now, kept very brief ---
|
|
||||||
@@ -1,63 +1,13 @@
|
|||||||
Index: httpd-2.4.25/docs/conf/httpd.conf.in
|
--- a/docs/conf/httpd.conf.in
|
||||||
===================================================================
|
+++ b/docs/conf/httpd.conf.in
|
||||||
--- httpd-2.4.25.orig/docs/conf/httpd.conf.in
|
@@ -74,8 +74,8 @@ Listen @@Port@@
|
||||||
+++ httpd-2.4.25/docs/conf/httpd.conf.in
|
|
||||||
@@ -63,7 +63,6 @@ Listen @@Port@@
|
|
||||||
# Example:
|
|
||||||
# LoadModule foo_module modules/mod_foo.so
|
|
||||||
#
|
|
||||||
-@@LoadModule@@
|
|
||||||
|
|
||||||
<IfModule unixd_module>
|
|
||||||
#
|
|
||||||
@@ -74,8 +73,8 @@ Listen @@Port@@
|
|
||||||
# It is usually good practice to create a dedicated user and group for
|
# It is usually good practice to create a dedicated user and group for
|
||||||
# running httpd, as with most system services.
|
# running httpd, as with most system services.
|
||||||
#
|
#
|
||||||
-User daemon
|
-User daemon
|
||||||
-Group daemon
|
-Group daemon
|
||||||
+User nobody
|
+User apache
|
||||||
+Group nogroup
|
+Group apache
|
||||||
|
|
||||||
</IfModule>
|
</IfModule>
|
||||||
|
|
||||||
@@ -188,7 +187,7 @@ ErrorLog "@rel_logfiledir@/error_log"
|
|
||||||
# Possible values include: debug, info, notice, warn, error, crit,
|
|
||||||
# alert, emerg.
|
|
||||||
#
|
|
||||||
-LogLevel warn
|
|
||||||
+LogLevel debug
|
|
||||||
|
|
||||||
<IfModule log_config_module>
|
|
||||||
#
|
|
||||||
@@ -330,7 +329,7 @@ LogLevel warn
|
|
||||||
# contents of the file itself to determine its type. The MIMEMagicFile
|
|
||||||
# directive tells the module where the hint definitions are located.
|
|
||||||
#
|
|
||||||
-#MIMEMagicFile @rel_sysconfdir@/magic
|
|
||||||
+MIMEMagicFile @rel_sysconfdir@/magic
|
|
||||||
|
|
||||||
#
|
|
||||||
# Customizable error responses come in three flavors:
|
|
||||||
@@ -360,7 +359,7 @@ LogLevel warn
|
|
||||||
# Defaults: EnableMMAP On, EnableSendfile Off
|
|
||||||
#
|
|
||||||
#EnableMMAP off
|
|
||||||
-#EnableSendfile on
|
|
||||||
+EnableSendfile off
|
|
||||||
|
|
||||||
# Supplemental configuration
|
|
||||||
#
|
|
||||||
@@ -411,8 +410,8 @@ Include @rel_sysconfdir@/extra/proxy-htm
|
|
||||||
# starting without SSL on platforms with no /dev/random equivalent
|
|
||||||
# but a statically compiled-in mod_ssl.
|
|
||||||
#
|
|
||||||
-<IfModule ssl_module>
|
|
||||||
-SSLRandomSeed startup builtin
|
|
||||||
-SSLRandomSeed connect builtin
|
|
||||||
-</IfModule>
|
|
||||||
+#<IfModule ssl_module>
|
|
||||||
+#SSLRandomSeed startup builtin
|
|
||||||
+#SSLRandomSeed connect builtin
|
|
||||||
+#</IfModule>
|
|
||||||
|
|
||||||
|
|||||||
@@ -5,10 +5,8 @@ Author: Jean-Michel Vourgère <nirgal@debian.org>
|
|||||||
Forwarded: no
|
Forwarded: no
|
||||||
Last-Update: 2015-08-11
|
Last-Update: 2015-08-11
|
||||||
|
|
||||||
Index: apache2/server/buildmark.c
|
--- a/server/buildmark.c
|
||||||
===================================================================
|
+++ b/server/buildmark.c
|
||||||
--- apache2.orig/server/buildmark.c
|
|
||||||
+++ apache2/server/buildmark.c
|
|
||||||
@@ -17,11 +17,7 @@
|
@@ -17,11 +17,7 @@
|
||||||
#include "ap_config.h"
|
#include "ap_config.h"
|
||||||
#include "httpd.h"
|
#include "httpd.h"
|
||||||
@@ -22,16 +20,14 @@ Index: apache2/server/buildmark.c
|
|||||||
|
|
||||||
AP_DECLARE(const char *) ap_get_server_built()
|
AP_DECLARE(const char *) ap_get_server_built()
|
||||||
{
|
{
|
||||||
Index: apache2/server/Makefile.in
|
--- a/server/Makefile.in
|
||||||
===================================================================
|
+++ b/server/Makefile.in
|
||||||
--- apache2.orig/server/Makefile.in
|
|
||||||
+++ apache2/server/Makefile.in
|
|
||||||
@@ -1,3 +1,4 @@
|
@@ -1,3 +1,4 @@
|
||||||
+export LC_ALL = C
|
+export LC_ALL = C
|
||||||
|
|
||||||
CLEAN_TARGETS = gen_test_char test_char.h \
|
CLEAN_TARGETS = gen_test_char test_char.h \
|
||||||
ApacheCoreOS2.def httpd.exp export_files \
|
ApacheCoreOS2.def httpd.exp export_files \
|
||||||
@@ -85,8 +86,8 @@ httpd.exp: exports.c export_vars.h
|
@@ -87,8 +88,8 @@ httpd.exp: exports.c export_vars.h
|
||||||
@echo "#! ." > $@
|
@echo "#! ." > $@
|
||||||
@echo "* This file was AUTOGENERATED at build time." >> $@
|
@echo "* This file was AUTOGENERATED at build time." >> $@
|
||||||
@echo "* Please do not edit by hand." >> $@
|
@echo "* Please do not edit by hand." >> $@
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=subversion
|
PKG_NAME:=subversion
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
PKG_VERSION:=1.12.2
|
PKG_VERSION:=1.12.2
|
||||||
PKG_SOURCE_URL:=@APACHE/subversion
|
PKG_SOURCE_URL:=@APACHE/subversion
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||||
@@ -30,7 +30,7 @@ define Package/subversion/Default
|
|||||||
CATEGORY:=Network
|
CATEGORY:=Network
|
||||||
SUBMENU:=Version Control Systems
|
SUBMENU:=Version Control Systems
|
||||||
TITLE:=A compelling replacement for CVS
|
TITLE:=A compelling replacement for CVS
|
||||||
DEPENDS:=+PACKAGE_unixodbc:unixodbc +libaprutil +libmagic $(ICONV_DEPENDS) $(INTL_DEPENDS)
|
DEPENDS:=+PACKAGE_unixodbc:unixodbc +libaprutil +libmagic +libsqlite3 $(ICONV_DEPENDS) $(INTL_DEPENDS)
|
||||||
URL:=https://subversion.apache.org/
|
URL:=https://subversion.apache.org/
|
||||||
endef
|
endef
|
||||||
|
|
||||||
@@ -78,10 +78,6 @@ define Package/subversion-server/conffiles
|
|||||||
/etc/config/subversion
|
/etc/config/subversion
|
||||||
endef
|
endef
|
||||||
|
|
||||||
TARGET_CFLAGS += $(FPIC)
|
|
||||||
APU_LIBS=$(shell $(STAGING_DIR)/usr/bin/apu-1-config --link-libtool --libs)
|
|
||||||
TARGET_LDFLAGS += $(APU_LIBS)
|
|
||||||
|
|
||||||
CONFIGURE_ARGS += \
|
CONFIGURE_ARGS += \
|
||||||
--with-apr="$(STAGING_DIR)/usr/bin/apr-1-config" \
|
--with-apr="$(STAGING_DIR)/usr/bin/apr-1-config" \
|
||||||
--with-apr-util="$(STAGING_DIR)/usr/bin/apu-1-config" \
|
--with-apr-util="$(STAGING_DIR)/usr/bin/apu-1-config" \
|
||||||
|
|||||||
Reference in New Issue
Block a user