Which optimum IDE could I use to develop freeorion?

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

Moderator: Committer

Message
Author
User avatar
Rydra
Space Squid
Posts: 55
Joined: Fri Jun 28, 2013 6:15 pm

Which optimum IDE could I use to develop freeorion?

#1 Post by Rydra »

Hi there,

As I could see on the source, there are MSVC and XCode file projects to develop using those applications. However, I'm a bit reluctant on developing over Microsoft (although I work with Visual Studio) and I don't have a Mac to develop with XCode.

As for now, when developing C++ applications I always used eclipse when developing on Linux, but I'm not sure it is that good in order to maintain a link to dependencies, Cmake compilation, etc...

After years of developìng I feel an IDE is necessary to dramatically increase productivity, so... what Linux IDE do you recommend me to develop and study a C++ application like freeorion?

Greetings

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

Re: Which optimum IDE could I use to develop freeorion?

#2 Post by Geoff the Medio »

You can probably use Eclipse. See: http://www.freeorion.org/index.php/Compile_With_Eclipse I don't know how up-to-date that is, but it suggests its doable.

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: Which optimum IDE could I use to develop freeorion?

#3 Post by Dilvish »

I use KDE on Linux & am reasonably content with it.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

User avatar
adrian_broher
Programmer
Posts: 1156
Joined: Fri Mar 01, 2013 9:52 am
Location: Germany

Re: Which optimum IDE could I use to develop freeorion?

#4 Post by adrian_broher »

Rydra wrote:As I could see on the source, there are MSVC and XCode file projects to develop using those applications.
The MSVC and Xcode projects are just there because some developers use them. In my opinion they should be retired on favour of CMake, but yeah, opinions are opinions and not facts.
Rydra wrote:As for now, when developing C++ applications I always used eclipse when developing on Linux, but I'm not sure it is that good in order to maintain a link to dependencies, Cmake compilation, etc...
If you're inclined to use Eclipse I would suggest to use the Eclipse project generator of CMake. Do do that install eclipse cdt and eclipse svnkit. Optionally you could install the cmake editor.

To get this working you need to remove/comment out the

Code: Select all

set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
in the CMakeLists.txt inside the project root. I will try to check what's going on there when I have the time.

Clean up the source directory of the freeorion source (removing CMakeCache.txt, CMakeFiles and Makefiles recursively and the build output) and call

Code: Select all

cmake -G "Eclipse CDT4 - Unix Makefiles" .
(-G selects the build system generator) to create Eclipse projects.

Import the generated project as existing project. You can build the project by building the Targets. Because of the comment out lines the executable is located at client/human/freeorion instead of the project root.
Rydra wrote:After years of developìng I feel an IDE is necessary to dramatically increase productivity, […]
I wouldn't think so. IDEs force themself onto you, standing in the way and are most times a general annoyance but ymmv.
Rydra wrote:[…] so... what Linux IDE do you recommend me to develop and study a C++ application like freeorion?
The one you're most accustomed and comfortable with and CMake has a generator for.

Personally I prefer the group of bash, vim, gnu utils, id utils and Nemiver or DDD as 'IDE'.
Geoff the Medio wrote:See: http://www.freeorion.org/index.php/Compile_With_Eclipse I don't know how up-to-date that is, but it suggests its doable.
This probably should be replaced with a proper cmake call, the setup described there is just convoluted.
Resident code gremlin
Attached patches are released under GPL 2.0 or later.
Git author: Marcel Metz

User avatar
Rydra
Space Squid
Posts: 55
Joined: Fri Jun 28, 2013 6:15 pm

Re: Which optimum IDE could I use to develop freeorion?

#5 Post by Rydra »

Dilvish wrote:I use KDE on Linux & am reasonably content with it.
KDE? Do you mean KDevelop? KDE is a desktop environment :P

Later i'll try those eclipse suggestions. I already had CDT installed yet I never used cmake to compile.

Thanks for the answers :D

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: Which optimum IDE could I use to develop freeorion?

#6 Post by Dilvish »

LOL yes I spaced a bit there, I meant that I use KDevelop, the primary KDE IDE :D

That's what I use for C++ anyway; I use Eric for Python. I used to use Eclipse for python some years back, but have come to prefer Eric.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

Eloque
Space Squid
Posts: 53
Joined: Mon Jul 21, 2014 11:56 am

Re: Which optimum IDE could I use to develop freeorion?

#7 Post by Eloque »

Sorry to do a bit of thread necromancy, but has anyone succeeded in creating an Eclipse MinGW (or other) project for Windows based systems? I've been fighting with cmake for quite a bit now, but so far, no dice. It keeps complaining about boost, freetype and other dependencies, no matter how I configure it.

I do have the SDK installed, but not matter what directory or lib I point to, I keep getting errors. I've put all the boost libs in by hand, but still get numerous errors. One about boost being version 0.0.0 another about the directory not existing.

Is there a guide, besides the one in this thread or on the wiki, or someone who has succeeded? Right now I am trying via CygWin, I kinda gave up on 'cmake -G "Eclipse CDT4 - MinGW Makefiles" . '
Code, justify, code - Pitr
Attached patches are released under GPL 2.0 or later, artwork and such are released under CC-BY-SA 3.0 license.

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

Re: Which optimum IDE could I use to develop freeorion?

#8 Post by Geoff the Medio »

Unless there's a reason you can't, I suggest using Visual Studio 2010...

http://www.visualstudio.com/downloads/d ... Families_4

User avatar
adrian_broher
Programmer
Posts: 1156
Joined: Fri Mar 01, 2013 9:52 am
Location: Germany

Re: Which optimum IDE could I use to develop freeorion?

#9 Post by adrian_broher »

Eloque wrote:Sorry to do a bit of thread necromancy, but has anyone succeeded in creating an Eclipse MinGW (or other) project for Windows based systems? I've been fighting with cmake for quite a bit now, but so far, no dice. It keeps complaining about boost, freetype and other dependencies, no matter how I configure it.

I do have the SDK installed, but not matter what directory or lib I point to, I keep getting errors. I've put all the boost libs in by hand, but still get numerous errors. One about boost being version 0.0.0 another about the directory not existing.

Is there a guide, besides the one in this thread or on the wiki, or someone who has succeeded? Right now I am trying via CygWin, I kinda gave up on 'cmake -G "Eclipse CDT4 - MinGW Makefiles" . '
CMake isn't set up for windows due to the fact that the windows sdk isn't fixed yet.
Resident code gremlin
Attached patches are released under GPL 2.0 or later.
Git author: Marcel Metz

Eloque
Space Squid
Posts: 53
Joined: Mon Jul 21, 2014 11:56 am

Re: Which optimum IDE could I use to develop freeorion?

#10 Post by Eloque »

Main reason is that I have a Linux/Windows system set up at home and a MacBook system on the road.

I'd rather not code in XCode and Visual Studio, much rather have one and the same setup, Eclipse works on all platforms, so that's why I'd like to try and set that up. Not in the least because XCode geeks out on me and crashed every other time I try to debug and jump into a function.
Code, justify, code - Pitr
Attached patches are released under GPL 2.0 or later, artwork and such are released under CC-BY-SA 3.0 license.

maxand
Space Floater
Posts: 36
Joined: Tue Mar 18, 2008 5:42 am
Location: Australia

Re: Which optimum IDE could I use to develop freeorion?

#11 Post by maxand »

I've been doing some reading on this, prior to choosing an IDE (or something else such as Visual Studio) for myself. Although Python IDEs have been discussed here and in other threads on this forum, I'd be grateful if some of you guys could comment on some of these issues. Running on Windows 7 64-bit.

1) Does anyone use Vim or Vim interface plugins such as IdeaVim for PyCharm? What do you think of using Vim for Python programming?
Some articles on Vim:
What IDE to use for Python?
Vim & Python: Making yourself at home
My Development Environment For Python
Vim as a Python IDE, or Python IDE as Vim
An Epic Review of PyCharm 3 from a Vim User’s Perspective
Turning Vim into a modern Python IDE

2) Eric has been recommended as a Python IDE. However, Comparison of Python IDEs for Development has this to say about Eric:
Eric is an IDE written in Python with PyQt. It integrates some familiar Qt tools, such as Designer and Linguist, uses the ubiquitous Scintilla editing component, and has some tools that look like they would be really useful.

That's about where I end with Eric, because it has a very serious drawback: it has a very complex interface with low discoverability and very little documentation. It feels like it was designed to make the user feel stupid and impotent. Where I was able to drop right in and use other editors and IDEs on this list, and consult the documents for the bits that weren't obvious, Eric stymied me at every turn, and though its plugin API is documented (by a tool, I think), there are no user docs included. None. Zero docs.

You will no doubt forgive the tone of frustration in this review.
Are these criticisms justified?

Another interesting article that doesn't mention Eric but recommends Eclipse with PyDev, Komodo Edit and PyCharm is The Best Python IDEs You Can Use for Development

3) With regards to PyCharm, is the free community version adequate for programming FO?

(Added)
4) No one seems to have mentioned PyPy, now moved away from Codespeak to have its own website:
PyPy is a fast, compliant alternative implementation of the Python language (2.7.6 and 3.2.5). It has several advantages and distinct features:

Speed: thanks to its Just-in-Time compiler, Python programs often run faster on PyPy. (What is a JIT compiler?)
Memory usage: large, memory-hungry Python programs might end up taking less space than they do in CPython.
Compatibility: PyPy is highly compatible with existing python code. It supports cffi and can run popular python libraries like twisted and django.
Sandboxing: PyPy provides the ability to run untrusted code in a fully secure way.
Stackless: PyPy comes by default with support for stackless mode, providing micro-threads for massive concurrency.
As well as other features.
Anyone use or recommend it?

Thanks for feedback.

User avatar
Vezzra
Release Manager, Design
Posts: 6102
Joined: Wed Nov 16, 2011 12:56 pm
Location: Sol III

Re: Which optimum IDE could I use to develop freeorion?

#12 Post by Vezzra »

maxand wrote:With regards to PyCharm, is the free community version adequate for programming FO?
If you use it to tinker with the FOs Python scripts (that is, the AI and universe generation scripts), then yes, it's more than sufficient, I use it myself (and I'm the one who implemented scripted universe generation).

If however you plan to dig into the C++ code, then the easiest choice on Windows would be MSVC 2010 (Express Edition), or Xcode on OSX, as the SDKs are tailored to be used with them, and respective project files are maintained in the SVN repo. There is no SDK for Linux, on this platform you need the CMake scripts maintained in the SVN repo to build FO. Whatever IDE can be set up to work with that can probably be used, but I'm no Linux user, better ask our Linux folks (Dilvish for example uses Linux as development platform for FO).

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: Which optimum IDE could I use to develop freeorion?

#13 Post by Dilvish »

Vezzra wrote:There is no SDK for Linux....
There is no Linux SDK because the cmake files and instructions here and here should generally be sufficient and are compatible with any Linux IDE. If any trouble comes up in your distribution then post the issue in the General->Compile forum.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

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

Re: Which optimum IDE could I use to develop freeorion?

#14 Post by Geoff the Medio »

Dilvish wrote:There is no Linux SDK because...
More so, there is no Linux SDK because there would probably need to be a separate SDK for each distribution and possibly version of Linux, much like how there needs to be separate binary packages for different distributions.

User avatar
adrian_broher
Programmer
Posts: 1156
Joined: Fri Mar 01, 2013 9:52 am
Location: Germany

Re: Which optimum IDE could I use to develop freeorion?

#15 Post by adrian_broher »

Geoff the Medio wrote:More so, there is no Linux SDK because there would probably need to be a separate SDK for each distribution and possibly version of Linux, much like how there needs to be separate binary packages for different distributions.
There is no Linux SDK because it's not required. CMake resolves the dependencies just fine and checks beforehand if the dependencies are there. The SDK concept is for broken platforms where you can't assume a sane setup.
Resident code gremlin
Attached patches are released under GPL 2.0 or later.
Git author: Marcel Metz

Post Reply