Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
commit
963553fef9
@ -471,7 +471,8 @@ config KERNEL_AIO
|
||||
|
||||
config KERNEL_IO_URING
|
||||
bool "Compile the kernel with io_uring support"
|
||||
default y if !SMALL_FLASH
|
||||
depends on !SMALL_FLASH
|
||||
default y if (x86_64 || aarch64)
|
||||
|
||||
config KERNEL_FHANDLE
|
||||
bool "Compile the kernel with support for fhandle syscalls"
|
||||
|
||||
@ -26,6 +26,8 @@ AM_TOOL_PATHS:= \
|
||||
AUTOPOINT=true \
|
||||
GTKDOCIZE=true
|
||||
|
||||
AM_TOOL_PATHS_FAKE:=$(subst = ,=,$(patsubst "%,"$(TRUE)",$(subst =,= ",$(AM_TOOL_PATHS))))
|
||||
|
||||
# 1: build dir
|
||||
# 2: remove files
|
||||
# 3: automake paths
|
||||
|
||||
@ -8,6 +8,13 @@ include $(INCLUDE_DIR)/prereq.mk
|
||||
SHELL:=sh
|
||||
PKG_NAME:=Build dependency
|
||||
|
||||
$(eval $(call TestHostCommand,true, \
|
||||
Please install GNU 'coreutils', \
|
||||
$(TRUE)))
|
||||
|
||||
$(eval $(call TestHostCommand,false, \
|
||||
Please install GNU 'coreutils', \
|
||||
$(FALSE); [ $$$$$$$$? = 1 ] && $(TRUE)))
|
||||
|
||||
# Required for the toolchain
|
||||
$(eval $(call TestHostCommand,working-make, \
|
||||
|
||||
36
package/devel/gperf/Makefile
Normal file
36
package/devel/gperf/Makefile
Normal file
@ -0,0 +1,36 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=gperf
|
||||
PKG_VERSION:=3.1
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=@GNU/gperf
|
||||
PKG_HASH:=588546b945bba4b70b6a3a616e80b4ab466e3f33024a352fc2198112cdbb3ae2
|
||||
|
||||
PKG_LICENSE:=GPL-3.0
|
||||
PKG_LICENSE_FILES:=COPYING
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
HOST_CPPFLAGS:=-I$(HOST_BUILD_DIR)/lib -I$(HOST_BUILD_DIR)/src $(HOST_CPPFLAGS)
|
||||
TARGET_CPPFLAGS:=-I$(PKG_BUILD_DIR)/lib -I$(PKG_BUILD_DIR)/src $(TARGET_CPPFLAGS)
|
||||
|
||||
define Package/gperf
|
||||
SECTION:=devel
|
||||
CATEGORY:=Development
|
||||
TITLE:=GNU gperf
|
||||
URL:=http://www.gnu.org/software/gperf
|
||||
endef
|
||||
|
||||
define Package/gperf/description
|
||||
GNU gperf is a perfect hash function generator. For a given list of strings,
|
||||
it produces a hash function and hash table, in form of C or C++ code,
|
||||
for looking up a value depending on the input string.
|
||||
The hash function is perfect, which means that the hash table has no collisions,
|
||||
and the hash table lookup needs a single string comparison only.
|
||||
endef
|
||||
|
||||
$(eval $(call HostBuild))
|
||||
$(eval $(call BuildPackage,gperf))
|
||||
@ -1,12 +1,12 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=wireless-regdb
|
||||
PKG_VERSION:=2023.02.13
|
||||
PKG_VERSION:=2023.05.03
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
||||
PKG_SOURCE_URL:=@KERNEL/software/network/wireless-regdb/
|
||||
PKG_HASH:=fe81e8a8694dc4753a45087a1c4c7e1b48dee5a59f5f796ce374ea550f0b2e73
|
||||
PKG_HASH:=f254d08ab3765aeae2b856222e11a95d44aef519a6663877c71ef68fae4c8c12
|
||||
|
||||
PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
|
||||
|
||||
|
||||
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=gettext-full
|
||||
PKG_VERSION:=0.21.1
|
||||
PKG_RELEASE:=1
|
||||
PKG_RELEASE:=2
|
||||
|
||||
PKG_SOURCE:=gettext-$(PKG_VERSION).tar.xz
|
||||
PKG_SOURCE_URL:=@GNU/gettext
|
||||
@ -21,12 +21,42 @@ PKG_MAINTAINER:=Jo-Philipp Wich <jo@mein.io>
|
||||
PKG_LICENSE:=GPL-3.0-or-later
|
||||
PKG_CPE_ID:=cpe:/a:gnu:gettext
|
||||
|
||||
PKG_FIXUP:=autoreconf
|
||||
PKG_INSTALL:=1
|
||||
PKG_BUILD_DEPENDS:=gettext-full/host
|
||||
PKG_BUILD_DEPENDS:=gettext-full/host libxml2
|
||||
PKG_BUILD_PARALLEL:=0
|
||||
|
||||
HOST_BUILD_DEPENDS:=gperf/host libxml2/host
|
||||
HOST_BUILD_PARALLEL:=0
|
||||
|
||||
PKG_SUBDIRS:= \
|
||||
$$$$(foreach dir, \
|
||||
intl \
|
||||
intl-csharp \
|
||||
intl-java \
|
||||
its \
|
||||
gnulib-lib \
|
||||
gnulib-local \
|
||||
lib \
|
||||
$$$$(SUBDIR_libasprintf) \
|
||||
libgettextpo \
|
||||
libgrep \
|
||||
libtextstyle \
|
||||
m4 \
|
||||
misc \
|
||||
po \
|
||||
projects \
|
||||
src \
|
||||
styles \
|
||||
gettext-runtime \
|
||||
gettext-tools \
|
||||
,$$$$(wildcard $$$$(dir)) )
|
||||
|
||||
PKG_MAKEFILES_FAKE:= \
|
||||
gnulib-local/m4/Makefile \
|
||||
libtextstyle/gnulib-local/Makefile \
|
||||
libtextstyle/m4/Makefile \
|
||||
m4/Makefile
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
|
||||
@ -38,6 +68,8 @@ define Package/libintl-full
|
||||
ABI_VERSION:=8
|
||||
endef
|
||||
|
||||
export GNULIB_SRCDIR:=$(HOST_GNULIB_SRCDIR)
|
||||
|
||||
TARGET_CFLAGS += $(FPIC)
|
||||
ifneq ($(HOST_OS),Linux)
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR_HOSTPKG)/include
|
||||
@ -55,6 +87,7 @@ CONFIGURE_ARGS += \
|
||||
--with-included-gettext \
|
||||
--without-libintl-prefix \
|
||||
--without-libexpat-prefix \
|
||||
--with-libxml2-prefix=$(STAGING_DIR) \
|
||||
--without-emacs
|
||||
|
||||
HOST_CONFIGURE_ARGS += \
|
||||
@ -64,9 +97,8 @@ HOST_CONFIGURE_ARGS += \
|
||||
--disable-rpath \
|
||||
--disable-java \
|
||||
--disable-openmp \
|
||||
--with-included-libxml \
|
||||
--without-emacs \
|
||||
--without-libxml2-prefix
|
||||
--with-libxml2-prefix=$(STAGING_DIR_HOSTPKG)
|
||||
|
||||
HOST_CONFIGURE_VARS += \
|
||||
EMACS="no" \
|
||||
@ -76,6 +108,52 @@ HOST_CONFIGURE_VARS += \
|
||||
|
||||
HOST_CFLAGS += $(HOST_FPIC)
|
||||
|
||||
define Host/Bootstrap
|
||||
( \
|
||||
cd $(HOST_BUILD_DIR); \
|
||||
$(AM_TOOL_PATHS) \
|
||||
./autogen.sh \
|
||||
)
|
||||
endef
|
||||
|
||||
define Host/Prepare
|
||||
$(call Host/Prepare/Default)
|
||||
$(if $(QUILT),,$(call Host/Bootstrap))
|
||||
endef
|
||||
|
||||
define Host/Configure
|
||||
$(if $(QUILT),$(call Host/Bootstrap))
|
||||
$(call Host/Configure/Default)
|
||||
endef
|
||||
|
||||
define Host/Compile
|
||||
$(foreach makefile,$(PKG_MAKEFILES_FAKE),printf '%s\n%s\n' 'all:' 'install:' > $(HOST_BUILD_DIR)/$(makefile); )
|
||||
$(call Host/Compile/Default,SUBDIRS='$(PKG_SUBDIRS)')
|
||||
endef
|
||||
|
||||
define Build/Bootstrap
|
||||
( \
|
||||
cd $(PKG_BUILD_DIR); \
|
||||
$(AM_TOOL_PATHS) \
|
||||
./autogen.sh \
|
||||
)
|
||||
endef
|
||||
|
||||
define Build/Prepare
|
||||
$(call Build/Prepare/Default)
|
||||
$(if $(QUILT),,$(call Build/Bootstrap))
|
||||
endef
|
||||
|
||||
define Build/Configure
|
||||
$(if $(QUILT),$(call Build/Bootstrap))
|
||||
$(call Build/Configure/Default)
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
$(foreach makefile,$(PKG_MAKEFILES_FAKE),printf '%s\n%s\n' 'all:' 'install:' > $(PKG_BUILD_DIR)/$(makefile); )
|
||||
$(call Build/Compile/Default,SUBDIRS='$(PKG_SUBDIRS)')
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/lib/libintl-full/include
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/libintl.h $(1)/usr/lib/libintl-full/include/
|
||||
@ -90,10 +168,14 @@ define Build/InstallDev
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
$(call Host/Install/Default)
|
||||
$(call Host/Compile/Default,install SUBDIRS='$(PKG_SUBDIRS)')
|
||||
$(LN) msgfmt $(STAGING_DIR_HOSTPKG)/bin/gmsgfmt
|
||||
endef
|
||||
|
||||
define Build/Install
|
||||
$(call Build/Install/Default,install SUBDIRS='$(PKG_SUBDIRS)')
|
||||
endef
|
||||
|
||||
define Package/libintl-full/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libintl.so.* $(1)/usr/lib/
|
||||
|
||||
@ -1,22 +0,0 @@
|
||||
--- a/gettext-runtime/Makefile.am
|
||||
+++ b/gettext-runtime/Makefile.am
|
||||
@@ -27,7 +27,7 @@ SUBDIR_libasprintf = libasprintf
|
||||
else
|
||||
SUBDIR_libasprintf =
|
||||
endif
|
||||
-SUBDIRS = doc intl intl-java intl-csharp gnulib-lib $(SUBDIR_libasprintf) src po man m4 tests
|
||||
+SUBDIRS = intl intl-java intl-csharp gnulib-lib $(SUBDIR_libasprintf) src po m4
|
||||
|
||||
EXTRA_DIST = BUGS
|
||||
|
||||
--- a/gettext-tools/Makefile.am
|
||||
+++ b/gettext-tools/Makefile.am
|
||||
@@ -19,7 +19,7 @@
|
||||
AUTOMAKE_OPTIONS = 1.5 gnu no-dependencies
|
||||
ACLOCAL_AMFLAGS = -I m4 -I ../gettext-runtime/m4 -I ../m4 -I gnulib-m4 -I libgrep/gnulib-m4 -I libgettextpo/gnulib-m4
|
||||
|
||||
-SUBDIRS = intl gnulib-lib libgrep src libgettextpo po its projects styles emacs misc man m4 tests system-tests gnulib-tests examples doc
|
||||
+SUBDIRS = intl gnulib-lib libgrep src libgettextpo po its projects styles misc m4
|
||||
|
||||
EXTRA_DIST = misc/DISCLAIM
|
||||
MOSTLYCLEANFILES = core *.stackdump
|
||||
@ -1,342 +0,0 @@
|
||||
--- a/gettext-runtime/gnulib-m4/stddef_h.m4
|
||||
+++ b/gettext-runtime/gnulib-m4/stddef_h.m4
|
||||
@@ -9,7 +9,7 @@ dnl A placeholder for <stddef.h>, for pl
|
||||
AC_DEFUN_ONCE([gl_STDDEF_H],
|
||||
[
|
||||
AC_REQUIRE([gl_STDDEF_H_DEFAULTS])
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
|
||||
dnl Persuade OpenBSD <stddef.h> to declare max_align_t.
|
||||
AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
|
||||
--- a/gettext-runtime/gnulib-m4/stdint.m4
|
||||
+++ b/gettext-runtime/gnulib-m4/stdint.m4
|
||||
@@ -15,7 +15,7 @@ AC_DEFUN_ONCE([gl_STDINT_H],
|
||||
AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles
|
||||
|
||||
AC_REQUIRE([gl_LIMITS_H])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
|
||||
dnl For backward compatibility. Some packages may still be testing these
|
||||
dnl macros.
|
||||
--- a/gettext-runtime/gnulib-m4/wchar_h.m4
|
||||
+++ b/gettext-runtime/gnulib-m4/wchar_h.m4
|
||||
@@ -27,7 +27,7 @@ AC_DEFUN_ONCE([gl_WCHAR_H],
|
||||
|
||||
AC_REQUIRE([gl_FEATURES_H])
|
||||
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
if test $gt_cv_c_wint_t = yes; then
|
||||
HAVE_WINT_T=1
|
||||
else
|
||||
--- a/gettext-runtime/gnulib-m4/wchar_t.m4
|
||||
+++ b/gettext-runtime/gnulib-m4/wchar_t.m4
|
||||
@@ -8,7 +8,7 @@ dnl From Bruno Haible.
|
||||
dnl Test whether <stddef.h> has the 'wchar_t' type.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
-AC_DEFUN([gt_TYPE_WCHAR_T],
|
||||
+AC_DEFUN([gt_TYPE_WCHAR_T_GT],
|
||||
[
|
||||
AC_CACHE_CHECK([for wchar_t], [gt_cv_c_wchar_t],
|
||||
[AC_COMPILE_IFELSE(
|
||||
--- a/gettext-runtime/gnulib-m4/wctype_h.m4
|
||||
+++ b/gettext-runtime/gnulib-m4/wctype_h.m4
|
||||
@@ -22,7 +22,7 @@ AC_DEFUN_ONCE([gl_WCTYPE_H],
|
||||
fi
|
||||
AC_SUBST([HAVE_ISWCNTRL])
|
||||
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
if test $gt_cv_c_wint_t = yes; then
|
||||
HAVE_WINT_T=1
|
||||
else
|
||||
--- a/gettext-runtime/gnulib-m4/wcwidth.m4
|
||||
+++ b/gettext-runtime/gnulib-m4/wcwidth.m4
|
||||
@@ -12,8 +12,8 @@ AC_DEFUN([gl_FUNC_WCWIDTH],
|
||||
dnl Persuade glibc <wchar.h> to declare wcwidth().
|
||||
AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS])
|
||||
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
|
||||
AC_CHECK_HEADERS_ONCE([wchar.h])
|
||||
AC_CHECK_FUNCS_ONCE([wcwidth])
|
||||
--- a/gettext-runtime/gnulib-m4/wint_t.m4
|
||||
+++ b/gettext-runtime/gnulib-m4/wint_t.m4
|
||||
@@ -9,7 +9,7 @@ dnl Test whether <wchar.h> has the 'wint
|
||||
dnl <wchar.h> or <wctype.h> would, if present, override 'wint_t'.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
-AC_DEFUN([gt_TYPE_WINT_T],
|
||||
+AC_DEFUN([gt_TYPE_WINT_T_GT],
|
||||
[
|
||||
AC_CACHE_CHECK([for wint_t], [gt_cv_c_wint_t],
|
||||
[AC_COMPILE_IFELSE(
|
||||
--- a/gettext-runtime/libasprintf/configure.ac
|
||||
+++ b/gettext-runtime/libasprintf/configure.ac
|
||||
@@ -76,8 +76,8 @@ dnl Checks for typedefs, structures, and
|
||||
AC_C_INLINE
|
||||
AC_TYPE_SIZE_T
|
||||
AC_TYPE_LONG_LONG_INT
|
||||
-gt_TYPE_WCHAR_T
|
||||
-gt_TYPE_WINT_T
|
||||
+gt_TYPE_WCHAR_T_GT
|
||||
+gt_TYPE_WINT_T_GT
|
||||
AC_TYPE_MBSTATE_T
|
||||
AC_CHECK_TYPE([ptrdiff_t], ,
|
||||
[AC_DEFINE([ptrdiff_t], [long],
|
||||
--- a/gettext-runtime/libasprintf/gnulib-m4/wchar_t.m4
|
||||
+++ b/gettext-runtime/libasprintf/gnulib-m4/wchar_t.m4
|
||||
@@ -8,7 +8,7 @@ dnl From Bruno Haible.
|
||||
dnl Test whether <stddef.h> has the 'wchar_t' type.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
-AC_DEFUN([gt_TYPE_WCHAR_T],
|
||||
+AC_DEFUN([gt_TYPE_WCHAR_T_GT],
|
||||
[
|
||||
AC_CACHE_CHECK([for wchar_t], [gt_cv_c_wchar_t],
|
||||
[AC_COMPILE_IFELSE(
|
||||
--- a/gettext-runtime/libasprintf/gnulib-m4/wint_t.m4
|
||||
+++ b/gettext-runtime/libasprintf/gnulib-m4/wint_t.m4
|
||||
@@ -9,7 +9,7 @@ dnl Test whether <wchar.h> has the 'wint
|
||||
dnl <wchar.h> or <wctype.h> would, if present, override 'wint_t'.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
-AC_DEFUN([gt_TYPE_WINT_T],
|
||||
+AC_DEFUN([gt_TYPE_WINT_T_GT],
|
||||
[
|
||||
AC_CACHE_CHECK([for wint_t], [gt_cv_c_wint_t],
|
||||
[AC_COMPILE_IFELSE(
|
||||
--- a/gettext-runtime/m4/intl.m4
|
||||
+++ b/gettext-runtime/m4/intl.m4
|
||||
@@ -31,8 +31,8 @@ AC_DEFUN([AM_INTL_SUBDIR],
|
||||
AC_REQUIRE([gl_VISIBILITY])dnl
|
||||
AC_REQUIRE([gt_INTL_SUBDIR_CORE])dnl
|
||||
AC_REQUIRE([AC_TYPE_LONG_LONG_INT])dnl
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])dnl
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])dnl
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])dnl
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])dnl
|
||||
AC_REQUIRE([gl_AC_HEADER_INTTYPES_H])
|
||||
AC_REQUIRE([gt_TYPE_INTMAX_T])
|
||||
AC_REQUIRE([gt_PRINTF_POSIX])
|
||||
--- a/gettext-tools/gnulib-m4/stdint.m4
|
||||
+++ b/gettext-tools/gnulib-m4/stdint.m4
|
||||
@@ -15,7 +15,7 @@ AC_DEFUN_ONCE([gl_STDINT_H],
|
||||
AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles
|
||||
|
||||
AC_REQUIRE([gl_LIMITS_H])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
|
||||
dnl For backward compatibility. Some packages may still be testing these
|
||||
dnl macros.
|
||||
--- a/gettext-tools/gnulib-m4/vasnprintf.m4
|
||||
+++ b/gettext-tools/gnulib-m4/vasnprintf.m4
|
||||
@@ -32,16 +32,16 @@ AC_DEFUN([gl_REPLACE_VASNPRINTF],
|
||||
# Prerequisites of lib/printf-args.h, lib/printf-args.c.
|
||||
AC_DEFUN([gl_PREREQ_PRINTF_ARGS],
|
||||
[
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
])
|
||||
|
||||
# Prerequisites of lib/printf-parse.h, lib/printf-parse.c.
|
||||
AC_DEFUN([gl_PREREQ_PRINTF_PARSE],
|
||||
[
|
||||
AC_REQUIRE([gl_FEATURES_H])
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
AC_REQUIRE([AC_TYPE_SIZE_T])
|
||||
AC_CHECK_TYPE([ptrdiff_t], ,
|
||||
[AC_DEFINE([ptrdiff_t], [long],
|
||||
@@ -54,8 +54,8 @@ AC_DEFUN([gl_PREREQ_PRINTF_PARSE],
|
||||
AC_DEFUN_ONCE([gl_PREREQ_VASNPRINTF],
|
||||
[
|
||||
AC_REQUIRE([AC_FUNC_ALLOCA])
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
AC_CHECK_FUNCS([snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb])
|
||||
dnl Use the _snprintf function only if it is declared (because on NetBSD it
|
||||
dnl is defined as a weak alias of snprintf; we prefer to use the latter).
|
||||
--- a/gettext-tools/gnulib-m4/wchar_h.m4
|
||||
+++ b/gettext-tools/gnulib-m4/wchar_h.m4
|
||||
@@ -27,7 +27,7 @@ AC_DEFUN_ONCE([gl_WCHAR_H],
|
||||
|
||||
AC_REQUIRE([gl_FEATURES_H])
|
||||
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
if test $gt_cv_c_wint_t = yes; then
|
||||
HAVE_WINT_T=1
|
||||
else
|
||||
--- a/gettext-tools/gnulib-m4/wchar_t.m4
|
||||
+++ b/gettext-tools/gnulib-m4/wchar_t.m4
|
||||
@@ -8,7 +8,7 @@ dnl From Bruno Haible.
|
||||
dnl Test whether <stddef.h> has the 'wchar_t' type.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
-AC_DEFUN([gt_TYPE_WCHAR_T],
|
||||
+AC_DEFUN([gt_TYPE_WCHAR_T_GT],
|
||||
[
|
||||
AC_CACHE_CHECK([for wchar_t], [gt_cv_c_wchar_t],
|
||||
[AC_COMPILE_IFELSE(
|
||||
--- a/gettext-tools/gnulib-m4/wctype_h.m4
|
||||
+++ b/gettext-tools/gnulib-m4/wctype_h.m4
|
||||
@@ -22,7 +22,7 @@ AC_DEFUN_ONCE([gl_WCTYPE_H],
|
||||
fi
|
||||
AC_SUBST([HAVE_ISWCNTRL])
|
||||
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
if test $gt_cv_c_wint_t = yes; then
|
||||
HAVE_WINT_T=1
|
||||
else
|
||||
--- a/gettext-tools/gnulib-m4/wcwidth.m4
|
||||
+++ b/gettext-tools/gnulib-m4/wcwidth.m4
|
||||
@@ -12,8 +12,8 @@ AC_DEFUN([gl_FUNC_WCWIDTH],
|
||||
dnl Persuade glibc <wchar.h> to declare wcwidth().
|
||||
AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS])
|
||||
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
|
||||
AC_CHECK_HEADERS_ONCE([wchar.h])
|
||||
AC_CHECK_FUNCS_ONCE([wcwidth])
|
||||
--- a/gettext-tools/gnulib-m4/wint_t.m4
|
||||
+++ b/gettext-tools/gnulib-m4/wint_t.m4
|
||||
@@ -9,7 +9,7 @@ dnl Test whether <wchar.h> has the 'wint
|
||||
dnl <wchar.h> or <wctype.h> would, if present, override 'wint_t'.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
-AC_DEFUN([gt_TYPE_WINT_T],
|
||||
+AC_DEFUN([gt_TYPE_WINT_T_GT],
|
||||
[
|
||||
AC_CACHE_CHECK([for wint_t], [gt_cv_c_wint_t],
|
||||
[AC_COMPILE_IFELSE(
|
||||
--- a/libtextstyle/gnulib-m4/stdint.m4
|
||||
+++ b/libtextstyle/gnulib-m4/stdint.m4
|
||||
@@ -15,7 +15,7 @@ AC_DEFUN_ONCE([gl_STDINT_H],
|
||||
AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles
|
||||
|
||||
AC_REQUIRE([gl_LIMITS_H])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
|
||||
dnl For backward compatibility. Some packages may still be testing these
|
||||
dnl macros.
|
||||
--- a/libtextstyle/gnulib-m4/vasnprintf.m4
|
||||
+++ b/libtextstyle/gnulib-m4/vasnprintf.m4
|
||||
@@ -32,16 +32,16 @@ AC_DEFUN([gl_REPLACE_VASNPRINTF],
|
||||
# Prerequisites of lib/printf-args.h, lib/printf-args.c.
|
||||
AC_DEFUN([gl_PREREQ_PRINTF_ARGS],
|
||||
[
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
])
|
||||
|
||||
# Prerequisites of lib/printf-parse.h, lib/printf-parse.c.
|
||||
AC_DEFUN([gl_PREREQ_PRINTF_PARSE],
|
||||
[
|
||||
AC_REQUIRE([gl_FEATURES_H])
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
AC_REQUIRE([AC_TYPE_SIZE_T])
|
||||
AC_CHECK_TYPE([ptrdiff_t], ,
|
||||
[AC_DEFINE([ptrdiff_t], [long],
|
||||
@@ -54,8 +54,8 @@ AC_DEFUN([gl_PREREQ_PRINTF_PARSE],
|
||||
AC_DEFUN_ONCE([gl_PREREQ_VASNPRINTF],
|
||||
[
|
||||
AC_REQUIRE([AC_FUNC_ALLOCA])
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
AC_CHECK_FUNCS([snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb])
|
||||
dnl Use the _snprintf function only if it is declared (because on NetBSD it
|
||||
dnl is defined as a weak alias of snprintf; we prefer to use the latter).
|
||||
--- a/libtextstyle/gnulib-m4/wchar_h.m4
|
||||
+++ b/libtextstyle/gnulib-m4/wchar_h.m4
|
||||
@@ -27,7 +27,7 @@ AC_DEFUN_ONCE([gl_WCHAR_H],
|
||||
|
||||
AC_REQUIRE([gl_FEATURES_H])
|
||||
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
if test $gt_cv_c_wint_t = yes; then
|
||||
HAVE_WINT_T=1
|
||||
else
|
||||
--- a/libtextstyle/gnulib-m4/wchar_t.m4
|
||||
+++ b/libtextstyle/gnulib-m4/wchar_t.m4
|
||||
@@ -8,7 +8,7 @@ dnl From Bruno Haible.
|
||||
dnl Test whether <stddef.h> has the 'wchar_t' type.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
-AC_DEFUN([gt_TYPE_WCHAR_T],
|
||||
+AC_DEFUN([gt_TYPE_WCHAR_T_GT],
|
||||
[
|
||||
AC_CACHE_CHECK([for wchar_t], [gt_cv_c_wchar_t],
|
||||
[AC_COMPILE_IFELSE(
|
||||
--- a/libtextstyle/gnulib-m4/wint_t.m4
|
||||
+++ b/libtextstyle/gnulib-m4/wint_t.m4
|
||||
@@ -9,7 +9,7 @@ dnl Test whether <wchar.h> has the 'wint
|
||||
dnl <wchar.h> or <wctype.h> would, if present, override 'wint_t'.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
-AC_DEFUN([gt_TYPE_WINT_T],
|
||||
+AC_DEFUN([gt_TYPE_WINT_T_GT],
|
||||
[
|
||||
AC_CACHE_CHECK([for wint_t], [gt_cv_c_wint_t],
|
||||
[AC_COMPILE_IFELSE(
|
||||
--- a/gettext-tools/gnulib-m4/gnulib-comp.m4
|
||||
+++ b/gettext-tools/gnulib-m4/gnulib-comp.m4
|
||||
@@ -2218,8 +2218,8 @@ changequote([, ])dnl
|
||||
AC_REQUIRE([gl_SOCKETLIB])
|
||||
AC_REQUIRE([gl_SOCKETS])
|
||||
gl_TYPE_SOCKLEN_T
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
- AC_REQUIRE([gt_TYPE_WINT_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
+ AC_REQUIRE([gt_TYPE_WINT_T_GT])
|
||||
gl_FUNC_STRERROR_R
|
||||
AS_IF([test $HAVE_DECL_STRERROR_R = 0 || test $REPLACE_STRERROR_R = 1], [
|
||||
AC_LIBOBJ([strerror_r])
|
||||
--- a/libtextstyle/gnulib-m4/stddef_h.m4
|
||||
+++ b/libtextstyle/gnulib-m4/stddef_h.m4
|
||||
@@ -9,7 +9,7 @@ dnl A placeholder for <stddef.h>, for pl
|
||||
AC_DEFUN_ONCE([gl_STDDEF_H],
|
||||
[
|
||||
AC_REQUIRE([gl_STDDEF_H_DEFAULTS])
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
|
||||
dnl Persuade OpenBSD <stddef.h> to declare max_align_t.
|
||||
AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
|
||||
--- a/gettext-tools/gnulib-m4/stddef_h.m4
|
||||
+++ b/gettext-tools/gnulib-m4/stddef_h.m4
|
||||
@@ -9,7 +9,7 @@ dnl A placeholder for <stddef.h>, for pl
|
||||
AC_DEFUN_ONCE([gl_STDDEF_H],
|
||||
[
|
||||
AC_REQUIRE([gl_STDDEF_H_DEFAULTS])
|
||||
- AC_REQUIRE([gt_TYPE_WCHAR_T])
|
||||
+ AC_REQUIRE([gt_TYPE_WCHAR_T_GT])
|
||||
|
||||
dnl Persuade OpenBSD <stddef.h> to declare max_align_t.
|
||||
AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
|
||||
@ -0,0 +1,31 @@
|
||||
--- a/libtextstyle/gnulib-local/modules/libxml.diff
|
||||
+++ /dev/null
|
||||
@@ -1,28 +0,0 @@
|
||||
-*** libxml.orig 2018-10-28 14:37:07.007164889 +0100
|
||||
---- libxml 2019-02-14 22:19:29.994771110 +0100
|
||||
-***************
|
||||
-*** 118,124 ****
|
||||
- fabs
|
||||
-
|
||||
- configure.ac:
|
||||
-! gl_LIBXML
|
||||
-
|
||||
- Makefile.am:
|
||||
- if INCLUDED_LIBXML
|
||||
---- 118,133 ----
|
||||
- fabs
|
||||
-
|
||||
- configure.ac:
|
||||
-! # In libtextstyle, we don't want to use an external libxml, because its
|
||||
-! # dependencies and their dynamic relocations have an impact on the startup
|
||||
-! # time of a program that is linked with it. As you can see by using
|
||||
-! # 'readelf -r ... | wc -l' and 'readelf -d ... | grep NEEDED':
|
||||
-! # - libxml2.so has more than 3300 relocations and depends on libicuuc.
|
||||
-! # - libicuuc.so has more than 4900 relocations and depends on libstdc++.
|
||||
-! # - libstdc++.so has more than 4600 relocations.
|
||||
-! # These are more than 12800 relocations, to perform at program startup.
|
||||
-! # So, force the use of the included libxml part.
|
||||
-! gl_LIBXML([yes])
|
||||
-
|
||||
- Makefile.am:
|
||||
- if INCLUDED_LIBXML
|
||||
@ -1,22 +0,0 @@
|
||||
--- a/gettext-tools/gnulib-lib/libxml/xmlversion.in.h
|
||||
+++ b/gettext-tools/gnulib-lib/libxml/xmlversion.in.h
|
||||
@@ -302,7 +302,7 @@ XMLPUBFUN void XMLCALL xmlCheckVersion(i
|
||||
*
|
||||
* Whether iconv support is available
|
||||
*/
|
||||
-#if 1
|
||||
+#if 0
|
||||
#define LIBXML_ICONV_ENABLED
|
||||
#endif
|
||||
|
||||
--- a/gnulib-local/lib/libxml/xmlversion.in.h
|
||||
+++ b/gnulib-local/lib/libxml/xmlversion.in.h
|
||||
@@ -302,7 +302,7 @@ XMLPUBFUN void XMLCALL xmlCheckVersion(i
|
||||
*
|
||||
* Whether iconv support is available
|
||||
*/
|
||||
-#if 1
|
||||
+#if 0
|
||||
#define LIBXML_ICONV_ENABLED
|
||||
#endif
|
||||
|
||||
206
package/libs/libxml2/Makefile
Normal file
206
package/libs/libxml2/Makefile
Normal file
@ -0,0 +1,206 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=libxml2
|
||||
PKG_VERSION:=2.10.3
|
||||
PKG_RELEASE:=2
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
||||
PKG_SOURCE_URL:=@GNOME/libxml2/$(basename $(PKG_VERSION))
|
||||
PKG_HASH:=5d2cc3d78bec3dbe212a9d7fa629ada25a7da928af432c93060ff5c17ee28a9c
|
||||
|
||||
PKG_LICENSE:=MIT
|
||||
PKG_LICENSE_FILES:=COPYING
|
||||
PKG_CPE_ID:=cpe:/a:xmlsoft:libxml2
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include $(INCLUDE_DIR)/cmake.mk
|
||||
include $(INCLUDE_DIR)/nls.mk
|
||||
|
||||
define Package/libxml2
|
||||
SECTION:=libs
|
||||
CATEGORY:=Libraries
|
||||
TITLE:=Gnome XML library
|
||||
URL:=http://xmlsoft.org/
|
||||
DEPENDS:=+libpthread +zlib $(ICONV_DEPENDS)
|
||||
endef
|
||||
|
||||
define Package/libxml2/description
|
||||
A library for manipulating XML and HTML resources.
|
||||
endef
|
||||
|
||||
define Package/libxml2-dev
|
||||
SECTION:=devel
|
||||
CATEGORY:=Development
|
||||
SUBMENU:=Libraries
|
||||
TITLE:=Development files for libxml2
|
||||
URL:=http://xmlsoft.org/
|
||||
DEPENDS:=+libxml2
|
||||
endef
|
||||
|
||||
define Package/libxml2-dev/description
|
||||
A library for manipulating XML and HTML resources.
|
||||
|
||||
This package contains the headers and xml2-config binary.
|
||||
endef
|
||||
|
||||
define Package/libxml2-utils
|
||||
SECTION:=utils
|
||||
CATEGORY:=Utilities
|
||||
TITLE:=XML command line utilities (xmllint...)
|
||||
URL:=http://xmlsoft.org/
|
||||
DEPENDS:=+libxml2
|
||||
endef
|
||||
|
||||
define Package/libxml2-utils/description
|
||||
This package contains the binaries xmllint and xmlcatalog
|
||||
from libxml2, a library for manipulating XML and HTML resources.
|
||||
endef
|
||||
|
||||
CMAKE_HOST_OPTIONS += \
|
||||
-DBUILD_SHARED_LIBS=OFF \
|
||||
-DLIBXML2_WITH_C14N=ON \
|
||||
-DLIBXML2_WITH_CATALOG=OFF \
|
||||
-DLIBXML2_WITH_DEBUG=ON \
|
||||
-DLIBXML2_WITH_FTP=OFF \
|
||||
-DLIBXML2_WITH_HTML=ON \
|
||||
-DLIBXML2_WITH_HTTP=OFF \
|
||||
-DLIBXML2_WITH_ICONV=ON \
|
||||
-DLIBXML2_WITH_ICU=OFF \
|
||||
-DLIBXML2_WITH_ISO8859X=OFF \
|
||||
-DLIBXML2_WITH_LEGACY=OFF \
|
||||
-DLIBXML2_WITH_LZMA=OFF \
|
||||
-DLIBXML2_WITH_MEM_DEBUG=OFF \
|
||||
-DLIBXML2_WITH_MODULES=OFF \
|
||||
-DLIBXML2_WITH_OUTPUT=ON \
|
||||
-DLIBXML2_WITH_PATTERN=ON \
|
||||
-DLIBXML2_WITH_PROGRAMS=OFF \
|
||||
-DLIBXML2_WITH_PUSH=ON \
|
||||
-DLIBXML2_WITH_PYTHON=OFF \
|
||||
-DLIBXML2_WITH_READER=ON \
|
||||
-DLIBXML2_WITH_REGEXPS=ON \
|
||||
-DLIBXML2_WITH_RUN_DEBUG=OFF \
|
||||
-DLIBXML2_WITH_SAX1=ON \
|
||||
-DLIBXML2_WITH_SCHEMAS=ON \
|
||||
-DLIBXML2_WITH_SCHEMATRON=OFF \
|
||||
-DLIBXML2_WITH_TESTS=OFF \
|
||||
-DLIBXML2_WITH_THREADS=ON \
|
||||
-DLIBXML2_WITH_THREAD_ALLOC=OFF \
|
||||
-DLIBXML2_WITH_TREE=ON \
|
||||
-DLIBXML2_WITH_VALID=ON \
|
||||
-DLIBXML2_WITH_WRITER=ON \
|
||||
-DLIBXML2_WITH_XINCLUDE=ON \
|
||||
-DLIBXML2_WITH_XPATH=ON \
|
||||
-DLIBXML2_WITH_XPTR=ON \
|
||||
-DLIBXML2_WITH_XPTR_LOCS=ON \
|
||||
-DLIBXML2_WITH_ZLIB=ON
|
||||
|
||||
CMAKE_OPTIONS += \
|
||||
-DBUILD_SHARED_LIBS=ON \
|
||||
-DLIBXML2_WITH_C14N=ON \
|
||||
-DLIBXML2_WITH_CATALOG=OFF \
|
||||
-DLIBXML2_WITH_DEBUG=ON \
|
||||
-DLIBXML2_WITH_FTP=OFF \
|
||||
-DLIBXML2_WITH_HTML=ON \
|
||||
-DLIBXML2_WITH_HTTP=OFF \
|
||||
-DLIBXML2_WITH_ICONV=ON \
|
||||
-DLIBXML2_WITH_ICU=OFF \
|
||||
-DLIBXML2_WITH_ISO8859X=OFF \
|
||||
-DLIBXML2_WITH_LEGACY=OFF \
|
||||
-DLIBXML2_WITH_LZMA=OFF \
|
||||
-DLIBXML2_WITH_MEM_DEBUG=OFF \
|
||||
-DLIBXML2_WITH_MODULES=OFF \
|
||||
-DLIBXML2_WITH_OUTPUT=ON \
|
||||
-DLIBXML2_WITH_PATTERN=ON \
|
||||
-DLIBXML2_WITH_PROGRAMS=ON \
|
||||
-DLIBXML2_WITH_PUSH=ON \
|
||||
-DLIBXML2_WITH_PYTHON=OFF \
|
||||
-DLIBXML2_WITH_READER=ON \
|
||||
-DLIBXML2_WITH_REGEXPS=ON \
|
||||
-DLIBXML2_WITH_RUN_DEBUG=OFF \
|
||||
-DLIBXML2_WITH_SAX1=ON \
|
||||
-DLIBXML2_WITH_SCHEMAS=ON \
|
||||
-DLIBXML2_WITH_SCHEMATRON=OFF \
|
||||
-DLIBXML2_WITH_TESTS=OFF \
|
||||
-DLIBXML2_WITH_THREADS=ON \
|
||||
-DLIBXML2_WITH_THREAD_ALLOC=OFF \
|
||||
-DLIBXML2_WITH_TREE=ON \
|
||||
-DLIBXML2_WITH_VALID=ON \
|
||||
-DLIBXML2_WITH_WRITER=ON \
|
||||
-DLIBXML2_WITH_XINCLUDE=ON \
|
||||
-DLIBXML2_WITH_XPATH=ON \
|
||||
-DLIBXML2_WITH_XPTR=ON \
|
||||
-DLIBXML2_WITH_XPTR_LOCS=ON \
|
||||
-DLIBXML2_WITH_ZLIB=ON \
|
||||
-DHAVE_LIBHISTORY=OFF \
|
||||
-DHAVE_LIBREADLINE=OFF
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(2)/bin
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/xml2-config \
|
||||
$(2)/bin/$(GNU_TARGET_NAME)-xml2-config
|
||||
$(SED) 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \
|
||||
$(2)/bin/$(GNU_TARGET_NAME)-xml2-config
|
||||
$(LN) $(GNU_TARGET_NAME)-xml2-config $(2)/bin/xml2-config
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/xmlcatalog $(1)/usr/bin/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/xmllint $(1)/usr/bin/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/include
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/libxml2 $(1)/usr/include/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libxml2.so* $(1)/usr/lib/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib/cmake/libxml2
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/cmake/libxml2-$(PKG_VERSION)/*.cmake \
|
||||
$(1)/usr/lib/cmake/libxml2
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
||||
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libxml-2.0.pc $(1)/usr/lib/pkgconfig/
|
||||
|
||||
$(INSTALL_DIR) $(2)/share/aclocal/
|
||||
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/aclocal/* $(2)/share/aclocal
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
$(call Host/Install/Default)
|
||||
mv $(1)/bin/xml2-config $(1)/bin/$(GNU_HOST_NAME)-xml2-config
|
||||
$(LN) $(GNU_HOST_NAME)-xml2-config $(1)/bin/xml2-config
|
||||
endef
|
||||
|
||||
define Package/libxml2/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libxml2.so.* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/libxml2-dev/install
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/xml2-config $(1)/usr/bin/
|
||||
$(SED) "s,$(STAGING_DIR),,g" $(1)/usr/bin/xml2-config
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/include/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libxml2.so $(1)/usr/lib/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib/{cmake,pkgconfig}
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/{cmake,pkgconfig} $(1)/usr/lib/
|
||||
$(SED) "s,$(STAGING_DIR),,g" $(1)/usr/lib/pkgconfig/*.pc
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/share/aclocal
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/share/aclocal/* $(1)/usr/share/aclocal
|
||||
endef
|
||||
|
||||
define Package/libxml2-utils/install
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/xmllint $(1)/usr/bin/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/xmlcatalog $(1)/usr/bin/
|
||||
endef
|
||||
|
||||
$(eval $(call HostBuild))
|
||||
$(eval $(call BuildPackage,libxml2))
|
||||
$(eval $(call BuildPackage,libxml2-dev))
|
||||
$(eval $(call BuildPackage,libxml2-utils))
|
||||
12
package/libs/libxml2/patches/010-iconv.patch
Normal file
12
package/libs/libxml2/patches/010-iconv.patch
Normal file
@ -0,0 +1,12 @@
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -496,6 +496,9 @@ if(LIBXML2_WITH_PROGRAMS)
|
||||
add_executable(LibXml2::${PROGRAM} ALIAS ${PROGRAM})
|
||||
target_compile_definitions(${PROGRAM} PRIVATE SYSCONFDIR="${CMAKE_INSTALL_FULL_SYSCONFDIR}")
|
||||
target_link_libraries(${PROGRAM} LibXml2)
|
||||
+ if(LIBXML2_WITH_ICONV AND NOT Iconv_IS_BUILT_IN)
|
||||
+ target_link_libraries(${PROGRAM} iconv)
|
||||
+ endif()
|
||||
if(HAVE_LIBHISTORY)
|
||||
target_link_libraries(${PROGRAM} history)
|
||||
endif()
|
||||
9
rules.mk
9
rules.mk
@ -268,6 +268,14 @@ FIND:=find
|
||||
PATCH:=patch
|
||||
PYTHON:=python3
|
||||
|
||||
ifeq ($(HOST_OS),Darwin)
|
||||
TRUE:=/usr/bin/env gtrue
|
||||
FALSE:=/usr/bin/env gfalse
|
||||
else
|
||||
TRUE:=/usr/bin/env true
|
||||
FALSE:=/usr/bin/env false
|
||||
endif
|
||||
|
||||
INSTALL_BIN:=install -m0755
|
||||
INSTALL_SUID:=install -m4755
|
||||
INSTALL_DIR:=install -d -m0755
|
||||
@ -350,6 +358,7 @@ ifeq ($(CONFIG_BUILD_LOG),y)
|
||||
endif
|
||||
|
||||
export BISON_PKGDATADIR:=$(STAGING_DIR_HOST)/share/bison
|
||||
export HOST_GNULIB_SRCDIR:=$(STAGING_DIR_HOST)/share/gnulib
|
||||
export M4:=$(STAGING_DIR_HOST)/bin/m4
|
||||
|
||||
define shvar
|
||||
|
||||
@ -135,7 +135,6 @@ CONFIG_INITRAMFS_SOURCE=""
|
||||
# CONFIG_IOMMU_IO_PGTABLE_ARMV7S is not set
|
||||
# CONFIG_IOMMU_IO_PGTABLE_LPAE is not set
|
||||
CONFIG_IOMMU_SUPPORT=y
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
CONFIG_IRQ_DOMAIN_HIERARCHY=y
|
||||
|
||||
@ -165,7 +165,6 @@ CONFIG_HW_RANDOM_BCM2835=y
|
||||
CONFIG_HZ_FIXED=0
|
||||
CONFIG_HZ_PERIODIC=y
|
||||
CONFIG_INITRAMFS_SOURCE=""
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
CONFIG_IRQ_DOMAIN_HIERARCHY=y
|
||||
|
||||
@ -171,7 +171,6 @@ CONFIG_HW_RANDOM_BCM2835=y
|
||||
CONFIG_HZ_FIXED=0
|
||||
CONFIG_HZ_PERIODIC=y
|
||||
CONFIG_INITRAMFS_SOURCE=""
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
CONFIG_IRQ_DOMAIN_HIERARCHY=y
|
||||
|
||||
@ -216,7 +216,6 @@ CONFIG_INPUT_KEYBOARD=y
|
||||
# CONFIG_IOMMU_IO_PGTABLE_ARMV7S is not set
|
||||
# CONFIG_IOMMU_IO_PGTABLE_LPAE is not set
|
||||
CONFIG_IOMMU_SUPPORT=y
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IPC_NS=y
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
|
||||
@ -217,7 +217,6 @@ CONFIG_INPUT_KEYBOARD=y
|
||||
# CONFIG_IOMMU_IO_PGTABLE_ARMV7S is not set
|
||||
# CONFIG_IOMMU_IO_PGTABLE_LPAE is not set
|
||||
CONFIG_IOMMU_SUPPORT=y
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IPC_NS=y
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
|
||||
@ -1746,7 +1746,7 @@ CONFIG_DVB_MAX_ADAPTERS=16
|
||||
# CONFIG_DW_EDMA_PCIE is not set
|
||||
# CONFIG_DW_WATCHDOG is not set
|
||||
# CONFIG_DYNAMIC_DEBUG is not set
|
||||
CONFIG_DYNAMIC_DEBUG_CORE=y
|
||||
# CONFIG_DYNAMIC_DEBUG_CORE is not set
|
||||
# CONFIG_E100 is not set
|
||||
# CONFIG_E1000 is not set
|
||||
# CONFIG_E1000E is not set
|
||||
|
||||
@ -1830,7 +1830,7 @@ CONFIG_DVB_MAX_ADAPTERS=16
|
||||
# CONFIG_DW_WATCHDOG is not set
|
||||
# CONFIG_DW_XDATA_PCIE is not set
|
||||
# CONFIG_DYNAMIC_DEBUG is not set
|
||||
CONFIG_DYNAMIC_DEBUG_CORE=y
|
||||
# CONFIG_DYNAMIC_DEBUG_CORE is not set
|
||||
# CONFIG_E100 is not set
|
||||
# CONFIG_E1000 is not set
|
||||
# CONFIG_E1000E is not set
|
||||
|
||||
@ -233,7 +233,6 @@ CONFIG_IMX_SDMA=y
|
||||
CONFIG_IMX_THERMAL=y
|
||||
# CONFIG_IMX_WEIM is not set
|
||||
CONFIG_INITRAMFS_SOURCE=""
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
CONFIG_IRQ_DOMAIN_HIERARCHY=y
|
||||
|
||||
@ -144,7 +144,6 @@ CONFIG_DMA_SHARED_BUFFER=y
|
||||
CONFIG_DMA_VIRTUAL_CHANNELS=y
|
||||
CONFIG_DTC=y
|
||||
CONFIG_DT_IDLE_STATES=y
|
||||
CONFIG_DYNAMIC_DEBUG=y
|
||||
CONFIG_EDAC_ATOMIC_SCRUB=y
|
||||
CONFIG_EDAC_SUPPORT=y
|
||||
CONFIG_EEPROM_AT24=y
|
||||
@ -211,7 +210,6 @@ CONFIG_INITRAMFS_SOURCE=""
|
||||
# CONFIG_IOMMU_IO_PGTABLE_ARMV7S is not set
|
||||
# CONFIG_IOMMU_IO_PGTABLE_LPAE is not set
|
||||
CONFIG_IOMMU_SUPPORT=y
|
||||
CONFIG_IO_URING=y
|
||||
# CONFIG_IPQ_APSS_PLL is not set
|
||||
CONFIG_IPQ_GCC_4019=y
|
||||
# CONFIG_IPQ_GCC_6018 is not set
|
||||
|
||||
@ -135,7 +135,6 @@ CONFIG_DT_IDLE_STATES=y
|
||||
# CONFIG_DWMAC_GENERIC is not set
|
||||
CONFIG_DWMAC_IPQ806X=y
|
||||
# CONFIG_DWMAC_QCOM_ETHQOS is not set
|
||||
CONFIG_DYNAMIC_DEBUG=y
|
||||
CONFIG_EDAC_ATOMIC_SCRUB=y
|
||||
CONFIG_EDAC_SUPPORT=y
|
||||
CONFIG_ETHERNET_PACKET_MANGLE=y
|
||||
|
||||
@ -136,7 +136,6 @@ CONFIG_DT_IDLE_STATES=y
|
||||
# CONFIG_DWMAC_GENERIC is not set
|
||||
CONFIG_DWMAC_IPQ806X=y
|
||||
# CONFIG_DWMAC_QCOM_ETHQOS is not set
|
||||
CONFIG_DYNAMIC_DEBUG=y
|
||||
CONFIG_EDAC_ATOMIC_SCRUB=y
|
||||
CONFIG_EDAC_SUPPORT=y
|
||||
CONFIG_ETHERNET_PACKET_MANGLE=y
|
||||
|
||||
@ -6,11 +6,10 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
BOARD:=lantiq
|
||||
BOARDNAME:=Lantiq
|
||||
FEATURES:=squashfs source-only
|
||||
FEATURES:=squashfs
|
||||
SUBTARGETS:=xrx200 xway xway_legacy falcon ase
|
||||
|
||||
KERNEL_PATCHVER:=5.10
|
||||
KERNEL_TESTING_PATCHVER:=5.15
|
||||
KERNEL_PATCHVER:=5.15
|
||||
|
||||
define Target/Description
|
||||
Build firmware images for Lantiq SoC
|
||||
|
||||
@ -18,7 +18,7 @@ define Device/avm_fritz7320
|
||||
DEVICE_ALT0_VENDOR := 1&1
|
||||
DEVICE_ALT0_MODEL := HomeServer
|
||||
DEVICE_ALT1_VENDOR := AVM
|
||||
DEVICE_ALT1_MODEL := Fritz!box 7330
|
||||
DEVICE_ALT1_MODEL := Fritz!Box 7330
|
||||
SOC := ar9
|
||||
IMAGE_SIZE := 15744k
|
||||
LOADER_FLASH_OFFS := 0x31000
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
ARCH:=mips
|
||||
SUBTARGET:=xrx200
|
||||
BOARDNAME:=XRX200
|
||||
FEATURES+=atm nand ramdisk
|
||||
FEATURES+=atm nand ramdisk source-only
|
||||
CPU_TYPE:=24kc
|
||||
|
||||
DEFAULT_PACKAGES+=kmod-leds-gpio \
|
||||
|
||||
@ -127,7 +127,6 @@ CONFIG_DMA_OF=y
|
||||
CONFIG_DMA_REMAP=y
|
||||
CONFIG_DMA_VIRTUAL_CHANNELS=y
|
||||
CONFIG_DTC=y
|
||||
CONFIG_DYNAMIC_DEBUG=y
|
||||
CONFIG_EDAC_SUPPORT=y
|
||||
CONFIG_EINT_MTK=y
|
||||
CONFIG_EXT4_FS=y
|
||||
@ -187,7 +186,6 @@ CONFIG_I2C_MT65XX=y
|
||||
CONFIG_ICPLUS_PHY=y
|
||||
CONFIG_ILLEGAL_POINTER_VALUE=0xdead000000000000
|
||||
CONFIG_INITRAMFS_SOURCE=""
|
||||
CONFIG_IO_URING=y
|
||||
# CONFIG_IR_MTK is not set
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
|
||||
@ -150,7 +150,6 @@ CONFIG_DMA_OF=y
|
||||
CONFIG_DMA_REMAP=y
|
||||
CONFIG_DMA_VIRTUAL_CHANNELS=y
|
||||
CONFIG_DTC=y
|
||||
CONFIG_DYNAMIC_DEBUG=y
|
||||
CONFIG_EDAC_SUPPORT=y
|
||||
CONFIG_EINT_MTK=y
|
||||
CONFIG_EXT4_FS=y
|
||||
|
||||
@ -281,7 +281,6 @@ CONFIG_IOMMU_IO_PGTABLE_ARMV7S=y
|
||||
# CONFIG_IOMMU_IO_PGTABLE_ARMV7S_SELFTEST is not set
|
||||
# CONFIG_IOMMU_IO_PGTABLE_LPAE is not set
|
||||
CONFIG_IOMMU_SUPPORT=y
|
||||
CONFIG_IO_URING=y
|
||||
# CONFIG_IR_MTK is not set
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
|
||||
@ -142,7 +142,6 @@ CONFIG_HW_RANDOM=y
|
||||
CONFIG_HW_RANDOM_MTK=y
|
||||
CONFIG_HZ_FIXED=0
|
||||
CONFIG_INITRAMFS_SOURCE=""
|
||||
CONFIG_IO_URING=y
|
||||
# CONFIG_IR_MTK is not set
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
|
||||
@ -93,7 +93,6 @@ CONFIG_DMA_OPS_BYPASS=y
|
||||
CONFIG_DPAA_ERRATUM_A050385=y
|
||||
CONFIG_DTC=y
|
||||
CONFIG_DUMMY_CONSOLE=y
|
||||
CONFIG_DYNAMIC_DEBUG=y
|
||||
CONFIG_E500=y
|
||||
# CONFIG_E5500_CPU is not set
|
||||
CONFIG_E6500_CPU=y
|
||||
|
||||
@ -310,7 +310,6 @@ CONFIG_IOMMU_IO_PGTABLE_LPAE=y
|
||||
# CONFIG_IOMMU_IO_PGTABLE_LPAE_SELFTEST is not set
|
||||
CONFIG_IOMMU_SUPPORT=y
|
||||
# CONFIG_IO_STRICT_DEVMEM is not set
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IRQCHIP=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
CONFIG_IRQ_DOMAIN_HIERARCHY=y
|
||||
|
||||
@ -143,7 +143,6 @@ CONFIG_DVB_CORE=y
|
||||
CONFIG_DWMAC_GENERIC=y
|
||||
# CONFIG_DWMAC_SUN8I is not set
|
||||
CONFIG_DWMAC_SUNXI=y
|
||||
CONFIG_DYNAMIC_DEBUG=y
|
||||
CONFIG_EDAC_ATOMIC_SCRUB=y
|
||||
CONFIG_EDAC_SUPPORT=y
|
||||
CONFIG_ELF_CORE=y
|
||||
|
||||
@ -181,7 +181,6 @@ CONFIG_IO_DELAY_0X80=y
|
||||
# CONFIG_IO_DELAY_0XED is not set
|
||||
# CONFIG_IO_DELAY_NONE is not set
|
||||
# CONFIG_IO_DELAY_UDELAY is not set
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
CONFIG_IRQ_DOMAIN_HIERARCHY=y
|
||||
CONFIG_IRQ_FORCED_THREADING=y
|
||||
|
||||
@ -184,7 +184,6 @@ CONFIG_IO_DELAY_0X80=y
|
||||
# CONFIG_IO_DELAY_0XED is not set
|
||||
# CONFIG_IO_DELAY_NONE is not set
|
||||
# CONFIG_IO_DELAY_UDELAY is not set
|
||||
CONFIG_IO_URING=y
|
||||
CONFIG_IRQ_DOMAIN=y
|
||||
CONFIG_IRQ_DOMAIN_HIERARCHY=y
|
||||
CONFIG_IRQ_FORCED_THREADING=y
|
||||
|
||||
@ -45,6 +45,7 @@ tools-y += findutils
|
||||
tools-y += firmware-utils
|
||||
tools-y += flex
|
||||
tools-y += gengetopt
|
||||
tools-y += gnulib
|
||||
tools-y += libressl
|
||||
tools-y += libtool
|
||||
tools-y += lzma
|
||||
@ -105,7 +106,7 @@ $(curdir)/gptfdisk/compile += $(curdir)/e2fsprogs/compile $(curdir)/popt/compile
|
||||
$(curdir)/isl/compile := $(curdir)/gmp/compile
|
||||
$(curdir)/liblzo/compile := $(curdir)/cmake/compile
|
||||
$(curdir)/libressl/compile := $(curdir)/pkgconf/compile
|
||||
$(curdir)/libtool/compile := $(curdir)/automake/compile $(curdir)/missing-macros/compile
|
||||
$(curdir)/libtool/compile := $(curdir)/automake/compile $(curdir)/gnulib/compile $(curdir)/missing-macros/compile
|
||||
$(curdir)/lz4/compile := $(curdir)/meson/compile
|
||||
$(curdir)/lzma-old/compile := $(curdir)/zlib/compile
|
||||
$(curdir)/lzop/compile := $(curdir)/cmake/compile $(curdir)/liblzo/compile
|
||||
@ -128,6 +129,7 @@ $(curdir)/squashfs4/compile := $(curdir)/xz/compile $(curdir)/zlib/compile
|
||||
$(curdir)/zstd/compile := $(curdir)/meson/compile
|
||||
|
||||
ifneq ($(HOST_OS),Linux)
|
||||
$(curdir)/coreutils/compile += $(curdir)/automake/compile $(curdir)/bison/compile $(curdir)/gnulib/compile
|
||||
$(curdir)/squashfs4/compile += $(curdir)/coreutils/compile
|
||||
tools-y += coreutils
|
||||
endif
|
||||
|
||||
29
tools/automake/patches/101-do-not-require-files.patch
Normal file
29
tools/automake/patches/101-do-not-require-files.patch
Normal file
@ -0,0 +1,29 @@
|
||||
--- a/bin/automake.in
|
||||
+++ b/bin/automake.in
|
||||
@@ -4513,7 +4513,7 @@ sub handle_gettext ()
|
||||
&& grep ($_ eq 'intl', @subdirs));
|
||||
}
|
||||
|
||||
- require_file ($ac_gettext_location, GNU, 'ABOUT-NLS');
|
||||
+ require_file ($ac_gettext_location, GNITS, 'ABOUT-NLS');
|
||||
}
|
||||
|
||||
# Emit makefile footer.
|
||||
@@ -5641,7 +5641,7 @@ sub check_gnu_standards ()
|
||||
# otherwise require non-.md.
|
||||
my $required
|
||||
= (! -f $file && -f "$file.md") ? "$file.md" : $file;
|
||||
- require_file ("$am_file.am", GNU, $required);
|
||||
+ require_file ("$am_file.am", GNITS, $required);
|
||||
}
|
||||
|
||||
# Accept one of these three licenses; default to COPYING.
|
||||
@@ -5655,7 +5655,7 @@ sub check_gnu_standards ()
|
||||
last;
|
||||
}
|
||||
}
|
||||
- require_file ("$am_file.am", GNU, 'COPYING')
|
||||
+ require_file ("$am_file.am", GNITS, 'COPYING')
|
||||
unless $license;
|
||||
}
|
||||
|
||||
@ -20,15 +20,42 @@ BUILD_PROGRAMS = date readlink touch ln chown ginstall
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
|
||||
export GNULIB_SRCDIR:=$(HOST_GNULIB_SRCDIR)
|
||||
|
||||
BUILD_BINS = $(patsubst %,src/%,$(BUILD_PROGRAMS))
|
||||
|
||||
HOST_CONFIGURE_ARGS += \
|
||||
--enable-install-program=$(subst $(space),$(comma),$(strip $(BUILD_PROGRAMS)))
|
||||
|
||||
HOST_MAKE_FLAGS += \
|
||||
$(AM_TOOL_PATHS_FAKE) \
|
||||
PROGRAMS="$(BUILD_BINS)" \
|
||||
LIBRARIES= MANS= SUBDIRS=.
|
||||
|
||||
define Host/Bootstrap
|
||||
( \
|
||||
cd $(HOST_BUILD_DIR); \
|
||||
$(AM_TOOL_PATHS_FAKE) \
|
||||
./bootstrap \
|
||||
--bootstrap-sync \
|
||||
--force \
|
||||
--no-git \
|
||||
--skip-po \
|
||||
--gnulib-srcdir=$(GNULIB_SRCDIR) \
|
||||
)
|
||||
endef
|
||||
|
||||
define Host/Prepare
|
||||
$(call Host/Prepare/Default)
|
||||
$(if $(QUILT),,$(call Host/Bootstrap))
|
||||
endef
|
||||
|
||||
define Host/Configure
|
||||
$(if $(QUILT),$(call Host/Bootstrap))
|
||||
-$(CP) $(HOST_BUILD_DIR)/lib/time.in.h~ $(HOST_BUILD_DIR)/lib/time.in.h # @GNULIB_TIME@ not defined
|
||||
$(call Host/Configure/Default)
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
$(INSTALL_DIR) $(1)/bin
|
||||
$(INSTALL_BIN) $(patsubst %,$(HOST_BUILD_DIR)/%,$(BUILD_BINS)) $(1)/bin/
|
||||
|
||||
45
tools/coreutils/patches/000-bootstrap.patch
Normal file
45
tools/coreutils/patches/000-bootstrap.patch
Normal file
@ -0,0 +1,45 @@
|
||||
--- a/bootstrap
|
||||
+++ b/bootstrap
|
||||
@@ -278,7 +278,7 @@ check_exists() {
|
||||
($2 --version </dev/null)
|
||||
fi
|
||||
else
|
||||
- ($1 --version </dev/null) >/dev/null 2>&1
|
||||
+ ($@ --version </dev/null) >/dev/null 2>&1
|
||||
fi
|
||||
|
||||
test $? -lt 126
|
||||
@@ -563,7 +563,7 @@ p
|
||||
q'
|
||||
|
||||
get_version() {
|
||||
- app=$1
|
||||
+ app="$@"
|
||||
|
||||
$app --version >/dev/null 2>&1 || { $app --version; return 1; }
|
||||
|
||||
@@ -620,13 +620,13 @@ check_versions() {
|
||||
if [ "$req_ver" = "-" ]; then
|
||||
# Merely require app to exist; not all prereq apps are well-behaved
|
||||
# so we have to rely on $? rather than get_version.
|
||||
- if ! check_exists --verbose $app; then
|
||||
+ if ! check_exists --verbose "$app"; then
|
||||
warn_ "Error: '$app' not found"
|
||||
ret=1
|
||||
fi
|
||||
else
|
||||
# Require app to produce a new enough version string.
|
||||
- inst_ver=$(get_version $app)
|
||||
+ inst_ver=$(get_version "$app")
|
||||
if [ ! "$inst_ver" ]; then
|
||||
warn_ "Error: '$app' not found"
|
||||
ret=1
|
||||
@@ -923,7 +923,7 @@ version_controlled_file() {
|
||||
# two just-pre-run programs.
|
||||
|
||||
# Import from gettext.
|
||||
-with_gettext=yes
|
||||
+with_gettext=no
|
||||
grep '^[ ]*AM_GNU_GETTEXT_VERSION(' configure.ac >/dev/null || \
|
||||
with_gettext=no
|
||||
|
||||
@ -21,13 +21,17 @@ include $(INCLUDE_DIR)/host-build.mk
|
||||
|
||||
HOST_CONFIGURE_ARGS += --disable-shared
|
||||
|
||||
define Host/Compile
|
||||
$(call Host/Compile/Default,SUBDIRS='src tools')
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
$(call Host/Install/Default)
|
||||
$(call Host/Compile/Default,install SUBDIRS='src tools')
|
||||
$(LN) flex $(STAGING_DIR_HOST)/bin/lex
|
||||
endef
|
||||
|
||||
define Host/Uninstall
|
||||
-$(call Host/Compile/Default,uninstall)
|
||||
-$(call Host/Compile/Default,uninstall SUBDIRS='src tools')
|
||||
endef
|
||||
|
||||
define Host/Clean
|
||||
|
||||
@ -1,13 +0,0 @@
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -43,10 +43,7 @@ EXTRA_DIST = \
|
||||
|
||||
SUBDIRS = \
|
||||
src \
|
||||
- doc \
|
||||
- examples \
|
||||
po \
|
||||
- tests \
|
||||
tools
|
||||
|
||||
# Create the ChangeLog, but only if we're inside a git working directory
|
||||
@ -13,12 +13,16 @@ PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
||||
PKG_SOURCE_URL:=@GNU/$(PKG_NAME)
|
||||
PKG_HASH:=b941aec9011864978dd7fdeb052b1943535824169d2aa2b0e7eae9ab807584ac
|
||||
|
||||
HOST_FIXUP:=autoreconf
|
||||
PKG_SUBDIRS:=$$$$(foreach dir,gl src skels,$$$$(wildcard $$$$(dir)) )
|
||||
|
||||
HOST_BUILD_PARALLEL:=1
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
|
||||
define Host/Compile
|
||||
$(call Host/Compile/Default,SUBDIRS='$(PKG_SUBDIRS)')
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
$(INSTALL_BIN) $(HOST_BUILD_DIR)/src/gengetopt $(STAGING_DIR_HOST)/bin/
|
||||
endef
|
||||
|
||||
@ -1,33 +0,0 @@
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -18,7 +18,7 @@
|
||||
ACLOCAL_AMFLAGS = -I m4 -I gl/m4
|
||||
|
||||
EXTRA_DIST = configure TODO LICENSE gl/m4/gnulib-cache.m4
|
||||
-SUBDIRS = gl src doc tests
|
||||
+SUBDIRS = gl src
|
||||
|
||||
gengetoptdoc_DATA = ChangeLog COPYING NEWS THANKS INSTALL README LICENSE
|
||||
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -593,7 +593,7 @@ top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
ACLOCAL_AMFLAGS = -I m4 -I gl/m4
|
||||
EXTRA_DIST = configure TODO LICENSE gl/m4/gnulib-cache.m4
|
||||
-SUBDIRS = gl src doc tests
|
||||
+SUBDIRS = gl src
|
||||
gengetoptdoc_DATA = ChangeLog COPYING NEWS THANKS INSTALL README LICENSE
|
||||
TARBALL = $(top_builddir)/gengetopt-$(PACKAGE_VERSION).tar.xz
|
||||
all: config.h
|
||||
--- a/src/Makefile.am
|
||||
+++ b/src/Makefile.am
|
||||
@@ -16,7 +16,7 @@
|
||||
# with gengetopt; see the file COPYING. If not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
|
||||
-SUBDIRS = skels tests
|
||||
+SUBDIRS = skels
|
||||
|
||||
bin_PROGRAMS = gengetopt
|
||||
|
||||
27
tools/gnulib/Makefile
Normal file
27
tools/gnulib/Makefile
Normal file
@ -0,0 +1,27 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=gnulib
|
||||
PKG_CPE_ID:=cpe:/a:gnu:$(PKG_NAME)
|
||||
PKG_VERSION:=f9a4ee73c3e7b544f640d0d04b55983d3a7b894e# # master
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://git.savannah.gnu.org/cgit/$(PKG_NAME).git/snapshot
|
||||
PKG_HASH:=514716d58987a9c0de0d69fb22d42bcd19edf80eed099882a004ff162060f1a8
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
|
||||
define Host/Configure
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
$(INSTALL_DIR) $(1)/share/aclocal
|
||||
$(INSTALL_DATA) $(HOST_BUILD_DIR)/m4/*.m4 $(1)/share/aclocal/
|
||||
$(INSTALL_DIR) $(1)/share/gnulib
|
||||
$(CP) $(HOST_BUILD_DIR)/* $(1)/share/gnulib/
|
||||
endef
|
||||
|
||||
define Host/Clean
|
||||
rm -rf $(STAGING_DIR_HOST)/share/gnulib
|
||||
endef
|
||||
|
||||
$(eval $(call HostBuild))
|
||||
54
tools/gnulib/patches/000-bootstrap.patch
Normal file
54
tools/gnulib/patches/000-bootstrap.patch
Normal file
@ -0,0 +1,54 @@
|
||||
--- a/build-aux/bootstrap
|
||||
+++ b/build-aux/bootstrap
|
||||
@@ -237,14 +237,14 @@ test -r "$conffile" && . "$conffile"
|
||||
|
||||
check_exists() {
|
||||
if test "$1" = "--verbose"; then
|
||||
- ($2 --version </dev/null) >/dev/null 2>&1
|
||||
+ ($2 $3 $4 --version </dev/null) >/dev/null 2>&1
|
||||
if test $? -ge 126; then
|
||||
# If not found, run with diagnostics as one may be
|
||||
# presented with env variables to set to find the right version
|
||||
- ($2 --version </dev/null)
|
||||
+ ($2 $3 $4 --version </dev/null)
|
||||
fi
|
||||
else
|
||||
- ($1 --version </dev/null) >/dev/null 2>&1
|
||||
+ ($@ --version </dev/null) >/dev/null 2>&1
|
||||
fi
|
||||
|
||||
test $? -lt 126
|
||||
@@ -309,7 +309,7 @@ p
|
||||
q'
|
||||
|
||||
get_version() {
|
||||
- app=$1
|
||||
+ app="$@"
|
||||
|
||||
$app --version >/dev/null 2>&1 || { $app --version; return 1; }
|
||||
|
||||
@@ -366,13 +366,13 @@ check_versions() {
|
||||
if [ "$req_ver" = "-" ]; then
|
||||
# Merely require app to exist; not all prereq apps are well-behaved
|
||||
# so we have to rely on $? rather than get_version.
|
||||
- if ! check_exists --verbose $app; then
|
||||
+ if ! check_exists --verbose "$app"; then
|
||||
warn_ "Error: '$app' not found"
|
||||
ret=1
|
||||
fi
|
||||
else
|
||||
# Require app to produce a new enough version string.
|
||||
- inst_ver=$(get_version $app)
|
||||
+ inst_ver=$(get_version "$app")
|
||||
if [ ! "$inst_ver" ]; then
|
||||
warn_ "Error: '$app' not found"
|
||||
ret=1
|
||||
@@ -1135,7 +1135,7 @@ autogen()
|
||||
# two just-pre-run programs.
|
||||
|
||||
# Import from gettext.
|
||||
- with_gettext=yes
|
||||
+ with_gettext=no
|
||||
grep '^[ ]*AM_GNU_GETTEXT_VERSION(' configure.ac >/dev/null || \
|
||||
with_gettext=no
|
||||
|
||||
@ -18,17 +18,31 @@ HOST_BUILD_PARALLEL:=1
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
|
||||
export GNULIB_SRCDIR:=$(HOST_GNULIB_SRCDIR)
|
||||
|
||||
HOST_CONFIGURE_VARS += \
|
||||
lt_cv_sys_dlsearch_path=""
|
||||
|
||||
define Host/Bootstrap
|
||||
( \
|
||||
cd $(HOST_BUILD_DIR); \
|
||||
$(AM_TOOL_PATHS) \
|
||||
./bootstrap \
|
||||
--force \
|
||||
--skip-git \
|
||||
--skip-po \
|
||||
--gnulib-srcdir=$(GNULIB_SRCDIR) \
|
||||
)
|
||||
endef
|
||||
|
||||
define Host/Prepare
|
||||
$(call Host/Prepare/Default)
|
||||
$(call Host/Uninstall)
|
||||
$(if $(QUILT),,(cd $(HOST_BUILD_DIR); touch README-release; $(AM_TOOL_PATHS) ./bootstrap --skip-git --skip-po --force))
|
||||
$(if $(QUILT),,$(call Host/Bootstrap))
|
||||
endef
|
||||
|
||||
define Host/Configure
|
||||
$(if $(QUILT),(cd $(HOST_BUILD_DIR); touch README-release; $(AM_TOOL_PATHS) ./bootstrap --skip-git --skip-po --force))
|
||||
$(if $(QUILT),$(call Host/Bootstrap))
|
||||
$(call Host/Configure/Default)
|
||||
endef
|
||||
|
||||
|
||||
@ -2,26 +2,13 @@ The m4/ directory below contains various m4 macros used
|
||||
by different packages in the OpenWrt feed.
|
||||
|
||||
|
||||
From GNU gettext:
|
||||
Library linking and rpath helper macros.
|
||||
|
||||
lib-ld.m4
|
||||
lib-link.m4
|
||||
lib-prefix.m4
|
||||
|
||||
Integer data type test macros.
|
||||
|
||||
intmax.m4
|
||||
wint_t.m4
|
||||
inttypes-pri.m4
|
||||
uintmax_t.m4
|
||||
stdint_h.m4
|
||||
intdiv0.m4
|
||||
inttypes_h.m4
|
||||
|
||||
Program test macro.
|
||||
|
||||
progtest.m4
|
||||
|
||||
GNU libc version test macros.
|
||||
|
||||
|
||||
@ -26,7 +26,7 @@ Getopt::Long::GetOptions(
|
||||
|
||||
if ($version)
|
||||
{
|
||||
print "makeinfo (OpenWrt stub) 4.13\n";
|
||||
print "makeinfo (OpenWrt stub) 9.99\n";
|
||||
exit 0;
|
||||
}
|
||||
|
||||
|
||||
@ -1,26 +0,0 @@
|
||||
# inttypes_h.m4 serial 9
|
||||
dnl Copyright (C) 1997-2004, 2006, 2008-2010 Free Software Foundation, Inc.
|
||||
dnl This file is free software; the Free Software Foundation
|
||||
dnl gives unlimited permission to copy and/or distribute it,
|
||||
dnl with or without modifications, as long as this notice is preserved.
|
||||
|
||||
dnl From Paul Eggert.
|
||||
|
||||
# Define HAVE_INTTYPES_H_WITH_UINTMAX if <inttypes.h> exists,
|
||||
# doesn't clash with <sys/types.h>, and declares uintmax_t.
|
||||
|
||||
AC_DEFUN([gl_AC_HEADER_INTTYPES_H],
|
||||
[
|
||||
AC_CACHE_CHECK([for inttypes.h], [gl_cv_header_inttypes_h],
|
||||
[AC_TRY_COMPILE(
|
||||
[#include <sys/types.h>
|
||||
#include <inttypes.h>],
|
||||
[uintmax_t i = (uintmax_t) -1; return !i;],
|
||||
[gl_cv_header_inttypes_h=yes],
|
||||
[gl_cv_header_inttypes_h=no])])
|
||||
if test $gl_cv_header_inttypes_h = yes; then
|
||||
AC_DEFINE_UNQUOTED([HAVE_INTTYPES_H_WITH_UINTMAX], [1],
|
||||
[Define if <inttypes.h> exists, doesn't clash with <sys/types.h>,
|
||||
and declares uintmax_t. ])
|
||||
fi
|
||||
])
|
||||
@ -1,110 +0,0 @@
|
||||
# lib-ld.m4 serial 4 (gettext-0.18)
|
||||
dnl Copyright (C) 1996-2003, 2009-2010 Free Software Foundation, Inc.
|
||||
dnl This file is free software; the Free Software Foundation
|
||||
dnl gives unlimited permission to copy and/or distribute it,
|
||||
dnl with or without modifications, as long as this notice is preserved.
|
||||
|
||||
dnl Subroutines of libtool.m4,
|
||||
dnl with replacements s/AC_/AC_LIB/ and s/lt_cv/acl_cv/ to avoid collision
|
||||
dnl with libtool.m4.
|
||||
|
||||
dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no.
|
||||
AC_DEFUN([AC_LIB_PROG_LD_GNU],
|
||||
[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], [acl_cv_prog_gnu_ld],
|
||||
[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
|
||||
case `$LD -v 2>&1 </dev/null` in
|
||||
*GNU* | *'with BFD'*)
|
||||
acl_cv_prog_gnu_ld=yes ;;
|
||||
*)
|
||||
acl_cv_prog_gnu_ld=no ;;
|
||||
esac])
|
||||
with_gnu_ld=$acl_cv_prog_gnu_ld
|
||||
])
|
||||
|
||||
dnl From libtool-1.4. Sets the variable LD.
|
||||
AC_DEFUN([AC_LIB_PROG_LD],
|
||||
[AC_ARG_WITH([gnu-ld],
|
||||
[ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
|
||||
test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
|
||||
AC_REQUIRE([AC_PROG_CC])dnl
|
||||
AC_REQUIRE([AC_CANONICAL_HOST])dnl
|
||||
# Prepare PATH_SEPARATOR.
|
||||
# The user is always right.
|
||||
if test "${PATH_SEPARATOR+set}" != set; then
|
||||
echo "#! /bin/sh" >conf$$.sh
|
||||
echo "exit 0" >>conf$$.sh
|
||||
chmod +x conf$$.sh
|
||||
if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
|
||||
PATH_SEPARATOR=';'
|
||||
else
|
||||
PATH_SEPARATOR=:
|
||||
fi
|
||||
rm -f conf$$.sh
|
||||
fi
|
||||
ac_prog=ld
|
||||
if test "$GCC" = yes; then
|
||||
# Check if gcc -print-prog-name=ld gives a path.
|
||||
AC_MSG_CHECKING([for ld used by GCC])
|
||||
case $host in
|
||||
*-*-mingw*)
|
||||
# gcc leaves a trailing carriage return which upsets mingw
|
||||
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
|
||||
*)
|
||||
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
|
||||
esac
|
||||
case $ac_prog in
|
||||
# Accept absolute paths.
|
||||
[[\\/]* | [A-Za-z]:[\\/]*)]
|
||||
[re_direlt='/[^/][^/]*/\.\./']
|
||||
# Canonicalize the path of ld
|
||||
ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
|
||||
while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
|
||||
ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
|
||||
done
|
||||
test -z "$LD" && LD="$ac_prog"
|
||||
;;
|
||||
"")
|
||||
# If it fails, then pretend we aren't using GCC.
|
||||
ac_prog=ld
|
||||
;;
|
||||
*)
|
||||
# If it is relative, then search for the first ld in PATH.
|
||||
with_gnu_ld=unknown
|
||||
;;
|
||||
esac
|
||||
elif test "$with_gnu_ld" = yes; then
|
||||
AC_MSG_CHECKING([for GNU ld])
|
||||
else
|
||||
AC_MSG_CHECKING([for non-GNU ld])
|
||||
fi
|
||||
AC_CACHE_VAL([acl_cv_path_LD],
|
||||
[if test -z "$LD"; then
|
||||
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
|
||||
for ac_dir in $PATH; do
|
||||
test -z "$ac_dir" && ac_dir=.
|
||||
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
|
||||
acl_cv_path_LD="$ac_dir/$ac_prog"
|
||||
# Check to see if the program is GNU ld. I'd rather use --version,
|
||||
# but apparently some GNU ld's only accept -v.
|
||||
# Break only if it was the GNU/non-GNU ld that we prefer.
|
||||
case `"$acl_cv_path_LD" -v 2>&1 < /dev/null` in
|
||||
*GNU* | *'with BFD'*)
|
||||
test "$with_gnu_ld" != no && break ;;
|
||||
*)
|
||||
test "$with_gnu_ld" != yes && break ;;
|
||||
esac
|
||||
fi
|
||||
done
|
||||
IFS="$ac_save_ifs"
|
||||
else
|
||||
acl_cv_path_LD="$LD" # Let the user override the test with a path.
|
||||
fi])
|
||||
LD="$acl_cv_path_LD"
|
||||
if test -n "$LD"; then
|
||||
AC_MSG_RESULT([$LD])
|
||||
else
|
||||
AC_MSG_RESULT([no])
|
||||
fi
|
||||
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
|
||||
AC_LIB_PROG_LD_GNU
|
||||
])
|
||||
@ -1,774 +0,0 @@
|
||||
# lib-link.m4 serial 21 (gettext-0.18)
|
||||
dnl Copyright (C) 2001-2010 Free Software Foundation, Inc.
|
||||
dnl This file is free software; the Free Software Foundation
|
||||
dnl gives unlimited permission to copy and/or distribute it,
|
||||
dnl with or without modifications, as long as this notice is preserved.
|
||||
|
||||
dnl From Bruno Haible.
|
||||
|
||||
AC_PREREQ([2.54])
|
||||
|
||||
dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and
|
||||
dnl the libraries corresponding to explicit and implicit dependencies.
|
||||
dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and
|
||||
dnl augments the CPPFLAGS variable.
|
||||
dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
|
||||
dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
|
||||
AC_DEFUN([AC_LIB_LINKFLAGS],
|
||||
[
|
||||
AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
|
||||
AC_REQUIRE([AC_LIB_RPATH])
|
||||
pushdef([Name],[translit([$1],[./-], [___])])
|
||||
pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
|
||||
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
|
||||
AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [
|
||||
AC_LIB_LINKFLAGS_BODY([$1], [$2])
|
||||
ac_cv_lib[]Name[]_libs="$LIB[]NAME"
|
||||
ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME"
|
||||
ac_cv_lib[]Name[]_cppflags="$INC[]NAME"
|
||||
ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX"
|
||||
])
|
||||
LIB[]NAME="$ac_cv_lib[]Name[]_libs"
|
||||
LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs"
|
||||
INC[]NAME="$ac_cv_lib[]Name[]_cppflags"
|
||||
LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix"
|
||||
AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
|
||||
AC_SUBST([LIB]NAME)
|
||||
AC_SUBST([LTLIB]NAME)
|
||||
AC_SUBST([LIB]NAME[_PREFIX])
|
||||
dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the
|
||||
dnl results of this search when this library appears as a dependency.
|
||||
HAVE_LIB[]NAME=yes
|
||||
popdef([NAME])
|
||||
popdef([Name])
|
||||
])
|
||||
|
||||
dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode, [missing-message])
|
||||
dnl searches for libname and the libraries corresponding to explicit and
|
||||
dnl implicit dependencies, together with the specified include files and
|
||||
dnl the ability to compile and link the specified testcode. The missing-message
|
||||
dnl defaults to 'no' and may contain additional hints for the user.
|
||||
dnl If found, it sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME}
|
||||
dnl and LTLIB${NAME} variables and augments the CPPFLAGS variable, and
|
||||
dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs
|
||||
dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.
|
||||
dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
|
||||
dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
|
||||
AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
|
||||
[
|
||||
AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
|
||||
AC_REQUIRE([AC_LIB_RPATH])
|
||||
pushdef([Name],[translit([$1],[./-], [___])])
|
||||
pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
|
||||
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
|
||||
|
||||
dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME
|
||||
dnl accordingly.
|
||||
AC_LIB_LINKFLAGS_BODY([$1], [$2])
|
||||
|
||||
dnl Add $INC[]NAME to CPPFLAGS before performing the following checks,
|
||||
dnl because if the user has installed lib[]Name and not disabled its use
|
||||
dnl via --without-lib[]Name-prefix, he wants to use it.
|
||||
ac_save_CPPFLAGS="$CPPFLAGS"
|
||||
AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
|
||||
|
||||
AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [
|
||||
ac_save_LIBS="$LIBS"
|
||||
dnl If $LIB[]NAME contains some -l options, add it to the end of LIBS,
|
||||
dnl because these -l options might require -L options that are present in
|
||||
dnl LIBS. -l options benefit only from the -L options listed before it.
|
||||
dnl Otherwise, add it to the front of LIBS, because it may be a static
|
||||
dnl library that depends on another static library that is present in LIBS.
|
||||
dnl Static libraries benefit only from the static libraries listed after
|
||||
dnl it.
|
||||
case " $LIB[]NAME" in
|
||||
*" -l"*) LIBS="$LIBS $LIB[]NAME" ;;
|
||||
*) LIBS="$LIB[]NAME $LIBS" ;;
|
||||
esac
|
||||
AC_TRY_LINK([$3], [$4],
|
||||
[ac_cv_lib[]Name=yes],
|
||||
[ac_cv_lib[]Name='m4_if([$5], [], [no], [[$5]])'])
|
||||
LIBS="$ac_save_LIBS"
|
||||
])
|
||||
if test "$ac_cv_lib[]Name" = yes; then
|
||||
HAVE_LIB[]NAME=yes
|
||||
AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the lib][$1 library.])
|
||||
AC_MSG_CHECKING([how to link with lib[]$1])
|
||||
AC_MSG_RESULT([$LIB[]NAME])
|
||||
else
|
||||
HAVE_LIB[]NAME=no
|
||||
dnl If $LIB[]NAME didn't lead to a usable library, we don't need
|
||||
dnl $INC[]NAME either.
|
||||
CPPFLAGS="$ac_save_CPPFLAGS"
|
||||
LIB[]NAME=
|
||||
LTLIB[]NAME=
|
||||
LIB[]NAME[]_PREFIX=
|
||||
fi
|
||||
AC_SUBST([HAVE_LIB]NAME)
|
||||
AC_SUBST([LIB]NAME)
|
||||
AC_SUBST([LTLIB]NAME)
|
||||
AC_SUBST([LIB]NAME[_PREFIX])
|
||||
popdef([NAME])
|
||||
popdef([Name])
|
||||
])
|
||||
|
||||
dnl Determine the platform dependent parameters needed to use rpath:
|
||||
dnl acl_libext,
|
||||
dnl acl_shlibext,
|
||||
dnl acl_hardcode_libdir_flag_spec,
|
||||
dnl acl_hardcode_libdir_separator,
|
||||
dnl acl_hardcode_direct,
|
||||
dnl acl_hardcode_minus_L.
|
||||
AC_DEFUN([AC_LIB_RPATH],
|
||||
[
|
||||
dnl Tell automake >= 1.10 to complain if config.rpath is missing.
|
||||
m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([config.rpath])])
|
||||
AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS
|
||||
AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld
|
||||
AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host
|
||||
AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir
|
||||
AC_CACHE_CHECK([for shared library run path origin], [acl_cv_rpath], [
|
||||
CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
|
||||
${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
|
||||
. ./conftest.sh
|
||||
rm -f ./conftest.sh
|
||||
acl_cv_rpath=done
|
||||
])
|
||||
wl="$acl_cv_wl"
|
||||
acl_libext="$acl_cv_libext"
|
||||
acl_shlibext="$acl_cv_shlibext"
|
||||
acl_libname_spec="$acl_cv_libname_spec"
|
||||
acl_library_names_spec="$acl_cv_library_names_spec"
|
||||
acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
|
||||
acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
|
||||
acl_hardcode_direct="$acl_cv_hardcode_direct"
|
||||
acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
|
||||
dnl Determine whether the user wants rpath handling at all.
|
||||
AC_ARG_ENABLE([rpath],
|
||||
[ --disable-rpath do not hardcode runtime library paths],
|
||||
:, enable_rpath=yes)
|
||||
])
|
||||
|
||||
dnl AC_LIB_FROMPACKAGE(name, package)
|
||||
dnl declares that libname comes from the given package. The configure file
|
||||
dnl will then not have a --with-libname-prefix option but a
|
||||
dnl --with-package-prefix option. Several libraries can come from the same
|
||||
dnl package. This declaration must occur before an AC_LIB_LINKFLAGS or similar
|
||||
dnl macro call that searches for libname.
|
||||
AC_DEFUN([AC_LIB_FROMPACKAGE],
|
||||
[
|
||||
pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
|
||||
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
|
||||
define([acl_frompackage_]NAME, [$2])
|
||||
popdef([NAME])
|
||||
pushdef([PACK],[$2])
|
||||
pushdef([PACKUP],[translit(PACK,[abcdefghijklmnopqrstuvwxyz./-],
|
||||
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
|
||||
define([acl_libsinpackage_]PACKUP,
|
||||
m4_ifdef([acl_libsinpackage_]PACKUP, [acl_libsinpackage_]PACKUP[[, ]],)[lib$1])
|
||||
popdef([PACKUP])
|
||||
popdef([PACK])
|
||||
])
|
||||
|
||||
dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and
|
||||
dnl the libraries corresponding to explicit and implicit dependencies.
|
||||
dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
|
||||
dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found
|
||||
dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
|
||||
AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
|
||||
[
|
||||
AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
|
||||
pushdef([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
|
||||
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
|
||||
pushdef([PACK],[m4_ifdef([acl_frompackage_]NAME, [acl_frompackage_]NAME, lib[$1])])
|
||||
pushdef([PACKUP],[translit(PACK,[abcdefghijklmnopqrstuvwxyz./-],
|
||||
[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
|
||||
pushdef([PACKLIBS],[m4_ifdef([acl_frompackage_]NAME, [acl_libsinpackage_]PACKUP, lib[$1])])
|
||||
dnl Autoconf >= 2.61 supports dots in --with options.
|
||||
pushdef([P_A_C_K],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit(PACK,[.],[_])],PACK)])
|
||||
dnl By default, look in $includedir and $libdir.
|
||||
use_additional=yes
|
||||
AC_LIB_WITH_FINAL_PREFIX([
|
||||
eval additional_includedir=\"$includedir\"
|
||||
eval additional_libdir=\"$libdir\"
|
||||
])
|
||||
AC_ARG_WITH(P_A_C_K[-prefix],
|
||||
[[ --with-]]P_A_C_K[[-prefix[=DIR] search for ]PACKLIBS[ in DIR/include and DIR/lib
|
||||
--without-]]P_A_C_K[[-prefix don't search for ]PACKLIBS[ in includedir and libdir]],
|
||||
[
|
||||
if test "X$withval" = "Xno"; then
|
||||
use_additional=no
|
||||
else
|
||||
if test "X$withval" = "X"; then
|
||||
AC_LIB_WITH_FINAL_PREFIX([
|
||||
eval additional_includedir=\"$includedir\"
|
||||
eval additional_libdir=\"$libdir\"
|
||||
])
|
||||
else
|
||||
additional_includedir="$withval/include"
|
||||
additional_libdir="$withval/$acl_libdirstem"
|
||||
if test "$acl_libdirstem2" != "$acl_libdirstem" \
|
||||
&& ! test -d "$withval/$acl_libdirstem"; then
|
||||
additional_libdir="$withval/$acl_libdirstem2"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
])
|
||||
dnl Search the library and its dependencies in $additional_libdir and
|
||||
dnl $LDFLAGS. Using breadth-first-seach.
|
||||
LIB[]NAME=
|
||||
LTLIB[]NAME=
|
||||
INC[]NAME=
|
||||
LIB[]NAME[]_PREFIX=
|
||||
dnl HAVE_LIB${NAME} is an indicator that LIB${NAME}, LTLIB${NAME} have been
|
||||
dnl computed. So it has to be reset here.
|
||||
HAVE_LIB[]NAME=
|
||||
rpathdirs=
|
||||
ltrpathdirs=
|
||||
names_already_handled=
|
||||
names_next_round='$1 $2'
|
||||
while test -n "$names_next_round"; do
|
||||
names_this_round="$names_next_round"
|
||||
names_next_round=
|
||||
for name in $names_this_round; do
|
||||
already_handled=
|
||||
for n in $names_already_handled; do
|
||||
if test "$n" = "$name"; then
|
||||
already_handled=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$already_handled"; then
|
||||
names_already_handled="$names_already_handled $name"
|
||||
dnl See if it was already located by an earlier AC_LIB_LINKFLAGS
|
||||
dnl or AC_LIB_HAVE_LINKFLAGS call.
|
||||
uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
|
||||
eval value=\"\$HAVE_LIB$uppername\"
|
||||
if test -n "$value"; then
|
||||
if test "$value" = yes; then
|
||||
eval value=\"\$LIB$uppername\"
|
||||
test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value"
|
||||
eval value=\"\$LTLIB$uppername\"
|
||||
test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value"
|
||||
else
|
||||
dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined
|
||||
dnl that this library doesn't exist. So just drop it.
|
||||
:
|
||||
fi
|
||||
else
|
||||
dnl Search the library lib$name in $additional_libdir and $LDFLAGS
|
||||
dnl and the already constructed $LIBNAME/$LTLIBNAME.
|
||||
found_dir=
|
||||
found_la=
|
||||
found_so=
|
||||
found_a=
|
||||
eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
|
||||
if test -n "$acl_shlibext"; then
|
||||
shrext=".$acl_shlibext" # typically: shrext=.so
|
||||
else
|
||||
shrext=
|
||||
fi
|
||||
if test $use_additional = yes; then
|
||||
dir="$additional_libdir"
|
||||
dnl The same code as in the loop below:
|
||||
dnl First look for a shared library.
|
||||
if test -n "$acl_shlibext"; then
|
||||
if test -f "$dir/$libname$shrext"; then
|
||||
found_dir="$dir"
|
||||
found_so="$dir/$libname$shrext"
|
||||
else
|
||||
if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
|
||||
ver=`(cd "$dir" && \
|
||||
for f in "$libname$shrext".*; do echo "$f"; done \
|
||||
| sed -e "s,^$libname$shrext\\\\.,," \
|
||||
| sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
|
||||
| sed 1q ) 2>/dev/null`
|
||||
if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
|
||||
found_dir="$dir"
|
||||
found_so="$dir/$libname$shrext.$ver"
|
||||
fi
|
||||
else
|
||||
eval library_names=\"$acl_library_names_spec\"
|
||||
for f in $library_names; do
|
||||
if test -f "$dir/$f"; then
|
||||
found_dir="$dir"
|
||||
found_so="$dir/$f"
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
dnl Then look for a static library.
|
||||
if test "X$found_dir" = "X"; then
|
||||
if test -f "$dir/$libname.$acl_libext"; then
|
||||
found_dir="$dir"
|
||||
found_a="$dir/$libname.$acl_libext"
|
||||
fi
|
||||
fi
|
||||
if test "X$found_dir" != "X"; then
|
||||
if test -f "$dir/$libname.la"; then
|
||||
found_la="$dir/$libname.la"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
if test "X$found_dir" = "X"; then
|
||||
for x in $LDFLAGS $LTLIB[]NAME; do
|
||||
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
|
||||
case "$x" in
|
||||
-L*)
|
||||
dir=`echo "X$x" | sed -e 's/^X-L//'`
|
||||
dnl First look for a shared library.
|
||||
if test -n "$acl_shlibext"; then
|
||||
if test -f "$dir/$libname$shrext"; then
|
||||
found_dir="$dir"
|
||||
found_so="$dir/$libname$shrext"
|
||||
else
|
||||
if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
|
||||
ver=`(cd "$dir" && \
|
||||
for f in "$libname$shrext".*; do echo "$f"; done \
|
||||
| sed -e "s,^$libname$shrext\\\\.,," \
|
||||
| sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
|
||||
| sed 1q ) 2>/dev/null`
|
||||
if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
|
||||
found_dir="$dir"
|
||||
found_so="$dir/$libname$shrext.$ver"
|
||||
fi
|
||||
else
|
||||
eval library_names=\"$acl_library_names_spec\"
|
||||
for f in $library_names; do
|
||||
if test -f "$dir/$f"; then
|
||||
found_dir="$dir"
|
||||
found_so="$dir/$f"
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
dnl Then look for a static library.
|
||||
if test "X$found_dir" = "X"; then
|
||||
if test -f "$dir/$libname.$acl_libext"; then
|
||||
found_dir="$dir"
|
||||
found_a="$dir/$libname.$acl_libext"
|
||||
fi
|
||||
fi
|
||||
if test "X$found_dir" != "X"; then
|
||||
if test -f "$dir/$libname.la"; then
|
||||
found_la="$dir/$libname.la"
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
if test "X$found_dir" != "X"; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
if test "X$found_dir" != "X"; then
|
||||
dnl Found the library.
|
||||
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name"
|
||||
if test "X$found_so" != "X"; then
|
||||
dnl Linking with a shared library. We attempt to hardcode its
|
||||
dnl directory into the executable's runpath, unless it's the
|
||||
dnl standard /usr/lib.
|
||||
if test "$enable_rpath" = no \
|
||||
|| test "X$found_dir" = "X/usr/$acl_libdirstem" \
|
||||
|| test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
|
||||
dnl No hardcoding is needed.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
|
||||
else
|
||||
dnl Use an explicit option to hardcode DIR into the resulting
|
||||
dnl binary.
|
||||
dnl Potentially add DIR to ltrpathdirs.
|
||||
dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
|
||||
haveit=
|
||||
for x in $ltrpathdirs; do
|
||||
if test "X$x" = "X$found_dir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
ltrpathdirs="$ltrpathdirs $found_dir"
|
||||
fi
|
||||
dnl The hardcoding into $LIBNAME is system dependent.
|
||||
if test "$acl_hardcode_direct" = yes; then
|
||||
dnl Using DIR/libNAME.so during linking hardcodes DIR into the
|
||||
dnl resulting binary.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
|
||||
else
|
||||
if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
|
||||
dnl Use an explicit option to hardcode DIR into the resulting
|
||||
dnl binary.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
|
||||
dnl Potentially add DIR to rpathdirs.
|
||||
dnl The rpathdirs will be appended to $LIBNAME at the end.
|
||||
haveit=
|
||||
for x in $rpathdirs; do
|
||||
if test "X$x" = "X$found_dir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
rpathdirs="$rpathdirs $found_dir"
|
||||
fi
|
||||
else
|
||||
dnl Rely on "-L$found_dir".
|
||||
dnl But don't add it if it's already contained in the LDFLAGS
|
||||
dnl or the already constructed $LIBNAME
|
||||
haveit=
|
||||
for x in $LDFLAGS $LIB[]NAME; do
|
||||
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
|
||||
if test "X$x" = "X-L$found_dir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir"
|
||||
fi
|
||||
if test "$acl_hardcode_minus_L" != no; then
|
||||
dnl FIXME: Not sure whether we should use
|
||||
dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
|
||||
dnl here.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
|
||||
else
|
||||
dnl We cannot use $acl_hardcode_runpath_var and LD_RUN_PATH
|
||||
dnl here, because this doesn't fit in flags passed to the
|
||||
dnl compiler. So give up. No hardcoding. This affects only
|
||||
dnl very old systems.
|
||||
dnl FIXME: Not sure whether we should use
|
||||
dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
|
||||
dnl here.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
else
|
||||
if test "X$found_a" != "X"; then
|
||||
dnl Linking with a static library.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a"
|
||||
else
|
||||
dnl We shouldn't come here, but anyway it's good to have a
|
||||
dnl fallback.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name"
|
||||
fi
|
||||
fi
|
||||
dnl Assume the include files are nearby.
|
||||
additional_includedir=
|
||||
case "$found_dir" in
|
||||
*/$acl_libdirstem | */$acl_libdirstem/)
|
||||
basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
|
||||
if test "$name" = '$1'; then
|
||||
LIB[]NAME[]_PREFIX="$basedir"
|
||||
fi
|
||||
additional_includedir="$basedir/include"
|
||||
;;
|
||||
*/$acl_libdirstem2 | */$acl_libdirstem2/)
|
||||
basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
|
||||
if test "$name" = '$1'; then
|
||||
LIB[]NAME[]_PREFIX="$basedir"
|
||||
fi
|
||||
additional_includedir="$basedir/include"
|
||||
;;
|
||||
esac
|
||||
if test "X$additional_includedir" != "X"; then
|
||||
dnl Potentially add $additional_includedir to $INCNAME.
|
||||
dnl But don't add it
|
||||
dnl 1. if it's the standard /usr/include,
|
||||
dnl 2. if it's /usr/local/include and we are using GCC on Linux,
|
||||
dnl 3. if it's already present in $CPPFLAGS or the already
|
||||
dnl constructed $INCNAME,
|
||||
dnl 4. if it doesn't exist as a directory.
|
||||
if test "X$additional_includedir" != "X/usr/include"; then
|
||||
haveit=
|
||||
if test "X$additional_includedir" = "X/usr/local/include"; then
|
||||
if test -n "$GCC"; then
|
||||
case $host_os in
|
||||
linux* | gnu* | k*bsd*-gnu) haveit=yes;;
|
||||
esac
|
||||
fi
|
||||
fi
|
||||
if test -z "$haveit"; then
|
||||
for x in $CPPFLAGS $INC[]NAME; do
|
||||
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
|
||||
if test "X$x" = "X-I$additional_includedir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
if test -d "$additional_includedir"; then
|
||||
dnl Really add $additional_includedir to $INCNAME.
|
||||
INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
dnl Look for dependencies.
|
||||
if test -n "$found_la"; then
|
||||
dnl Read the .la file. It defines the variables
|
||||
dnl dlname, library_names, old_library, dependency_libs, current,
|
||||
dnl age, revision, installed, dlopen, dlpreopen, libdir.
|
||||
save_libdir="$libdir"
|
||||
case "$found_la" in
|
||||
*/* | *\\*) . "$found_la" ;;
|
||||
*) . "./$found_la" ;;
|
||||
esac
|
||||
libdir="$save_libdir"
|
||||
dnl We use only dependency_libs.
|
||||
for dep in $dependency_libs; do
|
||||
case "$dep" in
|
||||
-L*)
|
||||
additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
|
||||
dnl Potentially add $additional_libdir to $LIBNAME and $LTLIBNAME.
|
||||
dnl But don't add it
|
||||
dnl 1. if it's the standard /usr/lib,
|
||||
dnl 2. if it's /usr/local/lib and we are using GCC on Linux,
|
||||
dnl 3. if it's already present in $LDFLAGS or the already
|
||||
dnl constructed $LIBNAME,
|
||||
dnl 4. if it doesn't exist as a directory.
|
||||
if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
|
||||
&& test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
|
||||
haveit=
|
||||
if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
|
||||
|| test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
|
||||
if test -n "$GCC"; then
|
||||
case $host_os in
|
||||
linux* | gnu* | k*bsd*-gnu) haveit=yes;;
|
||||
esac
|
||||
fi
|
||||
fi
|
||||
if test -z "$haveit"; then
|
||||
haveit=
|
||||
for x in $LDFLAGS $LIB[]NAME; do
|
||||
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
|
||||
if test "X$x" = "X-L$additional_libdir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
if test -d "$additional_libdir"; then
|
||||
dnl Really add $additional_libdir to $LIBNAME.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$additional_libdir"
|
||||
fi
|
||||
fi
|
||||
haveit=
|
||||
for x in $LDFLAGS $LTLIB[]NAME; do
|
||||
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
|
||||
if test "X$x" = "X-L$additional_libdir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
if test -d "$additional_libdir"; then
|
||||
dnl Really add $additional_libdir to $LTLIBNAME.
|
||||
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$additional_libdir"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
-R*)
|
||||
dir=`echo "X$dep" | sed -e 's/^X-R//'`
|
||||
if test "$enable_rpath" != no; then
|
||||
dnl Potentially add DIR to rpathdirs.
|
||||
dnl The rpathdirs will be appended to $LIBNAME at the end.
|
||||
haveit=
|
||||
for x in $rpathdirs; do
|
||||
if test "X$x" = "X$dir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
rpathdirs="$rpathdirs $dir"
|
||||
fi
|
||||
dnl Potentially add DIR to ltrpathdirs.
|
||||
dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
|
||||
haveit=
|
||||
for x in $ltrpathdirs; do
|
||||
if test "X$x" = "X$dir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
ltrpathdirs="$ltrpathdirs $dir"
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
-l*)
|
||||
dnl Handle this in the next round.
|
||||
names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
|
||||
;;
|
||||
*.la)
|
||||
dnl Handle this in the next round. Throw away the .la's
|
||||
dnl directory; it is already contained in a preceding -L
|
||||
dnl option.
|
||||
names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
|
||||
;;
|
||||
*)
|
||||
dnl Most likely an immediate library name.
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep"
|
||||
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
fi
|
||||
else
|
||||
dnl Didn't find the library; assume it is in the system directories
|
||||
dnl known to the linker and runtime loader. (All the system
|
||||
dnl directories known to the linker should also be known to the
|
||||
dnl runtime loader, otherwise the system is severely misconfigured.)
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
|
||||
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
done
|
||||
done
|
||||
if test "X$rpathdirs" != "X"; then
|
||||
if test -n "$acl_hardcode_libdir_separator"; then
|
||||
dnl Weird platform: only the last -rpath option counts, the user must
|
||||
dnl pass all path elements in one option. We can arrange that for a
|
||||
dnl single library, but not when more than one $LIBNAMEs are used.
|
||||
alldirs=
|
||||
for found_dir in $rpathdirs; do
|
||||
alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
|
||||
done
|
||||
dnl Note: acl_hardcode_libdir_flag_spec uses $libdir and $wl.
|
||||
acl_save_libdir="$libdir"
|
||||
libdir="$alldirs"
|
||||
eval flag=\"$acl_hardcode_libdir_flag_spec\"
|
||||
libdir="$acl_save_libdir"
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
|
||||
else
|
||||
dnl The -rpath options are cumulative.
|
||||
for found_dir in $rpathdirs; do
|
||||
acl_save_libdir="$libdir"
|
||||
libdir="$found_dir"
|
||||
eval flag=\"$acl_hardcode_libdir_flag_spec\"
|
||||
libdir="$acl_save_libdir"
|
||||
LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
|
||||
done
|
||||
fi
|
||||
fi
|
||||
if test "X$ltrpathdirs" != "X"; then
|
||||
dnl When using libtool, the option that works for both libraries and
|
||||
dnl executables is -R. The -R options are cumulative.
|
||||
for found_dir in $ltrpathdirs; do
|
||||
LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir"
|
||||
done
|
||||
fi
|
||||
popdef([P_A_C_K])
|
||||
popdef([PACKLIBS])
|
||||
popdef([PACKUP])
|
||||
popdef([PACK])
|
||||
popdef([NAME])
|
||||
])
|
||||
|
||||
dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR,
|
||||
dnl unless already present in VAR.
|
||||
dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes
|
||||
dnl contains two or three consecutive elements that belong together.
|
||||
AC_DEFUN([AC_LIB_APPENDTOVAR],
|
||||
[
|
||||
for element in [$2]; do
|
||||
haveit=
|
||||
for x in $[$1]; do
|
||||
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
|
||||
if test "X$x" = "X$element"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
[$1]="${[$1]}${[$1]:+ }$element"
|
||||
fi
|
||||
done
|
||||
])
|
||||
|
||||
dnl For those cases where a variable contains several -L and -l options
|
||||
dnl referring to unknown libraries and directories, this macro determines the
|
||||
dnl necessary additional linker options for the runtime path.
|
||||
dnl AC_LIB_LINKFLAGS_FROM_LIBS([LDADDVAR], [LIBSVALUE], [USE-LIBTOOL])
|
||||
dnl sets LDADDVAR to linker options needed together with LIBSVALUE.
|
||||
dnl If USE-LIBTOOL evaluates to non-empty, linking with libtool is assumed,
|
||||
dnl otherwise linking without libtool is assumed.
|
||||
AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS],
|
||||
[
|
||||
AC_REQUIRE([AC_LIB_RPATH])
|
||||
AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
|
||||
$1=
|
||||
if test "$enable_rpath" != no; then
|
||||
if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
|
||||
dnl Use an explicit option to hardcode directories into the resulting
|
||||
dnl binary.
|
||||
rpathdirs=
|
||||
next=
|
||||
for opt in $2; do
|
||||
if test -n "$next"; then
|
||||
dir="$next"
|
||||
dnl No need to hardcode the standard /usr/lib.
|
||||
if test "X$dir" != "X/usr/$acl_libdirstem" \
|
||||
&& test "X$dir" != "X/usr/$acl_libdirstem2"; then
|
||||
rpathdirs="$rpathdirs $dir"
|
||||
fi
|
||||
next=
|
||||
else
|
||||
case $opt in
|
||||
-L) next=yes ;;
|
||||
-L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'`
|
||||
dnl No need to hardcode the standard /usr/lib.
|
||||
if test "X$dir" != "X/usr/$acl_libdirstem" \
|
||||
&& test "X$dir" != "X/usr/$acl_libdirstem2"; then
|
||||
rpathdirs="$rpathdirs $dir"
|
||||
fi
|
||||
next= ;;
|
||||
*) next= ;;
|
||||
esac
|
||||
fi
|
||||
done
|
||||
if test "X$rpathdirs" != "X"; then
|
||||
if test -n ""$3""; then
|
||||
dnl libtool is used for linking. Use -R options.
|
||||
for dir in $rpathdirs; do
|
||||
$1="${$1}${$1:+ }-R$dir"
|
||||
done
|
||||
else
|
||||
dnl The linker is used for linking directly.
|
||||
if test -n "$acl_hardcode_libdir_separator"; then
|
||||
dnl Weird platform: only the last -rpath option counts, the user
|
||||
dnl must pass all path elements in one option.
|
||||
alldirs=
|
||||
for dir in $rpathdirs; do
|
||||
alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$dir"
|
||||
done
|
||||
acl_save_libdir="$libdir"
|
||||
libdir="$alldirs"
|
||||
eval flag=\"$acl_hardcode_libdir_flag_spec\"
|
||||
libdir="$acl_save_libdir"
|
||||
$1="$flag"
|
||||
else
|
||||
dnl The -rpath options are cumulative.
|
||||
for dir in $rpathdirs; do
|
||||
acl_save_libdir="$libdir"
|
||||
libdir="$dir"
|
||||
eval flag=\"$acl_hardcode_libdir_flag_spec\"
|
||||
libdir="$acl_save_libdir"
|
||||
$1="${$1}${$1:+ }$flag"
|
||||
done
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
AC_SUBST([$1])
|
||||
])
|
||||
@ -1,224 +0,0 @@
|
||||
# lib-prefix.m4 serial 7 (gettext-0.18)
|
||||
dnl Copyright (C) 2001-2005, 2008-2010 Free Software Foundation, Inc.
|
||||
dnl This file is free software; the Free Software Foundation
|
||||
dnl gives unlimited permission to copy and/or distribute it,
|
||||
dnl with or without modifications, as long as this notice is preserved.
|
||||
|
||||
dnl From Bruno Haible.
|
||||
|
||||
dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and
|
||||
dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't
|
||||
dnl require excessive bracketing.
|
||||
ifdef([AC_HELP_STRING],
|
||||
[AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])],
|
||||
[AC_DEFUN([AC_][LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])])
|
||||
|
||||
dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed
|
||||
dnl to access previously installed libraries. The basic assumption is that
|
||||
dnl a user will want packages to use other packages he previously installed
|
||||
dnl with the same --prefix option.
|
||||
dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate
|
||||
dnl libraries, but is otherwise very convenient.
|
||||
AC_DEFUN([AC_LIB_PREFIX],
|
||||
[
|
||||
AC_BEFORE([$0], [AC_LIB_LINKFLAGS])
|
||||
AC_REQUIRE([AC_PROG_CC])
|
||||
AC_REQUIRE([AC_CANONICAL_HOST])
|
||||
AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
|
||||
AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
|
||||
dnl By default, look in $includedir and $libdir.
|
||||
use_additional=yes
|
||||
AC_LIB_WITH_FINAL_PREFIX([
|
||||
eval additional_includedir=\"$includedir\"
|
||||
eval additional_libdir=\"$libdir\"
|
||||
])
|
||||
AC_LIB_ARG_WITH([lib-prefix],
|
||||
[ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib
|
||||
--without-lib-prefix don't search for libraries in includedir and libdir],
|
||||
[
|
||||
if test "X$withval" = "Xno"; then
|
||||
use_additional=no
|
||||
else
|
||||
if test "X$withval" = "X"; then
|
||||
AC_LIB_WITH_FINAL_PREFIX([
|
||||
eval additional_includedir=\"$includedir\"
|
||||
eval additional_libdir=\"$libdir\"
|
||||
])
|
||||
else
|
||||
additional_includedir="$withval/include"
|
||||
additional_libdir="$withval/$acl_libdirstem"
|
||||
fi
|
||||
fi
|
||||
])
|
||||
if test $use_additional = yes; then
|
||||
dnl Potentially add $additional_includedir to $CPPFLAGS.
|
||||
dnl But don't add it
|
||||
dnl 1. if it's the standard /usr/include,
|
||||
dnl 2. if it's already present in $CPPFLAGS,
|
||||
dnl 3. if it's /usr/local/include and we are using GCC on Linux,
|
||||
dnl 4. if it doesn't exist as a directory.
|
||||
if test "X$additional_includedir" != "X/usr/include"; then
|
||||
haveit=
|
||||
for x in $CPPFLAGS; do
|
||||
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
|
||||
if test "X$x" = "X-I$additional_includedir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
if test "X$additional_includedir" = "X/usr/local/include"; then
|
||||
if test -n "$GCC"; then
|
||||
case $host_os in
|
||||
linux* | gnu* | k*bsd*-gnu) haveit=yes;;
|
||||
esac
|
||||
fi
|
||||
fi
|
||||
if test -z "$haveit"; then
|
||||
if test -d "$additional_includedir"; then
|
||||
dnl Really add $additional_includedir to $CPPFLAGS.
|
||||
CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
dnl Potentially add $additional_libdir to $LDFLAGS.
|
||||
dnl But don't add it
|
||||
dnl 1. if it's the standard /usr/lib,
|
||||
dnl 2. if it's already present in $LDFLAGS,
|
||||
dnl 3. if it's /usr/local/lib and we are using GCC on Linux,
|
||||
dnl 4. if it doesn't exist as a directory.
|
||||
if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
|
||||
haveit=
|
||||
for x in $LDFLAGS; do
|
||||
AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
|
||||
if test "X$x" = "X-L$additional_libdir"; then
|
||||
haveit=yes
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test -z "$haveit"; then
|
||||
if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
|
||||
if test -n "$GCC"; then
|
||||
case $host_os in
|
||||
linux*) haveit=yes;;
|
||||
esac
|
||||
fi
|
||||
fi
|
||||
if test -z "$haveit"; then
|
||||
if test -d "$additional_libdir"; then
|
||||
dnl Really add $additional_libdir to $LDFLAGS.
|
||||
LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
])
|
||||
|
||||
dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix,
|
||||
dnl acl_final_exec_prefix, containing the values to which $prefix and
|
||||
dnl $exec_prefix will expand at the end of the configure script.
|
||||
AC_DEFUN([AC_LIB_PREPARE_PREFIX],
|
||||
[
|
||||
dnl Unfortunately, prefix and exec_prefix get only finally determined
|
||||
dnl at the end of configure.
|
||||
if test "X$prefix" = "XNONE"; then
|
||||
acl_final_prefix="$ac_default_prefix"
|
||||
else
|
||||
acl_final_prefix="$prefix"
|
||||
fi
|
||||
if test "X$exec_prefix" = "XNONE"; then
|
||||
acl_final_exec_prefix='${prefix}'
|
||||
else
|
||||
acl_final_exec_prefix="$exec_prefix"
|
||||
fi
|
||||
acl_save_prefix="$prefix"
|
||||
prefix="$acl_final_prefix"
|
||||
eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
|
||||
prefix="$acl_save_prefix"
|
||||
])
|
||||
|
||||
dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the
|
||||
dnl variables prefix and exec_prefix bound to the values they will have
|
||||
dnl at the end of the configure script.
|
||||
AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX],
|
||||
[
|
||||
acl_save_prefix="$prefix"
|
||||
prefix="$acl_final_prefix"
|
||||
acl_save_exec_prefix="$exec_prefix"
|
||||
exec_prefix="$acl_final_exec_prefix"
|
||||
$1
|
||||
exec_prefix="$acl_save_exec_prefix"
|
||||
prefix="$acl_save_prefix"
|
||||
])
|
||||
|
||||
dnl AC_LIB_PREPARE_MULTILIB creates
|
||||
dnl - a variable acl_libdirstem, containing the basename of the libdir, either
|
||||
dnl "lib" or "lib64" or "lib/64",
|
||||
dnl - a variable acl_libdirstem2, as a secondary possible value for
|
||||
dnl acl_libdirstem, either the same as acl_libdirstem or "lib/sparcv9" or
|
||||
dnl "lib/amd64".
|
||||
AC_DEFUN([AC_LIB_PREPARE_MULTILIB],
|
||||
[
|
||||
dnl There is no formal standard regarding lib and lib64.
|
||||
dnl On glibc systems, the current practice is that on a system supporting
|
||||
dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
|
||||
dnl $prefix/lib64 and 32-bit libraries go under $prefix/lib. We determine
|
||||
dnl the compiler's default mode by looking at the compiler's library search
|
||||
dnl path. If at least one of its elements ends in /lib64 or points to a
|
||||
dnl directory whose absolute pathname ends in /lib64, we assume a 64-bit ABI.
|
||||
dnl Otherwise we use the default, namely "lib".
|
||||
dnl On Solaris systems, the current practice is that on a system supporting
|
||||
dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
|
||||
dnl $prefix/lib/64 (which is a symlink to either $prefix/lib/sparcv9 or
|
||||
dnl $prefix/lib/amd64) and 32-bit libraries go under $prefix/lib.
|
||||
AC_REQUIRE([AC_CANONICAL_HOST])
|
||||
acl_libdirstem=lib
|
||||
acl_libdirstem2=
|
||||
case "$host_os" in
|
||||
solaris*)
|
||||
dnl See Solaris 10 Software Developer Collection > Solaris 64-bit Developer's Guide > The Development Environment
|
||||
dnl <http://docs.sun.com/app/docs/doc/816-5138/dev-env?l=en&a=view>.
|
||||
dnl "Portable Makefiles should refer to any library directories using the 64 symbolic link."
|
||||
dnl But we want to recognize the sparcv9 or amd64 subdirectory also if the
|
||||
dnl symlink is missing, so we set acl_libdirstem2 too.
|
||||
AC_CACHE_CHECK([for 64-bit host], [gl_cv_solaris_64bit],
|
||||
[AC_EGREP_CPP([sixtyfour bits], [
|
||||
#ifdef _LP64
|
||||
sixtyfour bits
|
||||
#endif
|
||||
], [gl_cv_solaris_64bit=yes], [gl_cv_solaris_64bit=no])
|
||||
])
|
||||
if test $gl_cv_solaris_64bit = yes; then
|
||||
acl_libdirstem=lib/64
|
||||
case "$host_cpu" in
|
||||
sparc*) acl_libdirstem2=lib/sparcv9 ;;
|
||||
i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
|
||||
esac
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
|
||||
if test -n "$searchpath"; then
|
||||
acl_save_IFS="${IFS= }"; IFS=":"
|
||||
for searchdir in $searchpath; do
|
||||
if test -d "$searchdir"; then
|
||||
case "$searchdir" in
|
||||
*/lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
|
||||
*/../ | */.. )
|
||||
# Better ignore directories of this form. They are misleading.
|
||||
;;
|
||||
*) searchdir=`cd "$searchdir" && pwd`
|
||||
case "$searchdir" in
|
||||
*/lib64 ) acl_libdirstem=lib64 ;;
|
||||
esac ;;
|
||||
esac
|
||||
fi
|
||||
done
|
||||
IFS="$acl_save_IFS"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
|
||||
])
|
||||
@ -1,92 +0,0 @@
|
||||
# progtest.m4 serial 6 (gettext-0.18)
|
||||
dnl Copyright (C) 1996-2003, 2005, 2008-2010 Free Software Foundation, Inc.
|
||||
dnl This file is free software; the Free Software Foundation
|
||||
dnl gives unlimited permission to copy and/or distribute it,
|
||||
dnl with or without modifications, as long as this notice is preserved.
|
||||
dnl
|
||||
dnl This file can can be used in projects which are not available under
|
||||
dnl the GNU General Public License or the GNU Library General Public
|
||||
dnl License but which still want to provide support for the GNU gettext
|
||||
dnl functionality.
|
||||
dnl Please note that the actual code of the GNU gettext library is covered
|
||||
dnl by the GNU Library General Public License, and the rest of the GNU
|
||||
dnl gettext package package is covered by the GNU General Public License.
|
||||
dnl They are *not* in the public domain.
|
||||
|
||||
dnl Authors:
|
||||
dnl Ulrich Drepper <drepper@cygnus.com>, 1996.
|
||||
|
||||
AC_PREREQ([2.50])
|
||||
|
||||
# Search path for a program which passes the given test.
|
||||
|
||||
dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
|
||||
dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
|
||||
AC_DEFUN([AM_PATH_PROG_WITH_TEST],
|
||||
[
|
||||
# Prepare PATH_SEPARATOR.
|
||||
# The user is always right.
|
||||
if test "${PATH_SEPARATOR+set}" != set; then
|
||||
echo "#! /bin/sh" >conf$$.sh
|
||||
echo "exit 0" >>conf$$.sh
|
||||
chmod +x conf$$.sh
|
||||
if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
|
||||
PATH_SEPARATOR=';'
|
||||
else
|
||||
PATH_SEPARATOR=:
|
||||
fi
|
||||
rm -f conf$$.sh
|
||||
fi
|
||||
|
||||
# Find out how to test for executable files. Don't use a zero-byte file,
|
||||
# as systems may use methods other than mode bits to determine executability.
|
||||
cat >conf$$.file <<_ASEOF
|
||||
#! /bin/sh
|
||||
exit 0
|
||||
_ASEOF
|
||||
chmod +x conf$$.file
|
||||
if test -x conf$$.file >/dev/null 2>&1; then
|
||||
ac_executable_p="test -x"
|
||||
else
|
||||
ac_executable_p="test -f"
|
||||
fi
|
||||
rm -f conf$$.file
|
||||
|
||||
# Extract the first word of "$2", so it can be a program name with args.
|
||||
set dummy $2; ac_word=[$]2
|
||||
AC_MSG_CHECKING([for $ac_word])
|
||||
AC_CACHE_VAL([ac_cv_path_$1],
|
||||
[case "[$]$1" in
|
||||
[[\\/]]* | ?:[[\\/]]*)
|
||||
ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
|
||||
;;
|
||||
*)
|
||||
ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
|
||||
for ac_dir in ifelse([$5], , $PATH, [$5]); do
|
||||
IFS="$ac_save_IFS"
|
||||
test -z "$ac_dir" && ac_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
|
||||
echo "$as_me: trying $ac_dir/$ac_word..." >&AS_MESSAGE_LOG_FD
|
||||
if [$3]; then
|
||||
ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext"
|
||||
break 2
|
||||
fi
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS="$ac_save_IFS"
|
||||
dnl If no 4th arg is given, leave the cache variable unset,
|
||||
dnl so AC_PATH_PROGS will keep looking.
|
||||
ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
|
||||
])dnl
|
||||
;;
|
||||
esac])dnl
|
||||
$1="$ac_cv_path_$1"
|
||||
if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
|
||||
AC_MSG_RESULT([$][$1])
|
||||
else
|
||||
AC_MSG_RESULT([no])
|
||||
fi
|
||||
AC_SUBST([$1])dnl
|
||||
])
|
||||
@ -1,26 +0,0 @@
|
||||
# stdint_h.m4 serial 8
|
||||
dnl Copyright (C) 1997-2004, 2006, 2008-2010 Free Software Foundation, Inc.
|
||||
dnl This file is free software; the Free Software Foundation
|
||||
dnl gives unlimited permission to copy and/or distribute it,
|
||||
dnl with or without modifications, as long as this notice is preserved.
|
||||
|
||||
dnl From Paul Eggert.
|
||||
|
||||
# Define HAVE_STDINT_H_WITH_UINTMAX if <stdint.h> exists,
|
||||
# doesn't clash with <sys/types.h>, and declares uintmax_t.
|
||||
|
||||
AC_DEFUN([gl_AC_HEADER_STDINT_H],
|
||||
[
|
||||
AC_CACHE_CHECK([for stdint.h], [gl_cv_header_stdint_h],
|
||||
[AC_TRY_COMPILE(
|
||||
[#include <sys/types.h>
|
||||
#include <stdint.h>],
|
||||
[uintmax_t i = (uintmax_t) -1; return !i;],
|
||||
[gl_cv_header_stdint_h=yes],
|
||||
[gl_cv_header_stdint_h=no])])
|
||||
if test $gl_cv_header_stdint_h = yes; then
|
||||
AC_DEFINE_UNQUOTED([HAVE_STDINT_H_WITH_UINTMAX], [1],
|
||||
[Define if <stdint.h> exists, doesn't clash with <sys/types.h>,
|
||||
and declares uintmax_t. ])
|
||||
fi
|
||||
])
|
||||
@ -1,28 +0,0 @@
|
||||
# wint_t.m4 serial 4 (gettext-0.18)
|
||||
dnl Copyright (C) 2003, 2007-2010 Free Software Foundation, Inc.
|
||||
dnl This file is free software; the Free Software Foundation
|
||||
dnl gives unlimited permission to copy and/or distribute it,
|
||||
dnl with or without modifications, as long as this notice is preserved.
|
||||
|
||||
dnl From Bruno Haible.
|
||||
dnl Test whether <wchar.h> has the 'wint_t' type.
|
||||
dnl Prerequisite: AC_PROG_CC
|
||||
|
||||
AC_DEFUN([gt_TYPE_WINT_T],
|
||||
[
|
||||
AC_CACHE_CHECK([for wint_t], [gt_cv_c_wint_t],
|
||||
[AC_TRY_COMPILE([
|
||||
/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
|
||||
<wchar.h>.
|
||||
BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
|
||||
before <wchar.h>. */
|
||||
#include <stddef.h>
|
||||
#include <stdio.h>
|
||||
#include <time.h>
|
||||
#include <wchar.h>
|
||||
wint_t foo = (wchar_t)'\0';], ,
|
||||
[gt_cv_c_wint_t=yes], [gt_cv_c_wint_t=no])])
|
||||
if test $gt_cv_c_wint_t = yes; then
|
||||
AC_DEFINE([HAVE_WINT_T], [1], [Define if you have the 'wint_t' type.])
|
||||
fi
|
||||
])
|
||||
Loading…
Reference in New Issue
Block a user