3

Trying to compile gcc on an armhf embedded device but it halts when trying to compile libgcc with xgcc saying it can't find sys/cdefs.h

libc6 and libc6-dev are already installed and cdefs.h can be found at /usr/arm-linux-gnueabihf/sys/

how do i add /usr/arm-linux-gnueabihf to the xgcc include path?

normad
  • 115
  • 1
  • 10

2 Answers2

3

Needed to add --with-float=hard to the configure line.

This is because MULTIARCH_DIRNAME is defined based on the with-float configuration option

MULTIARCH_DIRNAME = $(call if_multiarch,arm$(ARM_EB)-linux-gnueabi$(if $(filter hard,$(with_float)),hf))

As pointed out by the kind fellows at gcc

normad
  • 115
  • 1
  • 10
1

add the parameter: -I/usr/arm-linux-gnueabihf to the compile statement

user3629249
  • 16,402
  • 1
  • 16
  • 17
  • that would work but i would have to dig into the configure script to do that right? was hoping for an easier way out – normad Sep 01 '16 at 16:43