OSX Xboard 4.7.2 .app

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: OSX Xboard 4.7.2 .app

Post by hgm »

Ah yes, it doesn't like that DATADIR is #defined as a variable in the OS X build: concatenation in C only works between string constants (like "xxx" "yyy" to indicate "xxxyyy"). So I had to combine the strings with an snprintf in a temporary buffer again.

The latter two points are now fixed in hgm.nubati.net (also in v4.7.x).

If I understand the configure problem correctly, you say that these extra 10.6 arguments were only needed for you, because you wanted to do a 'cross build' for 10.6 on a higher system? I guess I should ask Arun than to make an extra configure argument to force such a cross build, to make your life easier.
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: OSX Xboard 4.7.2 .app

Post by JoshPettus »

Great! I'll give it a try when I'm done resetting my environment. Apparently GTK wouldn't build on 10.5. Oh well, it was worth a shot. (doesn't bode well for my 10.4 PPC dreams ;))

About Arun making my life easier, that's alright. I wouldn't want to make things difficult for anyone else by demanding that they go acquire the 10.6sdk to build xboard. And it's small potatoes to copy paste the line from my building notes textfile.

./configure --with-gtk --enable-zippy LDFLAGS="-mmacosx-min-version=10.6 -isysroot /Developer/SDKs/MacOSX10.6.sdk"
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: OSX Xboard 4.7.2 .app

Post by JoshPettus »

hmm didn't find -lgtkmacinegration even before i made the change to the configure.ac. I'm not sure whats going on there.
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: OSX Xboard 4.7.2 .app

Post by JoshPettus »

I got good news and bad news.

Goodnews Since you redid all of the code the -headerpad_max_install_names flag is no longer necessary for dylibbuilder to relink the libs. So we should get rid of that in config.ac as well as figure out why -lgtkmacintegration isn't being found as it is written. :\

The bad news is that I'm not sure why, but it's no longer parsing ~~/ as an option. it's not reading -pieceImageDirectory "~~/../Resources/share/xboard/textures/default" in the conf file and when i try to put that in the command line after xboard directly it doesn't work either. Unless it's not finding the .conf file altogether...

Also now that we are pointing to fairymax with an absolute directory it doesn't find it's fmax.ini anymore. (as that use to be relative too) Is there a way to put in the .ini data staticly into the binary or do what we are doing with xboard for it.
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: OSX Xboard 4.7.2 .app

Post by JoshPettus »

I realized I can just use a little launch script for fairymax. Like the ones I used for man and info.

[EDIT] So that worked for fairymax so it must have found the .conf file if it knows where it is and to launch it. Now I have to figure out why it's not working for -pid
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: OSX Xboard 4.7.2 .app

Post by JoshPettus »

OK nvm it's not finding the conf file either. It found fairymax through some compiled setting you had. :( I'm not sure why it doesn't find xboard.conf
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: OSX Xboard 4.7.2 .app

Post by JoshPettus »

Damn it that's right! I forgot
thanks to that command in the integration library
~~/ points to the bundle root directory, not the executable directory i.e.
*/xboard.app/ not */xboard.app/Contents/MacOS/
Ergo,
datadir needs to be
~~/Contents/Resources/etc rather then ~~/../Resources/etc

I have to do a bunch of modifying in the xboard.conf
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: OSX Xboard 4.7.2 .app

Post by hgm »

When you run

xboard --show-config Datadir

it should print what ~~ is.

I am not sure how you compile Fairy-Max. The Makefile assumes Linux, and defines the path to the fmax.ini file accordingly. But it seems that what you really would like is where it just uses ./fmax.ini, i.e. in its own directory, like in windows. Or perhaps relative to its own directory.

Btw, when you want to start Fairy-Max in a certain directory, you don't need a launch script, but you need to install it in XBoard with an -fd command. This could use ~~ to be specified relative to the bundle.
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: OSX Xboard 4.7.2 .app

Post by JoshPettus »

Yup that was it.
So in short we need to:

Change the conf dir to %s/Contents/Resources/etc
edit the configure.ac figure out why -lgtkmacintegration lib isn't found and remove the -headerpad_max_install_names.

You were right about fairymax. Now that I know what ~~ is it worked just fine is is with fd set.
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: OSX Xboard 4.7.2 .app

Post by JoshPettus »

I'm debating as to what to call the version for this app bundle. As it's not exactly 4.7.3. should i call it 4.7.3+? Or just call it by your master branch name? What would you prefer?