update to 0.1.2.rc2 for test
Fix some issues. syscare-pre.service enable by default. Signed-off-by: snoweay <snoweay@163.com> (cherry picked from commit 9fc37db201cf8a97aab545b0c7b12188162c0ed0)
This commit is contained in:
parent
ea7f1c24be
commit
d611d043bf
23
0001-upatch-Disable-kmod-compile.patch
Normal file
23
0001-upatch-Disable-kmod-compile.patch
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
From 62960a89c36155163cb30d086ae4dca3f96fd221 Mon Sep 17 00:00:00 2001
|
||||||
|
From: snoweay <snoweay@163.com>
|
||||||
|
Date: Thu, 8 Dec 2022 03:05:32 +0000
|
||||||
|
Subject: [PATCH] upatch: Disable kmod compile
|
||||||
|
|
||||||
|
Signed-off-by: snoweay <snoweay@163.com>
|
||||||
|
---
|
||||||
|
upatch/CMakeLists.txt | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/upatch/CMakeLists.txt b/upatch/CMakeLists.txt
|
||||||
|
index 3e8e127..d063259 100644
|
||||||
|
--- a/upatch/CMakeLists.txt
|
||||||
|
+++ b/upatch/CMakeLists.txt
|
||||||
|
@@ -11,4 +11,4 @@ endif()
|
||||||
|
add_subdirectory(upatch-build)
|
||||||
|
add_subdirectory(upatch-diff)
|
||||||
|
add_subdirectory(upatch-tool)
|
||||||
|
-add_subdirectory(kmod)
|
||||||
|
+#add_subdirectory(kmod)
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
Binary file not shown.
33
syscare.spec
33
syscare.spec
@ -1,7 +1,7 @@
|
|||||||
%global debug_package %{nil}
|
%global debug_package %{nil}
|
||||||
|
|
||||||
Name: syscare
|
Name: syscare
|
||||||
Version: 0.1.2
|
Version: 0.1.2.rc2
|
||||||
Release: 1
|
Release: 1
|
||||||
Summary: system hot-fix service
|
Summary: system hot-fix service
|
||||||
|
|
||||||
@ -13,9 +13,12 @@ ExclusiveArch: x86_64
|
|||||||
|
|
||||||
BuildRequires: rust cargo gcc gcc-g++ cmake make
|
BuildRequires: rust cargo gcc gcc-g++ cmake make
|
||||||
BuildRequires: elfutils-libelf-devel
|
BuildRequires: elfutils-libelf-devel
|
||||||
|
BuildRequires: kernel-devel
|
||||||
|
|
||||||
Requires: kpatch-runtime
|
Requires: kpatch-runtime
|
||||||
|
|
||||||
|
Patch0: 0001-upatch-Disable-kmod-compile.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
SysCare is a system-level hot-fix software that provides single-machine-level and cluster-level security patches and system error hot-fixes for the operating system.
|
SysCare is a system-level hot-fix software that provides single-machine-level and cluster-level security patches and system error hot-fixes for the operating system.
|
||||||
The host can fix the system problem without rebooting.
|
The host can fix the system problem without rebooting.
|
||||||
@ -29,29 +32,51 @@ Requires: rpm-build
|
|||||||
%description build
|
%description build
|
||||||
Syscare build tools.
|
Syscare build tools.
|
||||||
|
|
||||||
|
%define kernel_version $(rpm -q --qf "\%%{VERSION}-\%%{RELEASE}.\%%{ARCH}" `rpm -q kernel-devel` | head -n 1)
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup -p1
|
%autosetup -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
cmake .
|
mkdir -p tmp_build
|
||||||
|
cd tmp_build
|
||||||
|
cmake ..
|
||||||
make
|
make
|
||||||
|
|
||||||
%install
|
%install
|
||||||
|
cd tmp_build
|
||||||
%make_install
|
%make_install
|
||||||
|
|
||||||
|
mkdir -p %{buildroot}/lib/modules/%{kernel_version}/extra/syscare
|
||||||
|
#install -m 0640 %{buildroot}/usr/libexec/%{name}/upatch.ko %{buildroot}/lib/modules/%{kernel_version}/extra/syscare
|
||||||
|
|
||||||
mkdir -p %{buildroot}/usr/lib/systemd/system
|
mkdir -p %{buildroot}/usr/lib/systemd/system
|
||||||
install -m 0644 %{_builddir}/%{name}-%{version}/misc/%{name}-restore.service %{buildroot}/usr/lib/systemd/system
|
install -m 0644 %{_builddir}/%{name}-%{version}/misc/%{name}-restore.service %{buildroot}/usr/lib/systemd/system
|
||||||
install -m 0644 %{_builddir}/%{name}-%{version}/misc/%{name}-pre.service %{buildroot}/usr/lib/systemd/system
|
install -m 0644 %{_builddir}/%{name}-%{version}/misc/%{name}-pre.service %{buildroot}/usr/lib/systemd/system
|
||||||
|
|
||||||
|
#cd %{buildroot}
|
||||||
|
#find lib -name "upatch.ko" \
|
||||||
|
# -fprintf %{_builddir}/%{name}-%{version}/ko.files.list "/%p\n"
|
||||||
|
|
||||||
%post
|
%post
|
||||||
%systemd_post %{name}-restore.service
|
%systemd_post %{name}-restore.service
|
||||||
%systemd_post %{name}-pre.service
|
%{_bindir}/systemctl enable %{name}-pre.service
|
||||||
|
#depmod -A
|
||||||
|
|
||||||
|
%preun
|
||||||
|
%systemd_preun %{name}-restore.service
|
||||||
|
%systemd_preun %{name}-pre.service
|
||||||
|
|
||||||
|
%postun
|
||||||
|
#depmod -A
|
||||||
|
|
||||||
|
#%files -f ko.files.list
|
||||||
%files
|
%files
|
||||||
%defattr(-,root,root,-)
|
%defattr(-,root,root,-)
|
||||||
%attr(755,root,root) /usr/bin/syscare
|
%attr(755,root,root) /usr/bin/syscare
|
||||||
%attr(755,root,root) /usr/libexec/%{name}/upatch-tool
|
%attr(755,root,root) /usr/libexec/%{name}/upatch-tool
|
||||||
%attr(755,root,root) /usr/libexec/%{name}/auto-recovery.sh
|
%attr(755,root,root) /usr/libexec/%{name}/auto-recovery.sh
|
||||||
|
#%attr(640,root,root) /usr/libexec/%{name}/upatch.ko
|
||||||
%attr(644,root,root) /usr/lib/systemd/system/%{name}-restore.service
|
%attr(644,root,root) /usr/lib/systemd/system/%{name}-restore.service
|
||||||
%attr(644,root,root) /usr/lib/systemd/system/%{name}-pre.service
|
%attr(644,root,root) /usr/lib/systemd/system/%{name}-pre.service
|
||||||
|
|
||||||
@ -63,6 +88,8 @@ install -m 0644 %{_builddir}/%{name}-%{version}/misc/%{name}-pre.service %{build
|
|||||||
%attr(755,root,root) /usr/libexec/%{name}/syscare-build
|
%attr(755,root,root) /usr/libexec/%{name}/syscare-build
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Dec 8 2022 snoweay<snoweay@163.com> - 0.1.2.rc2-1
|
||||||
|
- 0.1.2.rc2 version for test. Fix some issues..
|
||||||
* Thu Dec 1 2022 snoweay<snoweay@163.com> - 0.1.2-1
|
* Thu Dec 1 2022 snoweay<snoweay@163.com> - 0.1.2-1
|
||||||
- 0.1.2 version for test. Fix some syscare cli bugs.
|
- 0.1.2 version for test. Fix some syscare cli bugs.
|
||||||
* Mon Nov 28 2022 snoweay<snoweay@163.com> - 0.1.1-1
|
* Mon Nov 28 2022 snoweay<snoweay@163.com> - 0.1.1-1
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user