Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Vanilla

Reply
 
Thread Tools Display Modes
Old April 11, 2008, 17:20   #1
wastedyouth
Rookie
 
Join Date: Apr 2008
Posts: 4
wastedyouth is on a distinguished road
Angband and the Borg on Linux

Hello,

I've been a big fan of Angband since I was a kid, and it's nice to see it getting some attention again. I'm also quite proud of myself, because I've managed to compile it from the source on my Linux box.

However, I'm wanting to compile it with the Borg. Is it even possible to compile in the APWborg for linux?

Once I start to make the files I start running into problems...

Code:
        CC     borg1.c             
        CC     borg2.c             
        CC     borg3.c             
borg3.c: In function ‘borg_read_unknown’:
borg3.c:3348: warning: unused variable ‘ag’
borg3.c: In function ‘borg_read_scroll’:
borg3.c:3489: warning: unused variable ‘ag’
borg3.c: In function ‘borg_spell_okay’:
borg3.c:4119: warning: unused variable ‘ag’
borg3.c: In function ‘borg_prayer_okay’:
borg3.c:4307: warning: unused variable ‘ag’
and then it ends like this...

Code:
        CC     z-virt.c            
birth.o: In function `player_birth':
/home/djp/angband-3.0.9b/src/birth.c:1758: undefined reference to `saver_creates'
birth.o: In function `player_birth_aux':
/home/djp/angband-3.0.9b/src/birth.c:1691: undefined reference to `saver_creates'
birth.o: In function `player_birth_aux_3':
/home/djp/angband-3.0.9b/src/birth.c:1543: undefined reference to `saver_creates'
/home/djp/angband-3.0.9b/src/birth.c:1590: undefined reference to `saver_creates'
util.o: In function `get_name':
/home/djp/angband-3.0.9b/src/util.c:2888: undefined reference to `saver_creates'
collect2: ld returned 1 exit status
make[2]: *** [angband] Error 1
make[1]: *** [build] Error 2
make: *** [build] Error 2
Am I trying to do something thats impossible or am I doing it wrong?
wastedyouth is offline   Reply With Quote
Old April 12, 2008, 14:45   #2
Remuz
Apprentice
 
Join Date: Apr 2007
Posts: 77
Remuz is on a distinguished road
I get the same error. Since the only main-*.c modified by the borg code is main-win.c, I would suspect the borg is for windows only.

The variable 'saver_creates' exists so that the game knows if it has to create a new character automatically (when running the borg through the screensaver).

I did not spend too much time on this, so there is no guaranty, but apparently, in externs.h, changing the following lines :


Code:
extern bool saver_creates; /* apw  */
extern char screensaver_inkey_hack_buffer[1024]; /* apw */
extern int screensaver_inkey_hack_size;
into

Code:
bool saver_creates; /* apw */
char screensaver_inkey_hack_buffer[1024]; /* apw */
int screensaver_inkey_hack_size;
Obviously, this is a bad hack, and you should not mess with the option to automatically recreate a character after death, as this will probably not work.

Also, but this probably comes from my inexperience with installing angband, the game was looking for borg.txt (lower case) in ~/.angband/Angband. You might want to add the following lines in borg9.c, around line 4725 (after the "if(!fp) part) :

Code:
        msg_print("Looking for borg.txt in");
        msg_print( buf );
When testing, my character died from starvation at clvl 6, not too sure if that is ok or not.
Edit: Ok, my current char is clvl 26 and going, so this seems to run as expected, after all.

Hope that helps.

Last edited by Remuz; April 12, 2008 at 15:11.
Remuz is offline   Reply With Quote
Old April 13, 2008, 23:56   #3
takkaria
Veteran
 
takkaria's Avatar
 
Join Date: Apr 2007
Posts: 1,951
Donated: $40
takkaria is on a distinguished road
Quote:
Originally Posted by Remuz View Post
I get the same error. Since the only main-*.c modified by the borg code is main-win.c, I would suspect the borg is for windows only.
No, it's just developed on Windows and APW has no means of testing on other systems.

Quote:
The variable 'saver_creates' exists so that the game knows if it has to create a new character automatically (when running the borg through the screensaver).

I did not spend too much time on this, so there is no guaranty, but apparently, in externs.h, changing the following lines :
Try instead just appending "bool saver_creates;" to the end of variable.c. Works like a dream!
takkaria is offline   Reply With Quote
Old April 14, 2008, 02:51   #4
takkaria
Veteran
 
takkaria's Avatar
 
Join Date: Apr 2007
Posts: 1,951
Donated: $40
takkaria is on a distinguished road
BTW, Unix people;

A version of 3.0.9b + APWBorg + fixes is available using "git". Install the git and git-core packages for your flavour of Unix and run:
Code:
$ git clone git://repo.or.cz/angband/borg.git
Like magic, you'll have working copy. I've just got interested in the borg, which is probably a terrible terrible thing for actually keeping the game maintained, but http://repo.or.cz/w/angband/borg/takk.git is the page with the latest changes to my own branch of APW's borg. Right now it's mainly code cleanup, but I want to make the borg generally a little more aggressive in its playstyle.
takkaria is offline   Reply With Quote
Old April 14, 2008, 04:06   #5
Nick
Vanilla maintainer
 
Nick's Avatar
 
Join Date: Apr 2007
Location: Canberra, Australia
Age: 58
Posts: 9,532
Donated: $60
Nick will become famous soon enoughNick will become famous soon enough
Quote:
Originally Posted by takkaria View Post
I've just got interested in the borg
You might be interested in being able to run it in xscreensaver, then. I've mailed some stuff to your rephial address.
__________________
One for the Dark Lord on his dark throne
In the Land of Mordor where the Shadows lie.
Nick is offline   Reply With Quote
Old April 14, 2008, 04:27   #6
takkaria
Veteran
 
takkaria's Avatar
 
Join Date: Apr 2007
Posts: 1,951
Donated: $40
takkaria is on a distinguished road
Quote:
Originally Posted by Nick View Post
You might be interested in being able to run it in xscreensaver, then. I've mailed some stuff to your rephial address.
You are obviously evil incarnate. Not only for giving me something else borg-related to hack on, but also for finding a good reason to keep the X11 port..
takkaria is offline   Reply With Quote
Old April 14, 2008, 06:19   #7
Nick
Vanilla maintainer
 
Nick's Avatar
 
Join Date: Apr 2007
Location: Canberra, Australia
Age: 58
Posts: 9,532
Donated: $60
Nick will become famous soon enoughNick will become famous soon enough
Quote:
Originally Posted by takkaria View Post
You are obviously evil incarnate.
Well, you know, I do what I can...
__________________
One for the Dark Lord on his dark throne
In the Land of Mordor where the Shadows lie.
Nick is offline   Reply With Quote
Old April 17, 2008, 17:49   #8
maastrictian
Rookie
 
Join Date: Apr 2008
Posts: 3
maastrictian is on a distinguished road
Takkaria's git link above was very useful to me. I got the source and am now running angband on linux. But I'm not able to run the borg.

I've followed the steps outlined in borgread.txt (it seems like 2 & 3 were not needed with the git link) but I can't seem to start the borg.

The "angband" command starts the game, but ctrl-z just suspends the game, either when I execute the command on game start or when I have a character loaded.

What am I missing? How do I start the borg?

Thanks!
--Chris
maastrictian is offline   Reply With Quote
Old April 17, 2008, 17:56   #9
takkaria
Veteran
 
takkaria's Avatar
 
Join Date: Apr 2007
Posts: 1,951
Donated: $40
takkaria is on a distinguished road
Quote:
Originally Posted by maastrictian View Post
Takkaria's git link above was very useful to me. I got the source and am now running angband on linux. But I'm not able to run the borg.

I've followed the steps outlined in borgread.txt (it seems like 2 & 3 were not needed with the git link) but I can't seem to start the borg.

The "angband" command starts the game, but ctrl-z just suspends the game, either when I execute the command on game start or when I have a character loaded.

What am I missing? How do I start the borg?

Thanks!
--Chris
In that case, try literally '^' followed by 'Z'. Your problem is that you're running in a terminal, and in a terminal ^Z means "suspend". Luckily if you press ^ then Angband lets you press another key afterward and treats it like you'd pressed control and the second key at the same time.
takkaria is offline   Reply With Quote
Old April 17, 2008, 18:23   #10
maastrictian
Rookie
 
Join Date: Apr 2008
Posts: 3
maastrictian is on a distinguished road
Thanks, that's what I needed to know!

--Chris
maastrictian is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Angband Borg 3.0.9 and windows Zappa Vanilla 38 October 27, 2010 20:31
How to change font in angband (linux)? danvari Vanilla 3 February 28, 2008 13:44
APW borg on OS X pesachyonah Vanilla 7 February 12, 2008 10:56
Angband 3.0.9 under Linux (graphics?) strangeintp Vanilla 4 January 19, 2008 22:44
Trouble compiling angband 3.0.9 on linux RastaRuedi Vanilla 2 August 1, 2007 17:28


All times are GMT +1. The time now is 13:01.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.