* Tue Mar 19 2024 Jean-Philippe Pialasse <jpp@koozali.org> 2.1.2-2.sme

- patch so it builds against el8/SME11
This commit is contained in:
Jean-Philippe Pialasse 2024-03-19 10:00:19 -04:00
parent 646288e223
commit f0316e8312
2 changed files with 75 additions and 39 deletions

31
runit-2.1.2-el8.patch Normal file
View File

@ -0,0 +1,31 @@
diff -Nur --no-dereference admin.old/runit-2.1.2/src/chkshsgr.c admin/runit-2.1.2/src/chkshsgr.c
--- admin.old/runit-2.1.2/src/chkshsgr.c 2014-08-10 14:22:35.000000000 -0400
+++ admin/runit-2.1.2/src/chkshsgr.c 2024-03-19 09:47:06.132000000 -0400
@@ -1,10 +1,13 @@
/* Public domain. */
+#include <sys/types.h>
+#include <stdlib.h>
+#include <grp.h>
#include <unistd.h>
-int main()
+int main(int argc, char *argv[])
{
- short x[4];
+ gid_t x[4];
x[0] = x[1] = 0;
if (getgroups(1,x) == 0) if (setgroups(1,x) == -1) _exit(1);
diff -Nur --no-dereference admin.old/runit-2.1.2/src/Makefile admin/runit-2.1.2/src/Makefile
--- admin.old/runit-2.1.2/src/Makefile 2014-08-10 14:22:35.000000000 -0400
+++ admin/runit-2.1.2/src/Makefile 2024-03-19 09:55:47.638000000 -0400
@@ -234,7 +234,7 @@
hasshsgr.h: chkshsgr choose compile hasshsgr.h1 hasshsgr.h2 load \
tryshsgr.c warn-shsgr
- ./chkshsgr || ( cat warn-shsgr; exit 1 )
+ echo "Warning: We can not run test on cross target. - ignoring ./chkshsgr || ( cat warn-shsgr; exit 1 )"
./choose clr tryshsgr hasshsgr.h1 hasshsgr.h2 > hasshsgr.h
haswaitp.h: choose compile haswaitp.h1 haswaitp.h2 load trywaitp.c

View File

@ -1,9 +1,9 @@
# $Id: runit.spec,v 1.1 2016/02/07 21:09:42 stephdl Exp $ # $Id: runit.spec,v 1.1 2016/02/07 21:09:42 stephdl Exp $
%global debug_package %{nil}
Summary: a UNIX init scheme with service supervision Summary: a UNIX init scheme with service supervision
Name: runit Name: runit
Version: 2.1.2 Version: 2.1.2
Release: 1%{?dist} Release: 2%{?dist}
License: BSD style License: BSD style
Group: System Enviornment/Daemons Group: System Enviornment/Daemons
Url: http://smarden.org/runit/ Url: http://smarden.org/runit/
@ -12,6 +12,7 @@ Source1: runit.svup
Source2: runit.svdown Source2: runit.svdown
Source3: runit.svdepcalc Source3: runit.svdepcalc
Source4: runit.dependencies.README Source4: runit.dependencies.README
Patch0: runit-2.1.2-el8.patch
BuildRequires: dietlibc BuildRequires: dietlibc
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}.root BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}.root
%description %description
@ -26,7 +27,48 @@ fail. Make sure you are able to recover and repair your system, for
example if you run a boot loader, it should be able to pass init=/bin/sh example if you run a boot loader, it should be able to pass init=/bin/sh
to the kernel. to the kernel.
%prep
%setup -c -n %{name}-%{version}
%patch0
%build
cd admin/%{name}-%{version}
#Change the conf-cc and conf-ld to use diet
echo 'diet -Os gcc -O2 -Wall' >src/conf-cc
echo 'diet -Os gcc -s -Os -pipe' >src/conf-ld
./package/compile
%install
cd admin/%{name}-%{version}
mkdir -p $RPM_BUILD_ROOT/%{_bindir}
install %{SOURCE1} command/svisup
install %{SOURCE2} command/svisdown
install %{SOURCE3} command/svdepcalc
install %{SOURCE4} doc/dependencies.README
for i in $(cat package/commands) svisup svisdown svdepcalc
do
install command/$i $RPM_BUILD_ROOT/%{_bindir}
done
#mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man1
#install man/*.1 $RPM_BUILD_ROOT/%{_mandir}/man1
mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man8
install man/*.8 $RPM_BUILD_ROOT/%{_mandir}/man8
%clean
rm -r $RPM_BUILD_ROOT
%files
%defattr(-,root,root)
%{_bindir}/*
%doc %{_mandir}/man8/*
#%{_mandir}/man1/*
%doc admin/%{name}-%{version}/package/COPYING
%doc admin/%{name}-%{version}/doc/*
%changelog %changelog
* Tue Mar 19 2024 Jean-Philippe Pialasse <jpp@koozali.org> 2.1.2-2.sme
- patch so it builds against el8/SME11
* Fri Jul 14 2023 BogusDateBot * Fri Jul 14 2023 BogusDateBot
- Eliminated rpmbuild "bogus date" warnings due to inconsistent weekday, - Eliminated rpmbuild "bogus date" warnings due to inconsistent weekday,
by assuming the date is correct and changing the weekday. by assuming the date is correct and changing the weekday.
@ -102,40 +144,3 @@ to the kernel.
* Wed Jun 18 2003 Charlie Brady <charlieb@e-smith.com> 0.95-01 * Wed Jun 18 2003 Charlie Brady <charlieb@e-smith.com> 0.95-01
- Initial - Initial
%prep
%setup -c -n %{name}-%{version}
%build
cd admin/%{name}-%{version}
#Change the conf-cc and conf-ld to use diet
echo 'diet -Os gcc -O2 -Wall' >src/conf-cc
echo 'diet -Os gcc -s -Os -pipe' >src/conf-ld
./package/compile
%install
cd admin/%{name}-%{version}
mkdir -p $RPM_BUILD_ROOT/%{_bindir}
install %{SOURCE1} command/svisup
install %{SOURCE2} command/svisdown
install %{SOURCE3} command/svdepcalc
install %{SOURCE4} doc/dependencies.README
for i in $(cat package/commands) svisup svisdown svdepcalc
do
install command/$i $RPM_BUILD_ROOT/%{_bindir}
done
#mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man1
#install man/*.1 $RPM_BUILD_ROOT/%{_mandir}/man1
mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man8
install man/*.8 $RPM_BUILD_ROOT/%{_mandir}/man8
%clean
rm -r $RPM_BUILD_ROOT
%files
%defattr(-,root,root)
%{_bindir}/*
%doc %{_mandir}/man8/*
#%{_mandir}/man1/*
%doc admin/%{name}-%{version}/package/COPYING
%doc admin/%{name}-%{version}/doc/*