add default machine name loongarch support
disable test on loongarch Signed-off-by: Jingyun Hua <huajingyun@loongson.cn>
This commit is contained in:
parent
c6173ebd2d
commit
8001027705
30
add-default-machine-name-to-support-loongarch.patch
Normal file
30
add-default-machine-name-to-support-loongarch.patch
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
From f492b34a694a4bf40e075a030c01f360eaa5500e Mon Sep 17 00:00:00 2001
|
||||||
|
From: Wenlong Zhang <zhangwenlong@loongson.cn>
|
||||||
|
Date: Fri, 27 May 2022 09:41:38 +0800
|
||||||
|
Subject: [PATCH] add default machine name to support loongarch
|
||||||
|
|
||||||
|
---
|
||||||
|
lib/rpmrc.c | 7 +++++++
|
||||||
|
1 file changed, 7 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/lib/rpmrc.c b/lib/rpmrc.c
|
||||||
|
index 120777c..bd0dbca 100644
|
||||||
|
--- a/lib/rpmrc.c
|
||||||
|
+++ b/lib/rpmrc.c
|
||||||
|
@@ -1242,6 +1242,13 @@ static void defaultMachine(rpmrcCtx ctx, const char ** arch, const char ** os)
|
||||||
|
}
|
||||||
|
# endif /* riscv */
|
||||||
|
|
||||||
|
+# if defined(__linux__) && defined(__loongarch__)
|
||||||
|
+ if (sizeof(long) == 4)
|
||||||
|
+ strcpy(un.machine, "loongarch32");
|
||||||
|
+ else if (sizeof(long) == 8)
|
||||||
|
+ strcpy(un.machine, "loongarch64");
|
||||||
|
+# endif /* loongarch */
|
||||||
|
+
|
||||||
|
# if defined(__GNUC__) && defined(__alpha__)
|
||||||
|
{
|
||||||
|
unsigned long amask, implver;
|
||||||
|
--
|
||||||
|
2.27.0
|
||||||
|
|
||||||
9
rpm.spec
9
rpm.spec
@ -1,6 +1,6 @@
|
|||||||
Name: rpm
|
Name: rpm
|
||||||
Version: 4.17.0
|
Version: 4.17.0
|
||||||
Release: 16
|
Release: 17
|
||||||
Summary: RPM Package Manager
|
Summary: RPM Package Manager
|
||||||
License: GPLv2+
|
License: GPLv2+
|
||||||
URL: http://www.rpm.org/
|
URL: http://www.rpm.org/
|
||||||
@ -29,6 +29,7 @@ Patch20: Add-license-to-digest_list.c.patch
|
|||||||
Patch21: Avoid-generating-digest-lists-if-they-are-already-pa.patch
|
Patch21: Avoid-generating-digest-lists-if-they-are-already-pa.patch
|
||||||
Patch22: dont-remove-ima-xattr-of-parser-when-upgrading.patch
|
Patch22: dont-remove-ima-xattr-of-parser-when-upgrading.patch
|
||||||
Patch23: rpm-Add-sw64-architecture.patch
|
Patch23: rpm-Add-sw64-architecture.patch
|
||||||
|
Patch24: add-default-machine-name-to-support-loongarch.patch
|
||||||
|
|
||||||
Patch6000: backport-Use-root-as-default-UID_0_USER-and-UID_0_GROUP.patch
|
Patch6000: backport-Use-root-as-default-UID_0_USER-and-UID_0_GROUP.patch
|
||||||
Patch6001: backport-Check-file-iterator-for-being-NULL-consistently.patch
|
Patch6001: backport-Check-file-iterator-for-being-NULL-consistently.patch
|
||||||
@ -245,7 +246,9 @@ rm -f $RPM_BUILD_ROOT/%{_rpmconfigdir}/{tcl.req,osgideps.pl}
|
|||||||
rm -f $RPM_BUILD_ROOT/%{_sysconfdir}/dbus-1/system.d/org.rpm.conf
|
rm -f $RPM_BUILD_ROOT/%{_sysconfdir}/dbus-1/system.d/org.rpm.conf
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
%ifnarch loongarch64
|
||||||
make check || (cat tests/rpmtests.log; exit 0)
|
make check || (cat tests/rpmtests.log; exit 0)
|
||||||
|
%endif
|
||||||
|
|
||||||
%post -p /sbin/ldconfig
|
%post -p /sbin/ldconfig
|
||||||
|
|
||||||
@ -363,6 +366,10 @@ make check || (cat tests/rpmtests.log; exit 0)
|
|||||||
%exclude %{_mandir}/man8/rpmspec.8.gz
|
%exclude %{_mandir}/man8/rpmspec.8.gz
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Nov 18 2022 huajingyun<huajingyun@loongson.cn> - 4.17.0-17
|
||||||
|
- add default machine name loongarch support
|
||||||
|
- disable test on loongarch
|
||||||
|
|
||||||
* Wed Nov 16 2022 xujing<xujing125@huawei.com> - 4.17.0-16
|
* Wed Nov 16 2022 xujing<xujing125@huawei.com> - 4.17.0-16
|
||||||
- rpm: fix rpm is blocked when open fifo file
|
- rpm: fix rpm is blocked when open fifo file
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user