# git tag %global git_commit 424b11f6c3ab2e3bb199180e142fbcf9eebf2ac3 %global git_commitdate 20220714.102650 %global git_shortcommit %%(c=%%{git_commit}; echo ${c:0:7}) %global git_tag 1.6.2 # too many weird issues with dependencies, turning this off for now - Aug 20, 2021 -JAH # epel-8 aarch64 has an issue with smp. Disabling for now %undefine _smp_mflags # not going to fight this for now %global _disable_ld_no_undefined 1 Name: libtraceevent Version: 1.6.2 Release: 202209071319%{?dist} Summary: Library to parse raw trace event formats License: LGPLv2+ and GPLv2+ URL: https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/ # If upstream does not provide tarballs, to generate: # git clone git://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git # cd libtraceevent # git archive --prefix=libtraceevent-%%{version}/ -o libtraceevent-%%{version}.tar.gz %%{git_commit} #Source0: libtraceevent-1.3.3.tar.gz Source0: https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/snapshot/libtraceevent-%{git_tag}.tar.gz Patch0: libtraceevent-Makefile-set-LIBS-as-conditional-assig.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: make BuildRequires: gcc BuildRequires: xmlto BuildRequires: asciidoc %if "%{_vendor}" == "openmandriva" BuildRequires: glibc-devel BuildRequires: glibc %endif %if 0%{?is_opensuse} == 1 BuildRequires: docbook-xsl-stylesheets %endif %description libtraceevent is a library to parse raw trace event formats. %package devel Summary: Development headers for %{name} Requires: %{name}%{?_isa} = %{version}-%{release} %package static Summary: Static variant of %{name} Requires: %{name}-devel = %{version}-%{release} %description devel Development headers for %{name} %description static Static variant of %{name} %prep rpm --showrc %setup -n %{name}-%{version} -q %build # If we are Fedora or RHEL(ish) run this %if 0%{?fedora} || 0%{?rhel} || "%{_vendor}" == "openmandriva" echo "~ Into Fedora / RHEL / openmandriva" MANPAGE_DOCBOOK_XSL=`rpm -ql docbook-style-xsl | grep manpages/docbook.xsl` %endif %if 0%{?is_opensuse} == 1 echo "~ Into OpenSuse" MANPAGE_DOCBOOK_XSL=`rpm -ql docbook-xsl-stylesheets | grep manpages/docbook.xsl` %endif # most of the time the default is fine, # EXCEPT for clang / openmandriva which -ldl just breaks %if "%{_vendor}" == "openmandriva" %global te_build_libs LIBS="" %endif %set_build_flags %make_build %{?te_build_libs} prefix=%{_prefix} libdir=%{_libdir} MANPAGE_XSL=${MANPAGE_DOCBOOK_XSL} %{?_smp_mflags} all doc %install rm -rf %{RPM_BUILD_ROOT} %make_install prefix=%{_prefix} libdir=%{_libdir} install doc-install %if 0%{?is_opensuse} == 1 ls -lah %{buildroot}/usr/share/doc/%{name}-doc mkdir %{buildroot}%{_docdir}/ ls -lah %{buildroot}%{_docdir}/ mv %{buildroot}/usr/share/doc/%{name}-doc %{buildroot}%{_docdir}/%{name}-doc %endif %files %license LICENSES/LGPL-2.1 %license LICENSES/GPL-2.0 %{_libdir}/traceevent/ %{_libdir}/libtraceevent.so.* %{_mandir}/man3/tep_*.3.* %{_mandir}/man3/libtraceevent.3.* %{_mandir}/man3/trace_seq*.3.* %{_docdir}/%{name}-doc %files devel %{_includedir}/traceevent/ %{_libdir}/pkgconfig/libtraceevent.pc %{_libdir}/libtraceevent.so %files static %{_libdir}/libtraceevent.a %changelog * Sat Jun 25 2022 John 'Warthog9' Hawley (VMware) 1.6.1-1 - Updating to 1.6.1 * Mon Oct 04 2021 John 'Warthog9' Hawley (VMware) 1.4.0-1 - Updating to 1.4.0 * Fri Jul 09 2021 John 'Warthog9' Hawley (VMware) 1.3.3-1 - Updating to 1.3.3 - Adding static package * Mon Jun 07 2021 Justin Forbes - Remove erroneus "Conflicts: perf" which broke perf. * Mon Apr 19 2021 Zamir SUN - 1.2.1-1 - Update to 1.2.1 * Mon Feb 08 2021 Zamir SUN - 1.1.1-1 - Update to 1.1.1 * Sat Oct 17 2020 Zamir SUN - 1.1.0-1 - Update to 1.1.0 * Fri Oct 09 2020 Zamir SUN - 0-0.1.20201009git5dd505f - Initial libtraceevent