Last week I submitted a message to the list describing a problem with
pl35 and FvwmM4. Arguments meant for FvwmM4 were, for some reason,
passing to fvwm itself. Even simple lines like
fvwm -f "FvwmM4 .fvwmrc"
weren't working correctly. In the above example, I'd get an error
stating that ".fvwmrc" wasn't an option to fvwm.
Well folks, I feel pretty silly. I've learned yet again how Unix can
give you enough rope to shoot yourself in the foot. (Sorry for the
tortured analogy there...)
I run on multiple architectures -- Sun (mostly), SGI, and HP. To make
things easier for me, most of the files in my binary directories are
actually hardlinks to a shell script that figures out what
architecture I'm on, selects the appropriate directory of binaries,
and executes the chosen binary.
One of the Korn shell's more obscure quoting mechanisms is at the
heart of what tripped me up last week. The last line of my execution
script looks something like this:
exec $BINDIR/$ARCHDIR/$PROGRAM $_at_
By using $_at_ , any command-line arguments I pass to the script go on
to the real program.
But! Here's the catch. That line should really look like this:
exec $BINDIR/$ARCHDIR/$PROGRAM "$_at_"
Those double-quote marks around $_at_ made all the difference. The
reason: without the double quotes, command-line arguments are combined
and passed along as a single string. If "$_at_" is used, command-line
arguments are kept separate from each other.
So, it's no surprise fvwm was complaining about the command-line args.
It was getting exactly what I gave it! (grrr..)
Now that that's fixed, I'm running both pl35 *and* FvwmM4 with no
problems. Thanks to everyone for their help.
(For those interested in the details of my little goof-up, e-mail me
directly and I'll give you the scoop. Since my real problem was more
related to shell programming than Fvwm, I feel it's outside the scope of
the list.)
Christopher W. Taylor | You know you've been on the Net too long
shaggy_at_av8r.dwc.edu | when you're reading a book next to your
shaggy_at_mv.mv.com | computer and you press the computer's
God is an iron. | space bar at the end of the book's page.
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to majordomo_at_hpc.uh.edu.
To report problems, send mail to fvwm-owner_at_hpc.uh.edu.
Received on Thu Sep 28 1995 - 22:20:18 BST