Any Mac GUI programmers?

Discussion of chess software programming and technical issues.

Moderator: Ras

MikeAtBookup
Posts: 8
Joined: Fri Jun 14, 2013 7:45 pm

Any Mac GUI programmers?

Post by MikeAtBookup »

The new Macintosh version of Chess Openings Wizard is almost complete but I cannot get chess engines to run inside the app's bundle.

I downloaded Stockfish from the Mac app store. Its bundle has the usual Contents/Resources folder which contains three engines. The Mac Finder says the engines are Unix executables.

In contrast, when I look inside my app's bundle (where I've placed the same engines) those engines appear as generic documents.

NSTask.launch throws an exception with "launch path not accessible" when I try to run Stockfish from my app's bundle.

My app runs Stockfish just fine from a regular folder.

Is anyone an OSX entitlements guru? This is my first attempt at a Mac app in 20 years so I'm sure I'm missing something basic.
Mike Leahy
www.bookup.com
User avatar
stegemma
Posts: 859
Joined: Mon Aug 10, 2009 10:05 pm
Location: Italy
Full name: Stefano Gemma

Re: Any Mac GUI programmers?

Post by stegemma »

I'm not a MAC guru but maybe you need to run "chmod a+x file" on the engine executables?
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: Any Mac GUI programmers?

Post by JoshPettus »

It does indeed sound like permissions issues.

sudo chmod +X whateverDirectory/stockfish marking as an executable should do it. if not, a simple
sudo chmod 755 whateverDirectory/stockfish to be sure.