Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package 
golang-github-lusitaniae-apache_exporter for openSUSE:Factory checked in at 
2022-03-09 18:48:00
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/golang-github-lusitaniae-apache_exporter 
(Old)
 and      
/work/SRC/openSUSE:Factory/.golang-github-lusitaniae-apache_exporter.new.2349 
(New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "golang-github-lusitaniae-apache_exporter"

Wed Mar  9 18:48:00 2022 rev:4 rq:960381 version:0.7.0

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/golang-github-lusitaniae-apache_exporter/golang-github-lusitaniae-apache_exporter.changes
        2021-03-10 08:58:42.382978851 +0100
+++ 
/work/SRC/openSUSE:Factory/.golang-github-lusitaniae-apache_exporter.new.2349/golang-github-lusitaniae-apache_exporter.changes
      2022-03-11 11:43:45.550775362 +0100
@@ -1,0 +2,5 @@
+Fri Jan 21 20:09:39 UTC 2022 - Stefan Bluhm <stefan.bl...@clacee.eu>
+
+- Adapted to build on Enterprise Linux 8
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ golang-github-lusitaniae-apache_exporter.spec ++++++
--- /var/tmp/diff_new_pack.dDAM09/_old  2022-03-11 11:43:45.990775855 +0100
+++ /var/tmp/diff_new_pack.dDAM09/_new  2022-03-11 11:43:45.998775865 +0100
@@ -16,6 +16,11 @@
 # Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
+%if 0%{?rhel}
+%global debug_package %{nil}
+# Fix ERROR: No build ID note found in
+%undefine _missing_build_ids_terminate_build
+%endif
 
 # Templating vars to simplify and standardize Prometheus exporters spec files
 %define        githubrepo    github.com/lusitaniae/apache_exporter
@@ -35,10 +40,15 @@
 BuildRequires:  fdupes
 BuildRequires:  golang-packaging
 BuildRequires:  xz
+%if 0%{?rhel}
+BuildRequires:  golang >= 1.15
+Requires(pre):  shadow-utils
+%else
 BuildRequires:  golang(API) = 1.15
+Requires(pre):  shadow
+%endif
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 %{?systemd_requires}
-Requires(pre):  shadow
 
 %description
 Exports apache mod_status statistics via HTTP for Prometheus consumption.
@@ -48,6 +58,10 @@
 
 %build
 %goprep %{githubrepo}
+%if 0%{?rhel}
+# Fix automatic versioning
+export GO111MODULE=auto
+%endif
 %gobuild
 
 %install
@@ -57,19 +71,39 @@
 install -d -m 0755 %{buildroot}%{_sbindir}
 ln -s /usr/sbin/service %{buildroot}%{_sbindir}/rc%{targetname}
 
+%check
+%if 0%{?rhel}
+# Fix OBS debug_package execution.
+rm -f %{buildroot}/usr/lib/debug/%{_bindir}/%{targetname}-%{version}-*.debug
+%endif
+
 %pre
+%if 0%{?suse_version}
 %service_add_pre %{targetname}.service
+%endif
 getent group %{serviceuser} >/dev/null || %{_sbindir}/groupadd -r 
%{serviceuser}
 getent passwd %{serviceuser} >/dev/null || %{_sbindir}/useradd -r -g 
%{serviceuser} -d %{_localstatedir}/lib/%{serviceuser} -M -s /sbin/nologin 
%{serviceuser}
 
 %post
+%if 0%{?rhel}
+%systemd_post %{targetname}.service
+%else
 %service_add_post %{targetname}.service
+%endif
 
 %preun
+%if 0%{?rhel}
+%systemd_preun %{targetname}.service
+%else
 %service_del_preun %{targetname}.service
+%endif
 
 %postun
+%if 0%{?rhel}
+%systemd_postun %{targetname}.service
+%else
 %service_del_postun %{targetname}.service
+%endif
 
 %files
 %defattr(-,root,root,-)

Reply via email to