foss-for-synopsys-dwc-arc-processors / linux

Helpful resources for users & developers of Linux kernel for ARC
22 stars 13 forks source link

make headers_install broken in v5.1 final #10

Closed vineetgarc closed 5 years ago

vineetgarc commented 5 years ago

userspace toolchain build requires kernel headers to be installed. This step didn't need the cross compiler (as it would not exist given we were building the toolchain). However as of v5.1 kernel this needs CROSS_COMPILER to be passed (v5.1-rc1) is OK. This needs to be tracked down and reported upstream.

vineetgarc commented 5 years ago

@abrodkin can someone in the group track this down !

abrodkin commented 5 years ago

@EvgeniiDidin could you please take a look at this?

abrodkin commented 5 years ago

@vineetgarc may we have more details on what is really broken and how to reproduce this problem?

I don't see any significant problems so far:

 make ARCH=arc headers_install
gcc: error: unrecognized command line option ‘-mmedium-calls’
gcc: error: unrecognized command line option ‘-mno-sdata’
  HOSTCC  scripts/basic/fixdep
  WRAP    arch/arc/include/generated/uapi/asm/ucontext.h
  WRAP    arch/arc/include/generated/uapi/asm/auxvec.h
  WRAP    arch/arc/include/generated/uapi/asm/bitsperlong.h
  WRAP    arch/arc/include/generated/uapi/asm/bpf_perf_event.h
  WRAP    arch/arc/include/generated/uapi/asm/errno.h
  WRAP    arch/arc/include/generated/uapi/asm/fcntl.h
  WRAP    arch/arc/include/generated/uapi/asm/ioctl.h
  WRAP    arch/arc/include/generated/uapi/asm/ioctls.h
  WRAP    arch/arc/include/generated/uapi/asm/ipcbuf.h
  WRAP    arch/arc/include/generated/uapi/asm/mman.h
  WRAP    arch/arc/include/generated/uapi/asm/msgbuf.h
  WRAP    arch/arc/include/generated/uapi/asm/param.h
  WRAP    arch/arc/include/generated/uapi/asm/poll.h
  WRAP    arch/arc/include/generated/uapi/asm/posix_types.h
  WRAP    arch/arc/include/generated/uapi/asm/resource.h
  WRAP    arch/arc/include/generated/uapi/asm/sembuf.h
  WRAP    arch/arc/include/generated/uapi/asm/shmbuf.h
  WRAP    arch/arc/include/generated/uapi/asm/siginfo.h
  WRAP    arch/arc/include/generated/uapi/asm/socket.h
  WRAP    arch/arc/include/generated/uapi/asm/sockios.h
  WRAP    arch/arc/include/generated/uapi/asm/stat.h
  WRAP    arch/arc/include/generated/uapi/asm/statfs.h
  WRAP    arch/arc/include/generated/uapi/asm/termbits.h
  WRAP    arch/arc/include/generated/uapi/asm/termios.h
  WRAP    arch/arc/include/generated/uapi/asm/types.h
  UPD     include/generated/uapi/linux/version.h
  HOSTCC  scripts/unifdef
  INSTALL usr/include/asm-generic/ (36 files)
  INSTALL usr/include/drm/ (28 files)
  INSTALL usr/include/linux/android/ (2 files)
  INSTALL usr/include/linux/byteorder/ (2 files)
  INSTALL usr/include/linux/caif/ (2 files)
  INSTALL usr/include/linux/can/ (6 files)
  INSTALL usr/include/linux/cifs/ (1 file)
  INSTALL usr/include/linux/dvb/ (8 files)
  INSTALL usr/include/linux/genwqe/ (1 file)
  INSTALL usr/include/linux/hdlc/ (1 file)
  INSTALL usr/include/linux/hsi/ (2 files)
  INSTALL usr/include/linux/iio/ (2 files)
  INSTALL usr/include/linux/isdn/ (1 file)
  INSTALL usr/include/linux/mmc/ (1 file)
  INSTALL usr/include/linux/netfilter/ipset/ (4 files)
  INSTALL usr/include/linux/netfilter/ (88 files)
  INSTALL usr/include/linux/netfilter_arp/ (2 files)
  INSTALL usr/include/linux/netfilter_bridge/ (17 files)
  INSTALL usr/include/linux/netfilter_ipv4/ (9 files)
  INSTALL usr/include/linux/netfilter_ipv6/ (13 files)
  INSTALL usr/include/linux/nfsd/ (5 files)
  INSTALL usr/include/linux/raid/ (2 files)
  INSTALL usr/include/linux/sched/ (1 file)
  INSTALL usr/include/linux/spi/ (1 file)
  INSTALL usr/include/linux/sunrpc/ (1 file)
  INSTALL usr/include/linux/tc_act/ (15 files)
  INSTALL usr/include/linux/tc_ematch/ (5 files)
  INSTALL usr/include/linux/usb/ (13 files)
  INSTALL usr/include/linux/wimax/ (1 file)
  INSTALL usr/include/linux/ (504 files)
  INSTALL usr/include/misc/ (4 files)
  INSTALL usr/include/mtd/ (5 files)
  INSTALL usr/include/rdma/hfi/ (2 files)
  INSTALL usr/include/rdma/ (26 files)
  INSTALL usr/include/scsi/fc/ (4 files)
  INSTALL usr/include/scsi/ (5 files)
  INSTALL usr/include/sound/sof/ (8 files)
  INSTALL usr/include/sound/ (16 files)
  INSTALL usr/include/video/ (3 files)
  INSTALL usr/include/xen/ (4 files)
  INSTALL usr/include/asm/ (35 files)
vineetgarc commented 5 years ago

what kernel version is this ?

abrodkin commented 5 years ago
# git describe
v5.2-rc1-233-g0a72ef899014
# git l
0a72ef899014 - (HEAD -> torvalds/master, torvalds/HEAD) Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux (2 hours ago) <Linus Torvalds>
c50bbf615f2f - Merge tag 'platform-drivers-x86-v5.2-2' of git://git.infradead.org/linux-platform-drivers-x86 (3 hours ago) <Linus Torvalds>
49bbd8bb34a4 - Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/evalenti/linux-soc-thermal (3 hours ago) <Linus Torvalds>
e50e6798f1e2 - Merge tag 'mmc-v5.2-2' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc (3 hours ago) <Linus Torvalds>
a3b25d157d5a - Merge tag 'drm-fixes-2019-05-24-1' of git://anongit.freedesktop.org/drm/drm (4 hours ago) <Linus Torvalds>
edbcf50eb8ae - arm64: insn: Add BUILD_BUG_ON() for invalid masks (6 hours ago) <Jean-Philippe Brucker>
c5e2edeb01ae - arm64: insn: Fix ldadd instruction encoding (6 hours ago) <Jean-Philippe Brucker>
96a13f57b946 - arm64: Kconfig: Make ARM64_PSEUDO_NMI depend on BROKEN for now (6 hours ago) <Will Deacon>
c07498917180 - Revert "drm/amd/display: Don't load DMCU for Raven 1" (10 hours ago) <Dave Airlie>
6a310f8f97bb - thermal: rcar_gen3_thermal: Update temperature conversion method (15 hours ago) <Yoshihiro Kaneko>
vineetgarc commented 5 years ago

Turns out the issue was something different.

This stopped working since the commit https://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc.git/commit/?h=for-curr&id=48b5ffd1268788afb01525e71e864e901e9aa070. The problem is that this commit relies on the presence of “realpath” utility, which is not present in CentOS 6 systems. Thus problem manifests itself only on CentOS 6, everything is cool on CentOS 7. But on CentOS6 I get a makefile that contains “include” statement without an argument, thus make reports that “headers_install” target is not present.

My setup didn't have realpath issue and i can't reproduce the failure i supposedly saw, so not sure what was going on.