Re: The machine stack and the C language



In article <87fxwhdop8.fsf@xxxxxxxxxxxxxxx>,
Keith Thompson <kst-u@xxxxxxx> wrote:
But the only reason to
execute "/bin/true --version" with the expectation of having it do
nothing is deliberate conformance testing. There's no real-world
reason to give it an argument at all.

Real life example:

Portable(-ish) Makefiles with a step that would normally be
ar -t (topological sort on the archive contents) but that step
is unneeded or unimplemented on some architectures. The usual
solution is to parameterize the program name as a variable in
the makefile, and for those architectures that do not need or
support the step, use /bin/true or ':' (colon) as the program name,
taking advantage of the fact that arguments will be ignored but
the step will be considered to succeed.

--
'Roberson' is my family name; my given name is 'Walter'.
.



Relevant Pages

  • Re: [patch] kbuild: building with a mostly-clean /usr/src/linux and O=
    ... makefiles asm-offsets.s (or however the specific architectures call ... this) now need their dependencies on include/linux/version.h changed (I ... prepare1: prepare2 outputmakefile ...
    (Linux-Kernel)
  • Re: Make file
    ... > is there a way to create a make file that is generic for any compiler? ... This is part of the reason that Makefiles aren't ... you'll have to look to a Linux/Unix newsgroup. ...
    (alt.comp.lang.learn.c-cpp)
  • Re: Cannot use cvsup
    ... >> I can't use cvsup for some reason. ... if i go into all of my ports, there are no makefiles. ...
    (freebsd-questions)
  • Re: Why leave the error handling to the caller?
    ... Nothing OT on the library debate. ... How to use makefiles so that the people you ship the source to don't need to know how to link is OT, and that is what I am suggesting was the better approach. ... The details of makefiles are OT, but the reason you can link up a library in minutes whilst it takes me an hour or more is certainly topical, and very interesting. ... Personally I don't think I'm as good as my colleagues do and certainly don't consider myself to be brilliant, but our respective abilities are not topical here. ...
    (comp.lang.c)
  • Re: Using -traditional in EXTRA_AFLAGS
    ... Glauber de Oliveira Costa wrote: ... is there any particular reason we're using -traditional in ... EXTRA_AFLAGS in Makefiles? ...
    (Linux-Kernel)