• A
    samples/seccomp: be less stupid about cross compiling · 275aaa68
    Arnd Bergmann 提交于
    The seccomp filters are currently built for the build host, not for the
    machine that they are going to run on, but they are also built for with
    the -m32 flag if the kernel is built for a 32 bit machine, both of which
    seems rather odd.
    
    It broke allyesconfig on my machine, which is x86-64, but building for
    32 bit ARM, with this error message:
    
      In file included from /usr/include/stdio.h:28:0,
                       from samples/seccomp/bpf-fancy.c:15:
      /usr/include/features.h:324:26: fatal error: bits/predefs.h: No such file or directory
    
    because there are no 32 bit libc headers installed on this machine.  We
    should really be building all the samples for the target machine rather
    than the build host, but since the infrastructure for that appears to be
    missing right now, let's be a little bit smarter and not pass the '-m32'
    flag to the HOSTCC when cross- compiling.
    Signed-off-by: NArnd Bergmann <arnd@arndb.de>
    Acked-by: NKees Cook <keescook@chromium.org>
    Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
    Cc: James Morris <james.l.morris@oracle.com>
    Acked-by: NWill Drewry <wad@chromium.org>
    Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
    275aaa68
Makefile 1.2 KB
新手
引导
客服 返回
顶部