Skip to content

Failed to build ksim-stub@sha/avx-builder.c.o #1

@nanley

Description

@nanley

I get the following error attempting to build ksim on Arch Linux:

$ ninja -C build/
ninja: Entering directory `build/'
[3/19] Compiling c object 'ksim-stub@sha/avx-builder.c.o'
FAILED: ksim-stub@sha/avx-builder.c.o
ccache cc  '-Iksim-stub@sha' '-fdiagnostics-color=always' '-I..' '-I.' '-pipe' '-Wall' '-Winvalid-pch' '-fvisibility=hidden' '-Wall' '-march=native' '-mrtm' '-D_GNU_SOURCE' '-O0' '-g' '-fPIC' '-I/usr/include/libdrm' '-I/usr/include/libpng16' '-MMD' '-MQ' 'ksim-stub@sha/avx-builder.c.o' '-MF' 'ksim-stub@sha/avx-builder.c.o.d' -o 'ksim-stub@sha/avx-builder.c.o' -c ../avx-builder.c
In file included from ../avx-builder.h:1:0,
                 from ../avx-builder.c:28:
/usr/include/bfd.h:35:2: error: #error config.h must be included before this header
 #error config.h must be included before this header
  ^~~~~
[4/19] Compiling c object 'ksim-stub@sha/eu.c.o'
FAILED: ksim-stub@sha/eu.c.o
ccache cc  '-Iksim-stub@sha' '-fdiagnostics-color=always' '-I..' '-I.' '-pipe' '-Wall' '-Winvalid-pch' '-fvisibility=hidden' '-Wall' '-march=native' '-mrtm' '-D_GNU_SOURCE' '-O0' '-g' '-fPIC' '-I/usr/include/libdrm' '-I/usr/include/libpng16' '-MMD' '-MQ' 'ksim-stub@sha/eu.c.o' '-MF' 'ksim-stub@sha/eu.c.o.d' -o 'ksim-stub@sha/eu.c.o' -c ../eu.c
In file included from ../avx-builder.h:1:0,
                 from ../eu.c:38:
/usr/include/bfd.h:35:2: error: #error config.h must be included before this header
 #error config.h must be included before this header
  ^~~~~
[8/19] Compiling c object 'ksim-stub@sha/stub.c.o'
ninja: build stopped: subcommand failed.

I'm not sure what the appropriate fix is, but defining PACKAGE above the include avoids the error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions