From: Bruno Haible Date: Sun, 5 Oct 2025 15:33:27 +0000 (+0200) Subject: Refactor: New subdirectory gettext-tools/wizard/. X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=21a3caa8011d5bbe595f00451ba3b0264f3cea4b;p=thirdparty%2Fgettext.git Refactor: New subdirectory gettext-tools/wizard/. * gettext-tools/configure.ac: Invoke AC_CONFIG_FILES for wizard/Makefile, wizard/gettextize, instead of for misc/gettextize. * gettext-tools/Makefile.am (SUBDIRS): Add wizard. (distdir2): Recurse into wizard/. * gettext-tools/wizard/Makefile.am: New file, based on gettext-tools/misc/Makefile.am. * gettext-tools/wizard/gettextize.in: Renamed from gettext-tools/misc/gettextize.in. * gettext-tools/misc/Makefile.am (bin_SCRIPTS, DISTCLEANFILES): Remove gettextize. (install-data-local, uninstall-local, uninstall-sources): Remove rules. * gettext-tools/man/Makefile.am (man_MAN1WIZARD): New variable. (man_MAN1MISC): Remove gettextize.1. ($(man_MAN1WIZARD)): New rule. (gettextize.1): Update. ($(man_MAN1MISC)): Simplify. --- diff --git a/.gitignore b/.gitignore index 02e7d5f00..e8be98271 100644 --- a/.gitignore +++ b/.gitignore @@ -658,7 +658,6 @@ autom4te.cache/ # (see DISTCLEANFILES in Makefile.am): /gettext-tools/misc/autopoint /gettext-tools/misc/convert-archive -/gettext-tools/misc/gettextize /gettext-tools/po/Makefile.in /gettext-tools/po/Makefile /gettext-tools/projects/Makefile @@ -668,6 +667,7 @@ autom4te.cache/ /gettext-tools/system-tests/Makefile /gettext-tools/tests/Makefile /gettext-tools/tests/init-env +/gettext-tools/wizard/gettextize /gettext-tools/install-tests/Makefile /gnulib-local/Makefile diff --git a/gettext-tools/Makefile.am b/gettext-tools/Makefile.am index 0cec542ce..cf1dd6006 100644 --- a/gettext-tools/Makefile.am +++ b/gettext-tools/Makefile.am @@ -19,7 +19,7 @@ AUTOMAKE_OPTIONS = 1.5 gnu ACLOCAL_AMFLAGS = -I m4 -I ../gettext-runtime/m4 -I ../m4 -I gnulib-m4 -I libgrep/gnulib-m4 -I libgettextpo/gnulib-m4 -I tests/gnulib-m4 -SUBDIRS = gnulib-lib libgrep src libgettextpo po its projects styles emacs misc man m4 tests system-tests gnulib-tests install-tests examples doc +SUBDIRS = gnulib-lib libgrep src libgettextpo po its projects styles wizard emacs misc man m4 tests system-tests gnulib-tests install-tests examples doc EXTRA_DIST = misc/disclaim-translations.txt MOSTLYCLEANFILES = core *.stackdump @@ -264,6 +264,7 @@ gen-man1: programs-for-distdir \ #distdir: distdir2 .PHONY: distdir2 distdir2: programs-for-distdir + cd wizard && $(MAKE) $(AM_MAKEFLAGS) cd misc && $(MAKE) $(AM_MAKEFLAGS) cd examples && $(MAKE) $(AM_MAKEFLAGS) diff --git a/gettext-tools/configure.ac b/gettext-tools/configure.ac index de1380a6e..b288aa1dd 100644 --- a/gettext-tools/configure.ac +++ b/gettext-tools/configure.ac @@ -747,10 +747,12 @@ AC_CONFIG_FILES([projects/Makefile]) AC_CONFIG_FILES([styles/Makefile]) +AC_CONFIG_FILES([wizard/Makefile]) +AC_CONFIG_FILES([wizard/gettextize], [chmod a+x wizard/gettextize]) + AC_CONFIG_FILES([emacs/Makefile]) AC_CONFIG_FILES([misc/Makefile]) -AC_CONFIG_FILES([misc/gettextize], [chmod a+x misc/gettextize]) AC_CONFIG_FILES([misc/autopoint], [chmod a+x misc/autopoint]) AC_CONFIG_FILES([misc/convert-archive], [chmod a+x misc/convert-archive]) diff --git a/gettext-tools/man/Makefile.am b/gettext-tools/man/Makefile.am index 7a6f12330..18a606561 100644 --- a/gettext-tools/man/Makefile.am +++ b/gettext-tools/man/Makefile.am @@ -1,5 +1,5 @@ ## Makefile for the gettext-tools/man subdirectory of GNU gettext -## Copyright (C) 2001-2003, 2006-2007, 2013-2015, 2018, 2021 Free Software Foundation, Inc. +## Copyright (C) 2001-2025 Free Software Foundation, Inc. ## ## This program is free software: you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -22,7 +22,7 @@ AUTOMAKE_OPTIONS = 1.2 gnits EXTRA_DIST = # A manual page for each of the bin_PROGRAMS in src/Makefile.am -# and for each of the bin_SCRIPTS in misc/Makefile.am. +# and for each of the bin_SCRIPTS in wizard/Makefile.am, misc/Makefile.am. man_aux = \ msgcmp.x msgfmt.x msgmerge.x msgunfmt.x xgettext.x \ @@ -38,9 +38,11 @@ msgcmp.1 msgfmt.1 msgmerge.1 msgunfmt.1 xgettext.1 \ msgattrib.1 msgcat.1 msgcomm.1 msgconv.1 msgen.1 msgexec.1 msgfilter.1 \ msggrep.1 msginit.1 msguniq.1 \ recode-sr-latin.1 +man_MAN1WIZARD = \ +gettextize.1 man_MAN1MISC = \ -gettextize.1 autopoint.1 -man_MAN1 = $(man_MAN1SRC) $(man_MAN1MISC) +autopoint.1 +man_MAN1 = $(man_MAN1SRC) $(man_MAN1WIZARD) $(man_MAN1MISC) man_MANS = $(man_MAN1) man_HTML = \ @@ -118,13 +120,18 @@ msginit.1: msginit.x ../src/msginit.c msguniq.1: msguniq.x ../src/msguniq.c recode-sr-latin.1: recode-sr-latin.x ../src/recode-sr-latin.c +$(man_MAN1WIZARD): help2man $(top_srcdir)/../.version + progname=`echo $@ | sed -e 's/\.in$$//' -e 's/\.1$$//'`; \ + IN_HELP2MAN=1 $(SHELL) x-to-1 $(UPDATEMODE) "$(PERL)" "$(HELP2MAN)" \ + ../wizard/$${progname}$(EXEEXT) $(srcdir)/$${progname}.x $@ + +gettextize.1: gettextize.x ../wizard/gettextize.in + $(man_MAN1MISC): help2man $(top_srcdir)/../.version progname=`echo $@ | sed -e 's/\.in$$//' -e 's/\.1$$//'`; \ - if test "$$progname" = autopoint; then option='--version-option=--version-without-config'; else option=''; fi; \ - IN_HELP2MAN=1 $(SHELL) x-to-1 $(UPDATEMODE) "$(PERL)" "$(HELP2MAN) $$option" \ + IN_HELP2MAN=1 $(SHELL) x-to-1 $(UPDATEMODE) "$(PERL)" "$(HELP2MAN) --version-option=--version-without-config" \ ../misc/$${progname}$(EXEEXT) $(srcdir)/$${progname}.x $@ -gettextize.1: gettextize.x ../misc/gettextize.in autopoint.1: autopoint.x ../misc/autopoint.in diff --git a/gettext-tools/misc/Makefile.am b/gettext-tools/misc/Makefile.am index 87fa7806b..3156bb12b 100644 --- a/gettext-tools/misc/Makefile.am +++ b/gettext-tools/misc/Makefile.am @@ -1,6 +1,5 @@ ## Makefile for the gettext-tools/misc subdirectory of GNU gettext -## Copyright (C) 1995-1997, 2000-2003, 2005-2007, 2009-2010, 2019-2021 Free -## Software Foundation, Inc. +## Copyright (C) 1995-2025 Free Software Foundation, Inc. ## ## This program is free software: you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -26,9 +25,9 @@ DISTCLEANFILES = # Scripts for maintainers. -bin_SCRIPTS = gettextize autopoint +bin_SCRIPTS = autopoint -DISTCLEANFILES += gettextize autopoint convert-archive +DISTCLEANFILES += autopoint convert-archive CLEANFILES += \ archive.dir.tar.gz \ @@ -99,10 +98,3 @@ archive.git.tar.gz: $(srcdir)/archive.dir.tar # The archive.cvs.tar.gz is generated from archive.dir.tar. archive.cvs.tar.gz: $(srcdir)/archive.dir.tar ./convert-archive dir cvs '$(srcdir)'/archive.dir.tar $@ - - -# We don't install the source code in unpacked form any more. -install-data-local: uninstall-sources -uninstall-local: uninstall-sources -uninstall-sources: - rm -rf $(DESTDIR)$(datadir)/gettext/intl diff --git a/gettext-tools/wizard/Makefile.am b/gettext-tools/wizard/Makefile.am new file mode 100644 index 000000000..f4f47c7ba --- /dev/null +++ b/gettext-tools/wizard/Makefile.am @@ -0,0 +1,37 @@ +## Makefile for the gettext-tools/wizard subdirectory of GNU gettext +## Copyright (C) 1995-2025 Free Software Foundation, Inc. +## +## This program is free software: you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 3 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program. If not, see . + +## Process this file with automake to produce Makefile.in. + +AUTOMAKE_OPTIONS = 1.2 gnits +EXTRA_DIST = +MOSTLYCLEANFILES = +CLEANFILES = +DISTCLEANFILES = + + +# Scripts for maintainers. + +bin_SCRIPTS = gettextize + +DISTCLEANFILES += gettextize + + +# We don't install the source code in unpacked form any more. +install-data-local: uninstall-sources +uninstall-local: uninstall-sources +uninstall-sources: + rm -rf $(DESTDIR)$(datadir)/gettext/intl diff --git a/gettext-tools/misc/gettextize.in b/gettext-tools/wizard/gettextize.in similarity index 100% rename from gettext-tools/misc/gettextize.in rename to gettext-tools/wizard/gettextize.in