Re: EuApp
- Posted by jimcbrown (admin) Apr 24, 2016
- 1508 views
I took a quick look, and that package inclues a 32 bit shared library (.so), which is why it won't work on 64 bits.
README say
euApp uses a slightly modified version of GraphApp 3.48 called libeuapp.so
The source for libeuapp.so does not seem to be available.
GraphApp itself is open-source though ( see http://enchantia.com/software/graphapp/package/about/LICENCE.TXT ), so perhaps someone could attempt to reconstruct it.
I tried this. I grabbed the source and built a 32bit version of GraphApp using make dynamic (using /usr/share/apps/font as the font dir which I pulled out of libeuapp.so). I then started ex01.exu and it came up. (Had to rename switch() in ex01.exu to sswitch() and GraphApp.eu defined get_image_area() twice for some reason, but after that it came up.) So no mods necessary....
I then tried to build GraphApp on 64bits. It took some work to build, I got a weird error on x11/timer.c (something about %rcx and l being the wrong size) and had to use the BSD version of sleep, and I had to edit the Makefile to make it build everything with fPIC. (Seeing that GraphApp was last updated in 2005, I suspect that it may not have been tried on 64 bits before.)
I got it to build eventually, and with more makefile tweaking I was able to build and run the GraphApp smiley demo (the C one).
64bit eu won't run any eugraphapp demos though. I get a BadValue from libX11 (Protocol request 1, minor request code 0, resource id 0x0, integer parameter out of range for operation).
I tracked this down to the passing of Rect structures to the C code. It's a structure passed by value instead of a pointer. The eu code just passes down 4 ints.
Not sure why this trick works fine on 32bit but not on 64bit.
If I hack the C code to explicitly pass the rect value as 4 integers (instead of a single Rect struct parameter), then I can get a window to pop up.