This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: "Permission denied" on /usr/bin/sh when running gmake with multiple jobs

Hi Corinna,

I was using a "gmake" not the cygwin "make", and that was generating the
windows path. I've moved over to the cygwin supplied make and fixed up all
the relevant environment variables. No windows paths anymore but I'm still
getting the permission problem.

None of the scripts are created dynamically.

I'd tried strace before, but didn't really know how to interpret the output
or locate the relevant bits. (is there an article that describes the

I've run the make again under strace and posted the output of both strace
and make (I couldn't find how to have the output of both go to the same
file) to Would it be too much to ask that
you take a look?

Thanks for your help,


-----Original Message-----
From: Corinna Vinschen [] 
Sent: 29 October 2009 13:39
Subject: Re: "Permission denied" on /usr/bin/sh when running gmake with
multiple jobs

On Oct 29 11:25, John Daintree wrote:
> Can you shed some light on
> I may need to get my local cygwin build working to investigate this

>> "J:\trunk\svn\apl\win\bin\mk_cc:
>> /cygdrive/j/trunk/svn/apl/allos/bin/verbose: /usr/bin/sh: bad
>> Permission denied"

Where's this Windows path coming from?  Are you sure you're using only
Cygwin tools?  If so, get rid of the Win32 path and use either the
matching /cygdrive path, or mount (the relevant subtree of) drive J to
some other POSIX path.

The permission denied is probably not the permission of sh itself, but
the permissions of the script.  It's lacking execute permissions,
perhaps.  If the script gets generated during the make run, it might
be a race.  One job tries to use the script before another job has
run chmod on the script.

Instead of building your own debug version of Cygwin, you could also
just start with stracing your make runs and see what happens when the
script access fails.


Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

Problem reports:
Unsubscribe info:

Problem reports:
Unsubscribe info:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]