Subject: Beta 18 bash will complain if /tmp is missing
From: [email-masked] (Geoffrey Noer)

17 Apr 1997 16:32:04 -0700
Approved: [email-masked]
Distribution: cygnus
Message-ID: <[email-masked]>
Content-Type: text
Original-To: [email-masked]
Original-Cc: [email-masked] (Geoffrey Noer)
In-Reply-To: <[email-masked]> from "Wade Richards" at Apr 16, 97 11:59:10 pm
X-Mailer: ELM [version 2.4 PL23]
Original-Sender: [email-masked]

I was asked:

> I noticed that this list doens't include the most popular FAQ problem.  Have
> you done anything about bash and it's need for /tmp for this build?  
> 
> If not, I'll send in a simplistic patch (just have bash.exe check for /tmp
> on startup, and complain if it doesn't exist).

Yeah, this should be done.  I just added the following at the beginning of
main() in bash/shell.c which seems to do the trick:

#ifdef __CYGWIN32__
  /* verify that /tmp exists, complain if it doesn't */
  {
    struct stat statbuf;
    if (stat ("/tmp", &statbuf) < 0)
      {
        printf("WARNING: bash couldn't find /tmp, please create one!\n");
      } 
    else /* stat succeeded */
      {
        if (!S_ISDIR (statbuf.st_mode))
          printf("WARNING: bash needs /tmp to be a valid directory!\n");
      }
  }
#endif __CYGWIN32__

-- 
Geoffrey Noer
[email-masked]
-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".