Page 1 of 1

Compile question

Posted: 16 Apr 2004 17:57
by Muldy
Hi!

i've downloaded source from the svn server, i am compiling it with VC6

and:
Linking...
saveload.obj : error LNK2001: unresolved external symbol @inflateInit_@12
saveload.obj : error LNK2001: unresolved external symbol @inflate@8
saveload.obj : error LNK2001: unresolved external symbol @inflateEnd@4
saveload.obj : error LNK2001: unresolved external symbol @deflateInit_@16
saveload.obj : error LNK2001: unresolved external symbol @deflate@8
saveload.obj : error LNK2001: unresolved external symbol @deflateEnd@4
ReleasePNG/ttd.exe : fatal error LNK1120: 6 unresolved externals
Error executing link.exe.
looks like there is some files missing ?! can't find inflate anywhere in source ...

Can someone help me?

Posted: 16 Apr 2004 17:57
by ludde
you need zlib, you can find it in the openttd useful package.

Posted: 16 Apr 2004 18:01
by Muldy
thanks for the quick reply ;)

i saw last updates to code were minutes ago ;)

you're coding too :)

Posted: 16 Apr 2004 18:17
by Muldy
hmm i think i need the dll too :|

zlibwapi.dll

not included in the useful zip.

tried the zlib http://www.winimage.com/zLibDll/

1.2.1 won't work (renamed zlib.dll to zlibwapi.dll)


Zlib is only needed for png support ... :)
soo i'll skip that :)

Posted: 16 Apr 2004 21:26
by orudge
It's also needed for the new zlib-compressed saved games in 0.3.0.

Posted: 16 Apr 2004 22:28
by Korenn
you can compile either with the static zlib or the dll.

both work fine.

Posted: 17 Apr 2004 00:31
by Muldy
First time i looked at the code, i just had to raise the vehicles limit.

I doubled it, noticed that it was an array, so i assumed there would be no memory alloc problems...

But there are :)
Some sporadic crashes in train navigation code ...

.oO(there should be a develop topic)

Posted: 17 Apr 2004 01:01
by Korenn
those aren't memory alloc problems, some vehicle ids are reserved for special things and I think that's where it goes wrong =]

Posted: 17 Apr 2004 02:24
by Muldy
You mean some indexes of the array are reserved for "special" vehicles?

Do we have these indexes? :)

Maybe makeing them depend on the array size ...
I'll check that in the morning :)

Time for my beauty sleep :)