diff --git a/systemtap-3.2-modern-rpm-api.patch b/systemtap-3.2-modern-rpm-api.patch new file mode 100644 index 0000000..46eb6cc --- /dev/null +++ b/systemtap-3.2-modern-rpm-api.patch @@ -0,0 +1,33 @@ +diff -up systemtap-3.2/rpm_finder.cxx.newrpm systemtap-3.2/rpm_finder.cxx +--- systemtap-3.2/rpm_finder.cxx.newrpm 2017-08-10 22:13:10.283393224 +0300 ++++ systemtap-3.2/rpm_finder.cxx 2017-08-10 22:13:28.320385642 +0300 +@@ -22,7 +22,6 @@ using namespace std; + + extern "C" { + +-#define _RPM_4_4_COMPAT + #include + #include + #include +@@ -100,8 +99,7 @@ missing_rpm_enlist (systemtap_session& s + break; + /* Verify the kernel file is not already installed. */ + +- rpminfo = headerSprintf(h, header, +- rpmTagTable, rpmHeaderFormats, &err); ++ rpminfo = headerFormat(h, header, &err); + + if (!rpminfo) + { +@@ -154,9 +152,8 @@ missing_rpm_enlist (systemtap_session& s + /* The allocated memory gets utilized below for MISSING_RPM_HASH. */ + if(strcmp(rpm_type,"-debuginfo")==0){ + xfree(rpminfo); +- rpminfo = headerSprintf(h, +- "%{name}-%{version}-%{release}.%{arch}", +- rpmTagTable, rpmHeaderFormats, &err); ++ rpminfo = headerFormat(h, ++ "%{name}-%{version}-%{release}.%{arch}", &err); + } + if (!rpminfo) + { diff --git a/systemtap.spec b/systemtap.spec index ed100ad..01ad915 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -153,6 +153,7 @@ BuildRequires: /usr/bin/latex /usr/bin/dvips /usr/bin/ps2pdf %if 0%{?fedora} >= 18 || 0%{?rhel} >= 7 BuildRequires: tex(fullpage.sty) tex(fancybox.sty) tex(bchr7t.tfm) tex(graphicx.sty) %endif +Patch2: systemtap-3.2-modern-rpm-api.patch # For the html.sty mentioned in the .tex files, even though latex2html is # not run during the build, only during manual scripts/update-docs runs: BuildRequires: latex2html @@ -477,6 +478,7 @@ sleep 1 find . \( -name configure -o -name config.h.in \) -print | xargs touch cd .. %endif +%patch2 -p1 %build