On Mon, Sep 01, 2025 at 03:55:55PM -0400, Thomas Dickey wrote:
> On Tue, Aug 26, 2025 at 07:21:02PM +0200, наб wrote:
> > Package: cproto
> > Version: 4.7x-1
> > Severity: normal
> > Tags: upstream
> > 
> > Dear Maintainer,
> > 
> >   cproto -E '/bin/cpp' -D'ARGS_DECL(...)=__VA_ARGS__' -{P,F,C}"int f(a, b)" 
> > exec.c
> >   /* exec.c */
> >   sh: 1: Syntax error: "(" unexpected
> > and a strace reveals
> >   3076044 execve("/bin/sh", ["sh", "-c", "/bin/cpp 
> > -DARGS_DECL(...)=__VA_A"...], 0x7fff30971dc0 /* 32 vars */ <unfinished ...>
> > this seems obviously wrong, considering that -D is described as
> >   This option is passed through to the preprocessor
> 
> actually it's what you get with popen.
> The updated manpage says it uses a pipe.

The updated manpage also clarifies the known limitations of cproto's
built-in support for preprocessor directives which prevent its being
used for general-purpose transformation of source code.

This bug can be either closed (wontfix) or changed to a wishlist item.

In either case, it's unlikely that someone's going to write a full-fledged
C preprocessor which can be used in this application.

-- 
Thomas E. Dickey <[email protected]>
https://invisible-island.net

Attachment: signature.asc
Description: PGP signature

Reply via email to