aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2010-06-19 17:33:38 +0000
committerVincent Torri <vincent.torri@gmail.com>2010-06-19 17:33:38 +0000
commitf34e89ffeca9a2bea10ab4f5f2798430b53108b5 (patch)
tree6ced84e379037aecd99c1d9917f27820da8300e1
parentFix nasty formatting. (diff)
downloadenlightenment-f34e89ffeca9a2bea10ab4f5f2798430b53108b5.tar.gz
* allow compilation without gettext
* fix a bit maintainer-clean rule SVN revision: 49759
-rw-r--r--Makefile.am75
-rw-r--r--configure.ac14
-rw-r--r--src/bin/e.h5
-rw-r--r--src/bin/e_intl.h5
4 files changed, 88 insertions, 11 deletions
diff --git a/Makefile.am b/Makefile.am
index 0d7416416..d9b586cbe 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,11 +1,70 @@
-SUBDIRS = src data doc po config
-
-MAINTAINERCLEANFILES = Makefile.in aclocal.m4 config.guess \
- config.h.in config.sub configure install-sh \
- ltconfig ltmain.sh missing mkinstalldirs \
- stamp-h.in acconfig.h config.rpath compile depcomp \
- enlightenment.spec enlightenment.pc ABOUT-NLS* \
- $(PACKAGE_TARNAME)-$(PACKAGE_VERSION)-doc.tar.bz2
+SUBDIRS = src data doc config
+
+if HAVE_PO
+
+SUBDIRS += po
+
+endif
+
+MAINTAINERCLEANFILES = \
+ABOUT-NLS* \
+Makefile.in \
+aclocal.m4 \
+autom4te.cache \
+compile \
+config.guess \
+config.h.in \
+config.h.in~ \
+config.rpath \
+config.sub \
+configure \
+depcomp \
+install-sh \
+ltmain.sh \
+missing \
+mkinstalldirs \
+$(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz \
+$(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.bz2 \
+$(PACKAGE_TARNAME)-$(PACKAGE_VERSION)-doc.tar.bz2 \
+m4/libtool.m4 \
+m4/lt~obsolete.m4 \
+m4/ltoptions.m4 \
+m4/ltsugar.m4 \
+m4/ltversion.m4 \
+m4/codeset.m4 \
+m4/gettext.m4 \
+m4/glibc21.m4 \
+m4/iconv.m4 \
+m4/intdiv0.m4 \
+m4/inttypes_h.m4 \
+m4/inttypes.m4 \
+m4/inttypes-pri.m4 \
+m4/isc-posix.m4 \
+m4/lcmessage.m4 \
+m4/lib-ld.m4 \
+m4/lib-link.m4 \
+m4/lib-prefix.m4 \
+m4/nls.m4 \
+m4/po.m4 \
+m4/progtest.m4 \
+m4/stdint_h.m4 \
+m4/uintmax_t.m4 \
+m4/ulonglong.m4
+
+if HAVE_PO
+
+MAINTAINERCLEANFILES += \
+po/boldquot.sed \
+po/en@boldquot.header \
+po/en@quot.header \
+po/insert-header.sin \
+po/Makefile.in.in \
+po/Makevars.template \
+po/quot.sed \
+po/remove-potcdate.sin \
+po/Rules-quot
+
+endif
EXTRA_DIST = config.rpath README AUTHORS COPYING COPYING-PLAIN \
enlightenment.spec.in enlightenment.spec enlightenment.pc
diff --git a/configure.ac b/configure.ac
index 62c9e3186..2e7eba7f4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -242,8 +242,18 @@ dnl fi
ALL_LINGUAS="bg ca cs da de el eo es fi fr fr_CH he hu it ja ko nb nl pl pt_BR ru sk sl sv tr zh_CN zh_TW"
AC_SUBST(ALL_LINGUAS)
-AM_GNU_GETTEXT([external])
+m4_ifdef([AM_GNU_GETTEXT_VERSION], [
AM_GNU_GETTEXT_VERSION([0.12.1])
+])
+
+m4_ifdef([AM_GNU_GETTEXT], [
+AM_GNU_GETTEXT([external])
+po_makefile_in=po/Makefile.in
+AM_CONDITIONAL([HAVE_PO], [true])
+],[
+AM_CONDITIONAL([HAVE_PO], [false])
+])
+AC_SUBST(LTLIBINTL)
if test "x$LIBINTL" = "x"; then
LIBINTL="$INTLLIBS"
fi
@@ -798,7 +808,7 @@ config/scaleable/Makefile
config/netbook/Makefile
config/illume/Makefile
config/illume-home/Makefile
-po/Makefile.in
+$po_makefile_in
])
if test "$device_backend" = "eeze";then
diff --git a/src/bin/e.h b/src/bin/e.h
index fac3d0387..a337c12ee 100644
--- a/src/bin/e.h
+++ b/src/bin/e.h
@@ -59,11 +59,14 @@ void *alloca (size_t);
#include <grp.h>
#include <glob.h>
#include <locale.h>
-#include <libintl.h>
#include <errno.h>
#include <signal.h>
#include <inttypes.h>
+#ifdef HAVE_GETTEXT
+# include <libintl.h>
+#endif
+
#ifndef _POSIX_HOST_NAME_MAX
#define _POSIX_HOST_NAME_MAX 255
#endif
diff --git a/src/bin/e_intl.h b/src/bin/e_intl.h
index 93cbddd48..e648c111b 100644
--- a/src/bin/e_intl.h
+++ b/src/bin/e_intl.h
@@ -4,8 +4,13 @@
#ifdef E_TYPEDEFS
#if E_INTERNAL
+#ifdef HAVE_GETTEXT
#define _(str) gettext(str)
#define d_(str, dom) dgettext(PACKAGE dom, str)
+#else
+#define _(str) (str)
+#define d_(str, dom) (str)
+#endif
#endif
/* This macro is used to just mark string for translation, this is useful