Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Linux Programming Essentials

Tags:

c++

linux

I was just thrust into Linux programming (Red Hat) after several years of C++ on Win32. So I am not looking for the basics of programming. Rather I am looking to get up to speed with things unique to the Linux programming world, such as packages, etc. In other words, I need to know everything in https://www.redhat.com/courses/rhd251_red_hat_linux_programming/details/ without spending 3K. Any ideas of how I can acquire that knowledge quickly (and relatively cheaply)?

Update: The things that I am used to doing on Windows like building .exe and dlls using VC++, creating install scripts etc are just done differently on Linux. They use things like yum, make and make install, etc. Things like dependency walker that I take for granted in the windows world constantly send me to google while doing linux. Is there a 'set' of new skills somewhere that I can browse or is this more of a learn as you go?

The primary problem is this: As a very experienced programmer in Windows,I am having to ask simple questions like what's the difference between usr\bin and usr\local\bin and I would like to be prepared.

like image 720
Jason Hunter Avatar asked Nov 04 '10 14:11

Jason Hunter


2 Answers

Edited because I had to leave a meeting when I originally submitted this, but wanted to complete the information

Half of that material is learning about development in a Unix-like environment, and for that, I'd recommend a book since it's tougher to filter out useful information from the start.

I'd urge you to go to a bookstore and browse through these books:

  • Advanced Programming in the Unix Environment by Stevens and Rago - this book covers threads, networking, IPC, signals, files, process management
  • Unix Network Programming, Volume 1 by Stevens - This book is focused on network programming techniques, design - you might not need this until much later
  • Unix/Linux System Administration - This book covers the more system administrator side of stuff, like directory structure of most Unix and Linux file systems (Linux distributions are more diverse than their Unix-named counterparts in how they might structure their file system)

    Other information accessible online:

  • GCC Online Manual - the comprehensive GNU GCC documentation

  • Beej's network programming guide - A really well written tutorial to network programming with the use of the BSD API. If you have done work with winsock, this should be mostly familiar to you.
  • Red Hat Enterprise Linux 5's Deployment Guide - talks specifically about Red Hat EL 5's basic administrative/deployment, like installing with package manager, a Red Hat system's directory structure...
  • make - Wikipedia article that will have links to the various make documentation out there
  • binutils - These are the Linux tools used for manipulating object/binaries.
  • GNU Build System - Wikipedia article about the traditional build system of GNU software, using autoconf/automake/autogen

Additionally, you will want to learn about ldd, which is like dependency walker in Windows. It lists a target binary's dependencies, if it has any.

And for Debugging, check out this StackOverflow thread which talks about a well written GDB tutorial and also links to an IBM guide.

Happy reading.

like image 83
逆さま Avatar answered Oct 29 '22 09:10

逆さま


that is quite a large and diverse topic list. for the programming part i think the C++ library should be portable, things that are not should be documented. for the linux-admin part, i suggest you try to use linux as your main desktop system, as many notions are absorbed via day to day work, there is no magic tutorial

like image 1
uovobw Avatar answered Oct 29 '22 11:10

uovobw