1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-18 20:10:29 +01:00

configure: replaced option '--with-nls' by autoconf's '--localedir'

Autoconf have been providing the option '--localedir' for a long time now,
so this patch removes the deprecated '--with-nls' option and makes use of
the standard '--localedir' instead.

Took opportunity to define the path in the 'config-paths.h' in the same way
the other paths are defined to be consistent, which also simplify the
compilation commands.

Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This commit is contained in:
Christophe CURIS
2015-01-20 22:04:01 +01:00
committed by Carlos R. Mafra
parent 1b0b2d7b1b
commit bf6bc120a5
11 changed files with 27 additions and 38 deletions

View File

@@ -19,6 +19,9 @@ config-paths.h: Makefile
echo '#define MENU_TEXTDOMAIN "$(menutextdomain)"' >> $@; \
fi
@echo '' >> $@
@echo '/* define where the translations are stored */' >> $@
@echo '#define LOCALEDIR "$(localedir)"' >> $@
@echo '' >> $@
@echo '/* define an extra path for pixmaps */' >> $@
@echo '#define PIXMAPDIR "$(pixmapdir)"' >> $@
@echo '' >> $@

View File

@@ -91,7 +91,7 @@ libWUtil_la_SOURCES = \
AM_CFLAGS =
AM_CPPFLAGS = -DLOCALEDIR=\"$(NLSDIR)\" -DRESOURCE_PATH=\"$(datadir)/WINGs\" \
AM_CPPFLAGS = -DRESOURCE_PATH=\"$(datadir)/WINGs\" \
-I$(top_srcdir)/WINGs/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \
@XFTFLAGS@ @HEADER_SEARCH_PATH@

View File

@@ -1,7 +1,5 @@
DOMAIN = WINGs
nlsdir = $(NLSDIR)
CATALOGS = @WINGSMOFILES@
CLEANFILES = $(CATALOGS) $(DOMAIN).pot
@@ -93,12 +91,12 @@ endif
install-data-local: $(CATALOGS)
$(mkinstalldirs) $(DESTDIR)$(nlsdir)
$(mkinstalldirs) $(DESTDIR)$(localedir)
for n in $(CATALOGS) __DuMmY ; do \
if test "$$n" -a "$$n" != "__DuMmY" ; then \
l=`basename $$n .mo`; \
$(mkinstalldirs) $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES; \
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES/$(DOMAIN).mo; \
$(mkinstalldirs) $(DESTDIR)$(localedir)/$$l/LC_MESSAGES; \
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(localedir)/$$l/LC_MESSAGES/$(DOMAIN).mo; \
fi; \
done

View File

@@ -47,7 +47,7 @@ WPrefs_SOURCES = \
AM_CFLAGS =
AM_CPPFLAGS = -DLOCALEDIR=\"$(NLSDIR)\" -DRESOURCE_PATH=\"$(wpdatadir)\" -DWMAKER_RESOURCE_PATH=\"$(pkgdatadir)\" \
AM_CPPFLAGS = -DRESOURCE_PATH=\"$(wpdatadir)\" -DWMAKER_RESOURCE_PATH=\"$(pkgdatadir)\" \
-I$(top_srcdir)/wrlib -I$(top_srcdir)/WINGs @HEADER_SEARCH_PATH@
WPrefs_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.la

View File

@@ -2,8 +2,6 @@ DOMAIN = WPrefs
CATALOGS = @WPREFSMOFILES@
nlsdir = $(NLSDIR)
CLEANFILES = $(DOMAIN).pot $(CATALOGS)
EXTRA_DIST = bg.po ca.po cs.po de.po es.po et.po fi.po fr.po hr.po hu.po \
@@ -59,12 +57,12 @@ endif
install-data-local: $(CATALOGS)
$(mkinstalldirs) $(DESTDIR)$(nlsdir)
$(mkinstalldirs) $(DESTDIR)$(localedir)
for n in $(CATALOGS) __DuMmY ; do \
if test "$$n" -a "$$n" != "__DuMmY" ; then \
l=`basename $$n .mo`; \
$(mkinstalldirs) $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES; \
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES/$(DOMAIN).mo; \
$(mkinstalldirs) $(DESTDIR)$(localedir)/$$l/LC_MESSAGES; \
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(localedir)/$$l/LC_MESSAGES/$(DOMAIN).mo; \
fi; \
done

View File

@@ -419,18 +419,11 @@ dnl that the gettext environment works
WM_I18N_LANGUAGES
WM_I18N_XGETTEXT
dnl 2014/12/29: The option is deprecated, we should keep this message for at
dnl least 2 years to ensure users see it and update their build scripts
AC_ARG_WITH([nlsdir], [],
[AC_MSG_ERROR([option '--with-nlsdir' is deprecated, please use autoconf's standard '--localedir' instead])])
dnl Added by Oliver - Support for NLSDIR option
dnl ===========================================
AC_ARG_WITH(nlsdir, AS_HELP_STRING([--with-nlsdir=PATH], [specify where the locale stuff should go]))
if test "x$NLSDIR" = "x"; then
if test "x$with_nlsdir" != "x"; then
NLSDIR=$with_nlsdir
else
NLSDIR='$(prefix)/lib/locale'
fi
fi
menutextdomain=
AC_ARG_WITH(menu-textdomain, AS_HELP_STRING([--with-menu-textdomain=DOMAIN], [specify gettext domain used for menu translations]),
@@ -916,8 +909,6 @@ echo "Unsupported features :$unsupported"
echo "Antialiased text support in WINGs : $xft"
echo "Pango text layout support in WINGs : $pango"
echo "Translated languages to support :$supported_locales"
AS_IF([test "x$supported_locales" != "x disabled"],
[echo "Installation path for translations : $NLSDIR" | sed -e 's|\$(prefix)|'"$prefix|"])
AS_IF([test "x$debug" = "xyes"],
[AS_ECHO(["Debug enabled: CFLAGS = $CFLAGS"]) ])
echo

View File

@@ -109,6 +109,10 @@ library); when you run @command{make} to compile the project, it will also compi
(@code{mo} files) for the language(s) you asked (if available, of course), and during
@command{make install} it will install them in the usual directory.
The installation directory can be changed with the standard option @option{--localedir} to the
@command{configure} script, the default path being
@file{@emph{<prefix>}/share/locale/@emph{<lang>}/LC_MESSAGES}).
@c --------------------------------------------------------------------- LINGUAS at system level ---
@section Setting @env{LINGUAS} at system level

View File

@@ -1,7 +1,5 @@
DOMAIN = WindowMaker
nlsdir = $(NLSDIR)
CATALOGS = @WMAKERMOFILES@
CLEANFILES = $(CATALOGS) $(DOMAIN).pot
@@ -88,12 +86,12 @@ endif
install-data-local: $(CATALOGS)
$(mkinstalldirs) $(DESTDIR)$(nlsdir)
$(mkinstalldirs) $(DESTDIR)$(localedir)
for n in $(CATALOGS) __DuMmY ; do \
if test "$$n" -a "$$n" != "__DuMmY" ; then \
l=`basename $$n .mo`; \
$(mkinstalldirs) $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES; \
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES/$(DOMAIN).mo; \
$(mkinstalldirs) $(DESTDIR)$(localedir)/$$l/LC_MESSAGES; \
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(localedir)/$$l/LC_MESSAGES/$(DOMAIN).mo; \
fi; \
done

View File

@@ -146,8 +146,7 @@ endif
AM_CFLAGS =
AM_CPPFLAGS = \
$(DFLAGS) -DLOCALEDIR=\"$(NLSDIR)\" \
AM_CPPFLAGS = $(DFLAGS) \
-I$(top_srcdir)/wrlib \
-I$(top_srcdir)/WINGs @HEADER_SEARCH_PATH@

View File

@@ -11,7 +11,7 @@ bin_SCRIPTS = wmaker.inst wm-oldmenu2new wkdemenu.pl
EXTRA_DIST = wmaker.inst.in bughint wm-oldmenu2new wkdemenu.pl
AM_CPPFLAGS = -DLOCALEDIR=\"$(NLSDIR)\" \
AM_CPPFLAGS = \
$(DFLAGS) -I$(top_srcdir)/WINGs -I$(top_srcdir)/wrlib \
@HEADER_SEARCH_PATH@ \
-DETCDIR=\"sysconfdir\" -DDATADIR=\"pkgdatadir\"

View File

@@ -2,8 +2,6 @@ DOMAIN = wmgenmenu
CATALOGS = @UTILMOFILES@
nlsdir = $(NLSDIR)
CLEANFILES = $(DOMAIN).pot $(CATALOGS)
EXTRA_DIST = de.po es.po fr.po nl.po pt.po
@@ -34,11 +32,11 @@ endif
install-data-local: $(CATALOGS)
$(mkinstalldirs) $(DESTDIR)$(nlsdir)
$(mkinstalldirs) $(DESTDIR)$(localedir)
for n in $(CATALOGS) __DuMmY ; do \
if test "$$n" -a "$$n" != "__DuMmY" ; then \
l=`basename $$n .mo`; \
$(mkinstalldirs) $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES; \
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES/$(DOMAIN).mo; \
$(mkinstalldirs) $(DESTDIR)$(localedir)/$$l/LC_MESSAGES; \
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(localedir)/$$l/LC_MESSAGES/$(DOMAIN).mo; \
fi; \
done