Linux CVS Compile Issues

NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Forum rules
NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Locked
Tylius-

Linux CVS Compile Issues

Post by Tylius- »

I'm trying to compile the CVS snapshot under linux, I've managed to get up to this point, but I can't seem to resolve this issue.

Searched and searched for info, but no luck, and I can't find a CVS binary package :(

ucparse.o: In function `yyparse()':
/usr/share/bison/bison.simple:574: undefined reference to `yylex()'
ucparse.o: In function `yyparse()':
/home/bryantona/Desktop/exult-cvs/exult/usecode/compiler/ucparse.yy:549: undefined reference to `start_script()'
/home/bryantona/Desktop/exult-cvs/exult/usecode/compiler/ucparse.yy:561: undefined reference to `end_script()'
ucmain.o: In function `main':
/home/bryantona/Desktop/exult-cvs/exult/usecode/compiler/ucmain.cc:107: undefined reference to `yyin'
/home/bryantona/Desktop/exult-cvs/exult/usecode/compiler/ucmain.cc:93: undefined reference to `yyin'
collect2: ld returned 1 exit status

Any info on how to get this fixed would be greatly appreciated, or even just a lead on where I could look for some more info, thanks in advance :)
Tylius-

Re: Linux CVS Compile Issues

Post by Tylius- »

Bah, no edit feature...

Xubuntu Linux, running off the Edgy repositories, so gcc and whatnot are all 4.1 I believe.
wjp
Site Admin
Posts: 1708
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by wjp »

Try removing uclex.cc, ucparse.cc, ucparse.h from the usecode/compiler directory and then re-running make.
Tylius-

Re: Linux CVS Compile Issues

Post by Tylius- »

Fixed it, thanks!
Tylius-

Re: Linux CVS Compile Issues

Post by Tylius- »

Sorry...another compile issue, I saw the updates about avatar's speed in the changelog so decided to update =P

ucsym.h:268: error: 'Uc_scope' has not been declared
ucparse.yy: In function 'int yyparse()':
ucparse.yy:229: error: no matching function for call to 'Uc_function_symbol::create(char*&, int, std::vector >&, bool, Uc_scope*)'
ucsym.h:268: note: candidates are: static Uc_function_symbol* Uc_function_symbol::create(char*, int, std::vector >&, bool, int*)
make[3]: *** [ucparse.o] Error 1

I tried removing the three files listed above, like last time, except there's no uclex.cc with this cvs package to remove, and when I remove ucparse.h / .cc, it just gets created again when I run make.

Any idea? Sorry to bother again ;x
Tylius-

Re: Linux CVS Compile Issues

Post by Tylius- »

And I tried removing ucparse.yy, but then it says it's needed by ucparse.cc
Tylius-

Re: Linux CVS Compile Issues

Post by Tylius- »

*shrugs* I just deleted the .yy file, then removed a section from the makefil that wanted it

Hope that doesn't break anything O.o
Tylius-

Re: Linux CVS Compile Issues

Post by Tylius- »

Alright, guess it did :(

It compiled more, but now I'm getting, so....I'm stumped and I'll wait, or see if I can find the cvs package I had before :)


xdrag.o: In function `Get_window_coords':
/home/bryantona/Desktop/exult/exult/xdrag.cc:51: undefined reference to `XQueryTree'
/home/bryantona/Desktop/exult/exult/xdrag.cc:53: undefined reference to `XFree'
/home/bryantona/Desktop/exult/exult/xdrag.cc:59: undefined reference to `XGetWindowAttributes'
xdrag.o: In function `Xdnd':
/home/bryantona/Desktop/exult/exult/xdrag.cc:88: undefined reference to `XInternAtom'
/home/bryantona/Desktop/exult/exult/xdrag.cc:89: undefined reference to `XInternAtom'
/home/bryantona/Desktop/exult/exult/xdrag.cc:90: undefined reference to `XInternAtom'
/home/bryantona/Desktop/exult/exult/xdrag.cc:91: undefined reference to `XInternAtom'
/home/bryantona/Desktop/exult/exult/xdrag.cc:93: undefined reference to `XInternAtom'
xdrag.o:/home/bryantona/Desktop/exult/exult/xdrag.cc:94: more undefined references to `XInternAtom' follow
xdrag.o: In function `Xdnd::select_msg(XSelectionEvent&)':
/home/bryantona/Desktop/exult/exult/xdrag.cc:258: undefined reference to `XGetAtomName'
/home/bryantona/Desktop/exult/exult/xdrag.cc:275: undefined reference to `XGetWindowProperty'
/home/bryantona/Desktop/exult/exult/xdrag.cc:307: undefined reference to `XFree'
xdrag.o: In function `Xdnd::client_msg(XClientMessageEvent&)':
/home/bryantona/Desktop/exult/exult/xdrag.cc:132: undefined reference to `XGetAtomName'
/home/bryantona/Desktop/exult/exult/xdrag.cc:190: undefined reference to `XSendEvent'
/home/bryantona/Desktop/exult/exult/xdrag.cc:154: undefined reference to `XGetWindowProperty'
/home/bryantona/Desktop/exult/exult/xdrag.cc:200: undefined reference to `XConvertSelection'
xdrag.o: In function `Xdnd':
/home/bryantona/Desktop/exult/exult/xdrag.cc:108: undefined reference to `XChangeProperty'
/home/bryantona/Desktop/exult/exult/xdrag.cc:108: undefined reference to `XChangeProperty'
collect2: ld returned 1 exit status
wjp
Site Admin
Posts: 1708
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by wjp »

Try adding the line

Code: Select all

class Uc_scope;
right below the line

Code: Select all

class Uc_class;
in usecode/compiler/ucsym.h.
wjp
Site Admin
Posts: 1708
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by wjp »

The X link errors you're seeing are unrelated to these ucsym.h issues, by the way.
MeddlingMonk
Posts: 237
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by MeddlingMonk »

I've started getting errors myself when making in Fedora 5 in the last three snapshots. Make keeps ending with

ucsym.h:268: error: ‘Uc_scope’ has not been declared
ucparse.yy: In function ‘int yyparse()’:
ucparse.yy:229: error: no matching function for call to ‘Uc_function_symbol::create(char*&, int, std::vector >&, bool, Uc_scope*)’
ucsym.h:268: note: candidates are: static Uc_function_symbol* Uc_function_symbol::create(char*, int, std::vector >&, bool, int*)
make[3]: *** [ucparse.o] Error 1
make[3]: Leaving directory `/home/meddlingmonk/Desktop/exult/usecode/compiler'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/meddlingmonk/Desktop/exult/usecode'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/meddlingmonk/Desktop/exult'
make: *** [all] Error 2

It kind of looks like what you suggest is relevant with this as well. I'm going to try. But it's interesting I didn't get this before. I tried building the snapshot I got on the 16th, the last one before I started getting these errors, and it still builds ok.
MeddlingMonk
Posts: 237
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by MeddlingMonk »

Nope. Get the same errors.
marzo
Site Admin
Posts: 1925
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by marzo »

Tylius: deleting the ucparse.yy file and related section will break the usecode compiler (UCC). If you are not going to be compiling usecode yourself, you will not have any problems with it.

MeddlingMonk: after adding the line wjp suggested, try deleting the ucsym.o file. And can you confirm that in ucsym.h, near line 268, there are the following lines of code?

Code: Select all

	static Uc_function_symbol *create(char *nm, int num, 
				std::vector& p, bool is_extern=false,
				Uc_scope *scope = 0, int shp = -1);
------
Marzo Sette Torres Junior
aka Geometrodynamic Dragon
[url=http://www.catb.org/~esr/faqs/smart-questions.html]How To Ask Questions The Smart Way[/url]
Tylius-

Re: Linux CVS Compile Issues

Post by Tylius- »

Right, I figured that compile section was for a utility rather than some core piece of Exult, since they had me remove some files relating to it last time, but after doing it this time I got those X errors.

Trying out the fix for the header file he posted right now
Tylius
Posts: 28
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by Tylius »

Alright, the fix for the usecode compiler worked perfectly and got past all that, however it's still getting stuck on the errors around:

xdrag.o: In function `Get_window_coords':
/home/bryantona/Desktop/exult/exult/xdrag.cc:51: undefined reference to `XQueryTree'
/home/bryantona/Desktop/exult/exult/xdrag.cc:53: undefined reference to `XFree'

And I've no clue what to do to fix that >.D)
Tylius
Posts: 28
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by Tylius »

(I really wish there was an edit feature)

If there's any information, compiler info, or anything that would be handy for tracking this down, just let me know and I'll do my best to get the information for you :)
Axel S

Re: Linux CVS Compile Issues

Post by Axel S »

I fixed the "undefined reference to 'X...'" rather simply: there's a "-lX11" missing in the generated Makefile. I've added that in the line "x_libraries =" so that it reads "x_libraries = -lX11".
Maybe that's not its intention but it works just fine.
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Linux CVS Compile Issues

Post by Dominus »

Necroposter!!!!

Seriously isn't that fixed in SVN? I'm sure we added something for x11 after the rc1 release.

Edit: yes, added this 19th December 2010
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Locked