[rescue] The Machine Emulator (TME) on a Mac?
bear at typewritten.org
Wed May 7 21:25:05 CDT 2014
On May 7, 2014, at 7:12 PM, Mouse wrote:
>> 1) non-portable use of echo -n.
> I'm not sure how fair it is to call this nonportable when every other
> way to suppress the newline is also nonportable; the echos that take \c
> generally don't take -n, and conversely.
It's perfectly fair, and at the same time you are absolutely correct to
describe \c as non-portable too. The correct approach is either to test and
adapt, or arrange your s**t so it doesn't NEED an echo without a newline.
Strings can be concatenated before they are printed, it's not rocket science.
>> (on linux /bin/sh is the same thing as bash, [...])
> This must be at least somewhat distro-dependent; I've recently been
> subjected to Linux at work, and on that machine (Ubuntu of some stripe,
> I think it is) sh and bash are different. IIRC sh is ash.
I was making a probably unfair overgeneralization. But in any case, the Bourne
shell does not have "echo -n", and when you say, "/bin/sh" you should treat
what you get as if it is the Bourne shell. If you don't want to write a Bourne
shell script, don't start it with #! /bin/sh.
...or as it actually is in this case, start your script with #! /bin/sh but
then ignore it and invoke /bin/sh (as $(SHELL)) directly in your Makefile,
which is what allows CONFIG_SHELL to do the trick.
> Actually, you don't need GNU tr; BSD tr - or NetBSD tr at least - works
> fine with that. (Not that this is a reason to not change it, of
> course; just pointing out that "unless you have gnu tr" is not actually
Fair enough. (I might've guessed that would come up.)
until further notice
More information about the rescue