Jim Meyering writes:
> Just to be clear: we're taking this slightly kludgey alternative
> solely to accommodate theoretical non-POSIX systems.
Well, no, it's for POSIX systems too. POSIX says that if you clear all
environment variables, the resulting behavior need not conform to POSIX
any more.
Eric Blake wrote:
> On 04/06/2010 11:26 AM, Jim Meyering wrote:
>>> Even 'env -i' is risky, since you are removing other possibly-important
>>> variables, like POSIXLY_CORRECT. Isn't it better to just do:
>>>
>>> d=`unset TMPDIR; mktemp -d ...`
>>>
>>> and bypass env altogether?
>>
>> Yes, that re
On 04/06/2010 11:26 AM, Jim Meyering wrote:
>> Even 'env -i' is risky, since you are removing other possibly-important
>> variables, like POSIXLY_CORRECT. Isn't it better to just do:
>>
>> d=`unset TMPDIR; mktemp -d ...`
>>
>> and bypass env altogether?
>
> Yes, that reminds me of your reporting
Eric Blake wrote:
> On 04/06/2010 09:36 AM, Jim Meyering wrote:
>> FYI,
>> I noticed unnecessary mktemp simulation in test logs on Solaris 5.11.
>> This fixes it:
>>
>># First, try to use mktemp.
>> - d=`env -u TMPDIR mktemp -d -t -p "$destdir_" "$template_" 2>/dev/null` \
>> + d=`env -i PAT
On 04/06/2010 09:36 AM, Jim Meyering wrote:
> FYI,
> I noticed unnecessary mktemp simulation in test logs on Solaris 5.11.
> This fixes it:
>
># First, try to use mktemp.
> - d=`env -u TMPDIR mktemp -d -t -p "$destdir_" "$template_" 2>/dev/null` \
> + d=`env -i PATH="$PATH" mktemp -d -t -p "
FYI,
I noticed unnecessary mktemp simulation in test logs on Solaris 5.11.
This fixes it:
>From 5fae8b2c1ede890005a55067b1f6630b114f112d Mon Sep 17 00:00:00 2001
From: Jim Meyering
Date: Tue, 6 Apr 2010 17:33:51 +0200
Subject: [PATCH] init.sh: portability fix: use env's POSIX-specified -