Source: xir Version: 1.4.1-5.1 Severity: wishlist Tags: patch User: debian-riscv@lists.debian.org Usertags: riscv64 X-Debbugs-Cc: debian-riscv@lists.debian.org Dear xir Maintainer, The xir package can be built on riscv64 arch with the patch attached, so could you please add support for riscv64 arch as build target, thanks. -- Regards, -- Bo YU
diff -Nru xir-1.4.1/debian/control xir-1.4.1/debian/control
--- xir-1.4.1/debian/control 2022-02-13 15:32:22.000000000 +0800
+++ xir-1.4.1/debian/control 2022-05-23 03:34:37.000000000 +0800
@@ -17,7 +17,7 @@
Vcs-Browser: https://salsa.debian.org/xilinx-packages-team/vitis-ai/xir
Package: libxir1
-Architecture: amd64 arm64 armhf armel
+Architecture: amd64 arm64 armhf armel riscv64
Multi-Arch: same
Depends: ${misc:Depends}, ${shlibs:Depends}
Description: Xilinx Intermediate Representation (XIR) for deep learning algorithms (runtime)
@@ -54,7 +54,7 @@
This package provides the runtime environment for XIR.
Package: libxir-dev
-Architecture: amd64 arm64 armhf armel
+Architecture: amd64 arm64 armhf armel riscv64
Section: libdevel
Multi-Arch: same
Depends: ${misc:Depends}, ${shlibs:Depends}, libxir1 (= ${binary:Version})
@@ -92,7 +92,7 @@
This package provides the development environment for XIR.
Package: libxir-utils
-Architecture: amd64 arm64 armhf armel
+Architecture: amd64 arm64 armhf armel riscv64
Section: utils
Depends: ${misc:Depends}, ${shlibs:Depends}, libxir1 (= ${binary:Version})
Description: Xilinx Intermediate Representation (XIR) for deep learning algorithms (utils)
diff -Nru xir-1.4.1/debian/patches/0007-add-riscv64-support.patch xir-1.4.1/debian/patches/0007-add-riscv64-support.patch
--- xir-1.4.1/debian/patches/0007-add-riscv64-support.patch 1970-01-01 07:30:00.000000000 +0730
+++ xir-1.4.1/debian/patches/0007-add-riscv64-support.patch 2022-05-23 03:34:37.000000000 +0800
@@ -0,0 +1,20 @@
+--- a/src/xir/graph/elf2xir.cpp
++++ b/src/xir/graph/elf2xir.cpp
+@@ -594,6 +594,8 @@
+ auto symbols = get<Elf32_Sym>(section_offset(section_symtab_));
+ #elif defined __x86_64__
+ auto symbols = get<Elf64_Sym>(section_offset(section_symtab_));
++#elif defined (__riscv) && __riscv_xlen == 64
++ auto symbols = get<Elf64_Sym>(section_offset(section_symtab_));
+ #elif defined __microblaze__
+ // I am not sure it is 64bits or 32 bits to avoid recompile all
+ // models, let's assume it is 64bits model
+@@ -636,6 +638,8 @@
+ auto symbols = get<Elf64_Sym>(section_offset(section_symtab_));
+ #elif defined __arm__
+ auto symbols = get<Elf32_Sym>(section_offset(section_symtab_));
++#elif defined (__riscv) && __riscv_xlen == 64
++ auto symbols = get<Elf64_Sym>(section_offset(section_symtab_));
+ #elif defined __x86_64__
+ auto symbols = get<Elf32_Sym>(section_offset(section_symtab_));
+ #else
diff -Nru xir-1.4.1/debian/patches/series xir-1.4.1/debian/patches/series
--- xir-1.4.1/debian/patches/series 2022-05-23 03:34:37.000000000 +0800
+++ xir-1.4.1/debian/patches/series 2022-05-23 03:34:37.000000000 +0800
@@ -4,3 +4,4 @@
Fix-FTBFS-with-Werror-range-loop-construct-Closes-99.patch
0005-cmake-vitis_version.c.in-Remove-the-build-date-from-.patch
0006-No-Werror.patch
+0007-add-riscv64-support.patch
Attachment:
signature.asc
Description: PGP signature