[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: /lib/cpp not found in c-mode
From: |
Eli Zaretskii |
Subject: |
Re: /lib/cpp not found in c-mode |
Date: |
Fri, 06 May 2005 15:34:13 +0300 |
> From: Nick Roberts <address@hidden>
> Date: Fri, 6 May 2005 09:02:51 +1200
> Cc: Eli Zaretskii <address@hidden>, address@hidden,
> address@hidden
>
> Stefan Monnier writes:
> > >> ((not (file-executable-p "/lib/cpp")) "gcc -E -C -")
> >
> > > Right, but please amend this to look for cpp.exe etc. on systems that
> > > need that (or perhaps file-executable-p should try that
> > > automatically?).
> >
> > Or maybe (executable-find "/lib/cpp"),
>
> Since its a trivial change for someone who knows what the right change is,
> could you or Eli make it please. I think my changes are more general, but
> theres not much point in them being continually reviewed for correctness.
Done. I preferred to use locate-file instead of executable-find,
since the latter would load another package.
The new version is below, in case someone wants to comment.
(defcustom c-macro-preprocessor
(cond ;; Solaris has it in an unusual place.
((and (string-match "^[^-]*-[^-]*-\\(solaris\\|sunos5\\)"
system-configuration)
(file-exists-p "/opt/SUNWspro/SC3.0.1/bin/acomp"))
"/opt/SUNWspro/SC3.0.1/bin/acomp -C -E")
((locate-file "/usr/ccs/lib/cpp"
'("/") exec-suffixes 'file-executable-p)
"/usr/ccs/lib/cpp -C")
((locate-file "/lib/cpp"
'("/") exec-suffixes 'file-executable-p)
"/lib/cpp -C")
;; On some systems, we cannot rely on standard directories to
;; find CPP. In fact, we cannot rely on having cpp, either,
;; in some GCC versions.
((locate-file "cpp" exec-path exec-suffixes 'file-executable-p)
"cpp -C")
(t "gcc -E -C -o - -"))
"The preprocessor used by the cmacexp package.
If you change this, be sure to preserve the `-C' (don't strip comments)
option, or to set an equivalent one."
:type 'string
:group 'c-macro)
- Re: /lib/cpp not found in c-mode, (continued)
- Re: /lib/cpp not found in c-mode, Jan D., 2005/05/03
- Re: /lib/cpp not found in c-mode, Magnus Henoch, 2005/05/03
- Re: /lib/cpp not found in c-mode, Nick Roberts, 2005/05/04
- Re: /lib/cpp not found in c-mode, Stefan Monnier, 2005/05/05
- Re: /lib/cpp not found in c-mode, Eli Zaretskii, 2005/05/05
- Re: /lib/cpp not found in c-mode, Stefan Monnier, 2005/05/05
- Re: /lib/cpp not found in c-mode, Nick Roberts, 2005/05/05
- Re: /lib/cpp not found in c-mode,
Eli Zaretskii <=
- Re: /lib/cpp not found in c-mode, Nick Roberts, 2005/05/07
- Re: /lib/cpp not found in c-mode, Eli Zaretskii, 2005/05/08
- Re: /lib/cpp not found in c-mode, Nick Roberts, 2005/05/08
- Re: /lib/cpp not found in c-mode, Richard Stallman, 2005/05/08
- Re: /lib/cpp not found in c-mode, Eli Zaretskii, 2005/05/08
- Re: /lib/cpp not found in c-mode, Richard Stallman, 2005/05/08
- Re: /lib/cpp not found in c-mode, Stefan Monnier, 2005/05/08
- Re: /lib/cpp not found in c-mode, Eli Zaretskii, 2005/05/08
- Re: /lib/cpp not found in c-mode, Eli Zaretskii, 2005/05/08
- Re: /lib/cpp not found in c-mode, Stefan Monnier, 2005/05/08