I have a small game project that uses SFML, box2d and other small libraries.
I already managed to make my project work on both MSVC 2012 and Xcode5. All I have to do is to commit code, add source files I would have added in the other project, and I'm good to do.
It's pretty smooth except from weird stdafx differences, and the fact MSVC2012 doesn't support variadic templates yet.
I'm really wondering if I would really be able benefit from clion. I mean obviously I would have to recompile SFML as SFML does not provide binaries for clion ? That's a first problem I guess.
I also remember giving up on compiling Ogre3D on xcode, there were many dependencies, versions of the engine (repo or stable), it was very annoying and I'm not into tweaking Cmake.txt files. I guess jetbrains would not solve this.
I have not given a try to this IDE, but I'm skeptic. C++ is designed as a cross platform languages, but the fact build systems differ is a huge pain, and an IDE won't solve this unless library maintainer provide solid cmake scripts.
To clarify one thing: it's not like VS with its own proprietary compiler and build system. You choose what c, c++ compiler (eg gcc, g++), debugger (gdb), copy of cmake etc to use. Projects are built from a CMakeLists.txt you maintain.
Anyone with cmake (and know how to use it) can build your source.
Haven't messed with it much so I don't know yet what ways it DOES lock you in. There's probably something.. (other than needing to use cmake)
edit: By all that I mean, you can use the versions of SFML compiled for whatever compiler you plan to use it with.
I don't really care about the compiler, really. MSVC compiler has many C++11 features so it's fine, as long as things compile.
If I have to build SFML from source because SFML doesn't provide binaries for clion, and if it's a pain in the ass because it doesn't work out of the box, it's not a lock in, but it makes thing harder for clion.
I just hate to deal with library cross-platform gimmicks, not to mention CMake scripts. I want to write code, not learn some build scripting language that is just some hack and might go extinct some day.
> Anyone with cmake (and know how to use it) can build your source.
Usually I can give a project file, eventually I even give a zip with the library binaries, and it's fine. Once you use a binary library the heavy lifting is done.
What I'm worried about is that having a cross-platform IDE doesn't nullify the binary incompatibility between binaries.
I guess clion might be useful for very large C++ application projects who want to work in cross-platorm, but not libraries. Games are usually not very large applications, they just use some inputs and opengl.
You shouldn't have to build SFML from source. The blog post says that CLion supports Cygwin and MinGW toolchains on Windows and SFML provides MinGW binaries, so you should be fine there. As I think the parent post was trying to explain, not many IDEs are as closely tied to a specific compiler as Visual Studio is tied to MSVC. A lot of IDEs, including CLion, just use GCC, so anything that works with GCC will work with CLion.
To clarify your confusion in "provide binaries for clion":
That does not make sense. You don't need binaries for CLion. If anything, you need binaries for GCC or Clang (the compiler - not the editor/IDE).
In case of a C library, the library binaries build with any compiler will work with any other compiler in your C/C++ project.
In case of a C++ library, you might need to have the library binaries build with the same compiler. So, as CLion uses GCC, you need library binaries which were also build with GCC. You can build the library with whatever build system you like (Xcode, CMake, by hand, automake, ...) as long as you use GCC.
In any case, it does not matter what editor/IDE (Vim, Xcode, CLion) and what build system (Xcode, CMake, ...) you use, it only matters, what compiler (GCC, Clang) you use.
> In any case, it does not matter what editor/IDE (Vim, Xcode, CLion) and what build system (Xcode, CMake, ...) you use, it only matters, what compiler (GCC, Clang) you use.
so if I use clion on mac, do I give it frameworks or .dylib ?
How exactly to you choose a compiler? I have both cygwin gcc and clang (3.4 cygwin, and 3.5 native) installed. I can't seem to get it to use anything other than cygwin gcc.
Aside from the fact that JetBrains make incredible IDEs, basing it around CMake is a great idea as it means project files that aren't tied to a specific platform or IDE. You can develop a project in CLion just as easily as you could with vim and the build instructions would be the same.
I very much hope this is the future and the tooling around CMake is improved too. In my perfect world, this would include dependency management - even if that just meant a reference to versioned sources that you could easily include in a project file and the tooling was responsible for pulling them down and building them.
I truly hope people aren't choosing their build systems based on the IDE they use. If you program C++, you will have to use some combination of a dozen strange autoconf/Make solutions, CMake, boost::jam, scons, rake, etc. If you work at a big corporation, you'll probably have a custom build tool. Any ide worth a damn will either be build tool agnostic or it won't be useful to the majority of the target market.
Then it has to have its own build system, with its own descriptor files, so you're maintaining two build systems anyway. Might as well pick one of the existing ones.
> Then it has to have its own build system, with its own descriptor files
...Why? Just interface with the existing build system. Most have very clear semantics, and it's not clear anything is gained from prioritizing one over the other. All the ide needs to worry about is generally syntax highlighting, targets, flags (e.g. to enable debugging), and the STANDARDIZED error reporting.
Also, gyp, ninja.... so many build systems. CMake only has a fraction of the market, and not even an impressive one.
This is not a thing of the past. Font rendering is still significantly different between java and non-java apps, and in my opinion appears distinctly wrong in java:
I really hope they add the ability to customize your toolchain in the later releases. I'd absolutely LOVE to ditch eclipse for CLion for use with arm-none-eabi and openocd/gdb :D This would shake the embedded world. I absolutely love JetBrains' IDE's for every other language.
I wish it were an IntelliJ plugin instead, or at least would give IntelliJ the ability to syntax-highlight C++. IntelliJ can syntax-highlight a gazillian exotic languages, but not C/C++... Having two separate programs is annoying if you have projects with many different programming languages.
JetBrains has said that it might show turn up as an IntelliJ plugin for Ultimate subscribers, but they're focusing on making it a great stand-alone product, and they're not promising any plugin version.
To be fair, you need a good portion of a compiler to syntax highlight C and C++ accurately due to the preprocessor, overloading, operator overloading, and a few other features.
Of course the solution, perhaps, would be to use a clang-based tool to provide syntax highlighting rules. I would hope JetBrains does something like this and contributes back to the clang project so everyone else can benefit from the bugfixes and new features they require to get their product to a good place.
It is a shame it only supports MinGW and not MinGW-W64 at the moment.
I hope they settle on Clang/LLVM for the main tool chain and include a complete version of Clang for Windows (when the Clang standard library is done).
Let me preface this by saying I'm a huge JetBrains fan.
My one issue with these essentially single-purpose IDEs is that they are intentionally crippled for other languages. I find it very annoying, for example, that I have to edit Vagrantfiles as plain text because shipping Ruby support in another IDE product is verboten. In contrast, I can fire up SublimeText and have support for every language in existence, including config syntaxes and scripts.
Their products are typically very good though, other than that. I've grown completely dependent on PyCharm.
It's a big ask to want integrated debugging, project management, advanced semantic search (go to implementation in child class), and semantic manipulation (extract these methods into a new class) for all the languages you happen to want. Perhaps it's possible, but it's a huge project.
It's at least an order of magnitude easier to support viewing, editing, syntax highlighting, and textual search across arbitrarily many languages, which is why there are many tools that support that feature set, including almost all major code editors.
I don't know how JetBrains architects their IDEs, but I suspect they have some in-memory database that populated with indexed project metadata. To add multiple metadata indices (for different languages) with cross indexing between them would be an entirely different data model. Again, it would be much more work to develop, test, and maintain.
In IntelliJ IDEA Ultimate, you can install all language plugins for no additional cost. However, project initialisation and management gets a lot harder with several language plugins enabled. The language-specific IDE from JetBrains will still be easier to use, but for a price.
Is there any word as to whether the functionality we see here will be coming to IDEA as a plugin (as is the case with other language specific IDEs Jetbrains produce)?
If so and the word is positive, is there any indication of the kind of delay we might expect. I already pay for IDEA and love it, much as I want what CLion offers, I couldn't personally justify another paid license on top (with the increased load in yearly renewals that implies).
I'd been happily developing with VIM for more than five years but last year I tried RubyMine and once I let go of my perfectionistic/unixy point-of-view things got a lot easier tbh. If I were still doing systems programming I'd be very tempted to try this new IDE. Be warned though, the JetBrains products are usually not very pleasant to look at (alas there usually is support for themes).
JetBrains has great products. Support could use some improvement but overall I am a happy customer. I use PyCharm on a daily basis and love it. I will certainly keep CLion in mind.
I have to disagree. I don't see what's so amazing.. The EAP is limited to 60 days.. so you're either going to pay the $X00.. or move on to something else. If you can't buy it, I don't see why you would want to learn it just to abandon it 2 months from now.