The Ur-Quan Masters Home Page Welcome, Guest. Please login or register.
Did you miss your activation email?
December 03, 2022, 07:33:22 pm
Home Help Search Login Register
News: Celebrating 30 years of Star Control 2 - The Ur-Quan Masters

+  The Ur-Quan Masters Discussion Forum
|-+  The Ur-Quan Masters Re-Release
| |-+  Technical Issues (Moderator: Death 999)
| | |-+  Undeclared Error
« previous next »
Pages: [1] Print
Author Topic: Undeclared Error  (Read 1802 times)
fetid_breath
Zebranky food
*
Offline Offline

Gender: Male
Posts: 29


Current Livelihood: Anyway I want. I can now code!


View Profile
Undeclared Error
« on: April 30, 2005, 03:58:43 am »

I edited the src/sc2code/load.c

See http://uqm.stack.nl/cgi-bin/yabb/YaBB.pl?action=display;board=Gendiscuss;num=1086978888;start=0#3

Well When I went to build my changes, I got this:

Code:
gcc -o "obj/release/./src/sc2code/load.o" -c  -I/usr/local/include/SDL -Dmain=SDL_main -I/usr/local/include/SDL -Dmain=SDL_main -O3 -DGFXMODULE_SDL -DHAVE_OPENGL  -DSOUNDMODULE_SDL  -DHAVE_ZIP=1  -I "." -I src -I src/sc2code -I src/sc2code/libs -I src/regex "src/sc2code/load.c"
src/sc2code/load.c: In function `LoadGame':
src/sc2code/load.c:197: error: `KOHR_AH_VICTORIOUS_EVENT' undeclared (first use in this function)
src/sc2code/load.c:197: error: (Each undeclared identifier is reported only once
src/sc2code/load.c:197: error: for each function it appears in.)
make: *** [obj/release/./src/sc2code/load.o] Error 1


Anyone know how to fix this?
Logged

The only similarity between me and Kazon is the fact we both have fetid breath in the morning.
0xDEC0DE
*Many bubbles*
***
Offline Offline

Posts: 175



View Profile WWW
Re: Undeclared Error
« Reply #1 on: April 30, 2005, 04:32:05 am »

You'll need to make sure that load.c references src/sc2code/globdata.h

Typically, this is done at the top of the file with a line like this:

Code:
#include "globdata.h"
Logged

"I’m not a robot like you. I don’t like having disks crammed into me… unless they’re Oreos, and then only in the mouth."  --Fry
fetid_breath
Zebranky food
*
Offline Offline

Gender: Male
Posts: 29


Current Livelihood: Anyway I want. I can now code!


View Profile
Re: Undeclared Error
« Reply #2 on: April 30, 2005, 04:55:34 am »

Code:
#include "globdata.h"
is already in load.c

It still doesn't work.
« Last Edit: April 30, 2005, 05:11:49 am by fetid_breath » Logged

The only similarity between me and Kazon is the fact we both have fetid breath in the morning.
0xDEC0DE
*Many bubbles*
***
Offline Offline

Posts: 175



View Profile WWW
Re: Undeclared Error
« Reply #3 on: April 30, 2005, 07:08:03 am »

Whoops, I got my names confused.  Include gameev.h (in addition to the rest) to get the symbol definition you're after.

Sorry about that.
Logged

"I’m not a robot like you. I don’t like having disks crammed into me… unless they’re Oreos, and then only in the mouth."  --Fry
Culture20
Enlightened
*****
Offline Offline

Posts: 917


Thraddash Flower Child


View Profile
Re: Undeclared Error
« Reply #4 on: April 30, 2005, 11:51:52 am »

Stupid Programming Trick #337374:
Use a search method (Search for files containing text "X" in windows, grep "X" -r   in *nix, where "X" is the text you're looking for) to find the function or variable name.
« Last Edit: April 30, 2005, 11:52:18 am by Culture20 » Logged
fetid_breath
Zebranky food
*
Offline Offline

Gender: Male
Posts: 29


Current Livelihood: Anyway I want. I can now code!


View Profile
Re: Undeclared Error
« Reply #5 on: April 30, 2005, 06:55:46 pm »

Thanks 0xdecode. I added:

#include "gameev.h"

to the top of load.c and it got built fine.
Logged

The only similarity between me and Kazon is the fact we both have fetid breath in the morning.
Pages: [1] Print 
« previous next »
Jump to:  


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!