Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 439636 - dev-util/catalyst: should not clean out /usr/share/gettext in stage1
Summary: dev-util/catalyst: should not clean out /usr/share/gettext in stage1
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: Catalyst (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Catalyst Developers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-25 16:27 UTC by Anthony Basile
Modified: 2012-10-29 21:20 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Anthony Basile gentoo-dev 2012-10-25 16:27:38 UTC
The problem comes in stage3 when you have packages that inherit autotools.eclass.  That eclass makes use of gettext (if it exists) and run autopoint which will fail if it doesn't find /usr/share/gettext/archive.dir.tar.gz.

The fix is to remove /usr/share/gettext from the list of stage1 cleanables.  I'll inline the patch:

diff -Naur catalyst-2.0.11.orig/modules/stage1_target.py catalyst-2.0.11/modules/stage1_target.py
--- catalyst-2.0.11.orig/modules/stage1_target.py	2012-09-08 17:38:02.000000000 -0400
+++ catalyst-2.0.11/modules/stage1_target.py	2012-10-25 12:20:39.000000000 -0400
@@ -28,7 +28,7 @@
 	
 	def set_cleanables(self):
 		generic_stage_target.set_cleanables(self)
-		self.settings["cleanables"].extend(["/usr/share/gettext",\
+		self.settings["cleanables"].extend([\
 		"/usr/lib/python2.2/test", "/usr/lib/python2.2/email",\
 		"/usr/lib/python2.2/lib-tk", "/usr/lib/python2.3/test",\
 		"/usr/lib/python2.3/email", "/usr/lib/python2.3/lib-tk",\
Comment 1 Rick Farina (Zero_Chaos) gentoo-dev 2012-10-25 17:14:53 UTC
I'm curious how I've never hit this, can you please provide a sample error if possible?
Comment 2 Anthony Basile gentoo-dev 2012-10-25 19:14:22 UTC
This is happening on a uclibc system where the dependencies are different.  Nonetheless it can happen on any system because autotools.eclass thinks gettext is installed and assumes autopoint is working.  But autopoint is broken because catalyst stage1 removed /usr/share/gettext/*

I lost the autopoint.out (of course I can regenerate it), but here's the error from portage:

>>>  '/var/tmp/portage/sys-apps/util-linux-2.21.2/temp/build.log'
 * Package:    sys-apps/util-linux-2.21.2
 * Repository: gentoo
 * USE:        amd64 cramfs crypt elibc_uclibc kernel_linux ncurses uclibc unicode userland_GNU
 * FEATURES:   sandbox
 * Applying util-linux-2.21.1-no-printf-alloc.patch ...
 [ ok ]
 * Running eautoreconf in '/var/tmp/portage/sys-apps/util-linux-2.21.2/work/util-linux-2.21.2' ...
 * Running autopoint --force ...
 [ !! ]

 * Failed Running autopoint !
 * 
 * Include in your bugreport the contents of:
 * 
 *   /var/tmp/portage/sys-apps/util-linux-2.21.2/temp/autopoint.out

 * ERROR: sys-apps/util-linux-2.21.2 failed (prepare phase):
 *   Failed Running autopoint !
 * 
 * Call stack:
 *     ebuild.sh, line   85:  Called src_prepare
 *   environment, line 3191:  Called eautoreconf
 *   environment, line  945:  Called autotools_run_tool '--at-missing' 'autopoint' '--force'
 *   environment, line  726:  Called die
 * The specific snippet of code:
 *           die "Failed Running $1 !";
 * 
 * If you need support, post the output of `emerge --info '=sys-apps/util-linux-2.21.2'`,
 * the complete build log and the output of `emerge -pqv '=sys-apps/util-linux-2.21.2'`.
/usr/lib/portage/bin/isolated-functions.sh: line 214: wait: `Failed Running autopoint !': not a pid or valid job spec
 * The complete build log is located at '/var/tmp/portage/sys-apps/util-linux-2.21.2/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-apps/util-linux-2.21.2/temp/environment'.
 * Working directory: '/var/tmp/portage/sys-apps/util-linux-2.21.2/work/util-linux-2.21.2'
 * S: '/var/tmp/portage/sys-apps/util-linux-2.21.2/work/util-linux-2.21.2'
Comment 3 Anthony Basile gentoo-dev 2012-10-25 19:33:50 UTC
Here's autopoint.out

cat /var/tmp/portage/sys-apps/util-linux-2.21.2/temp/autopoint.out
***** autopoint *****
***** PWD: /var/tmp/portage/sys-apps/util-linux-2.21.2/work/util-linux-2.21.2
***** autopoint --force

/usr/bin/autopoint: line 393: /usr/share/gettext/archive.dir.tar.gz: No such file or directory
tar: This does not look like a tar archive
tar: gettext-0.14.1: Not found in archive
tar: Exiting with failure status due to previous errors
autopoint: *** infrastructure files for version 0.14.1 not found; this is autopoint from GNU gettext-tools 0.18.1
autopoint: *** Stop.