From: noer AT cygnus DOT com (Geoffrey Noer) Subject: Beta 18 bash will complain if /tmp is missing 17 Apr 1997 16:32:04 -0700 Approved: cygnus DOT gnu-win32 AT cygnus DOT com Distribution: cygnus Message-ID: <199704171813.LAA03355.cygnus.gnu-win32@cirdan.cygnus.com> Content-Type: text Original-To: gnu-win32 AT cygnus DOT com Original-Cc: noer AT cygnus DOT com (Geoffrey Noer) In-Reply-To: <1.5.4.32.19970417065910.006983e0@mail.direct.ca> from "Wade Richards" at Apr 16, 97 11:59:10 pm X-Mailer: ELM [version 2.4 PL23] Original-Sender: owner-gnu-win32 AT cygnus DOT com 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 noer AT cygnus DOT com - For help on using this list (especially unsubscribing), send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".