GNOME Bugzilla – Bug 132858
glib-gettextize doesn't work with automake-1.8
Last modified: 2011-02-18 16:07:52 UTC
The Makefile.in.in that is installed by glib-gettextize refers to $(top_srcdir)/mkinstalldirs but this file is not installed by automake-1.8. This causes 'make install' to break in the po directory for any projects that use glib-gettextize and are built using automake-1.8.
The best solution is probably to use $(mkinstalldirs) as defined by automake instead of using $(top_srcdir)/@MKINSTALLDIRS@ as it is done now. Even automake-1.8 defines $(mkinstalldirs) so this should fix it for all versions.
Sorry, but of course this can't work since Makefile.in.in isn't under control of automake. Perhaps that's the basic problem here...
FYI: automake-1.8 defines $(mkinstalldirs) to @mkdir_p@ which is substituted to "mkdir -p -- ." by configure. Perhaps that's a possible solution.
Created attachment 25890 [details] [review] glib-mkinstalldirs.patch
Attached patch works for me with automake 1.8, glib 2.2.3 and make distcheck in test package.
Probably, better solution will be to install ./mkinstalldirs in glib-gettextize (gettextize do it). That will help to avoid problems with other files, that use mkinstalldirs, like omf.make and xmldocs.make
*** Bug 140176 has been marked as a duplicate of this bug. ***
*** Bug 138538 has been marked as a duplicate of this bug. ***
The attached patch relies on substitutions created when you call Automake-1.8's AM_INIT_AUTOMAKE (@mkdir_p@ comes from AM_PROG_MKDIR_P which is called by AM_INIT_AUTOMAKE). Given that this problem was caused by glib-gettextize relying on something the Automake maintainers considered a side effect rather than a published API (ie. "automake --add-missing" installs mkinstalldirs), I wouldn't check this in. Also, automake < 1.8 doesn't define @mkdir_p@, so the patch will break glib-gettextize's Makefile.in.in when used with older Automakes (such as the one glib and GTK are using ...). The two possible solutions are: 1. Get glib-gettextize to install mkinstalldirs. This is what gettext's gettextize does. 2. swipe the macro that defines @mkdir_p@ and integrate it into AM_GLIB_GNU_GETTEXT (using different subst name, so as to not cause a clash) then adjust Makefile.in.in similar to how Stanislav did in his patch. The latest version of automake's macro is at: http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/automake/automake/m4/mkdirp.m4
Created attachment 27413 [details] [review] glib-gettextize.patch A minimal patch that gets glib-gettextize to install mkinstalldirs. Adapted from upstream gettextize.
*** Bug 145308 has been marked as a duplicate of this bug. ***
*** Bug 141463 has been marked as a duplicate of this bug. ***