







Building Applications with the Linux Standard Base 282
Building Applications with the Linux Standard Base | |
author | Core Members of the Linux Standard Base Team |
pages | 246 |
publisher | Pearson plc publishing as IBM Press |
rating | 8 |
reviewer | Ray Lodato (rlodato AT yahoo DOT com) |
ISBN | 0131456954 |
summary | Very dry reading, but a lot of useful information packed into a slim 246 pages. |
I've been involved with IBM products and documentation since the late '70s, and their documentation has traditionally come in two flavors: user's guides, and reference manuals. The former are meant to be read cover-to-cover (more or less), and the latter are meant to be looked at for specific bits of information. This book falls more to the reference manual side of the spectrum. Consequently, reading it cover-to-cover was a little dry, but the information needed to get an application certified with the Linux Standard Base (LSB) was clearly laid out.
Building Applications with the Linux Standard Base (published by IBM Press and available on your favorite bookstore sites) is laid out in five large parts: Introduction, Developing LSB Applications, Certifying for the LSB, Contributing to the LSB Project, and Using LSB Resources. Except for the first part (Introduction), the book gives specific examples, and many, many references to the opengroup.org website's sections on the LSB.
It becomes obvious as you go through the book that the Linux Standard Base is still evolving. The authors (13 core members of the LSB team) frequently allude to how the project can (and should) be extended to increase its scope and sophistication. Two chapters (Adding New Interfaces..., and Adding New Architectures...) cover (albeit skimpily) what's needed to update the specification.
Backing up for a moment, Part II (Developing LSB Applications) describes in detail (with examples) the Dos and Don'ts of coding practices. It then explains carefully how an application should be packaged for distribution (RPM), and finally wraps up with a section on porting Solaris apps to the LSB. In each chapter, step-by-step instructions are given when appropriate. Differences in filesystem hierarchy, signal handling, and program options are all laid out to help you through.
Part III goes over the LSB Certification process. Both runtime environments (distros) and applications are covered. Again, the book lays out the process in a step-by-step approach.
The last part in the book talks about the various resources available: the written spec, the test suites, and various usage guides. The chapter on using the LSB test suites shows how much thought went into making sure a successful test ensures a certifiable (in a good way) application.
All in all, Building Applications with the Linux Standard Base, has what you need if you're developing a commercial-grade Linux distribution or application. Once your product has passed the testing described inside, you can be confident that it will work on almost anything Linux. Very dry reading, but a lot of useful information packed into a slim 246 pages. I'd give it a 7 for writing style, but a 9 for content: total=8/10.
You can purchase Building Applications with the Linux Standard Base from bn.com. Slashdot welcomes readers' book reviews -- to see your own review here, carefully read the book review guidelines, then visit the submission page.
Standards (Score:4, Funny)
Re:Standards (Score:4, Funny)
Re:Standards (Score:2, Informative)
Actually, a variation on a standard authoritative quote:
The nice thing about standards is that there are so many of them to choose from.
-- Andrew S. Tanenbaum
Re:Standards (Score:2, Redundant)
The nice thing about standards is that there are so many of them to choose from.
Andrew S. Tanenbaum
Actually... (Score:5, Funny)
Re:Actually... (Score:2)
Now for me to write my drgroove loves java flame counter application that can be deployed across all distros.
Re:Actually... (Score:3, Interesting)
Not really. (Score:2)
Re:Actually... (Score:2)
All major or popular distros have a common GPL'ed JVM and standard libraries? About time.
Re:Actually... (Score:5, Funny)
Re:Actually... (Score:5, Informative)
...and I've see Java apps (i.e.InstallAnywhere [zerog.com]) that stopped running because a distro changed from XFree86 to X.Org. The (Sun) JVM was expecting a certain library to be there, it wasn't, and boom!! - it fall down...
Mandatory "Java Sux!" - me
Re:Actually... (Score:3, Insightful)
If the virtual machine is not working properly, it's like running an x86 executable on a sparc.
Re:Actually... (Score:5, Insightful)
Java apps aren't immune to dependency issues either and I'm not aware of any widespread effort on the scale of LSB to create a compatibility and deployment standard.
Dont forget the biggest dependency of all--you need a JVM to run Java. That still needs to be packeaged like any other app. Let me know when there is a GPL-compatible JVM, available in an LSB-compliant package that will install and run cross-distro...and wont break if you use a different X server or non-standard hardware...then we'll talk.
Yes, Java can be written once to run everywhere, but you often still have a few hurdles to clear during compilation and installation.
Re:Actually... (Score:2)
For your GUI: use SWT to use a GTK toolkit underneath. That will probably solve your X problems, and lets your Application have a native look and feel (which is a must IMHO
Re:Actually... (Score:2)
Re:Actually... (Score:5, Funny)
--A friend of mine, aka Orlphar
Re:Actually... (Score:2)
In conclusion, your statement ("Saying that Java is nice because it works on all OSes is like saying anal sex is nice because it works on all genders.") seems highly accurate.
Re:Actually... (Score:2)
"Write once - debug everywhere" is horribly true.
Re:Actually... (Score:2)
-bash: java: command not found
As long as their isn't a finished and useable Open Source implementation Java stays a major pain to use on an Open Source OS. Sure, Suns marketing speach might make you believe its portable, but I never had so much throuble with getting software to run than I had with java programms.
Re:Actually... (Score:2)
Re:No! (Score:2)
Re:No! (Score:2)
Swing-based GUIs do have a differing look and feel than native apps; IBM's SWT GUI toolkit resolves this issue by allowing Java GUIs to appear as native ones.
I haven't experiences the problem of Java not running smoothly on various OSes. Windows, OSX, Solaris, various Linux distros - no probs.
Re:No! (Score:2)
Yeah, but though SWT on any platform, and GTK+ on Win32 with a certain theme may _look_ like the native widgets, the problem is that they're not
Besides not "feeling" the same, some things that affect native widgets won't work with those since they're basically just bitmaps. For example, themes (think windowblinds, or XP themes engine on Win32; c
Re:No! (Score:2)
Actually, the rule is that unlike the Intel compiler, G++ is cross-platform. Unfortunately, the IA32 architecture is a bitch to compile for.
Most modern compilers are designed for modern architectures, and the GCC suite is no exception. Unlike a modern architecture, the IA32 has effectively zero integer registers and precisely zero floating-point registers (that you can actually treat as registers, anyway). Basically, the IA32
Re:No! (Score:3, Insightful)
Absolutely true, and I can't tell you how many times I've heard otherwise-talented programmers blame their development environment for performance or stability issues. My attitude is usually something on the order of "Stop your bitching, get off your ass and deal with it."
Conversely though, it is a good craftsman who picks the right tool for the job. Most languages can, to some degree, accomplish most tasks, just not necessarily well
Re:Actually... (Score:3, Interesting)
"As it is right now, it's a neat language whose practical applications are limited by the performance penalties."
Okay, so I've answered my own question: no. You may want to go and check out this company called IBM sometime.
And yes, I'm talking client side also. The Visual Paradigm UML tool is a nice example of a great Java app.
Re:Actually... (Score:3, Insightful)
I guess IBM, Oracle, SAP, Intel, Novell, Red Hat, Wind River, and others desperately need you as a consultant to tell them that they should stop using Eclipse and rewrite their developer tools in C. Why don't you email them and suggest that?
GNOME is pretty slow too. What's that written in again?
Re:Actually... (Score:4, Funny)
Oh, no no no. Java is "write once, run anywhere". Common Lisp, on the other hand, is "write anywhere, run once".
Non Sequitur (Score:5, Insightful)
Does anyone see how one thing is supposed to follow the other?
-Peter
Re:Non Sequitur (Score:2)
Re:Non Sequitur (Score:2, Insightful)
-Peter
Re:Non Sequitur (Score:4, Insightful)
Doesn't releasing something under GPL pretty much guarantee a loss of standardization? GPL = "Go, procreate and live".
EricHow to detect Internet Explorer [ericgiguere.com] using the headers
Re:Non Sequitur (Score:3, Funny)
Re:Non Sequitur (Score:2)
"linux standardization" (Score:5, Insightful)
Good luck to it. I'd love see a "works with linux" stamp, and have distro choice be completely irrelevant.
It's absolutely necessary if linux is to go anywhere worth going commercially.
Re:"linux standardization" (Score:3, Informative)
Check out the membership of the Free Standards Group (which governs the LSB) here [freestandards.org]. Note that it includes essentially all the significant commercial Linux d
Re:"linux standardization" (Score:4, Interesting)
Re:"linux standardization" (Score:3, Interesting)
There are those that feel it's not important. Those that feel it's absolutely critical. And those that claim it already exists.
Well, it is important and it doesn't already exist. Four package managers that usually work don't count as a standard. That's just the shotgun method of hoping one of them will hit the target.
What helps linux growth in one area hurts it in other areas. Developers and
Re:What we need--installation/uninstallation API (Score:2)
But of those 1%, about 0% of the community-based programs are like that. The 1% is almost purely commercial and/or closed source apps. So why should anyone bother? For
Re:What we need--installation/uninstallation API (Score:4, Interesting)
While this is true there are programs that ran on 98 that don't run on XP. If they don't make a newer version of the program you are SOL. With OSS you just recompile, which is relatively painless for small applications. Even if a simple recompile doesn't work it is still possible to modify the source to get it to work.
That way, GNOME and KDE could just be seperate shells on top of the same desktop, and they would happily run each other's apps.
That seems pointless to me. Why wouldn't you just make one shell with all the options of GNOME and KDE? It seems like after you got everything to work as one DE with different shells, you would only be one small step away from merging them completely into one.
I do think GNOME and KDE should integrate as much as they can to keep things compatible and consistent BUT it's good to have two seperate environments, especially since they seem to aim at different crowds. Also, competition is a good thing.
I'd also request a kernel driver API that unties them from the kernel--recompiling an entire kernel to support a new scanner I just bought is ridiculous. I should just be able to go online and download a special binary driver
I'm confused by this. You don't need to recompile your kernel to include a new driver. You can build modules without rebuilding the entire kernel. Also I build the madwifi-driver, which is partially proprietary and outside of the kernel, without having to recompile the kernel.
Re:What we need--installation/uninstallation API (Score:3, Informative)
You're FUDDing about the linux binary API, as I can install the quake 3 arena from 1999 (which I originally ran on redhat 5.2) on my suse 9.2 and it runs perfectly.
As to your windows backwards compatibility, you lose points for dishonesty. I know of quite a few w95/w98 apps that simply cras
Re:What we need--installation/uninstallation API (Score:2)
Somewhere around here I have Loki's Myth II for Linux CD from some time last century, and I'd bet that if I tried to install that now it would work fine, and if it didn't work it would be because I don't have the 5 year old C library compatibility package installed. Note that I'm not the least bit worried about what distro I'm runni
make configure (Score:2)
Z
Re:make configure (Score:2)
Re:make configure (Score:2)
No, the whole LSB thing is pretty well irrelevant to software. It's about binary package compatibility, and only really interesting or useful for people that want to try and sell linux binaries instead. Which is one of the reasons you'll find lots of important people (Volkerding comes to mind) either apathetic or openly contemptuous of the thing, while the support for it c
it's lame that... (Score:4, Insightful)
15% of the server market - mainstream to me. (Score:2)
http://asia.cnet.com/news/systems/0,39037054,3920
Re:it's lame that... (Score:2)
Re:it's lame that... (Score:2)
You have the choice between extensions being disabled (big deal--wait for them to be updated), or extensions breaking horribly, possibly causing data loss, when you upgrade...
Re:it's lame that... (Score:2)
Re:it's lame that... (Score:3, Insightful)
Re:it's lame that... (Score:3, Insightful)
Linux will not get to the desktop until such time as one can walk into a store (or online) and buy SUPERDEEDUPER Tools for Linux for 49.95 and have it work, out of the box on all the major distros (SuSE, Redhat, Fedora, Debian
Re:it's lame that... (Score:2)
Why's this? One of the big advantages of Linux is that anything you'd reasonably expect to find in SUPERDEDUPER TOOLS is prepackaged by your distributor.
In fact, even Windows has moved away from "go to the store and buy random crap" to "go on the net and download random
Re:it's lame that... (Score:2)
but for businesses applications, it's perfectly fine.
if you have to fear that your system "upgrades" are taking too long, your HA setup is flawed. it is not a risk, it should be part of your quality testing no matter if it's supposed to work or not.
my managers don't fear linux, in fact most of our shop is on linux. most applications Just Work, yet we STILL test them... even on s
Application level isn't such a problem (Score:4, Insightful)
That would make it easier for manufacturers to make linux supported hardware and know that it worked.
Every linux user needs linux compatible hardware, but relatively few need commercial software.
Re:Application level isn't such a problem (Score:2)
Re:Application level isn't such a problem (Score:2)
Actually, the author has a simple reccomendation:
Re:Application level isn't such a problem (Score:3, Insightful)
--- QUOTE from someone who doesn't get the problem
Simple, get your kernel driver into the main kernel tree (remember we are talking about GPL released drivers here, if your code doesn't fall under this category, good luck, you are on your own here, you leech
Extract from book (Score:4, Funny)
------
Characters in filename names are a rare commodity, to be used wisely.
Filenames should be abbreviated to the point of obfuscating any meaning:
Why use "print" when you can use "prin," why use "prin" when you can use
"pin," why use "pin," when you can use "xb."
Standard output formatting protocol
------
When printing a table of data to standard output, there is no need to
label rows and columns. Linux users are elite professionals, they
instantly know what the endless rows and columns of hex values,
abbreviated acronyms, and various other standard and non-standard
variables represent.
In the rare occasion that a Linux user is unsure what some data
represents, he will simply view the source, if the source is not
available, he will disassemble the executable, and read the assembly code.
If you must label columns and/or rows, please
follow guidelines set out by the "File naming protocol" section.
Re:Extract from book (Score:2)
Re:Extract from book (Score:3, Interesting)
In a previous job, I was (among other things) maintaining a tool for installing updates to a big vertical-market ap. We got a bug report that it was throwing errors over some file. On investigation, we found a java file with a file name over 100 bytes long, which was more than 'tar' could handle.
We could have done some workaround on 'tar', but instead we bounced it back to the developers and told them to fix their *#$*%&#^ file name
Re:Extract from book (Score:2)
Note that Java supports inner classes, and concatenates the inner class name to the name of the owner class. The class name
Re:Extract from book (Score:2)
The documentation?
Re:Extract from book (Score:2)
Sorry. In true
Re:Extract from book (Score:2)
Wow. You learn something every day. (Really, I just did.)
Re:Extract from book (Score:2)
Re:Extract from book (Score:2, Interesting)
From The Free On-line Dictionary of Computing (19 Sep 2003) [foldoc]:
Re:Extract from book (Score:2)
Oh, and I found out about man pages in the install guide that came with my distribution.
Re:Extract from book (Score:2)
Current version of KDE / Gnome (and at this point even previous versions going back a couple years) are realistically about as learnable by exploring as Windows or a Mac.
If you put a random person who is used to a Mac and has never used Windows or Linux before in front of a properly set up Linux machine he'll have no more trouble performing the following tasks than he would if it were a Windows machine - in neither case would I expect that he'd need the documentation:
Surfing the Web, Checking Em
metastandard (Score:4, Interesting)
"That's the nice thing about standards... there's so many to choose from!" - Anonymous PHB
Re:metastandard (Score:2)
Re:metastandard (Score:2)
FreeBSD has it figured out (Score:4, Interesting)
Actually, each distro has its own little additions and, consequently, quirks. Writing an application to work reliably under all variations is not a slam-dunk.
IMHO, this is one great advantage that the FreeBSD project has - there are no "distros".
Re:FreeBSD has it figured out (Score:2)
Re:FreeBSD has it figured out (Score:2)
Re:FreeBSD has it figured out (Score:4, Insightful)
What about Debian GNU/kFreeBSD [debian.org]? Isn't that the Debian distro of FreeBSD? Just because FreeBSD is still relatively obscure doesn't mean that its not going to end up in the same boat as Linux. Give it a couple more years.
Re:FreeBSD has it figured out (Score:2)
Re:FreeBSD has it figured out (Score:2)
Re:FreeBSD has it figured out (Score:2)
Re:FreeBSD has it figured out (Score:2)
Excellent! That means it's obvious who to sue.
Yours sincerely,
SCO Attack Lawyer Drone #23
Re:FreeBSD has it figured out (Score:3, Interesting)
Let's talk about "Desktop Distros of Unix" for a second. We have the following major players:
Solaris, FreeBSD, OpenBSD, NetBSD, Debian GNU/Linux, Slackware Linux, RedHat/Fedora Linux, Mac OS X, (many others)
Then there's non-unix desktop systems:
Windows
Now, for some odd reason Windows has the majority of desktop market share even though almost every other system o
Re:FreeBSD has it figured out (Score:2)
Saying (FreeBSD, Debian GNU/Linux) are a group the same as (Windows XP, Windows 98) are a group is meaningful:
FreeBSD and Debian can run the same binaries but need different drivers - the same as Windows XP vs. 98.
Re:FreeBSD has it figured out (Score:2)
Isn't that pretty much the same as saying, "That's the thing I like about Gentoo, there are no distros?"
No it wouldn't be, because Gentoo is not ultimately responsible for Linux kernel development or the GNU tools. In FreeBSD, the same entity is responsible for (and owns the copyright to) both kernel and userland, whereas in Linux, kernel, userland and packaging and distribution of either is controlled by different entities.
Re:FreeBSD has it figured out (Score:2)
Do I use urpmi, APT-GET or YaST to get the doc? (Score:2, Interesting)
I think, until a Steve Jobs or Bill Gates comes out with a killer apps with a corresponding toolkit that takes over the market, we'll be stuck in the same boat.
Oh reeeally.. (Score:3, Interesting)
So it turns out that Microsoft's mutant penguin ad compaign [geocities.com] was right all along?
For the past few years, I've been screaming about the negative effects of having so many different standards to choose from on Linux - this is why I personally use FreeBSD and OSX (well, okay, and Windows for games).
But the biggest problem (which also exists on FreeBSD), is QT. The shitty licence has caused so much damage by keeping cross-platform and commercial development off KDE (one of the most popular window managers). I know there's GTK, but I can't help think that Linux might have reached critical mass and become mainstream popular without it - GTK might not be perfect, but it is a STANDARD.
Monkey man Steve Balmer might have looked silly when he yelled it on stage, but he was right: "Developers, developers, developers." The Linux community should be bending over backwards to attract new developers into their flock, by making their passage into the fold as easy and as hassle-free as possible.
Chicken and the egg: applications for Linux, users for Linux. The Linux community can't force people to use Linux for the sake of using Linux, but they can bring applications to the platform - if they're worth using, users will follow.
Shitty license? (Score:3, Insightful)
It's not LGPL, sure. That means that commerical developers must buy a license from TrollTech or make the source to their application availible under the GPL. Not ideal for developers, but TrollTech are not a charity, and in my view they're rather generous to permit Qt to be used under the GPL (yes, it's just good business, but still...).
I'd like Qt under the LGPL - or heck, the BSD license - too, but I don't see a viable way t
Online version w/ GNU Free Documentation License (Score:5, Informative)
Radio Edit... (Score:3, Insightful)
s/a slam-dunk/possible/
Solution: Python, Perl, ANSI C, etc. i.e. don't code "for Linux" at all, just code. Of all the ports I've done, Linux is always the biggest pain in the arse, due to the joyous work of glibc, and of course Redhat's need to do everything their own way.
Re:Radio Edit... (Score:2)
Re:Radio Edit... (Score:2)
Re:Radio Edit... (Score:2)
Agreed. How many modern MS-Windows app developers are targeting the GDI? With "time to market" being so important, app developers need to consume as high up the protocol stack as possible. The same is true for linux app developers. Scanning the LSB spec, I expected recommendations for Qt or SWT; maybe glib as the lowest level API. Instead, I found that LSB has recommendations for libc, libGL, libX11, and libXt. These are way too low level for serious, modern app development.
I'm sorry for the LSB guys (Score:2)
If we pretend for one moment that Linux is all about the desktop market, the LSB is only going to have relevance to the top two or four distributions, period. The server market is more restrictive, only two distributions, most likely sharing the desktop market. Forget the embedded market totally.
NOTHING else will register, and there's no reason why it ever should.
Re:I'm sorry for the LSB guys (Score:2)
LSB is useless (Score:3, Informative)
The differences between Linux distros are what make Linux a vibrant community and drive innovation. I hope the LSB project fails miserably to remove those differences.
Re:LSB is useless (Score:2)
Re:How about building applications for unix? (Score:5, Interesting)
Second, SUS and other UNIX standards don't cover binary portability at all, which is usually far more interesting to _users_ than source compatibility. I haven't and never will look at the source of most the apps I run, but I _do_ know that I want to be able to run them. I don't want to have to compile things myself, wait for others to compile and package them, and/or hunt through hundreds of packages for the same software to find the one that works on my systme. I want to go to the upstream software's site, click Install Software, and have it work. And that's 100% feasible, assuming the apps sticks to a standard like the LSB and your distro is LSB compliant.
Third, there's also then the issue of proprietary apps which don't even have the option of making users compile the source. Unfortunately, there are proprietary apps out there, there are people who _want_ to use proprietary apps even in the face of existing OSS alternatives, and that's that. The LSB largely exists to serve those apps, in fact.
Re:How about building applications for unix? (Score:3, Insightful)
If this (LSB) actually takes off it could be what allows *nix to displace windows in the Joe Sixpack Desktop. All Joe currently knows is that he has a windows computer, so he looks for software that says Windows on it. With this as a replacement Joe's information complexity does not change just =~s/windows/LSB/g and Joe's happy.
What I see here instead is:
1) My way of implementing portability is best(Java)
2) No it's not (Pyth
Re:Don't hardcode paths (Score:3, Insightful)
I don't know why anyone would put system-wide configuration data anywhere else but in
Yah, but that's not what he's alluding to. What about
Hence, make it all configurable. Then you don't have to worry.
Re:look how these apps are built (Score:2)