Mark Whitis's Website Home Page Linux Book: Linux Programming Unleashed My Resume Genealogical Data Contact Info Security About

[HOME(Mark Whitis)] [Contact] [Resume] [Browser Friendly] [No Spam] [FEL] [DBD]

Linux Programming Unleashed

This page contains information about the book Linux Programming Unleashed, which I coauthored, as well as information for readers of the book.

[Cover Image]
Title: Linux Programming Unleashed
Authors: Kurt Wall, Mark Watson, and Mark Whitis
Publisher: Sams (Macmillan Computer Publishing)
ISBN: 0-672-31607-2
LC Card Number: 98-89984
Publication Date: Aug 27, 1999
Pages: 844
Cover Price: $49.99
Street Price: $27 to $40
Size: 7-3/8"x9-1/8"x2"x1-3/4"
Weight: 3 Lbs

Now Availible

September 3, 1999: Amazon has the book in stock now. It has been sighted in stock at several local bookstores.

About the book

This is an intermediate to advanced book on programming for the Linux Operating System. The reader should already be proficient in C or C++ programming.

About these pages

These pages have info on for those possibly interested in purchasing the book as well as updates, corrections, and software listings and packages for those who already have the book.

Author's Home Pages

Buy a copy

This book is availible from amazon.com and many local bookstores.

Buy now from amazon.com
Order Linux Programming Unleashed from amazon.com for $39.99

Local Resellers

I have seen copies of the book for sale in the following bookstores in Charlottesville, VA: Barnes and Noble, B. Dalton, and Sam's Club. Sam's, a wholesale club, had it for about $27 for a little while, almost half off the cover price.

The case of the missing CD-ROMs

The publisher decided at the last minute not to include a lisging CD-ROM with the book and didn't correct the many references to the CD-ROm. I guess they decided readers could just get the files from the web site but they didn't put the files up there by the time the book shipped. Their Support Page [broken link, see below] now, finally, has the files. I also made reference to the RedHat CD-ROMs which were originally going to be included;if you need any files referenced from those cdroms, visit RedHat; the entire redhat 6.0 distribution is availible on their ftp site. You can also purchase the shrink wrapped distribution from RedHat or get cheap copies of the CD-ROMs for $3 from Linux Central. Redhat 6.1 is was anounced on Oct 4, 1999.

Note that the link above has been broken. The new page for the first edition is at http://www.samspublishing.com/title/0672316072 and the downloads are at http://www.samspublishing.com/content/images/0672316072/downloads/code.zip

My Chapters

Please report errata on my chapters to me (using the email address below). Report errata on other chapters to the appopriate authors (links to their pages can be found above).

Listings

Here are the listing files for my chapters. Visit the other authors web sites for listings for their chapters.

Newer versions of some of these are availible on my software page.

Table of Contents

Part IThe Linux Programming Toolkit
1Overview Kurt Wall
2Setting Up a Development System Mark Whitis
3Using GNU cc Kurt Wall
4Project Management Using GNU make Kurt Wall
5Creating Self-Configuring Software with autoconf Kurt Wall
6Comparing and Merging Source Files Kurt Wall
7Version Control with RCS Kurt Wall
8Creating Programs in Emacs Kurt Wall & Mark Watson
Part IISystem Programming
9I/O Routines Mark Whitis
10File Manipulation Mark Whitis
11~Process Control Mark Whitis
12Accessing System Information Mark Whitis
13Handling Errors Mark Whitis
14Memory Management Kurt Wall
Part IIIInterprocess Communication and Network Programming
15Introduction to IPC: Using Pipes Mark Watson
16Message Queues Mark Watson
17Shared Memory Mark Watson
18Semaphores Mark Whatson
19TCP/IP and Socket Programming Mark Watson
20UDP: The User Data[sic] Protocol Mark Watson
21Using Multicast Sockets Mark Watson
22Non-blocking Socket I/O Mark Watson
23A C++ Class Library for TCP Sockets Mark Watson
24Using Libraries Kurt Wall
25Device Drivers Mark Whitis
Part IVProgramming the User Interface
26Terminal Control the Hard Way Kurt Wall
27Screen Manipulation with ncurses Kurt Wall
28X Window Progrmming Mark Watson
29Using Athena and Motif Widgets Mark Watson
30GUI Programming Using GTK Mark Watson
31GUI Programming Using QT Mark Watson
32GUI Programming Using Java Mark Watson
33OpenGL/Mesa Graphics Programming Mark Watson
Part VSpecial Programming Techniques
34Shell Programming with GNU bash
35Secure Programming Mark Whitis
36Debugging: GNU gdbKurt Wall
Part VIFinishing Touches
37Package Management Kurt Wall
38Documentation Kurt Wall
ApendicesApendeces
39Licensing Kurt Wall
AA Symbol Table Library Mark Whitis
BGNU General Public License Free Software Foundation

Information for readers

Links

The links for my portion of the book.

Contact Information

All correspondence to me regarding the book should be sent to unleashed@mail.freelabs.com and should include "[Unleashed]" in the subject. No phone calls. No SPAM.

Listing

These are the versions which were submitted to the publishers for inclusion on the CD-ROM. Newer versions may be availible on my software page.

Related Pages (My content)

Notes, Erratta, and Updates

Chapter 2: Setting up a development system

In chapter 2, I mention that you can find certain documents on one of the acompanying CD-ROMS; unfortunately, the publisher omitted the CD-ROMs without bothering to correct the text.

I mentioned the Slink-e interface which allows you to control most consumer electronics. The device did not have a linux driver but the protocol was documented. I now have a Slink-e so there might be a Linux driver in the foreseable future.

The mentioned X10 CM10a interface which allows carrier current control of lights and appliances connected to X10 modules is controlled by the program "heyu". I have noticed a problem with that program. It will not run correctly unless I have used pppd on the same line previously. Since I haven't been able to isolate the critical port settings yet, I run pppd :-).

At the time this chapter was written, it was hard to find inexpensive tulip cards based on the prefered 21140 chips. Now that the newer tulip drivers should be availible on most current linux distributions, it should be ok to use the more 21143 chips or clones and inexpensive tulip compatible boards are availible. Linksys LNE100TX Etherfast 10/100 cards are readily availible ($25 from NECX,$30 from Data Comm Warehouse and at your local Staples or Office Depot. These are based on tulip clones (PNIC or Linksys relabled PNIC) which work with recent versions of the tulip driver (Including those shipped with Redhat >=5.2). Linksys has a Linux Support Page for these cards and they even include Linux drivers on the disk.

If you don't really need to buy a new printer, don't. Try to avoid supporting the manufacturers who make printers and don't document or provide drivers for them. All of the major inkjet printer manufacturers make printers which are not documented. The newer a printer is, the less well it is likely to be supported under Linux. So, you might be better off spending $35 at your local thrift store for an old printer. You can print text ok on most printers except most windows only printers. But if you want good quality photo printing, which many of us expect these days, your options are very limited. If I were to buy a new printer now, it would probably be a Epson 740 or 640. Other candidates might be an HP 880C or a Lexmark Optra 40. I have not used any of these, however.

Check the Printing HOWTO Support Database for more information on the support of various printers; note that it tends to be a little too optimistic, however. You will also note that most of the printers which are well supported turn out not to be in production any more.

I have written a driver for Costar label printers and Costar has donated printers in support of this effort.

Chapter 25: Device Drivers

In this chapter I show how to write a loadable kernel module device driver. I also explain when usermode device drivers are more appropriate. Scanners should be supported through SANE and printers through Ghostscript (directly or through a PBM filter). Real time video capture devices should be supported through video4linux.

Although, I reported that Quickcam 's work, avoid all the newer Quickcam's. The manufacturer has reverted to their prior bad habbits regarding documentation.

Since this chapter was written, I have written a device driver for many of the common label printers (Avery Personal Label Printers and Costar Labelwriter XL). This device driver runs in user mode and takes input in Plain PBM format. A PBM driver will work with any version of Ghostscript and is a separate program so there are no licensing issues to worry about. New: costar contacted me and volunteered to send me their newer printers for development and testing purposes.

There were some compilation problems with the stepper driver on 2.2.x kernels due to significant incompatibilities introduced in the new kernel. Working on fixes.

The parameters are backwards on verbose_outb() and outb() in a couple places. It is outb(value, port) rather than outb(port, value);

Newer kenels (such as 2.2 and 2.4) introduce various incompatibilities that prevent the sample device driver, or one written according to the instructions, to fail to compile. I have written some notes on porting old device drivers to linux kernel 2.4

Chapter 35: Secure Programming

From:
  sprintf(command, "fgrep -i %s address.book", name);
  system(name);
To:
  sprintf(command, "fgrep -i %s address.book", name);
  system(command);

Publisher's site

Their Support Page now, finally, has the files which would have been on the CD-ROm which the publisher decided to omit at the last minute.

If you are foolish enough to enable JAVA on your web browser, you might also try visiiting the SAMS Publishing web site; if you have JAVA disabled, are behind a firewall which blocks JAVA, have a visual disability, or are using a text mode browser the SAMS web site is useless. The links above allow you to bypass the disfunctional navigation pages to get directly to the pages relevent to this book.

Second Edition

I did not choose to be involved in the rewrites for the second edition. The downloads for that edition are at: http://www.samspublishing.com/content/images/0672320215/downloads/code.tar.gz . Note that the first edition is readily availible used for a few bucks.

Affiliates

I have my own company, Free Electron Labs, and I worked for DBD Group. Both contributed to the book.

In association with amazon.com As a member of the Amazon Associates program, I recieve a commision for each copy of the book which is ordered by clicking on the "Buy Now" link above. Indeed, this is the only way I directly profit from increased sales of the book since I don't get residuals. I am also a satisfied amazon.com customer; I am not easily satisfied, either.

This file is maintained by Mark Whitis (unleashed@mail.freelabs.com).

Senior Engineer for hire
Software Development - Electronic Design - Embedded Systems - Device Drivers - System/Network Administration and Security - Motor Control, RobotCNC - Linux/Un*x - 25+ years experience
The author of these pages is looking for a new gig.
[RESUME]

Engineers and electronic hobbyists: The new Open Symbol Project is creating open schematic symbols and PCB footprints for a variety of different CAD packages.

Mark Whitis's Website Home Page Linux Book: Linux Programming Unleashed My Resume Genealogical Data Contact Info Security About

All email messages received must pass the turing test or they will be considered SPAM. If it could have been written by a machine, it was.

Under no circumstances are you to email me with questions regarding windoze, any other microsoft operating system or application, or any software which runs under any form of windoze.

*