[rescue] GNU != Unix (was: PC v. PeeCees? (was: IBM hard

Jonathan C. Patschke jp at celestrion.net
Sun Jul 14 19:04:20 CDT 2002


On Sun, 14 Jul 2002, Eric Dittman wrote:

> And before that it was SunOS, x.yBSD, SxRy, etc.  Expecting portability
> to a different Un*x platform for a program written on another Un*x
> platform is wishful thinking.

Bah!  For the majority of simple programs, the problems are analogous to
writing HTML that renders properly on multiple browsers--you code against
a good POSIX manual, not your OS.

Potentially complicated things like file-locking, terminal control,
signals, threads, and semaphores, can introduce fun-with-#ifdef, but still
shouldn't be wholly unworkable, as the behaviors of most platforms are
well-documented.

> I blame this on a combination of lazy programming and poor
> documentation.  Failure to test is another problem.

Absolutely.  However, this isn't wholly the fault of the programmer.  I
have yet to find a good general-purpose test-harness for doing automated
software testing.  While writing one for your project is something that
could easily be construed as part of the development process, it's all too
easy to get caught up in fixes and new features, rather than writing
software that helps you write software.

I started work on one, but have yet to finish it.  I should clean-up and
release the source one of these days so that someone else might finish it.

> Poor testing and lazy programming have plagued the Un*x world for a long
> time, for all distributions and kernels (think of all the buffer-overrun
> exploits that still show up).

I believe everyone who intends on releasing software for public
consumption on a Unix-like OS should read at least two of the following
(in addition to a good POSIX.1 and POSIX.4 manual):

  * Code Complete, Steve McConnel, Microsoft Press[1], ISBN: 1-55615-484-4
  * The Pragmatic Programmer, Hunt & Thomas, Addison-Wesley, ISBN:
    0-201-61622-X
  * The Practice of Programming, Kernighan & Pike, Addison-Wesley, ISBN:
    0-201-61586-X


[1] Don't discount this book because of its publisher.  This is quite
    possibly the most valuable book I've ever seen on the subject of
    producing source code that may be used by others (either as part of
    the same team, or in the distributed case of open-source software).

-- 
Jonathan Patschke
  "gnu: we aim to fuck up everything with the potential to not suck"
                                                   --alex j avriette



More information about the rescue mailing list