Skip to content

Commit

Permalink
move endian flags to kbuild_helper
Browse files Browse the repository at this point in the history
  • Loading branch information
yadutaf committed Mar 29, 2016
1 parent 354ee0c commit b83ccf3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 3 additions & 0 deletions src/cc/frontends/clang/kbuild_helper.cc
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ int KBuildHelper::get_flags(const char *uname_machine, vector<string> *cflags) {
cflags->push_back("-include");
cflags->push_back("./include/linux/kconfig.h");
cflags->push_back("-D__KERNEL__");
cflags->push_back("-D__HAVE_BUILTIN_BSWAP16__");
cflags->push_back("-D__HAVE_BUILTIN_BSWAP32__");
cflags->push_back("-D__HAVE_BUILTIN_BSWAP64__");
cflags->push_back("-Wno-unused-value");
cflags->push_back("-Wno-pointer-sign");

Expand Down
6 changes: 0 additions & 6 deletions src/python/bcc/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,6 @@
ksym_names = {}
ksym_loaded = 0
_kprobe_limit = 1000
BASE_CFLAGS = [
'-D__HAVE_BUILTIN_BSWAP16__',
'-D__HAVE_BUILTIN_BSWAP32__',
'-D__HAVE_BUILTIN_BSWAP64__',
]

@atexit.register
def cleanup_kprobes():
Expand Down Expand Up @@ -146,7 +141,6 @@ def __init__(self, src_file="", hdr_file="", text=None, cb=None, debug=0, cflags
self.debug = debug
self.funcs = {}
self.tables = {}
cflags = BASE_CFLAGS + cflags
cflags_array = (ct.c_char_p * len(cflags))()
for i, s in enumerate(cflags): cflags_array[i] = s.encode("ascii")
if text:
Expand Down

0 comments on commit b83ccf3

Please sign in to comment.