Question

I'm looking for a way to programatically set the 'executable' bit on a file on OS X. I don't want to invoke 'chmod a+x' but I want the same effect as the chmod call. Any suggestions? A carbon API or any other C/C++ function would work...

Was it helpful?

Solution

See chmod(2), e.g. http://www.manpagez.com/man/2/chmod/osx-10.4.php (I think it's unchanged in 10.5).

OTHER TIPS

There is a "chmod" C library call. Go to a terminal window and type "man 2 chmod".

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top