1 ################################################################################
5 ################################################################################
7 GETTEXT_VERSION
= 0.19.8.1
8 GETTEXT_SITE
= $(BR2_GNU_MIRROR
)/gettext
9 GETTEXT_SOURCE
= gettext-
$(GETTEXT_VERSION
).
tar.xz
10 GETTEXT_INSTALL_STAGING
= YES
11 GETTEXT_LICENSE
= LGPLv2.1
+ (libintl
), GPLv3
+ (the rest
)
12 GETTEXT_LICENSE_FILES
= COPYING gettext-runtime
/intl
/COPYING.LIB
14 GETTEXT_DEPENDENCIES
= $(if
$(BR2_PACKAGE_LIBICONV
),libiconv
)
16 # Avoid using the bundled subset of libxml2
17 HOST_GETTEXT_DEPENDENCIES
= host-libxml2
19 GETTEXT_CONF_OPTS
+= \
20 --disable-libasprintf \
25 --disable-native-java \
27 --disable-relocatable \
30 HOST_GETTEXT_CONF_OPTS
= \
31 --disable-libasprintf \
36 --disable-native-java \
38 --disable-relocatable \
41 # For the target version, we only need the runtime, and for the host
42 # version, we only need the tools.
43 GETTEXT_SUBDIR
= gettext-runtime
44 HOST_GETTEXT_SUBDIR
= gettext-tools
46 # Disable the build of documentation and examples of gettext-tools,
47 # and the build of documentation and tests of gettext-runtime.
48 define HOST_GETTEXT_DISABLE_UNNEEDED
49 $(SED
) '/^SUBDIRS/s/ doc //;/^SUBDIRS/s/examples$$//' $(@D
)/gettext-tools
/Makefile.in
50 $(SED
) '/^SUBDIRS/s/ doc //;/^SUBDIRS/s/tests$$//' $(@D
)/gettext-runtime
/Makefile.in
53 GETTEXT_POST_PATCH_HOOKS
+= HOST_GETTEXT_DISABLE_UNNEEDED
54 HOST_GETTEXT_POST_PATCH_HOOKS
+= HOST_GETTEXT_DISABLE_UNNEEDED
56 define GETTEXT_REMOVE_UNNEEDED
57 $(RM
) -rf
$(TARGET_DIR
)/usr
/share
/gettext
/ABOUT-NLS
58 rmdir
--ignore-fail-on-non-empty
$(TARGET_DIR
)/usr
/share
/gettext
61 GETTEXT_POST_INSTALL_TARGET_HOOKS
+= GETTEXT_REMOVE_UNNEEDED
63 # Force build with NLS support, otherwise libintl is not built
64 # This is needed because some packages (eg. libglib2) requires
65 # locales, but do not properly depend on BR2_ENABLE_LOCALE, and
66 # instead select BR2_PACKAGE_GETTEXT. Those packages need to be
67 # fixed before we can remove the following 3 lines... :-(
68 ifeq ($(BR2_ENABLE_LOCALE
),)
69 GETTEXT_CONF_OPTS
+= --enable-nls
72 # Disable interactive confirmation in host gettextize for package fixups
73 define HOST_GETTEXT_GETTEXTIZE_CONFIRMATION
74 $(SED
) '/read dummy/d' $(HOST_DIR
)/usr
/bin
/gettextize
76 HOST_GETTEXT_POST_INSTALL_HOOKS
+= HOST_GETTEXT_GETTEXTIZE_CONFIRMATION
78 # autoreconf expects gettextize to install ABOUT-NLS, but it only gets
79 # installed by gettext-runtime which we don't build/install for the
80 # host, so do it manually
81 define HOST_GETTEXT_ADD_ABOUT_NLS
82 $(INSTALL
) -m
0644 $(@D
)/$(HOST_GETTEXT_SUBDIR
)/ABOUT-NLS \
83 $(HOST_DIR
)/usr
/share
/gettext
/ABOUT-NLS
86 HOST_GETTEXT_POST_INSTALL_HOOKS
+= HOST_GETTEXT_ADD_ABOUT_NLS
88 GETTEXTIZE
= $(HOST_CONFIGURE_OPTS
) AUTOM4TE
=$(HOST_DIR
)/usr
/bin
/autom4te
$(HOST_DIR
)/usr
/bin
/gettextize
-f
90 $(eval
$(autotools-package
))
91 $(eval
$(host-autotools-package
))