diff options
author | Hauke Mehrtens <hauke@hauke-m.de> | 2015-07-26 15:53:44 +0000 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2015-07-26 15:53:44 +0000 |
commit | 53647060abeeff507c21d1ce52abf2082aabe63f (patch) | |
tree | fab3baf60f05c3ec5e919756ce1c88c17dc1ba35 /package/devel/oprofile/patches/100-musl.patch | |
parent | ac96a1665ac74123f92bd7ec0154da186d918981 (diff) | |
download | upstream-53647060abeeff507c21d1ce52abf2082aabe63f.tar.gz upstream-53647060abeeff507c21d1ce52abf2082aabe63f.tar.bz2 upstream-53647060abeeff507c21d1ce52abf2082aabe63f.zip |
oprofile: update to 1.1.0-rc2 and make it work with musl
This brings oprifle to version 1.1.0-rc2 and adds some fixes for musl.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
SVN-Revision: 46505
Diffstat (limited to 'package/devel/oprofile/patches/100-musl.patch')
-rw-r--r-- | package/devel/oprofile/patches/100-musl.patch | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/package/devel/oprofile/patches/100-musl.patch b/package/devel/oprofile/patches/100-musl.patch new file mode 100644 index 0000000000..05a5283146 --- /dev/null +++ b/package/devel/oprofile/patches/100-musl.patch @@ -0,0 +1,39 @@ +--- a/pe_profiling/operf.cpp ++++ b/pe_profiling/operf.cpp +@@ -857,11 +857,14 @@ static int __delete_old_previous_sample_ + int tflag __attribute__((unused)), + struct FTW *ftwbuf __attribute__((unused))) + { ++ int err; ++ + if (remove(fpath)) { ++ err = errno; + perror("sample data removal error"); +- return FTW_STOP; ++ return err; + } else { +- return FTW_CONTINUE; ++ return 0; + } + } + +@@ -896,7 +899,7 @@ static void convert_sample_data(void) + return; + + if (!operf_options::append) { +- int flags = FTW_DEPTH | FTW_ACTIONRETVAL; ++ int flags = FTW_DEPTH; + errno = 0; + if (nftw(previous_sampledir.c_str(), __delete_old_previous_sample_data, 32, flags) !=0 && + errno != ENOENT) { +--- a/libop/op_events.c ++++ b/libop/op_events.c +@@ -83,7 +83,7 @@ static int parse_hex(char const * str) + static u64 parse_long_hex(char const * str) + { + u64 value; +- if (sscanf(str, "%Lx", &value) != 1) ++ if (sscanf(str, "0x%llx", &value) != 1) + parse_error("expected long hexadecimal value"); + + fflush(stderr); |