groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

HEAD build failure with OpenBSD yacc


From: Lennart Jablonka
Subject: HEAD build failure with OpenBSD yacc
Date: Mon, 4 Mar 2024 20:35:24 +0000

Hi Branden!

With commit 7b47855abd65 ("Update gnulib submodule."), groff doesn’t build anymore with OpenBSD yacc, even with the std::atexit thing fixed.

Gnulib headers pretending to be C standard library headers (lib/sys/types.h and the like) started requiring to be included after config.h. Turns out, not all appearances of #include directives for headers from the C standard library are directly controlled by the programmer: OpenBSD’s yacc, for example, starts its output (for example, src/preproc/refer/label.cpp) with:

        #include <stdlib.h>
        #include <string.h>

giving you error messages such as these:

        In file included from src/preproc/eqn/eqn.cpp:1:
        In file included from ./lib/stdlib.h:36:
        In file included from /usr/include/c++/v1/stdlib.h:94:
        In file included from /usr/include/stdlib.h:42:
        ./lib/sys/types.h:28:3: error: "Please include config.h first."
         #error "Please include config.h first."
          ^
        In file included from src/preproc/eqn/eqn.cpp:1:
        ./lib/stdlib.h:45:3: error: "Please include config.h first."
         #error "Please include config.h first."
          ^
        In file included from src/preproc/eqn/eqn.cpp:2:
        ./lib/string.h:52:3: error: "Please include config.h first."
         #error "Please include config.h first."
          ^



reply via email to

[Prev in Thread] Current Thread [Next in Thread]