On 7/31/21 6:33 PM, Bjarni Ingi Gislason wrote:
                  from ../src/devices/xditview/page.c:7:
./lib/unistd.h:663:3: error: #error "Please include config.h first."
   663 |  #error "Please include config.h first."
       |   ^~~~~

That's a problem. page.c should include config.h first. This is required of all Autoconf-using code.

  In my branch I have added the missing '#include "config.h"' in
../src/devices/xditview/page.c
and other missing "config.h" lines in other source files.

That sounds like the right thing to do, yes.

CPPFLAGS=-D_FORTIFY_SOURCE=2

  Changing the value from 2 to 0 or 1, eliminates the error.

I suggest configuring with the same flags that you build with, and if the flags seriously alter the API or ABI then putting them into CC. Something like this, perhaps.

  ./configure CC='gcc -D_FORTIFY_SOURCE=2'

This sort of thing can be needed if the -D option changes the API or ABI. The idea is that you want to configure with the same flags that you build with.

Reply via email to