import bpftrace-0.12.1-8.el9
This commit is contained in:
commit
6c3740c250
1
.bpftrace.metadata
Normal file
1
.bpftrace.metadata
Normal file
@ -0,0 +1 @@
|
||||
9cc3a1b5d4efd1649753cdb374102440c6625b57 SOURCES/bpftrace-0.12.1.tar.gz
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
SOURCES/bpftrace-0.12.1.tar.gz
|
26
SOURCES/bpftrace-0.12.1-Fix-mdflush.patch
Normal file
26
SOURCES/bpftrace-0.12.1-Fix-mdflush.patch
Normal file
@ -0,0 +1,26 @@
|
||||
From 7453a97005fda29f0b7be8f257736a19d7c13dbe Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Marchand <jmarchan@redhat.com>
|
||||
Date: Fri, 15 Oct 2021 14:26:28 +0200
|
||||
Subject: [PATCH] Fix mdflush
|
||||
|
||||
Since kernel commit 309dca309fc ("block: store a block_device pointer
|
||||
in struct bio") struct bio points again to a block_device and not to a
|
||||
gendisk directly.
|
||||
---
|
||||
tools/mdflush.bt | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/tools/mdflush.bt b/tools/mdflush.bt
|
||||
index e767b81d..541abba1 100755
|
||||
--- a/tools/mdflush.bt
|
||||
+++ b/tools/mdflush.bt
|
||||
@@ -26,5 +26,5 @@ kprobe:md_flush_request
|
||||
{
|
||||
time("%H:%M:%S ");
|
||||
printf("%-6d %-16s %s\n", pid, comm,
|
||||
- ((struct bio *)arg1)->bi_disk->disk_name);
|
||||
+ ((struct bio *)arg1)->bi_bdev->bd_disk->disk_name);
|
||||
}
|
||||
--
|
||||
2.31.1
|
||||
|
@ -0,0 +1,72 @@
|
||||
From b7fd0900b18c4b640926e0bb830464565a527ca1 Mon Sep 17 00:00:00 2001
|
||||
From: Daniel Xu <dxu@dxuuu.xyz>
|
||||
Date: Mon, 5 Apr 2021 14:35:08 -0700
|
||||
Subject: [PATCH] Fix single arg wildcard listings
|
||||
|
||||
The docs say we can do stuff like
|
||||
|
||||
# bpftrace -l "*sleep*"
|
||||
|
||||
so we should probably implement it. We probably regressed on this during
|
||||
the probe matching refactoring.
|
||||
---
|
||||
src/ast/attachpoint_parser.cpp | 10 +++++++---
|
||||
tests/runtime/regression | 6 ++++++
|
||||
2 files changed, 13 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/ast/attachpoint_parser.cpp b/src/ast/attachpoint_parser.cpp
|
||||
index cfac09bc..b62549d7 100644
|
||||
--- a/src/ast/attachpoint_parser.cpp
|
||||
+++ b/src/ast/attachpoint_parser.cpp
|
||||
@@ -77,6 +77,9 @@ AttachPointParser::State AttachPointParser::parse_attachpoint(AttachPoint &ap)
|
||||
std::set<std::string> probe_types;
|
||||
if (has_wildcard(parts_.front()))
|
||||
{
|
||||
+ // Single argument listing looks at all relevant probe types
|
||||
+ std::string probetype_query = (parts_.size() == 1) ? "*" : parts_.front();
|
||||
+
|
||||
// Probe type expansion
|
||||
// If PID is specified or the second part of the attach point is a path
|
||||
// (contains '/'), use userspace probe types.
|
||||
@@ -85,12 +88,12 @@ AttachPointParser::State AttachPointParser::parse_attachpoint(AttachPoint &ap)
|
||||
(parts_.size() >= 2 && parts_[1].find('/') != std::string::npos))
|
||||
{
|
||||
probe_types = bpftrace_.probe_matcher_->expand_probetype_userspace(
|
||||
- parts_.front());
|
||||
+ probetype_query);
|
||||
}
|
||||
else
|
||||
{
|
||||
probe_types = bpftrace_.probe_matcher_->expand_probetype_kernel(
|
||||
- parts_.front());
|
||||
+ probetype_query);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -111,7 +114,8 @@ AttachPointParser::State AttachPointParser::parse_attachpoint(AttachPoint &ap)
|
||||
for (const auto &probe_type : probe_types)
|
||||
{
|
||||
std::string raw_input = ap.raw_input;
|
||||
- erase_prefix(raw_input);
|
||||
+ if (parts_.size() > 1)
|
||||
+ erase_prefix(raw_input);
|
||||
raw_input = probe_type + ":" + raw_input;
|
||||
// New attach points have ignore_invalid set to true - probe types for
|
||||
// which raw_input has invalid number of parts will be ignored (instead
|
||||
diff --git a/tests/runtime/regression b/tests/runtime/regression
|
||||
index 7f40ffdb..b7fa4653 100644
|
||||
--- a/tests/runtime/regression
|
||||
+++ b/tests/runtime/regression
|
||||
@@ -33,3 +33,9 @@ NAME c_array_indexing
|
||||
RUN bpftrace -v -e 'struct Foo { int a; uint8_t b[10]; } uprobe:testprogs/uprobe_test:function2 { $foo = (struct Foo *)arg0; printf("%c %c %c %c %c\n", $foo->b[0], $foo->b[1], $foo->b[2], $foo->b[3], $foo->b[4]) }' -c ./testprogs/uprobe_test
|
||||
EXPECT h e l l o
|
||||
TIMEOUT 5
|
||||
+
|
||||
+# https://github.com/iovisor/bpftrace/issues/1773
|
||||
+NAME single_arg_wildcard_listing
|
||||
+RUN bpftrace -l "*do_nanosleep*"
|
||||
+EXPECT kprobe:do_nanosleep
|
||||
+TIMEOUT 1
|
||||
--
|
||||
2.34.1
|
||||
|
56
SOURCES/bpftrace-0.12.1-RHEL-9-fixes.patch
Normal file
56
SOURCES/bpftrace-0.12.1-RHEL-9-fixes.patch
Normal file
@ -0,0 +1,56 @@
|
||||
From 453e1ea9b9d036cc9cfa0ef2e20c53e926e1b3b8 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Marchand <jmarchan@redhat.com>
|
||||
Date: Tue, 11 Jun 2019 16:41:59 +0200
|
||||
Subject: [PATCH] RHEL 9 fixes
|
||||
|
||||
Fixes the following RHEL 8 specific issues:
|
||||
- library path in gethostlatency and threadsnoop
|
||||
---
|
||||
tools/gethostlatency.bt | 12 ++++++------
|
||||
tools/threadsnoop.bt | 2 +-
|
||||
2 files changed, 7 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/tools/gethostlatency.bt b/tools/gethostlatency.bt
|
||||
index 9f4ec31e..dd389c6f 100755
|
||||
--- a/tools/gethostlatency.bt
|
||||
+++ b/tools/gethostlatency.bt
|
||||
@@ -26,17 +26,17 @@ BEGIN
|
||||
"HOST");
|
||||
}
|
||||
|
||||
-uprobe:/lib/x86_64-linux-gnu/libc.so.6:getaddrinfo,
|
||||
-uprobe:/lib/x86_64-linux-gnu/libc.so.6:gethostbyname,
|
||||
-uprobe:/lib/x86_64-linux-gnu/libc.so.6:gethostbyname2
|
||||
+uprobe:/lib64/libc.so.6:getaddrinfo,
|
||||
+uprobe:/lib64/libc.so.6:gethostbyname,
|
||||
+uprobe:/lib64/libc.so.6:gethostbyname2
|
||||
{
|
||||
@start[tid] = nsecs;
|
||||
@name[tid] = arg0;
|
||||
}
|
||||
|
||||
-uretprobe:/lib/x86_64-linux-gnu/libc.so.6:getaddrinfo,
|
||||
-uretprobe:/lib/x86_64-linux-gnu/libc.so.6:gethostbyname,
|
||||
-uretprobe:/lib/x86_64-linux-gnu/libc.so.6:gethostbyname2
|
||||
+uretprobe:/lib64/libc.so.6:getaddrinfo,
|
||||
+uretprobe:/lib64/libc.so.6:gethostbyname,
|
||||
+uretprobe:/lib64/libc.so.6:gethostbyname2
|
||||
/@start[tid]/
|
||||
{
|
||||
$latms = (nsecs - @start[tid]) / 1e6;
|
||||
diff --git a/tools/threadsnoop.bt b/tools/threadsnoop.bt
|
||||
index 3824bc6d..bdc6e4df 100755
|
||||
--- a/tools/threadsnoop.bt
|
||||
+++ b/tools/threadsnoop.bt
|
||||
@@ -18,7 +18,7 @@ BEGIN
|
||||
printf("%-10s %-6s %-16s %s\n", "TIME(ms)", "PID", "COMM", "FUNC");
|
||||
}
|
||||
|
||||
-uprobe:/lib/x86_64-linux-gnu/libpthread.so.0:pthread_create
|
||||
+uprobe:/usr/lib64/libpthread.so.0:pthread_create
|
||||
{
|
||||
printf("%-10u %-6d %-16s %s\n", elapsed / 1e6, pid, comm,
|
||||
usym(arg2));
|
||||
--
|
||||
2.31.1
|
||||
|
@ -0,0 +1,84 @@
|
||||
From 617bb8501c091be2501b3abe4dad47804d5a4278 Mon Sep 17 00:00:00 2001
|
||||
From: Viktor Malik <viktor.malik@gmail.com>
|
||||
Date: Mon, 17 Jan 2022 11:15:26 +0100
|
||||
Subject: [PATCH] Update bio* tools to work on RHEL9
|
||||
|
||||
Kernel commit:
|
||||
9e6c144e5fee block: inline hot paths of blk_account_io_*()
|
||||
renamed some functions used in the tools.
|
||||
|
||||
Kernel commit:
|
||||
5f8d3bf600d2 block: move struct request to blk-mq.h
|
||||
moved "struct request" to a different header.
|
||||
|
||||
This fixes both issues.
|
||||
---
|
||||
tools/biolatency.bt | 4 ++--
|
||||
tools/biosnoop.bt | 6 +++---
|
||||
tools/biostacks.bt | 2 +-
|
||||
3 files changed, 6 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/tools/biolatency.bt b/tools/biolatency.bt
|
||||
index 4ea910b4..8fb0490d 100755
|
||||
--- a/tools/biolatency.bt
|
||||
+++ b/tools/biolatency.bt
|
||||
@@ -16,12 +16,12 @@ BEGIN
|
||||
printf("Tracing block device I/O... Hit Ctrl-C to end.\n");
|
||||
}
|
||||
|
||||
-kprobe:blk_account_io_start
|
||||
+kprobe:__blk_account_io_start
|
||||
{
|
||||
@start[arg0] = nsecs;
|
||||
}
|
||||
|
||||
-kprobe:blk_account_io_done
|
||||
+kprobe:__blk_account_io_done
|
||||
/@start[arg0]/
|
||||
{
|
||||
@usecs = hist((nsecs - @start[arg0]) / 1000);
|
||||
diff --git a/tools/biosnoop.bt b/tools/biosnoop.bt
|
||||
index 38ffeb52..6519054c 100755
|
||||
--- a/tools/biosnoop.bt
|
||||
+++ b/tools/biosnoop.bt
|
||||
@@ -1,5 +1,5 @@
|
||||
#!/usr/bin/env bpftrace
|
||||
-#include <linux/blkdev.h>
|
||||
+#include <linux/blk-mq.h>
|
||||
/*
|
||||
* biosnoop.bt Block I/O tracing tool, showing per I/O latency.
|
||||
* For Linux, uses bpftrace, eBPF.
|
||||
@@ -16,7 +16,7 @@ BEGIN
|
||||
printf("%-12s %-7s %-16s %-6s %7s\n", "TIME(ms)", "DISK", "COMM", "PID", "LAT(ms)");
|
||||
}
|
||||
|
||||
-kprobe:blk_account_io_start
|
||||
+kprobe:__blk_account_io_start
|
||||
{
|
||||
@start[arg0] = nsecs;
|
||||
@iopid[arg0] = pid;
|
||||
@@ -24,7 +24,7 @@ kprobe:blk_account_io_start
|
||||
@disk[arg0] = ((struct request *)arg0)->rq_disk->disk_name;
|
||||
}
|
||||
|
||||
-kprobe:blk_account_io_done
|
||||
+kprobe:__blk_account_io_done
|
||||
/@start[arg0] != 0 && @iopid[arg0] != 0 && @iocomm[arg0] != ""/
|
||||
|
||||
{
|
||||
diff --git a/tools/biostacks.bt b/tools/biostacks.bt
|
||||
index 58201cdf..fdd2efed 100755
|
||||
--- a/tools/biostacks.bt
|
||||
+++ b/tools/biostacks.bt
|
||||
@@ -18,7 +18,7 @@ BEGIN
|
||||
printf("Tracing block I/O with init stacks. Hit Ctrl-C to end.\n");
|
||||
}
|
||||
|
||||
-kprobe:blk_account_io_start
|
||||
+kprobe:__blk_account_io_start
|
||||
{
|
||||
@reqstack[arg0] = kstack;
|
||||
@reqts[arg0] = nsecs;
|
||||
--
|
||||
2.34.1
|
||||
|
@ -0,0 +1,64 @@
|
||||
From 69f6d7ff04f43451eea2fb028a84a76331bbf6ea Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Marchand <jmarchan@redhat.com>
|
||||
Date: Thu, 11 Jun 2020 14:56:36 +0200
|
||||
Subject: [PATCH] RHEL-8: aarch64: fixes statsnoop and opensnoop
|
||||
|
||||
On aarch64 the open syscall has been dropped. Only openat remains,
|
||||
wich is called by libc open() function.
|
||||
|
||||
The state of *stat* syscalls, is a mess. They are several generations
|
||||
of the system calls, and not all arches provides all of them. For
|
||||
instance, new(l)stat are missing from aarch64.
|
||||
|
||||
The only way I can think of fixing thess is RHEL-8 only arch specific
|
||||
patches.
|
||||
---
|
||||
tools/opensnoop.bt | 2 --
|
||||
tools/statsnoop.bt | 8 ++------
|
||||
2 files changed, 2 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/tools/opensnoop.bt b/tools/opensnoop.bt
|
||||
index a7de8026..d99db93e 100755
|
||||
--- a/tools/opensnoop.bt
|
||||
+++ b/tools/opensnoop.bt
|
||||
@@ -21,13 +21,11 @@ BEGIN
|
||||
printf("%-6s %-16s %4s %3s %s\n", "PID", "COMM", "FD", "ERR", "PATH");
|
||||
}
|
||||
|
||||
-tracepoint:syscalls:sys_enter_open,
|
||||
tracepoint:syscalls:sys_enter_openat
|
||||
{
|
||||
@filename[tid] = args->filename;
|
||||
}
|
||||
|
||||
-tracepoint:syscalls:sys_exit_open,
|
||||
tracepoint:syscalls:sys_exit_openat
|
||||
/@filename[tid]/
|
||||
{
|
||||
diff --git a/tools/statsnoop.bt b/tools/statsnoop.bt
|
||||
index b2d529e2..f612ea94 100755
|
||||
--- a/tools/statsnoop.bt
|
||||
+++ b/tools/statsnoop.bt
|
||||
@@ -30,17 +30,13 @@ tracepoint:syscalls:sys_enter_statfs
|
||||
@filename[tid] = args->pathname;
|
||||
}
|
||||
|
||||
-tracepoint:syscalls:sys_enter_statx,
|
||||
-tracepoint:syscalls:sys_enter_newstat,
|
||||
-tracepoint:syscalls:sys_enter_newlstat
|
||||
+tracepoint:syscalls:sys_enter_statx
|
||||
{
|
||||
@filename[tid] = args->filename;
|
||||
}
|
||||
|
||||
tracepoint:syscalls:sys_exit_statfs,
|
||||
-tracepoint:syscalls:sys_exit_statx,
|
||||
-tracepoint:syscalls:sys_exit_newstat,
|
||||
-tracepoint:syscalls:sys_exit_newlstat
|
||||
+tracepoint:syscalls:sys_exit_statx
|
||||
/@filename[tid]/
|
||||
{
|
||||
$ret = args->ret;
|
||||
--
|
||||
2.30.2
|
||||
|
132
SOURCES/bpftrace-0.12.1-orc-Fix-build-with-clang-13.patch
Normal file
132
SOURCES/bpftrace-0.12.1-orc-Fix-build-with-clang-13.patch
Normal file
@ -0,0 +1,132 @@
|
||||
From ddbd909505ed0530f0e4dec45c195e0cb315d516 Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Sat, 4 Sep 2021 17:28:17 -0700
|
||||
Subject: [PATCH] orc: Fix build with clang >= 13
|
||||
|
||||
Fixes errors like
|
||||
src/ast/bpforc/bpforcv2.cpp:3:9: error: constructor for 'bpftrace::BpfOrc' must explicitly initialize the member 'ES' which does not have a default constructor
|
||||
BpfOrc::BpfOrc(TargetMachine *TM, DataLayout DL)
|
||||
^
|
||||
|
||||
Fixes https://github.com/iovisor/bpftrace/issues/1963
|
||||
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
src/bpforc.h | 23 ++++++++++++++++++++++-
|
||||
src/bpforcv2.cpp | 23 +++++++++++++++--------
|
||||
2 files changed, 37 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/src/bpforc.h b/src/bpforc.h
|
||||
index 5634c544..1900e497 100644
|
||||
--- a/src/bpforc.h
|
||||
+++ b/src/bpforc.h
|
||||
@@ -20,6 +20,9 @@
|
||||
#ifdef LLVM_ORC_V2
|
||||
#include <llvm/ExecutionEngine/Orc/Core.h>
|
||||
#include <llvm/ExecutionEngine/Orc/JITTargetMachineBuilder.h>
|
||||
+#if LLVM_VERSION_MAJOR >= 13
|
||||
+#include <llvm/ExecutionEngine/Orc/ExecutorProcessControl.h>
|
||||
+#endif
|
||||
#endif
|
||||
|
||||
#include <optional>
|
||||
@@ -66,8 +69,12 @@ class BpfOrc
|
||||
std::unique_ptr<TargetMachine> TM;
|
||||
DataLayout DL;
|
||||
#if LLVM_VERSION_MAJOR >= 7
|
||||
+#ifdef LLVM_ORC_V2
|
||||
+ std::unique_ptr<ExecutionSession> ES;
|
||||
+#else // LLVM_ORC_V1
|
||||
ExecutionSession ES;
|
||||
#endif
|
||||
+#endif
|
||||
#if LLVM_VERSION_MAJOR >= 7 && LLVM_VERSION_MAJOR < 12
|
||||
std::shared_ptr<SymbolResolver> Resolver;
|
||||
#endif
|
||||
@@ -92,7 +99,21 @@ class BpfOrc
|
||||
#endif
|
||||
|
||||
public:
|
||||
+#if LLVM_VERSION_MAJOR >= 13
|
||||
+ ~BpfOrc()
|
||||
+ {
|
||||
+ if (auto Err = ES->endSession())
|
||||
+ ES->reportError(std::move(Err));
|
||||
+ }
|
||||
+#endif
|
||||
+#ifdef LLVM_ORC_V2
|
||||
+ BpfOrc(TargetMachine *TM,
|
||||
+ DataLayout DL,
|
||||
+ std::unique_ptr<ExecutionSession> ES);
|
||||
+#else
|
||||
BpfOrc(TargetMachine *TM, DataLayout DL);
|
||||
+#endif
|
||||
+
|
||||
void compile(std::unique_ptr<Module> M);
|
||||
|
||||
/* Helper for creating a orc object, responsible for creating internal objects
|
||||
@@ -125,7 +146,7 @@ class BpfOrc
|
||||
#ifdef LLVM_ORC_V2
|
||||
Expected<JITEvaluatedSymbol> lookup(StringRef Name)
|
||||
{
|
||||
- return ES.lookup({ &MainJD }, Mangle(Name.str()));
|
||||
+ return ES->lookup({ &MainJD }, Mangle(Name.str()));
|
||||
}
|
||||
#endif
|
||||
};
|
||||
diff --git a/src/bpforcv2.cpp b/src/bpforcv2.cpp
|
||||
index 209e08e5..104213b0 100644
|
||||
--- a/src/bpforcv2.cpp
|
||||
+++ b/src/bpforcv2.cpp
|
||||
@@ -1,24 +1,26 @@
|
||||
// Included by bpforc.cpp
|
||||
|
||||
-BpfOrc::BpfOrc(TargetMachine *TM, DataLayout DL)
|
||||
+BpfOrc::BpfOrc(TargetMachine *TM,
|
||||
+ DataLayout DL,
|
||||
+ std::unique_ptr<ExecutionSession> ES)
|
||||
: TM(std::move(TM)),
|
||||
DL(std::move(DL)),
|
||||
- ObjectLayer(ES,
|
||||
+ ES(std::move(ES)),
|
||||
+ ObjectLayer(*(this->ES),
|
||||
[this]() {
|
||||
return std::make_unique<MemoryManager>(sections_);
|
||||
}),
|
||||
- CompileLayer(ES,
|
||||
+ CompileLayer(*this->ES,
|
||||
ObjectLayer,
|
||||
std::make_unique<SimpleCompiler>(*this->TM)),
|
||||
- Mangle(ES, this->DL),
|
||||
+ Mangle(*this->ES, this->DL),
|
||||
CTX(std::make_unique<LLVMContext>()),
|
||||
- MainJD(cantFail(ES.createJITDylib("<main>")))
|
||||
+ MainJD(cantFail(this->ES->createJITDylib("<main>")))
|
||||
{
|
||||
MainJD.addGenerator(
|
||||
cantFail(DynamicLibrarySearchGenerator::GetForCurrentProcess(
|
||||
DL.getGlobalPrefix())));
|
||||
}
|
||||
-
|
||||
LLVMContext &BpfOrc::getContext()
|
||||
{
|
||||
return *CTX.getContext();
|
||||
@@ -37,8 +39,13 @@ std::unique_ptr<BpfOrc> BpfOrc::Create()
|
||||
// return unique_ptrs
|
||||
auto DL = cantFail(JTMB.getDefaultDataLayoutForTarget());
|
||||
auto TM = cantFail(JTMB.createTargetMachine());
|
||||
-
|
||||
- return std::make_unique<BpfOrc>(TM.release(), std::move(DL));
|
||||
+#if LLVM_VERSION_MAJOR >= 13
|
||||
+ auto EPC = SelfExecutorProcessControl::Create();
|
||||
+ auto ES = std::make_unique<ExecutionSession>(std::move(*EPC));
|
||||
+#else
|
||||
+ auto ES = std::make_unique<ExecutionSession>();
|
||||
+#endif
|
||||
+ return std::make_unique<BpfOrc>(TM.release(), std::move(DL), std::move(ES));
|
||||
}
|
||||
|
||||
void BpfOrc::compile(std::unique_ptr<Module> M)
|
||||
--
|
||||
2.31.1
|
||||
|
192
SPECS/bpftrace.spec
Normal file
192
SPECS/bpftrace.spec
Normal file
@ -0,0 +1,192 @@
|
||||
Name: bpftrace
|
||||
Version: 0.12.1
|
||||
Release: 8%{?dist}
|
||||
Summary: High-level tracing language for Linux eBPF
|
||||
License: ASL 2.0
|
||||
|
||||
URL: https://github.com/iovisor/bpftrace
|
||||
Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz
|
||||
Patch0: %{name}-%{version}-RHEL-9-fixes.patch
|
||||
Patch1: %{name}-%{version}-Fix-mdflush.patch
|
||||
Patch2: %{name}-%{version}-orc-Fix-build-with-clang-13.patch
|
||||
Patch3: %{name}-%{version}-Fix-single-arg-wildcard-listings.patch
|
||||
Patch4: %{name}-%{version}-Update-bio-tools-to-work-on-RHEL9.patch
|
||||
|
||||
Patch10: %{name}-%{version}-aarch64-fixes-statsnoop-and-opensnoop.patch
|
||||
|
||||
# Arches will be included as upstream support is added and dependencies are
|
||||
# satisfied in the respective arches
|
||||
ExclusiveArch: x86_64 %{power64} aarch64 s390x
|
||||
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: bison
|
||||
BuildRequires: flex
|
||||
BuildRequires: cmake
|
||||
BuildRequires: elfutils-libelf-devel
|
||||
BuildRequires: zlib-devel
|
||||
BuildRequires: llvm-devel
|
||||
BuildRequires: clang-devel
|
||||
BuildRequires: bcc-devel >= 0.19.0-8
|
||||
BuildRequires: libbpf-devel
|
||||
BuildRequires: libbpf-static
|
||||
BuildRequires: binutils-devel
|
||||
|
||||
|
||||
%description
|
||||
BPFtrace is a high-level tracing language for Linux enhanced Berkeley Packet
|
||||
Filter (eBPF) available in recent Linux kernels (4.x). BPFtrace uses LLVM as a
|
||||
backend to compile scripts to BPF-bytecode and makes use of BCC for
|
||||
interacting with the Linux BPF system, as well as existing Linux tracing
|
||||
capabilities: kernel dynamic tracing (kprobes), user-level dynamic tracing
|
||||
(uprobes), and tracepoints. The BPFtrace language is inspired by awk and C,
|
||||
and predecessor tracers such as DTrace and SystemTap
|
||||
|
||||
|
||||
%prep
|
||||
%autosetup -N
|
||||
%autopatch -p1 -M 9
|
||||
|
||||
%ifarch aarch64
|
||||
%patch10 -p1
|
||||
%endif
|
||||
|
||||
%build
|
||||
%cmake . \
|
||||
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
|
||||
-DBUILD_TESTING:BOOL=OFF \
|
||||
-DBUILD_SHARED_LIBS:BOOL=OFF
|
||||
%cmake_build
|
||||
|
||||
|
||||
%install
|
||||
# The post hooks strip the binary which removes
|
||||
# the BEGIN_trigger and END_trigger functions
|
||||
# which are needed for the BEGIN and END probes
|
||||
%global __os_install_post %{nil}
|
||||
%global _find_debuginfo_opts -g
|
||||
|
||||
%cmake_install
|
||||
|
||||
# Fix shebangs (https://fedoraproject.org/wiki/Packaging:Guidelines#Shebang_lines)
|
||||
find %{buildroot}%{_datadir}/%{name}/tools -type f -exec \
|
||||
sed -i -e '1s=^#!/usr/bin/env %{name}\([0-9.]\+\)\?$=#!%{_bindir}/%{name}=' {} \;
|
||||
|
||||
|
||||
%files
|
||||
%doc README.md CONTRIBUTING-TOOLS.md
|
||||
%doc docs/reference_guide.md docs/tutorial_one_liners.md
|
||||
%license LICENSE
|
||||
%dir %{_datadir}/%{name}
|
||||
%dir %{_datadir}/%{name}/tools
|
||||
%dir %{_datadir}/%{name}/tools/doc
|
||||
%{_bindir}/%{name}
|
||||
%{_mandir}/man8/*
|
||||
%attr(0755,-,-) %{_datadir}/%{name}/tools/*.bt
|
||||
%{_datadir}/%{name}/tools/doc/*.txt
|
||||
|
||||
%changelog
|
||||
* Mon Feb 21 2022 Viktor Malik <vmalik@redhat.com> - 0.12.1-8
|
||||
- Fix wildcard listing bug
|
||||
- Fix bio* tools
|
||||
|
||||
* Thu Dec 02 2021 Jerome Marchand <jmarchan@redhat.com> - 0.12.1.7
|
||||
- Bump up required bcc version.
|
||||
|
||||
* Thu Dec 02 2021 Jerome Marchand <jmarchan@redhat.com> - 0.12.1.6
|
||||
- Rebuild on LLVM13
|
||||
|
||||
* Mon Oct 18 2021 Jerome Marchand <jmarchan@redhat.com> - 0.12.1.5
|
||||
- threadsnoop: probe libpthread.so.0
|
||||
- Fix aarch64 failures
|
||||
|
||||
* Mon Oct 18 2021 Jerome Marchand <jmarchan@redhat.com> - 0.12.1.4
|
||||
- Fix gating
|
||||
|
||||
* Fri Oct 15 2021 Jerome Marchand <jmarchan@redhat.com> - 0.12.1-3
|
||||
- Fix mdflush (rhbz#1967567)
|
||||
|
||||
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 0.12.1-2
|
||||
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
||||
Related: rhbz#1991688
|
||||
|
||||
* Thu May 27 2021 Jerome Marchand <jmarchan@redhat.com> - 0.12.0-1
|
||||
- Rebase to bpftrace 0.12.1
|
||||
|
||||
* Thu Apr 15 2021 Mohan Boddu <mboddu@redhat.com> - 0.11.0-10
|
||||
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
||||
|
||||
* Fri Feb 12 2021 Jerome Marchand <jmarchan@redhat.com> - 0.11.0-9
|
||||
- Last build failed: rebuild.
|
||||
|
||||
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.11.0-8
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
* Fri Jan 22 2021 Tom Stellard <tstellar@redhat.com> - 0.11.0-7
|
||||
- Rebuild for clang-11.1.0
|
||||
|
||||
* Fri Dec 04 2020 Jeff Law <law@redhat.com> - 0.11.0-6
|
||||
- Fix missing #include for gcc-11
|
||||
|
||||
* Fri Nov 13 2020 Jerome Marchand <jmarchan@redhat.com> - 0.11.0-5
|
||||
- Rebuilt for LLVM 11
|
||||
|
||||
* Tue Aug 04 2020 Augusto Caringi <acaringi@redhat.com> - 0.11.0-4
|
||||
- Fix FTBFS due to cmake wide changes #1863295
|
||||
- Fix 'bpftrace symbols are stripped' #1865787
|
||||
|
||||
* Sat Aug 01 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.11.0-3
|
||||
- Second attempt - Rebuilt for
|
||||
https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.11.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Thu Jul 16 2020 Augusto Caringi <acaringi@redhat.com> - 0.11.0-1
|
||||
* Rebased to version 0.11.0
|
||||
|
||||
* Tue May 19 2020 Augusto Caringi <acaringi@redhat.com> - 0.10.0-2
|
||||
- Rebuilt for new bcc/libbpf versions
|
||||
|
||||
* Tue Apr 14 2020 Augusto Caringi <acaringi@redhat.com> - 0.10.0-1
|
||||
- Rebased to version 0.10.0
|
||||
- Dropped support for s390x temporaly due to build error
|
||||
|
||||
* Thu Feb 06 2020 Augusto Caringi <acaringi@redhat.com> - 0.9.4-1
|
||||
- Rebased to version 0.9.4
|
||||
|
||||
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.9.3-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
* Thu Nov 21 2019 Augusto Caringi <acaringi@redhat.com> - 0.9.3-1
|
||||
- Rebased to version 0.9.3
|
||||
|
||||
* Thu Aug 01 2019 Augusto Caringi <acaringi@redhat.com> - 0.9.2-1
|
||||
- Rebased to version 0.9.2
|
||||
|
||||
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.9.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Wed Jun 26 2019 Augusto Caringi <acaringi@redhat.com> - 0.9.1-1
|
||||
- Rebased to version 0.9.1
|
||||
|
||||
* Thu Apr 25 2019 Augusto Caringi <acaringi@redhat.com> - 0.9-3
|
||||
- Rebuilt for bcc 0.9.0
|
||||
|
||||
* Mon Apr 22 2019 Neal Gompa <ngompa@datto.com> - 0.9-2
|
||||
- Fix Source0 reference
|
||||
- Use make_build macro for calling make
|
||||
|
||||
* Mon Apr 1 2019 Peter Robinson <pbrobinson@fedoraproject.org> 0.9-1
|
||||
- Build on aarch64 and s390x
|
||||
|
||||
* Mon Mar 25 2019 Augusto Caringi <acaringi@redhat.com> - 0.9-0
|
||||
- Updated to version 0.9
|
||||
|
||||
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.0-2.20181210gitc49b333
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Mon Dec 10 2018 Augusto Caringi <acaringi@redhat.com> - 0.0-1.20181210gitc49b333
|
||||
- Updated to latest upstream (c49b333c034a6d29a7ce90f565e27da1061af971)
|
||||
|
||||
* Wed Nov 07 2018 Augusto Caringi <acaringi@redhat.com> - 0.0-1.20181107git029717b
|
||||
- Initial import
|
Loading…
Reference in New Issue
Block a user