XBoard (GtkBoard?) pre-alpha

Discussion of chess software programming and technical issues.

Moderators: hgm, Dann Corbit, Harvey Williamson

JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: XBoard (GtkBoard?) pre-alpha

Post by JoshPettus »

GAH! you're right! it was right there. Weird some quirk of macports required a separate x11 folder over there. A simple simlink did it. Thank-you!
Sven
Posts: 4052
Joined: Thu May 15, 2008 9:57 pm
Location: Berlin, Germany
Full name: Sven Schüle

Re: XBoard (GtkBoard?) pre-alpha

Post by Sven »

JoshPettus wrote:GAH! you're right! it was right there. Weird some quirk of macports required a separate x11 folder over there. A simple simlink did it. Thank-you!
Nice!

@HGM: I suggest that you (resp. Arun) check why configure did not detect that problem. It should never have printed

Code: Select all

checking X11/Xaw/Dialog.h usability... yes
checking X11/Xaw/Dialog.h presence... yes
checking for X11/Xaw/Dialog.h... yes
but later on generate a makefile that does not have the -I /usr/X11/include (or /opt/X11/include) in the build rules, that looks inconsistent. The purpose of "configure" is to create a working makefile if everything is installed properly, and to complain if it isn't. Saying "Dialog.h is present" would imply that the file is where it will be expected by the compiler with the configured command line. There might be some tiny detail in the "configure.ac" (or even in the autoconf tool?!) that makes trouble.

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

Re: XBoard (GtkBoard?) pre-alpha

Post by hgm »

Arun suggests the following:


In the check for presence we use (amongst others) X_CFLAGS as compiler argument, but it is not used later when we actually compile XBoard. So if the include directories are specified in that variable, ./configure would say they are present, but the compiler would not be told where they were.

Can you add the two lines

Code: Select all

echo " x_cflags $X_CFLAGS"
echo " x_lib $X_LIBS"
at the end of configure.ac, and run the autoconf process again to see what it prints for the value of these variables? On Arun's machine they are empty, meaning that nothing is missed by leaving them out in the compile command.

In case they are not empty, you should add @X_CFLAGS@ in the list of AM_CPPFLAGS in Makefile.am to correct the situation (i.e. make gcc use these flags too when compiling XBoard).

One more remark:

to get verbose output, there is no need to edit the Makefile to remove any @, but you could simply give the command

make V=1
JoshPettus
Posts: 730
Joined: Fri Oct 19, 2012 2:23 am

Re: XBoard (GtkBoard?) pre-alpha

Post by JoshPettus »

Sure thing, it actually wasn't empty. I got

Code: Select all

 x_cflags  -I/usr/X11/include
 x_lib -lXpm  -lSM -lICE  -L/usr/X11/lib -R/usr/X11/lib  -lXmu -lX11 -lXt 
And for the make part i got

Code: Select all

depbase=`echo xaw/xboard.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
	gcc -DHAVE_CONFIG_H -I.  -DINFODIR='"/usr/local/share/info"'  -I/usr/X11/include -D_REENTRANT -I/opt/local/include/cairo -I/opt/local/include/glib-2.0 -I/opt/local/lib/glib-2.0/include -I/opt/local/include -I/opt/local/include/pixman-1 -I/opt/local/include/freetype2 -I/opt/local/include/libpng15 -I/opt/local/include/librsvg-2.0 -I/opt/local/include/gdk-pixbuf-2.0     -DSYSCONFDIR='"/usr/local/etc"' -DLOCALEDIR='"/usr/local/share/locale"' -DSVGDIR='"/usr/local/share/games/xboard/themes/default"' -I xaw -DX11   -Wall -Wno-parentheses -MT xaw/xboard.o -MD -MP -MF $depbase.Tpo -c -o xaw/xboard.o xaw/xboard.c &&\
	mv -f $depbase.Tpo $depbase.Po
xaw/xboard.c: In function ‘InitializeFonts’:
xaw/xboard.c:919: warning: unused variable ‘vTo’
for the xboard.c part. So looks to me like it worked!
User avatar
hgm
Posts: 27701
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: XBoard (GtkBoard?) pre-alpha

Post by hgm »

OK, so we will fix it this way in he distribution then!