Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 132408

Summary: Genkernel handles --tempdir wrong
Product: Gentoo Hosted Projects Reporter: Martin Parm <parmus>
Component: genkernelAssignee: Gentoo Genkernel Maintainers <genkernel>
Status: RESOLVED FIXED    
Severity: normal Keywords: InVCS
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: Fixes for --tempdir handling

Description Martin Parm 2006-05-06 00:20:13 UTC
Genkernel has two minor problems with --tempdir
1) Setting --tempdir only changed the TEMP variable, so code using the TMPDIR will still use the default location
2) TEMP is set before commandline parameter are evaluated. So it's not enough just to change TEMP to TMPDIR in parse_cmdline().

This bug is a minor issue for most users, but it's a show-stopper for using genkernel in a sandboxed environment or if the default TMPDIR location (/var/tmp/) is read-only or short of space.
Comment 1 Martin Parm 2006-05-06 00:24:22 UTC
Created attachment 86237 [details, diff]
Fixes for --tempdir handling

This patch fixes the --tempdir handling.

The first part of the patch (gen_cmdline.sh) fixes the problem itself.

The second part (genkernel) is a cosmetic change, which make the evaluation order more clear. Having TEMP set after sourcing gen_cmdline.sh can be misleading.
Comment 2 Martin Parm 2006-05-06 00:29:09 UTC
The patch has been tested with genkernel-3.3.11d
Comment 3 Tim Yamin (RETIRED) gentoo-dev 2006-06-20 12:55:44 UTC
Fixed in 3.4.0_pre1, thanks.