It appears as if upgrading to the kernel-ml on centos 7 breaks the
bcc-tools that are available in Centos 7.  Installing kernel-ml-devel
does not resolve the epbf compile errors.

Does anyone have a quick solution for this?  It looks like I need to
replace kernel-headers with kernel-ml-headers, but that leads to rpm
dependency hell, as doing so causes dependency check failures for
glibc iirc.

Thanks,
Dave.

<---------------------------------------->
$ sudo /usr/share/bcc/tools/biosnoop
In file included from <built-in>:3:
In file included from /virtual/include/bcc/helpers.h:38:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/log2.h:12:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bitops.h:5:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bits.h:6:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/vdso/bits.h:5:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/vdso/const.h:5:
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/uapi/linux/const.h:28:9:
warning: '_BITUL' macro redefined [-Wmacro-redefined]
#define _BITUL(x)       (_UL(1) << (x))
        ^
/usr/include/linux/const.h:24:9: note: previous definition is here
#define _BITUL(x)       (_AC(1,UL) << (x))
        ^
In file included from <built-in>:3:
In file included from /virtual/include/bcc/helpers.h:38:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/log2.h:12:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bitops.h:5:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bits.h:6:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/vdso/bits.h:5:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/vdso/const.h:5:
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/uapi/linux/const.h:29:9:
warning: '_BITULL' macro redefined [-Wmacro-redefined]
#define _BITULL(x)      (_ULL(1) << (x))
        ^
/usr/include/linux/const.h:25:9: note: previous definition is here
#define _BITULL(x)      (_AC(1,ULL) << (x))
        ^
In file included from <built-in>:3:
In file included from /virtual/include/bcc/helpers.h:38:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/log2.h:12:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bitops.h:5:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bits.h:22:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/build_bug.h:5:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/compiler.h:232:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/generated/asm/rwonce.h:1:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/asm-generic/rwonce.h:26:
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kasan-checks.h:16:15:
error: unknown type name 'bool'
static inline bool __kasan_check_read(const volatile void *p, unsigned int size)
              ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kasan-checks.h:18:9:
error: use of undeclared identifier 'true'
        return true;
               ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kasan-checks.h:20:15:
error: unknown type name 'bool'
static inline bool __kasan_check_write(const volatile void *p,
unsigned int size)
              ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kasan-checks.h:22:9:
error: use of undeclared identifier 'true'
        return true;
               ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kasan-checks.h:34:15:
error: unknown type name 'bool'
static inline bool kasan_check_read(const volatile void *p, unsigned int size)
              ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kasan-checks.h:36:9:
error: use of undeclared identifier 'true'
        return true;
               ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kasan-checks.h:38:15:
error: unknown type name 'bool'
static inline bool kasan_check_write(const volatile void *p, unsigned int size)
              ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kasan-checks.h:40:9:
error: use of undeclared identifier 'true'
        return true;
               ^
In file included from <built-in>:3:
In file included from /virtual/include/bcc/helpers.h:38:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/log2.h:12:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bitops.h:5:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bits.h:22:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/build_bug.h:5:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/compiler.h:232:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/generated/asm/rwonce.h:1:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/asm-generic/rwonce.h:27:
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kcsan-checks.h:148:67:
error: unknown type name 'size_t'
static inline void __kcsan_check_access(const volatile void *ptr, size_t size,
                                                                  ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kcsan-checks.h:164:53:
error: unknown type name 'size_t'
kcsan_begin_scoped_access(const volatile void *ptr, size_t size, int type,
                                                    ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/kcsan-checks.h:184:65:
error: unknown type name 'size_t'
static inline void kcsan_check_access(const volatile void *ptr, size_t size,
                                                                ^
In file included from <built-in>:3:
In file included from /virtual/include/bcc/helpers.h:38:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/log2.h:12:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bitops.h:29:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/bitops.h:17:
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/alternative.h:59:2:
error: unknown type name 's32'
        s32 instr_offset;       /* original instruction */
        ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/alternative.h:60:2:
error: unknown type name 's32'
        s32 repl_offset;        /* offset to replacement instruction */
        ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/alternative.h:61:2:
error: unknown type name 'u16'
        u16 cpuid;              /* cpuid bit set for replacement */
        ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/alternative.h:62:2:
error: unknown type name 'u8'
        u8  instrlen;           /* length of original instruction */
        ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/alternative.h:63:2:
error: unknown type name 'u8'
        u8  replacementlen;     /* length of new instruction */
        ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/alternative.h:64:2:
error: unknown type name 'u8'
        u8  padlen;             /* length of build-time padding */
        ^
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/alternative.h:85:8:
error: unknown type name 'bool'
extern bool skip_smp_alternatives;
       ^
In file included from <built-in>:3:
In file included from /virtual/include/bcc/helpers.h:38:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/log2.h:12:
In file included from
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/include/linux/bitops.h:29:
/lib/modules/5.9.9-1.el7.elrepo.x86_64/build/arch/x86/include/asm/bitops.h:26:3:
error: "Unexpected BITS_PER_LONG"
# error "Unexpected BITS_PER_LONG"
  ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
2 warnings and 20 errors generated.
Traceback (most recent call last):
  File "/usr/share/bcc/tools/biosnoop", line 157, in <module>
    b = BPF(text=bpf_text)
  File "/usr/lib/python2.7/site-packages/bcc/__init__.py", line 325, in __init__
    raise Exception("Failed to compile BPF text")
Exception: Failed to compile BPF text
<---------------------------------------------------------------->
_______________________________________________
elrepo mailing list
elrepo@lists.elrepo.org
http://lists.elrepo.org/mailman/listinfo/elrepo

Reply via email to