How to Get Started Developing for Linux

Discussion in 'Getting Started' started by kenizl86, Nov 18, 2013.

  1. kenizl86

    kenizl86 New Member

    Messages:
    9
    Likes Received:
    2
    Trophy Points:
    3
    Hello!

    From what I can tell, no one has asked this question yet (on this forum), so I think I will. What is needed/required to get started in developing for Linux? Where would you start off if you wanted to develop packages, distros, drivers, applications, etc.? Would it be best learning C, C++, C#, Java, Assembly, Perl, Python, Pascal (I believe this is for databases, but I can't be all to sure about that), etc.; and which would be priority?

    I'm really wanting to be able to jump in and help the community and spread the love of Linux to all! I figured one good way to do that would be to help expand the base, offer insight, help others (and I figured this would all stem from being in the development "team").


    So... any sage advice and even not-so-sage advice would be greatly appreciated! Thanks!
    Amol Patil likes this.
  2. Codypy1

    Codypy1 Member

    Messages:
    84
    Likes Received:
    32
    Trophy Points:
    18
    Hmm C++ and C might would be the best to learn. I'm to sure about that type of programming. Just web programming and such. I think C# is more widely used in windows? Not to sure.

    But the best way to learn any language is to dive right in. Start looking and code seeing how it's done and programming and going trough tutorials.
  3. nixsavy

    nixsavy Member

    Messages:
    65
    Likes Received:
    17
    Trophy Points:
    8
    If you really mean to choose Linux development its all about know about linux kernel.

    If you are beginer, learn C and then C++ . Also try to understand how linux works (commands , directory structure , system calls , device drivers etc)

    choose any one area then explore and go deep into it. Refer https://lwn.net/Kernel/ and watch , what guys are doing there.

    why dont you try develop your own tool ? :) Have a goal set

    May be I can give some link for kernel development but it would only worth once you have gained knowledge in C/C++

    Good Luck !!!
    Amol Patil likes this.
  4. kenizl86

    kenizl86 New Member

    Messages:
    9
    Likes Received:
    2
    Trophy Points:
    3
    Sweetest deals! Thanks for your replies you guys!

    Yeah, learning the ins and outs of linux (and unix) is a lengthy path, but a rewarding one!

    Thanks nixsavy, I was in a real debate about which one to do first: C, or C++. It makes sense though, to do C first. Maybe I'll learn assembly after C, but maybe not. Assembly is pretty tough. I know how to do Java, but that's kinda hard to implement in some places.

    Anywho, thanks for the advice!
  5. MikeyD

    MikeyD Active Member

    Messages:
    184
    Likes Received:
    82
    Trophy Points:
    28
    Definitely start with C. It has a steep learning curve, but if you understand C most other languages are a cake walk. Linux development is mostly concerned with C, C++, Perl, and more recently Python.
    I would also add shell scripting to that list as it will provide programming basics (branching statements, loops, variables, etc) without making you sweat the nuances of compiling and will increase your Linux knowledge as well.
    I mostly develop in Java at work for a web application we're working on, but even developing on a Windows box in Java we still use shell scripts on the Linux server host to implement a lot of the app's functionality.
    I wouldn't waste time with assembly. It gives you hacker cred but is pretty worthless beyond that since it will be tied to the architecture of the system you're running. Assembly isn't used much beyond programming for hardware like cameras or motion sensors, etc.
  6. lin.and.phi

    lin.and.phi New Member

    Messages:
    4
    Likes Received:
    5
    Trophy Points:
    3
    Well, starting with C might be the best way to go, but it really doesn't matter that much. You can also start with any other programming language, because the first thing you want to do is to learn how to code in general (and after that, learn how to code well). Just learning C so you can hack the Linux kernel might not be the best idea, or at least you will experience some frustration with this approach. But then again, this is part of the journey ;)
    If you want to learn C, the book "The C programming language" by Kernighan & Ritchie gives you a pretty good and thorough insight (since it is written by the creators of C). For beginners to programming there might be better books, but if you know the drill and just want a short but still detailed guide, use this book. Highly recommended!
    After that, you probably should get to know the UNIX API so you can start writing programs for the system you one day want to modifiy. Check "Beginning linux programming" by Niel Matthew, for example.
    When you feel comfortable with that, you can get to know the Linux kernel. "Linux kernel development" by Robert Love is a beginner-friendly guide through the kernel, so you might go with this.

    Of course, this approach (and the literature) is just a suggestion on how to become a Linux programmer. While this might work for me (still on my way though), it doesn't mean that there isn't a better way for you.

    Good look!

    best regards,
    phil
    Amol Patil likes this.
  7. AVESH RAI

    AVESH RAI New Member

    Messages:
    4
    Likes Received:
    2
    Trophy Points:
    3
    @nixsavy and @MikeyD ........... yaa I have done programming in C/C++
    Can u please tell me how to modify or generate new system calls in the kernel ?
    I tried a lot but couldn't find it ?
    Thank u
    DevynCJohnson likes this.
  8. DevynCJohnson

    DevynCJohnson Super Moderator Staff Member Staff Writer

    Messages:
    973
    Likes Received:
    857
    Trophy Points:
    93
    This is a really interesting question. Could you ask in a new thread?

Share This Page