The Help Thread

Programmers discuss here anything related to FreeOrion programming. Primarily for the developers to discuss.

Moderators: Committer, Committer

Post Reply
Message
Author
duffy84
Space Krill
Posts: 3
Joined: Thu Apr 01, 2004 5:55 am

#91 Post by duffy84 » Wed Apr 14, 2004 6:08 am

Hi!

I still have problems compiling FreeOrion with Dev-C++ on Windows XP.
The latest issue is that I get tons of compiling errors from the boost-libraries.

There's to many rows to post here, but here is a sample:

38 C:\boost-1.30.2\boost\mpl\aux_\include_preprocessed.hpp:27, from C:\boost-1.30.2\boost\mpl\apply.hpp
In file included from C:/boost-1.30.2/boost/mpl/aux_/include_preprocessed.hpp:27, from C:/boost-1.30.2/boost/mpl/apply.hpp

38 C:\boost-1.30.2\boost\mpl\apply.hpp:38, from C:\boost-1.30.2\boost\mpl\aux_\apply.hpp
from C:/boost-1.30.2/boost/mpl/apply.hpp:38, from C:/boost-1.30.2/boost/mpl/aux_/apply.hpp

104 C:\boost-1.30.2\boost\spirit\core\non_terminal\parser_context.hpp
parse error before `const'


I get all theese messages when it compiles VarText.cpp.
I've also been trying to compile FreeOrion with Visual Studio .NET 2003, but I haven't been successfull.

Any ideas are appreciated.
/Mathias

vorenhutz
Pupating Mass
Posts: 98
Joined: Sun Mar 07, 2004 11:41 pm

#92 Post by vorenhutz » Wed Apr 14, 2004 6:55 am

I also have the problem with VarText. It can be fixed by moving the statement

Code: Select all

#include <boost/spirit.hpp> 
so that it's on line 2 instead on line 6 or whatever it is in CVS.
Don't ask me why this works, but it does it for me.

Also don't turn on optimisation, the compiler crashes.
Compile errors to do with GG usually mean that you have the wrong windowskit.zip or it's out of date.
Last edited by vorenhutz on Wed Apr 14, 2004 9:34 am, edited 1 time in total.

duffy84
Space Krill
Posts: 3
Joined: Thu Apr 01, 2004 5:55 am

#93 Post by duffy84 » Wed Apr 14, 2004 8:21 am

Thanks, that did the trick!

vishnou00
Space Kraken
Posts: 157
Joined: Tue May 25, 2004 3:15 am

#94 Post by vishnou00 » Fri May 28, 2004 6:47 pm

I expect having to figure out environnement settings, library scavenging (but WindowsKit alleviate this) and getting the right compiler, but I got an error about invalid convertions for UI/GalaxySetupWnd.cpp:

Code: Select all

g++.exe -D__DEBUG__ -c ../../UI/GalaxySetupWnd.cpp -o ../../objs/GalaxySetupWnd.o -I"d:/devel/Dev-Cpp/include/c++"  -I"d:/devel/Dev-Cpp/include/c++/mingw32"  -I"d:/devel/Dev-Cpp/include/c++/backward"  -I"d:/devel/Dev-Cpp/include"  -I"d:/devel/Dev-Cpp/include/SDL"  -I"d:/devel/Dev-Cpp/include/c++/mingw32"  -I"d:/devel/boost-1.30.2"  -I"d:/devel/Dev-Cpp/include/freetype2"  -I"d:/devel/log4cpp-0.2.7/include"  -I"../../GG/include"  -I"../../GG/include/net"  -I"../../GG/include/dialogs"  -I"../../GG/include/SDL" -DFREEORION_WIN32 -DFREEORION_BUILD_HUMAN    -g3

../../UI/GalaxySetupWnd.cpp: In member function `void 
   GalaxySetupPanel::Init()':
../../UI/GalaxySetupWnd.cpp:150: invalid conversion from `GalaxySetupPanel* 
   const' to `int'
../../UI/GalaxySetupWnd.cpp:150:   initializing argument 3 of `
   boost::signals::connection GG::Connect(SigT&, SigT::slot_type&, int) [with 
   SigT = boost::signal1<void, int, boost::last_value<void>, int, 
   std::less<int>, boost::function1<void, int, 
   std::allocator<boost::function_base> > >]'

d:/devel/boost-1.30.2/boost/function/function_template.hpp: In static member 
   function `static boost::detail::function::unusable 
   boost::detail::function::void_function_obj_invoker1<FunctionObj, R, 

   T0>::invoke(boost::detail::function::any_pointer, T0) [with FunctionObj = 
   boost::_mfi::mf1<void, GalaxySetupPanel, int>, R = void, T0 = int]':
d:/devel/boost-1.30.2/boost/function/function_template.hpp:481:   instantiated from `void boost::function1<R, T0, Allocator>::assign_to(FunctionObj, boost::detail::function::function_obj_tag) [with FunctionObj = boost::_mfi::mf1<void, GalaxySetupPanel, int>, R = void, T0 = int, Allocator = std::allocator<boost::function_base>]'
d:/devel/boost-1.30.2/boost/function/function_template.hpp:432:   instantiated from `void boost::function1<R, T0, Allocator>::assign_to(Functor) [with Functor = boost::_mfi::mf1<void, GalaxySetupPanel, int>, R = void, T0 = int, Allocator = std::allocator<boost::function_base>]'
d:/devel/boost-1.30.2/boost/function/function_template.hpp:465:   instantiated from `void boost::function1<R, T0, Allocator>::assign_to(MemberPtr, boost::detail::function::member_ptr_tag) [with MemberPtr = void (GalaxySetupPanel::*)(int), R = void, T0 = int, Allocator = std::allocator<boost::function_base>]'
d:/devel/boost-1.30.2/boost/function/function_template.hpp:432:   instantiated from `void boost::function1<R, T0, Allocator>::assign_to(Functor) [with Functor = void (GalaxySetupPanel::*)(int), R = void, T0 = int, Allocator = std::allocator<boost::function_base>]'
d:/devel/boost-1.30.2/boost/function/function_template.hpp:293:   instantiated from `boost::function1<R, T0, Allocator>::function1(Functor, boost::detail::function::enable_if<boost::type_traits::ice_not<boost::is_same<Functor, int>::value>::value, int>::type) [with Functor = void (GalaxySetupPanel::*)(int), R = void, T0 = int, Allocator = std::allocator<boost::function_base>]'
d:/devel/boost-1.30.2/boost/signals/slot.hpp:102:   instantiated from `boost::slot<SlotFunction>::slot(const F&) [with F = void (GalaxySetupPanel::*)(int), SlotFunction = boost::function1<void, int, std::allocator<boost::function_base> >]'
../../UI/GalaxySetupWnd.cpp:150:   instantiated from here
d:/devel/boost-1.30.2/boost/function/function_template.hpp:134: no match for 
   call to `(boost::_mfi::mf1<void, GalaxySetupPanel, int>) (int&)'
d:/devel/boost-1.30.2/boost/bind/mem_fn_template.hpp:129: candidates are: R 
   boost::_mfi::mf1<R, T, A1>::operator()(T*, A1) const [with R = void, T = 
   GalaxySetupPanel, A1 = int]
d:/devel/boost-1.30.2/boost/bind/mem_fn_template.hpp:139:                 R 
   boost::_mfi::mf1<R, T, A1>::operator()(T&, A1) const [with R = void, T = 
   GalaxySetupPanel, A1 = int]

make.exe: *** [../../objs/GalaxySetupWnd.o] Error 1

Execution terminated

So far, I compiled and linked successfully the debug version of both server and ai client components (from the CVS). It amounts to some hefty 39 MB and 35 MB binaries which run probably normally (server listen on TCP and UDP and AI client "has requested the Runtime to terminate it in an unusual way" when fired up from the command line).

The system is a Windows XP laptop with Dev-C++ 4.9.8.0, with the majority of devel files residing in d:\devel\, so the project files has to be modified accordingly). I applied vorenhutz patch for VarText to get the server compiling.

If someone consider the compile log too long, pm me and I'll skim it.
Last edited by vishnou00 on Thu Jun 17, 2004 5:34 am, edited 1 time in total.

vishnou00
Space Kraken
Posts: 157
Joined: Tue May 25, 2004 3:15 am

#95 Post by vishnou00 » Sun Jun 06, 2004 6:11 am

Sorry to bump but if anybody could tell me of a windows environnement that compile human client, I would apreciate.
After tracking down the error described in the last post, I get the feeling it's a compiler problem, as it doesn't use the right overload for GG::Connect. Looking at the header (GGSignalsAndSlots.h) I can see the right overload, but there are a lot of templates used, which lead to believe that a faulty compiler is involved.

Are the two updates ("DevC++ Critical Update" and "DevC++ Crash Detection") are crucial to that point? Because I never got them, for the update server is always down.
Last edited by vishnou00 on Thu Jun 17, 2004 5:34 am, edited 1 time in total.

User avatar
tzlaine
Programming Lead Emeritus
Posts: 1092
Joined: Thu Jun 26, 2003 1:33 pm

#96 Post by tzlaine » Sun Jun 06, 2004 7:15 pm

vishnou00 wrote:Sorry to bump but if anybody could tell me of a windows environnement that compile human client, I would apreciate.
After tracking down the error described in the last post, I get the feeling it's a compiler problem, as it doesn't use the right overload for GG::Connect. Looking at the header (GGSignalsAndSlots.h) I can see the right overload, but there are a lot of templates used, wich lead to believe that a faulty compiler is involved.

Are the two updates ("DevC++ Critical Update" and "DevC++ Crash Detection") are crucial to that point? Because I never got them, for the update server is always down.
You guys should both try using the free MS compiler. MS recently made the MSVC++ 7.x compiler free for download. In light of this, and since there have been so many problems with GCC under windows (including my lateness with updated GG DLLs), that it is now officially do-it-youself territory as far as I'm concerned. Obviously, the status of the Linux GCC environment remains the same.

User avatar
noelte
Juggernaut
Posts: 872
Joined: Fri Dec 26, 2003 12:42 pm
Location: Germany, Berlin

#97 Post by noelte » Sun Jun 06, 2004 8:23 pm

... and debugging with DevC++ won't work. MSVC 7.1 is just fine.

Antarious
Space Krill
Posts: 1
Joined: Mon Sep 08, 2003 4:20 pm

#98 Post by Antarious » Mon Jun 07, 2004 1:37 pm

Do you have any more info on where to find the msvc 7.1. I looked
through the microsoft web page, but found no reference to it.

Thanks

User avatar
tzlaine
Programming Lead Emeritus
Posts: 1092
Joined: Thu Jun 26, 2003 1:33 pm

#99 Post by tzlaine » Mon Jun 07, 2004 5:48 pm

Antarious wrote:Do you have any more info on where to find the msvc 7.1. I looked
through the microsoft web page, but found no reference to it.

Thanks
Google, anyone? Try "microsoft free compiler".

vishnou00
Space Kraken
Posts: 157
Joined: Tue May 25, 2004 3:15 am

#100 Post by vishnou00 » Mon Jun 07, 2004 7:40 pm

Does msvc 7.1 uses the libs/headers described in WindowsKit.zip?

If it does, what to do with the copy-to-Dev-Cpp folder?

If it doesn't, what to get and where to get it?

User avatar
noelte
Juggernaut
Posts: 872
Joined: Fri Dec 26, 2003 12:42 pm
Location: Germany, Berlin

#101 Post by noelte » Mon Jun 07, 2004 7:52 pm

vishnou00 wrote:Does msvc 7.1 uses the libs/headers described in WindowsKit.zip?
If it does, what to do with the copy-to-Dev-Cpp folder?
If it doesn't, what to get and where to get it?
There are project files which can be used with MSVC. You don't need WindowsKit.zip. But you have to compile GiGi, too.

vishnou00
Space Kraken
Posts: 157
Joined: Tue May 25, 2004 3:15 am

#102 Post by vishnou00 » Tue Jun 08, 2004 3:02 am

Thanks all, I got it working on MSVC 7.1. Here is a list of the files I needed from the internet:
-GiGi (CVS checkout on sourceforge)
-FreeOrion (CVS checkout on sourceforge)
-boost-1.30.2.zip (from sourceforge)
-boost-jam-3.1.10-1-ntx86.zip (from sourceforge boost project)
-log4cpp-0.3.4b.tar.gz (sourceforge)
-DevIL-SDK-1.6.5.zip (DevIL 1.6.5 Windows SDK)
-SDL-1.2.7.zip (libsdl.org)
-ft217.zip (sourceforge)
-zlib121-dll.zip (http://www.gzip.org/zlib/)
-SDL_mixer-devel-1.2.5a-VC6.zip (http://www.libsdl.org/projects/SDL_mixer/)

DevIL, SDL_mixer and zlib are precompiled, if I remember correctly the rest is all built from the source. Boost jam only a tool to build boost.
This list is useful because you know which version you can use to get the project compiling (as of june 7th, 2004, anonymous CVS login)


I don't know where to ask that, but is there an art package not on the CVS? default/art/small/planets/planets.xml refers to files I can't find (terran/terran1_%%%.png, such as default/art/small/planets/lights/lights1_000.png) anywhere.
Last edited by vishnou00 on Thu Jun 17, 2004 5:33 am, edited 1 time in total.

User avatar
noelte
Juggernaut
Posts: 872
Joined: Fri Dec 26, 2003 12:42 pm
Location: Germany, Berlin

#103 Post by noelte » Tue Jun 08, 2004 3:38 am

vishnou00 wrote:I don't know where to ask that, but is there an art package not on the CVS? default/art/small/planets/planets.xml refers to files I can't find (terran/terran1_%%%.png, such as default/art/small/planets/lights/lights1_000.png) anywhere.
Ask pd. :)

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 12563
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

CVS help

#104 Post by Geoff the Medio » Mon Jun 14, 2004 5:04 am

I've never used CVS.

I installed WinCVS and have (I think) attempted to download the source, without success.

Currently I:

-Select Remote -> Checkout Module...

Under Checkout Settings:
-Put "FreeOrion" as the module name and path on server (is this right?)

Under General:
-Authentication: ntserver
-Path: cvsroot/freeorion
-Host Address: cvs.sourceforge.net
-User Name: (blank)
-CVSROOT: cvs.sourceforge.net:cvsroot/freeorion

then I click OK, and get in the message window below:

cvs checkout -P FreeOrion (in directory C:\Documents and Settings\Geoff\My Documents)
cvs [checkout aborted]: the :ntserver: access method is not installed on this system

***** CVS exited normally with code 1 *****


...

I'm running WinXP, with WinCVS 1.3.17.2 Beta 17.

Any ideas what I should do to get the source, or what I should read (preferably the former, as the stuff I've seen so far hasn't helped, obviously)? I don't care (yet) about any other functions of CVS... I just want the code to peruse to see if I think I might be able to contribute to coding.

Thanks.

vishnou00
Space Kraken
Posts: 157
Joined: Tue May 25, 2004 3:15 am

#105 Post by vishnou00 » Mon Jun 14, 2004 5:41 am

See the wiki Compile article on Wiki. As for CVS usage, you should be able to find documentation on the net.

This page coud be a good read.

As for your error, it simply says ntserver access method isn't appropriate. You should use pserver authentication (with anonymous username and blank password).

Post Reply