linux-snps-arc.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] dpkg: Add ARC support
@ 2021-06-25 15:00 Alexey Brodkin
  0 siblings, 0 replies; only message in thread
From: Alexey Brodkin @ 2021-06-25 15:00 UTC (permalink / raw)
  To: openembedded-core; +Cc: linux-snps-arc, Alexey Brodkin

This back-ports ARC support which was added after the most recent
tag 1.20.9 was cut. So on the next version bump this change to be
reverted.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
---
 .../dpkg/0014-arch-Add-support-for-ARCv2-CPU.patch | 68 ++++++++++++++++++++++
 meta/recipes-devtools/dpkg/dpkg_1.20.9.bb          |  1 +
 2 files changed, 69 insertions(+)
 create mode 100644 meta/recipes-devtools/dpkg/dpkg/0014-arch-Add-support-for-ARCv2-CPU.patch

diff --git a/meta/recipes-devtools/dpkg/dpkg/0014-arch-Add-support-for-ARCv2-CPU.patch b/meta/recipes-devtools/dpkg/dpkg/0014-arch-Add-support-for-ARCv2-CPU.patch
new file mode 100644
index 0000000000..ece18a33ac
--- /dev/null
+++ b/meta/recipes-devtools/dpkg/dpkg/0014-arch-Add-support-for-ARCv2-CPU.patch
@@ -0,0 +1,68 @@
+From c6acfba64b470c7e919fd5bd29124d7228492537 Mon Sep 17 00:00:00 2001
+From: Guillem Jover <guillem@debian.org>
+Date: Fri, 28 May 2021 04:07:49 +0200
+Subject: [PATCH] arch: Add support for ARCv2 CPU
+
+This is based on the ARCv2 32-bit little-endian hard-float ISA.
+
+Closes: #980963
+
+Upstream-Status: Backport [https://salsa.debian.org/dpkg-team/dpkg/-/commit/0d134cdcb0dcc6b21fa7926964c1426a5821181d]
+
+Based-on-patch-by: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
+Signed-off-by: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
+---
+ data/cputable                  | 1 +
+ scripts/Dpkg/Shlibs/Objdump.pm | 1 +
+ scripts/t/Dpkg_Arch.t          | 4 ++--
+ 3 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/data/cputable b/data/cputable
+index 9f2a8e0e4..277bed88f 100644
+--- a/data/cputable
++++ b/data/cputable
+@@ -20,6 +20,7 @@ i386		i686		(i[34567]86|pentium)	32	little
+ ia64		ia64		ia64			64	little
+ alpha		alpha		alpha.*			64	little
+ amd64		x86_64		(amd64|x86_64)		64	little
++arc		arc		arc			32	little
+ armeb		armeb		arm.*b			32	big
+ arm		arm		arm.*			32	little
+ arm64		aarch64		aarch64			64	little
+diff --git a/scripts/Dpkg/Shlibs/Objdump.pm b/scripts/Dpkg/Shlibs/Objdump.pm
+index 4cee866e7..93319d1eb 100644
+--- a/scripts/Dpkg/Shlibs/Objdump.pm
++++ b/scripts/Dpkg/Shlibs/Objdump.pm
+@@ -100,6 +100,7 @@ use constant {
+     ELF_MACH_OR1K           => 92,
+     ELF_MACH_XTENSA         => 94,
+     ELF_MACH_MICROBLAZE     => 189,
++    ELF_MACH_ARCV2          => 195,
+     ELF_MACH_AVR_OLD        => 0x1057,
+     ELF_MACH_OR1K_OLD       => 0x8472,
+     ELF_MACH_ALPHA          => 0x9026,
+diff --git a/scripts/t/Dpkg_Arch.t b/scripts/t/Dpkg_Arch.t
+index a3a9e6fee..f0bba272a 100644
+--- a/scripts/t/Dpkg_Arch.t
++++ b/scripts/t/Dpkg_Arch.t
+@@ -16,7 +16,7 @@
+ use strict;
+ use warnings;
+ 
+-use Test::More tests => 16836;
++use Test::More tests => 18407;
+ 
+ use_ok('Dpkg::Arch', qw(debarch_to_debtuple debarch_to_multiarch
+                         debarch_eq debarch_is debarch_is_wildcard
+@@ -174,7 +174,7 @@ is(gnutriplet_to_debarch(undef), undef, 'undef gnutriplet');
+ is(gnutriplet_to_debarch('unknown-unknown-unknown'), undef, 'unknown gnutriplet');
+ is(gnutriplet_to_debarch('x86_64-linux-gnu'), 'amd64', 'known gnutriplet');
+ 
+-is(scalar get_valid_arches(), 539, 'expected amount of known architectures');
++is(scalar get_valid_arches(), 554, 'expected amount of known architectures');
+ 
+ {
+     local $ENV{CC} = 'false';
+-- 
+2.16.2
+
diff --git a/meta/recipes-devtools/dpkg/dpkg_1.20.9.bb b/meta/recipes-devtools/dpkg/dpkg_1.20.9.bb
index 60ae3ff736..18ca0e310b 100644
--- a/meta/recipes-devtools/dpkg/dpkg_1.20.9.bb
+++ b/meta/recipes-devtools/dpkg/dpkg_1.20.9.bb
@@ -15,6 +15,7 @@ SRC_URI = "git://salsa.debian.org/dpkg-team/dpkg.git;protocol=https;branch=1.20.
            file://pager.patch \
            file://0001-Add-support-for-riscv32-CPU.patch \
            file://0013-scripts-dpkg-fsys-usrunmess.pl-correct-shebang.patch \
+           file://0014-arch-Add-support-for-ARCv2-CPU.patch \
            "
 
 SRC_URI_append_class-native = " file://0001-build.c-ignore-return-of-1-from-tar-cf.patch"
-- 
2.16.2


_______________________________________________
linux-snps-arc mailing list
linux-snps-arc@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-snps-arc

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2021-06-25 15:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-25 15:00 [PATCH] dpkg: Add ARC support Alexey Brodkin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).