Jump to content

  • Log In with Google      Sign In   
  • Create Account

Banner advertising on our site currently available from just $5!


1. Learn about the promo. 2. Sign up for GDNet+. 3. Set up your advert!


Linux development workflows?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
7 replies to this topic

#1 Peppit   Members   -  Reputation: 123

Like
0Likes
Like

Posted 19 July 2014 - 05:11 PM

I'm sort of curious if anyone here develops on linux, and if they do, what do you use? Does anyone use vim/emacs as their "IDE"? How much boilerplate did you have to write?



Sponsor:

#2 TheChubu   Crossbones+   -  Reputation: 5562

Like
0Likes
Like

Posted 19 July 2014 - 05:17 PM

switch ( Platform.get() )
{
    case WIN:
        bpp = 32;
        break;
    case MAC:
        bpp = 32;
        break;
    case NIX:
        bpp = 24;
        break;
    default:
        bpp = 24;
        break;
}

And that's about it in my case (bpp is bits per pixel btw, turns out Windows/OSX defaults to 32 whereas *nix platforms default to 24).


Edited by TheChubu, 19 July 2014 - 05:17 PM.

"I AM ZE EMPRAH OPENGL 3.3 THE CORE, I DEMAND FROM THEE ZE SHADERZ AND MATRIXEZ"

 

My journals: dustArtemis ECS framework and Making a Terrain Generator


#3 Bacterius   Crossbones+   -  Reputation: 9876

Like
0Likes
Like

Posted 19 July 2014 - 07:15 PM

What kind of boilerplate?


The slowsort algorithm is a perfect illustration of the multiply and surrender paradigm, which is perhaps the single most important paradigm in the development of reluctant algorithms. The basic multiply and surrender strategy consists in replacing the problem at hand by two or more subproblems, each slightly simpler than the original, and continue multiplying subproblems and subsubproblems recursively in this fashion as long as possible. At some point the subproblems will all become so simple that their solution can no longer be postponed, and we will have to surrender. Experience shows that, in most cases, by the time this point is reached the total work will be substantially higher than what could have been wasted by a more direct approach.

 

- Pessimal Algorithms and Simplexity Analysis


#4 Oolala   Members   -  Reputation: 935

Like
2Likes
Like

Posted 19 July 2014 - 08:33 PM

Honestly, unless I'm sealed into developing on linux, which is rare, I'll program on windows in a cross-platform fashion, and port.  It sounds dumb, but it really doesn't take that much effort to be cross-platform, outside of video/audio and sometimes networking, and sometimes threading, that it just isn't worth using things that lock you in to one platform or another.  If you're like me, and primarily working on back-end stuff or tools, there just isn't much justification for doing platform specific work.



#5 SeraphLance   Members   -  Reputation: 1651

Like
0Likes
Like

Posted 19 July 2014 - 09:04 PM

I usually program windows-only, partly because my Linux workflow kind of sucks, but for comparison, this is what I use:

 

C/C++:

 

Editor:  For small tasks -- vim.  Larger tasks I open SublimeText for.

Compiler:  Usually gcc, but I've been toying with clang lately

Source Control:  hg (since I use bitbucket a lot)

Debugger:  command-line gdb)

Build System:  make;  More specifically, I have a non-recursive makefile that works as a great drop-in with very little customization.  I only need to specify the executable name and obscure library flags (like -lm for gcc).  All my external dependencies are handled with dependency generation features in gcc and fancy makefile macros.

 

Python:

Basically the same as C++ with no debugger or build system stuff.

 

 

It's kind of a pain.  While the tools are good, the system as a whole isn't cohesive enough (unix philosophy and all that) for the really nice stuff like goto definition, refactoring, or building/debugging in-editor.  So on that level, while Sublime is awesome and all, I strongly recommend finding an ide, unix philosophy be damned.

 

EDIT:  I should probably add that my Linux stuff all falls into two things:  homeworks from college or cross-platform stuff that I also use on windows.  As such, I generally only work on the Linux side when I need to make it work for Linux.


Edited by SeraphLance, 19 July 2014 - 09:06 PM.


#6 SeanMiddleditch   Crossbones+   -  Reputation: 8719

Like
1Likes
Like

Posted 19 July 2014 - 09:37 PM

outside of video/audio and sometimes networking, and sometimes threading


Even those are all easy enough to make portable. Use OpenGL, an audio library like FMOD or Wwise, and Boost/STL threading or a library like Intel's Threading Building Blocks. IO can be done via PhysicsFS, Boost/STL, and so on as well. All the windowing and input is handled by all the common window-system libraries like SDL.
 

Does anyone use vim/emacs as their "IDE"?


When I used Linux as a desktop/development OS (which I haven't for some years) I used Vim exclusively. These days a lot of people swear by QtCreator which also runs on Windows and OSX so it's a decent choice for a cross-platform IDE. I can't really stand any IDE I've put time into aside from Visual Studio anymore, though, though Sublime Text (which runs on Linux) make a good run.
 

How much boilerplate did you have to write?


The boilerplate is no more or less on Linux than it is elsewhere when you use a window-system toolkit like SDL2, GLFW, SFML, etc. and a build system tool like CMake. If you're writing raw OS API code (Win32, X11, etc.) there's tons of boilerplate to write but there's really no good reason to ever do that these days.

#7 Karsten_   Members   -  Reputation: 1697

Like
1Likes
Like

Posted 20 July 2014 - 07:01 AM

Since I started out with programming on UNIX I tend to use that same development environment even when on Windows.

In a typical Linux/UNIX project I generally find all of these tools useful.

Editor: Vim - Including the NETRW and Buffergator plugins. Helps navigating scattered source bases quickly. More importantly, it does not require a "project file" for source aware navigation to work. My biggest annoyance with Visual Studio or other IDEs.

Code completion / Navigation
- exuberant ctags (Vim supports by default now).
- cscope (performs some tasks ctags cannot)
- doxygen (With C the automatic flow chart generator is fantastic for development and learning codebases)

Compiler:
- gcc for main releases
- Any compiler I can get my hands on since they all potentially pick up on different issues.

Build System:
- cmake
- simple Makefiles for release builds and test harness

Continuous Integration: Jenkins on a bunch of VMs targeting many platforms

Misc: tmux for multiple terminals

Debuggers / Profilers:
- Valgrind
- gdb
- ElectricFence
- Intel VTune
- AddressSanitizer
- splint

Arguably GLX requires less boilerplate code than Windows alternatives when setting up an OpenGL rendering context.

http://www.opengl.org/wiki/Programming_OpenGL_in_Linux:_GLX_and_Xlib

You may notice it has a line count close to when using Glut.

Edited by Karsten_, 20 July 2014 - 07:08 AM.

Mutiny - Open-source C++ Unity re-implementation.
Defile of Eden 2 - FreeBSD and OpenBSD binaries of our latest game.


#8 Ravyne   GDNet+   -  Reputation: 9575

Like
2Likes
Like

Posted 20 July 2014 - 01:25 PM

Honestly, my development experience on Linux is mostly as a kind of playground. That is, the kind of coding I do there is mostly recreational -- messing around with Arduinos or other embedded stuff who's tool chain runs best on *nix, exercising my more 'academic' language pursuits like Haskell, or playing with neat linux stuff like Docker. Because I'm not so concerned with efficiency then, that informs some of my other choices. I use Vim not because I find it to be instantly productive, but because leaning Vim is a goal in itself -- its simply useful to know at least one lightweight text editor that you can use even from a remote text console -- and because the long walk leads to becoming possibly more efficient than WYSIWYG editors and fancy IDEs.

 

In general I like Linux because its a more 'orthogonal' environment in some sense of the word. The trend on Windows (and old-world Macs, the trend has reversed since OS X) has been towards more monolithic, swiss-army-knife applications, or to largely independent 'kingdoms' of apps that inter-operate nicely. The trend on *nix has always been towards a more inter-operable ecosystem of smaller and more focused tools that do one thing very well. It goes beyond the apps themselves though -- even where windows has functional equivalents (say grep vs. findstr) the command-line apps on Windows all use wildly-different argument formats, and not every app necessarily supports piping in ways it ought to. The *nix world largely has that problem sorted.






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS