Compiling with Code::Blocks, part deux

Trying to build your own version of Vega Strike and having problems? Unix users, paste your config.log here (stderr output alone is not helpful).
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Compiling with Code::Blocks, part deux

Post by klauss »

The only thing left to try is (VSSprite*)NULL.

But that's just dumb on MSVC's part.
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

klauss wrote:The only thing left to try is (VSSprite*)NULL.

But that's just dumb on MSVC's part.
That actually worked. Everything compiles without errors.

But now of course I get several hundred unresolved externals because I didn't include any of the new audio stuff in the project yet. :D
make me a sandwich
make: *** No rule to make target 'me'. Stop.
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

Here's an updated patch. use instead of the previous one.
You do not have the required permissions to view the files attached to this post.
make me a sandwich
make: *** No rule to make target 'me'. Stop.
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

I'm trying to clean up the VS projects, and noticed that they contain the cmd/collide folder as well as cmd/collide2; but there is no cmd/collide in the source tree. OK to nuke that?

Also, cmd/iterator.h absent. Ok to nuke?

3rd; am I right toassume that the following files should not be included in the project directly?
gfx/bmp_to_png.cpp
gfx/raw_to_png.cpp
cmd/unit_jump.cpp
cmd/ai/pythonai.cpp
cmd/oldcollection.cpp


Finally, what am I missing? This is my current output (see attached lest it exceeds max message size)
You do not have the required permissions to view the files attached to this post.
make me a sandwich
make: *** No rule to make target 'me'. Stop.
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Compiling with Code::Blocks, part deux

Post by klauss »

shenle wrote:I'm trying to clean up the VS projects, and noticed that they contain the cmd/collide folder as well as cmd/collide2; but there is no cmd/collide in the source tree. OK to nuke that?

Also, cmd/iterator.h absent. Ok to nuke?
If the source is missing, it's ok I would think.
shenle wrote: 3rd; am I right toassume that the following files should not be included in the project directly?
gfx/bmp_to_png.cpp
gfx/raw_to_png.cpp
cmd/unit_jump.cpp
cmd/ai/pythonai.cpp
cmd/oldcollection.cpp
You're correct, they're not in CMakeLists.txt, so linux isn't using them, I can't think of a reason for windows to want them either.
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Compiling with Code::Blocks, part deux

Post by klauss »

shenle wrote:Finally, what am I missing? This is my current output (see attached lest it exceeds max message size)
You need to include unit.cpp, which is no longer included in unit.h.
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

klauss wrote:
shenle wrote:Finally, what am I missing? This is my current output (see attached lest it exceeds max message size)
You need to include unit.cpp, which is no longer included in unit.h.
unit.cpp is already included, as well as unit.h.
make me a sandwich
make: *** No rule to make target 'me'. Stop.
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Compiling with Code::Blocks, part deux

Post by klauss »

Are you sure?

Take a good look. I remember it was marked as "do not build this file" (or something like that).
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

You're right. I'm not all that familiar with VS10, having used mostly C::B and VS7 in the past so I missed that.
Building now.
make me a sandwich
make: *** No rule to make target 'me'. Stop.
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

Code: Select all

1>OpenALRenderer.obj : error LNK2019: unresolved external symbol __imp__alSpeedOfSound referenced in function "protected: void __thiscall Audio::OpenALRenderer::setupDopplerEffect(void)" (?setupDopplerEffect@OpenALRenderer@Audio@@IAEXXZ)
1>unit_generic.obj : error LNK2019: unresolved external symbol "public: virtual __thiscall UnitImages<void>::~UnitImages<void>(void)" (??1?$UnitImages@X@@UAE@XZ) referenced in function "public: virtual void * __thiscall UnitImages<void>::`scalar deleting destructor'(unsigned int)" (??_G?$UnitImages@X@@UAEPAXI@Z)
last 2 errors remaining.
make me a sandwich
make: *** No rule to make target 'me'. Stop.
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Compiling with Code::Blocks, part deux

Post by klauss »

That means you're using a new al.h but an old al.lib/dll
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

klauss wrote:That means you're using a new al.h but an old al.lib/dll
I'm using both from vega-vc7, supposedly they're the same version.
make me a sandwich
make: *** No rule to make target 'me'. Stop.
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

I have downloaded and compiled OpenAL from svn, and replaced all the headers and libs with the new versions. I still get

Code: Select all

1>OpenALRenderer.obj : error LNK2019: unresolved external symbol __imp__alSpeedOfSound referenced in function "protected: void __thiscall Audio::OpenALRenderer::setupDopplerEffect(void)" (?setupDopplerEffect@OpenALRenderer@Audio@@IAEXXZ)
1>unit_generic.obj : error LNK2019: unresolved external symbol "public: virtual __thiscall UnitImages<void>::~UnitImages<void>(void)" (??1?$UnitImages@X@@UAE@XZ) referenced in function "public: virtual void * __thiscall UnitImages<void>::`scalar deleting destructor'(unsigned int)" (??_G?$UnitImages@X@@UAEPAXI@Z)
make me a sandwich
make: *** No rule to make target 'me'. Stop.
klauss
Elite
Elite
Posts: 7243
Joined: Mon Apr 18, 2005 2:40 pm
Location: LS87, Buenos Aires, República Argentina

Re: Compiling with Code::Blocks, part deux

Post by klauss »

It's just common sense: if the call was wrong (which it isn't), the compiler would complain, not the linker.

The fact that it's the linker complaining hints that the .h has the function's declaration, but the .lib doesn't have the function itself.

So... I'll urge you to keep digging ;)
Oíd mortales, el grito sagrado...
Call me "Menes, lord of Cats"
Wing Commander Universe
shenle
Confed Special Operative
Confed Special Operative
Posts: 381
Joined: Thu Jan 31, 2008 3:25 am
Location: hiding in a dark corner

Re: Compiling with Code::Blocks, part deux

Post by shenle »

I would dig, but don't know where anymore. I'm not a programmer (duh!)
make me a sandwich
make: *** No rule to make target 'me'. Stop.
Post Reply