[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Building/Compiling game xonix without X11 for console only



Hi,

How to play this game?

Thanks,
Markos

On 26-03-2014 13:35, Hörmetjan Yiltiz wrote:
Hi,

I like `xonix' quite a lot. This game is so fun!

But I prefer to play it from the console, rather than in an X window. The game originally written without X11 support. Here is man page xonix(6x):

The original xonix game has been seen somewhere on an old PC/XT  clone.
       This  is  a  reimplementation  from  scratch, done by Torsten Schoenitz
       starting the project on a Macintosh.  The X11 support has been  written
       by Joerg Wunsch with the pleasant help by Alfredo Herrera Hernandez.

I tried this:

$ apt-get source xonix
$ cd ./xonix-1.4/
$ ln -s ./Makefile.std ./Makefile  
$ #'cuz `make' looks for Makefile, without .std extention

This does not compile, since I did not run the following:
$ sudo apt-get build-dep xonix

And since I am not building for X11, I actually do not need (most) of those dependencies! So I am not installing them.

Question is:
In the Makefile.std, a MACRO called USE_X11 was defined. Which was also defined in xonix.h. I tried to fix Makefile.std into this:

#EXTRA_DEFINES=    -DUSE_X11="0" -DXONIXDIR=\"$(XONIXDIR)\" $(CUTE)
EXTRA_DEFINES=    -DXONIXDIR=\"$(XONIXDIR)\"


And then run `make'.
Here is the output:

make: *** No rule to make target `/usr/X11R6/include/X11/Xos.h', needed by `xonix.o'.  Stop.


Or I tried building directly calling gcc:
gcc -UUSE_X11 ./xonix.c
In file included from ./xonix.c:42:0:
./xonix.h:171:1: error: unknown type name ‘Boolean’
 extern Boolean      gQuit,                  /* Wenn gQuit auf true gesetzt  */
 ^

In the code, it was said that the <X11/Xos.h> provides Boolean.

So, how to build this little piece of game without X11 support?


​ Best,
========================
He who is worthy to receive his days and nights is worthy to receive* all
else* from you (and me).
                                                 The Prophet, Gibran Kahlil




Reply to: