This is the mail archive of the cygwin@cygwin.com 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: chmod again


On Tue, 15 Apr 2003, John Williams wrote:

> Hi there,
>
> Building a (cross-platform) uClinux kernel under Cygwin I stike a
> variant of the Cygwin chmod issue:
>
> The build process is to make the kernel, make the libs, make the user
> apps, then copy everything into a directory and run the utility genromfs
> over it.  This makes a romfs image of the file system which gets
> appended to the kernel and uploaded to the target board, ready to run.
>
> Here's the catch: the compiled and linked user executables coming out of
> my toolchain don't have the execute permissions set.  genromfs
> faithfully mirrors the file permissions, meaning that my user
> executables can't be exec'ed when my board boots up, failing because (of
> course) the files don't have execute permission.
>
> So, I naively tried to just do a chmod 777 on all of my user binaries
> then run genromfs over it, but chmod doesn't actually do anything, the
> permissions stay unchanged, as illustrated by the following log:
>
> jwilliams at G435-9029 /cygdrive/d/uClinux-dist/user/init
> $ ls -alrt init
> -rw-r--r--    1 jwilliam mkgroup_    27984 Apr 15 11:45 init
>
> jwilliams at G435-9029 /cygdrive/d/uClinux-dist/user/init
> $ chmod 777 init
>
> jwilliams at G435-9029 /cygdrive/d/uClinux-dist/user/init
> $ ls -alrt init
> -rw-r--r--    1 jwilliam mkgroup_    27984 Apr 15 11:45 init
>
> I've checked the FAQ and tried the CYGWIN variable settings ntsec and
> nontsec, but it has no effect in the example presented above.
>
> How can I force Cygwin to get these permissions right?
>
> Thanks,
> John

John,

First off, make sure your /etc/passwd and /etc/group are up to date (see
<http://cygwin.com/cygwin-ug-net/ntsec.html#NTSEC-RELEASE1.3.20>).

Second, you might wish to attach the output of "cygcheck -svr", as per
<http://cygwin.com/bugs.html>.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha at cs dot nyu dot edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor at watson dot ibm dot com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Knowledge is an unending adventure at the edge of uncertainty.
  -- Leto II


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


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