Allegro.cc - Online Community

Allegro.cc Forums » Installation, Setup & Configuration » Allegro/Fbend+Linux

This thread is locked; no one can reply to it. rss feed Print
Allegro/Fbend+Linux
hazul
Member #4,338
February 2004
avatar

I've installed gentoo instead of my old red hat, and I've installed allegro. I'm now trying to install FBlend, but here's what happens...

1bash-2.05b$ sh ./fix.sh unix
2Configuring FBlend for gcc...
3Done! Now run make to start the compilation.
4bash-2.05b$ make
5echo Testing for MMX assembler support...
6Testing for MMX assembler support...
7make mmxtest --quiet
8Testing for SSE assembler support...
9make ssetest --quiet
10gcc -c src/cadd.c -o obj/unix/release/cadd.o -O2 -ffast-math -fomit-frame-pointer -Iinclude
11gcc -c src/ctrans.c -o obj/unix/release/ctrans.o -O2 -ffast-math -fomit-frame-pointer -Iinclude
12gcc -c src/radd.c -o obj/unix/release/radd.o -O2 -ffast-math -fomit-frame-pointer -Iinclude
13gcc -c src/rtrans.c -o obj/unix/release/rtrans.o -O2 -ffast-math -fomit-frame-pointer -Iinclude
14gcc -c src/2xstretch.c -o obj/unix/release/2xstretch.o -O2 -ffast-math -fomit-frame-pointer -Iinclude
15gcc src/asmdef.c -o obj/unix/asmdef -I. -I./include
16obj/unix/asmdef obj/unix/asmdef.inc
17writing structure offsets into obj/unix/asmdef.inc...
18gcc -x assembler-with-cpp -c src/x86/cadd16.s -o obj/unix/release/x86/cadd16.o -I. -Isrc -Iinclude
19gcc -x assembler-with-cpp -c src/x86/cadd15.s -o obj/unix/release/x86/cadd15.o -I. -Isrc -Iinclude
20gcc -x assembler-with-cpp -c src/x86/cadd32.s -o obj/unix/release/x86/cadd32.o -I. -Isrc -Iinclude
21gcc -x assembler-with-cpp -c src/x86/trans16.s -o obj/unix/release/x86/trans16.o -I. -Isrc -Iinclude
22In file included from src/x86/trans16.s:15:
23src/x86/trans.inc:128:7: warning: no newline at end of file
24gcc -x assembler-with-cpp -c src/x86/trans15.s -o obj/unix/release/x86/trans15.o -I. -Isrc -Iinclude
25In file included from src/x86/trans15.s:15:
26src/x86/trans.inc:128:7: warning: no newline at end of file
27gcc -x assembler-with-cpp -c src/x86/trans32.s -o obj/unix/release/x86/trans32.o -I. -Isrc -Iinclude
28gcc -x assembler-with-cpp -c src/x86/radd16.s -o obj/unix/release/x86/radd16.o -I. -Isrc -Iinclude
29gcc -x assembler-with-cpp -c src/x86/radd15.s -o obj/unix/release/x86/radd15.o -I. -Isrc -Iinclude
30gcc -x assembler-with-cpp -c src/x86/radd32.s -o obj/unix/release/x86/radd32.o -I. -Isrc -Iinclude
31gcc -x assembler-with-cpp -c src/x86/rtrans16.s -o obj/unix/release/x86/rtrans16.o -I. -Isrc -Iinclude
32gcc -x assembler-with-cpp -c src/x86/rtrans15.s -o obj/unix/release/x86/rtrans15.o -I. -Isrc -Iinclude
33gcc -x assembler-with-cpp -c src/x86/rtrans32.s -o obj/unix/release/x86/rtrans32.o -I. -Isrc -Iinclude
34gcc -x assembler-with-cpp -c src/x86/2xstretch.s -o obj/unix/release/x86/2xstretch.o -I. -Isrc -Iinclude
35src/x86/2xstretch.s: Assembler messages:
36src/x86/2xstretch.s:177: Error: junk `(%esi)movq ' after expression
37src/x86/2xstretch.s:177: Error: suffix or operands invalid for `prefetcht0'
38make: *** [obj/unix/release/x86/2xstretch.o] Error 1
39bash-2.05b$

Also, I made an allegro test program:

1#include <allegro.h>
2 
3int main()
4{
5allegro_init();
6install_keyboard();
7install_mouse();
8set_color_depth(16);
9set_gfx_mode(GFX_AUTODETECT_WINDOWED,320,240,0,0);
10 
11do {
12textprintf(screen,font,mouse_x,mouse_y,makecol(255,0,0),"Hazul owns");
13} while (!key[KEY_ESC]);
14 
15 
16}END_OF_MAIN();

The error I get:

bash-2.05b# ./test
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

Allegro application is running on VT 8

Any ideas? Thanks,
Hazul

* * * * *
"Multiplayer is actually the best way of not programming a good AI" -ReyBrujo

Kitty Cat
Member #2,815
October 2002
avatar

Don't run programs as root.

Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

This means the Allegro app couldn't "connect" to the X server, which usually happens because you're running as root, and X isn't set up to allow root access to the X server.

If you must run as root (DGA, whatever), do this before su'ing to root: 'xhost +localhost'. That'll tell X to allow access for root.

As for FBlend, I believe you need to get the latest version. 0.5, I think.

--
"Do not meddle in the affairs of cats, for they are subtle and will pee on your computer." -- Bruce Graham

hazul
Member #4,338
February 2004
avatar

When trying to install the newest fblend, I get:

bash-2.05b# ./fix.sh
bash: ./fix.sh: Permission denied
bash-2.05b# sh ./fix.sh
: command not found
'/fix.sh: line 3: syntax error near unexpected token `{
'/fix.sh: line 3: `help () {
bash-2.05b#

I've tried as root too, same thing.

* * * * *
"Multiplayer is actually the best way of not programming a good AI" -ReyBrujo

X-G
Member #856
December 2000
avatar

Quote:

bash-2.05b# ./fix.sh
bash: ./fix.sh: Permission denied

chmod a+x fix.sh

?

--
Since 2008-Jun-18, democracy in Sweden is dead. | 悪霊退散!悪霊退散!怨霊、物の怪、困った時は ドーマン!セーマン!ドーマン!セーマン! 直ぐに呼びましょう陰陽師レッツゴー!

hazul
Member #4,338
February 2004
avatar

bash-2.05b# chmod a+x fix.sh
bash-2.05b# ./fix.sh
: bad interpreter: No such file or directory

* * * * *
"Multiplayer is actually the best way of not programming a good AI" -ReyBrujo

X-G
Member #856
December 2000
avatar

bash ./fix.sh

?

--
Since 2008-Jun-18, democracy in Sweden is dead. | 悪霊退散!悪霊退散!怨霊、物の怪、困った時は ドーマン!セーマン!ドーマン!セーマン! 直ぐに呼びましょう陰陽師レッツゴー!

hazul
Member #4,338
February 2004
avatar

bash-2.05b# bash ./fix.sh
: command not found
'/fix.sh: line 3: syntax error near unexpected token `{
'/fix.sh: line 3: `help () {
bash-2.05b#

-- X-G, this is SSH on a forum :)
If it's of any help, I really think my gentoo user group settings are fucked up. Is there a way of checking this?

* * * * *
"Multiplayer is actually the best way of not programming a good AI" -ReyBrujo

X-G
Member #856
December 2000
avatar

Do "which bash", then edit fix.sh and make sure that the first line looks like:

#!/path/to/your/bash

--
Since 2008-Jun-18, democracy in Sweden is dead. | 悪霊退散!悪霊退散!怨霊、物の怪、困った時は ドーマン!セーマン!ドーマン!セーマン! 直ぐに呼びましょう陰陽師レッツゴー!

hazul
Member #4,338
February 2004
avatar

Aha, getting somewhere.

bash-2.05b# bash ./fix.sh unix
Configuring FBlend for gcc...
Done! Now run make to start the compilation.
bash-2.05b# make
gcc -c src/cadd.c -o obj/unix/release/cadd.o -O2 -ffast-math -fomit-frame-pointer -I. -Isrc -Iinclude
gcc -c src/mem_test.c -o obj/unix/release/mem_test.o -O2 -ffast-math -fomit-frame-pointer -I. -Isrc -Iinclude
gcc -c src/csub.c -o obj/unix/release/csub.o -O2 -ffast-math -fomit-frame-pointer -I. -Isrc -Iinclude
gcc -c src/ctrans.c -o obj/unix/release/ctrans.o -O2 -ffast-math -fomit-frame-pointer -I. -Isrc -Iinclude
gcc -c src/radd.c -o obj/unix/release/radd.o -O2 -ffast-math -fomit-frame-pointer -I. -Isrc -Iinclude
gcc -c src/rtrans.c -o obj/unix/release/rtrans.o -O2 -ffast-math -fomit-frame-pointer -I. -Isrc -Iinclude
gcc -c src/2xstretch.c -o obj/unix/release/2xstretch.o -O2 -ffast-math -fomit-frame-pointer -I. -Isrc -Iinclude
gcc -c src/fade.c -o obj/unix/release/fade.o -O2 -ffast-math -fomit-frame-pointer -I. -Isrc -Iinclude
make: *** No rule to make target `/asmdef.c', needed by `obj/unix/asmdef.exe'.  Stop.
bash-2.05b#

* * * * *
"Multiplayer is actually the best way of not programming a good AI" -ReyBrujo

Go to: