mktemp behaviour (coreutils vs. busybox)

Robert betulichergutmensch at googlemail.com
Tue Jun 15 22:06:51 UTC 2010


Kind greetings from a new ML member ;-)

Forgive me if I'm reviving an old topic but ML search did not reveal
anything related to that topic. I wondered today whether the busybox
mktemp(b) and the GNU coreutils mktemp(c) (b and c just as abbr.) have a
different behaviour.

mktemp(c) states the options -t and -p as deprecated and mktemp(b) only
works like mktemp(c), when the option -t is specified.

Example:

$ mktemp(c)
/tmp/tmp.8fM3VmH3PF

$ mktemp(b)
tmp.DqP4t2

$ mktemp(b) -t
/tmp/tmp.Amsp3O

Is there any special intention about that difference? As coreutils
states -t and -p as deprecated I would prefer to not writing scripts
with the -t option (when that might lead to an error in the future).
Would it be possible to change the default behaviour of mktemp(b) to use
the absolute path of the /tmp/ folder like it is in coreutils?

Best regards,
Robert


More information about the busybox mailing list