Skip to content
Snippets Groups Projects
  • Jianpeng Ma's avatar
    cmake: sync submodule libbpf when do cmake. · 3df26a54
    Jianpeng Ma authored
    
    Meet the following compiler error:
    /mnt/trace-tools/eBPF/bcc/src/cc/frontends/clang/b_frontend_action.cc:
    In member function bool
    ebpf::BTypeVisitor::VisitVarDecl(clang::VarDecl*):]
    /mnt/trace-tools/eBPF/bcc/src/cc/frontends/clang/b_frontend_action.cc:1449:18:
    error: BPF_MAP_TYPE_RINGBUF was not declared in this scope; did you mean
    BPF_MAP_TYPE_QUEUE?
    1449 | map_type = BPF_MAP_TYPE_RINGBUF; | ^~~~~~~~~~~~~~~~~~~~ |
         BPF_MAP_TYPE_QUEUE
    make[2]: ***  [src/cc/frontends/clang/CMakeFiles/clang_frontend.dir/build.make:95:
    rc/cc/frontends/clang/CMakeFiles/clang_frontend.dir/b_frontend_action.cc.o] Error 1
    make[1]: *** [CMakeFiles/Makefile2:1065: src/cc/frontends/clang/CMakeFiles/clang_frontend.dir/all] Error 2
    make: *** [Makefile:160: all] Error 2
    
    This because, submodule libbpf can't sync when do cmake.
    So enlarger the sync contion: only submodule is clean, we do sync
    submodle when do cmake.
    
    Signed-off-by: default avatarJianpeng Ma <jianpeng.ma@intel.com>
    3df26a54