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.
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.
The patch has been tested with genkernel-3.3.11d
Fixed in 3.4.0_pre1, thanks.