PDA

View Full Version : Borland CBuilder and the SDK



colkai
01-10-2008, 06:53 AM
Hiya folks,
To avoid permanently hijacking the thread on the sunspot I thought I'd post here for assistance.

Trying to get the SDK working with CBUilder (and old copy of 3.0 Pro I got on a coverdisk).

Thinking I'd managed to get it working, I dropped back to the 7.5 SDK and followed some instructions I had. It worked very well and got the 'box' plguni compiled and running ok in modeller.

However, when I try to use the SDK for 9.2 - I get all sorts of errors, even though the 'source' files in the SDK still appear, to all intents and purposes, to be identical to the one from the 7.5 SDK.

Going through exactly the same motions, I am presented with the following errors.
.........
[C++Error] servmain.c(21): Undefined symbol 'MOD_MACHINE'.
[C++Error] servmain.c(22): Type mismatch in redeclaration of 'Startup'.
[C++Error] servmain.c(8): Earlier declaration of 'Startup'.
[C++Error] servmain.c(23): Type mismatch in redeclaration of 'Shutdown'.
[C++Error] servmain.c(9): Earlier declaration of 'Shutdown'.
[C++Error] servmain.c(25): Type mismatch in redeclaration of 'ServerDesc'.
[C++Error] servmain.c(25): Declaration syntax error.
[C++Error] servmain.c(25): Unexpected }.
.........

If I simply choose the 7.5 versions of the source files and point to the 7.5 sdk include - it compiles just fine.

Anyone ever come across anything like this?

tischbein3
01-10-2008, 07:24 AM
Anyone ever come across anything like this?


no borland experience here, but did you include the MSWIN preprocessor variable wich has been introduced in 8.x ?

Lightwolf
01-10-2008, 07:31 AM
no borland experience here, but did you include the MSWIN preprocessor variable wich has been introduced in 8.x ?
He should have... it's been there for ages (6.0 at least).

It could be that they kicked out Borland specific code for the newer SDK (since nobody is using it really, and you can get MSVC for free anyhow).
However, you ought to be able to use the old server.lib code, nothing has really changed there.
Or just get MSVC Express and stop fighting the compiler ;)

Cheers,
Mike

kruemel_1
01-10-2008, 07:37 AM
define the symbol _MSWIN and it will compile. (in Builder6 under Project-directory/conditions - definitions)

greetings
Martin

colkai
01-10-2008, 09:18 AM
It could be that they kicked out Borland specific code for the newer SDK (since nobody is using it really, and you can get MSVC for free anyhow).
However, you ought to be able to use the old server.lib code, nothing has really changed there.
Or just get MSVC Express and stop fighting the compiler)

Looks like I may have no choice. Just a PITA as I use CBuilder for work and I was trying to avoid this PC getting as "cluttered" as my old one, but looks like I have to face facts that CBuilder is not seen as a "normal" development package against the might of MSVC. :eek: :p

Oh how I hate getting to grips with new IDE's. :compbeati ;)

EDIT: ... or not.. :D :D - although I get warnings - it compiles using _MSWIN - I am given to understand, the correct expression is 'W00t!' :p

colkai
01-11-2008, 07:32 AM
Hmm, spoke too soon.
box1.C compiles and runs, but box2.C doesn't work at all in modeller. It compiles, but running it, though it displays the panel for parameters, it htne returns an error.
Also found though the source compiled, I get a list of warnings.
Have installed MSVC-Express on my other PC to see if I can get it working there and if I get the same problems. That way I know if it's the code or the compiler at fault.

colkai
01-12-2008, 07:55 AM
ok, tis indeed the compiler, I've just gone through setting up Bloodshed and apart from now having to include the "_MSWIN" during the lib build, everything works. Including the Box2.c program so I guess BCB is out for LW. - ahh well.