On 7 November 2013 14:55, Jim Meyering <[email protected]> wrote:

> Can you investigate, e.g., instrumenting those rules to see what's
> happening (then I don't have to ask for instructions on how to
> reproduce :-), for example, by, inserting "| tee /tmp/1" or similar in
> piplelines to see what intermediate results look like?
>

Thanks for the gentle hint. Initially, I get the following functions output:

defaultpapername
defaultpapersizefile
paperdone
paperfirst
paperinfo
paperinit
paperlast
papername
papernext
paperprev
paperpsheight
paperpswidth
paperwithsize
systempapername
systempapersizefile
the above functions should have static scope

and the following from the first sort -u result:

^__.*$
^main$
^psdimension$
^unitfactor$
^usage$

So everything seems correct (the files in the second extract are static;
the rest are not).

After some rummaging, I found the problem. The following pipeline:

      grep -h -A1 '^extern .*[^;]$$' $$src                \
        | grep -vE '^(extern |--)' | sed 's/ .*//'

was coming up with an empty line, by making:

extern _GL_ATTRIBUTE_CONST const char* defaultpapersizefile(void) {
    return PAPERCONF;

into an empty string. This was then later -v-matching every line of a list
of functions, and hence no error was generated.

I guessed at this point that I was supposed to do GNU-style declarations.

Bingo!

There's nothing in the documentation about this assumption, AFAICS.

Reply via email to