Page 1 of 1

really dumb question

Posted: 11.08.2002, 16:37
by Captain Radium
OK.
I am a total noob when it comes to programing and am thankfull nobody's life depends on me doing this correctly.

I downloaded the source file for Celestia 1.2.4 and unzipped it to it's own dircetory.

I opened up celestiacore.cpp with MS visual C++.
I changed one digit in one number to increase the maximum FOV (line 364).
I compliled the file ( I think that is what I have to do to get an executable program. comments?)
I got the following error message.


--------------------Configuration: celestiacore - Win32 Debug--------------------
Compiling...
celestiacore.cpp
d:\celestia\source\celestia-1.2.4\src\celestia\celestiacore.cpp(24) : fatal error C1083: Cannot open include file: 'celengine/gl.h': No such file or directory
Error executing cl.exe.

celestiacore.obj - 1 error(s), 0 warning(s)

I know I'm pretty clueless and way out of my depth, but I'm wondering if I am on the right track and how would I remedy this error.
:oops:

Posted: 11.08.2002, 17:00
by Miserableman
Did it compile beforehand? Compiling celestia in VC++ is a bit of a pain (I've yet to manage it). How did you try and compile it?

Posted: 11.08.2002, 17:39
by Captain Radium
I opened the file celestiacore.cpp with MS visual C++.
Then I changed the number I modified.
Then I went into the Build pulldown menu and hit Compile celestiacore.cpp

Then I got the error message.

Posted: 12.08.2002, 00:07
by Miserableman
You need to load the entire Celestia project in VC++, which is celestia.dsw in the \src dir. If it doesn't load, open it in notepad - if everything seems to be on one line and there are funny black blocks everywhere, then replace the contents of the file with this:

Microsoft Developer Studio Workspace File, Format Version 6.00


# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!



###############################################################################



Project: "Celestia"=.\celestia\Celestia.dsp - Package Owner=<4>



Package=<5>

{{{

}}}



Package=<4>

{{{

Begin Project Dependency

Project_Dep_Name cel3ds

End Project Dependency

Begin Project Dependency

Project_Dep_Name celengine

End Project Dependency

Begin Project Dependency

Project_Dep_Name celmath

End Project Dependency

Begin Project Dependency

Project_Dep_Name celtxf

End Project Dependency

Begin Project Dependency

Project_Dep_Name celutil

End Project Dependency

}}}



###############################################################################



Project: "cel3ds"=.\cel3ds\cel3ds.dsp - Package Owner=<4>



Package=<5>

{{{

}}}



Package=<4>

{{{

}}}



###############################################################################



Project: "celengine"=.\celengine\celengine.dsp - Package Owner=<4>



Package=<5>

{{{

}}}



Package=<4>

{{{

}}}



###############################################################################



Project: "celmath"=.\celmath\celmath.dsp - Package Owner=<4>

Package=<5>

{{{

}}}



Package=<4>

{{{

}}}



###############################################################################



Project: "celtxf"=.\celtxf\celtxf.dsp - Package Owner=<4>



Package=<5>

{{{

}}}



Package=<4>

{{{

}}}



###############################################################################



Project: "celutil"=.\celutil\celutil.dsp - Package Owner=<4>

Package=<5>

{{{

}}}



Package=<4>

{{{

}}}



###############################################################################



Global:

Package=<5>

{{{

}}}



Package=<3>

{{{

}}}



###############################################################################

Posted: 12.08.2002, 00:10
by Miserableman
Any changes made to the code means that module at least has to be rebuilt, and you may need to rebuild the entire project for it to work.

Good luck getting further tho, I'm still stuck with linker errors (HELP)

Posted: 12.08.2002, 16:47
by chris
Miserableman wrote:Any changes made to the code means that module at least has to be rebuilt, and you may need to rebuild the entire project for it to work.

Good luck getting further tho, I'm still stuck with linker errors (HELP)

What linker errors are you getting? Are you missing the lib files for the JPEG and PNG libraries?

--Chris

Posted: 13.08.2002, 12:38
by Miserableman
chris wrote:
Miserableman wrote:Any changes made to the code means that module at least has to be rebuilt, and you may need to rebuild the entire project for it to work.

Good luck getting further tho, I'm still stuck with linker errors (HELP)
What linker errors are you getting? Are you missing the lib files for the JPEG and PNG libraries?

--Chris


I've fixed it now. I had all the jpeg/png/zlib libraries, but somewhere in my conversion of the project files from Unix line returns to Windows line returns one of them corrupted, and was throwing the build process awry. I recopied/remade the files and it's okay now |o/

Posted: 13.08.2002, 23:48
by Captain Radium
I tried this again. I got the libpng, libjpeg, and libz files from http://enchantia.com/software/graphapp/download/ and I put them into include directories. I tried again and got the following errors.


--------------------Configuration: celengine - Win32 Debug--------------------
Compiling...
texture.cpp
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\libjpeg\jmorecfg.h(178) : warning C4005: 'FAR' : macro redefinition
d:\microsoft visual studio\vc98\include\windef.h(135) : see previous definition of 'FAR'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(46) : error C2371: 'APP_BYTE_SIZE' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(46) : see declaration of 'APP_BYTE_SIZE'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(47) : error C2371: 'APP_SHORT_SIZE' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(47) : see declaration of 'APP_SHORT_SIZE'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(48) : error C2371: 'APP_INT_SIZE' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(48) : see declaration of 'APP_INT_SIZE'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(49) : error C2371: 'APP_FLOAT_SIZE' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(49) : see declaration of 'APP_FLOAT_SIZE'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(50) : error C2371: 'APP_REAL_SIZE' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(50) : see declaration of 'APP_REAL_SIZE'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(52) : error C2371: 'APP_POINTER_SIZE' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(52) : see declaration of 'APP_POINTER_SIZE'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(56) : error C2371: 'APP_BYTE_PACKING' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(56) : see declaration of 'APP_BYTE_PACKING'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(57) : error C2371: 'APP_SHORT_PACKING' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(57) : see declaration of 'APP_SHORT_PACKING'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(58) : error C2371: 'APP_INT_PACKING' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(58) : see declaration of 'APP_INT_PACKING'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(59) : error C2371: 'APP_FLOAT_PACKING' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(59) : see declaration of 'APP_FLOAT_PACKING'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(60) : error C2371: 'APP_REAL_PACKING' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(60) : see declaration of 'APP_REAL_PACKING'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(61) : error C2371: 'APP_POINTER_PACKING' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(61) : see declaration of 'APP_POINTER_PACKING'
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(63) : error C2371: 'APP_MAXIMUM_PACKING' : redefinition; different basic types
d:\celestia\source\celestia-1.2.4\include\graphapp_3.26\src\apptypes.h(63) : see declaration of 'APP_MAXIMUM_PACKING'
Error executing cl.exe.

Celestia.exe - 13 error(s), 1 warning(s)


Any tips?

Posted: 14.08.2002, 17:33
by Miserableman
Assuming you're compiling the original source and not your modified version (I'm not going to help you debug your code :O]), it looks like you've got a similar error to what I had, i.e. one of your project files is corrupted. Try building each of the projects individually. For whichever one the errors appear in, re-extract the project .dsp file from the source, and remake it into a windows file.

A very handy tool to do this is Program File Editor (or PFE), which is like notepad on steroids for programmers. You can open the dsp files in PFE, and resave them as Windows text files instead of Unix.