[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#897655: xutils-dev: Please add support for riscv64



Source: xutils-dev
Version: 1:7.7+5
Severity: normal
Tags: patch
User: debian-riscv@lists.debian.org
Usertags: riscv64

Hello,

We need support in this package for the riscv64 architecture.

I am attaching a patch that adds support.  It applies cleanly when added last in
the "series" file.

A similar patch was sent by Fedora people ~1 month ago and rejected, since
upstream are not interested in continuing support of this software.

They already said something similar when I sent a patch back in 2014 for
OpenRISC or1k.  They were even surprised that people wanted to add support to
it.  I would gladly let it go, but it turns out that packages like for example
emacs25 still need it (through xaw3d).

It would be great if you could include these changes and release a new version
for unstable, it lives in "unreleased" for the time being.


Thanks and cheers.
--
Manuel A. Fernandez Montecelo <mafm@debian.org>
Description: Add support for riscv64
 Upstream is not interested in adding these patches, they rejected changes when
 proposed by people from Fedora.
 .
 They were already reluctant to add support back in 2014 for other arches,
 e.g. OpenRISC or1k (I sent the support then).
Author: Manuel A. Fernandez Montecelo <mafm@debian.org>
Last-Update: 2018-05-03
--- a/xorg-cf-files/Imake.cf
+++ b/xorg-cf-files/Imake.cf
@@ -1037,6 +1037,10 @@
 #   define AArch64Architecture
 #   undef __aarch64__
 # endif
+# if defined(__riscv) && (__riscv_xlen == 64)
+#   define RISCV64Architecture
+#   /* undef __riscv */
+# endif
 #endif /* linux || __GLIBC__ */
 
 #if (defined(__Lynx__) || defined(Lynx)) && (defined(i386) || defined(__i386__) || defined(__x86__) || defined(__powerpc__) || defined(__sparc__) || defined(sparc))
--- a/xorg-cf-files/linux.cf
+++ b/xorg-cf-files/linux.cf
@@ -1111,6 +1111,15 @@
 # define ServerExtraDefines    -DGCCUSESGAS XFree86ServerDefines -D_XSERVER64
 #endif /* AArch64Architecture */
 
+#ifdef RISCV64Architecture
+# ifndef OptimizedCDebugFlags
+#  define OptimizedCDebugFlags DefaultGcc2RISCV64Opt DefaultGcc2OptimizeOpt GccAliasingArgs
+# endif
+# define LinuxMachineDefines   -D__riscv
+# define ServerOSDefines   XFree86ServerOSDefines -DDDXTIME
+# define ServerExtraDefines    -DGCCUSESGAS XFree86ServerDefines -D_XSERVER64
+#endif /* RISCV64Architecture */
+
 #ifndef StandardDefines
 # ifdef __linux__
 #  define StandardDefines	-Dlinux LinuxMachineDefines LinuxSourceDefines
--- a/xorg-cf-files/xfree86.cf
+++ b/xorg-cf-files/xfree86.cf
@@ -2067,6 +2067,12 @@
 # endif
 #endif
 
+#if HasGcc2 && defined(RISCV64Architecture)
+# ifndef DefaultGcc2RISCV64Opt
+#  define DefaultGcc2RISCV64Opt DefaultGcc2OptimizeOpt GccAliasingArgs
+# endif
+#endif
+
 #if HasGcc2 && defined(AlphaArchitecture)
 # ifndef DefaultGcc2AxpOpt
 #  define DefaultGcc2AxpOpt DefaultGcc2OptimizeOpt GccAliasingArgs
--- a/xorg-cf-files/xorg.cf
+++ b/xorg-cf-files/xorg.cf
@@ -1584,6 +1584,12 @@
 # endif
 #endif
 
+#if HasGcc2 && defined(RISCV64Architecture)
+# ifndef DefaultGcc2RISCV64Opt
+#  define DefaultGcc2RISCV64Opt DefaultGcc2OptimizeOpt GccAliasingArgs
+# endif
+#endif
+
 #if HasGcc2 && defined(AMD64Architecture)
 # ifndef DefaultGcc2AMD64Opt
 #  define DefaultGcc2AMD64Opt DefaultGcc2OptimizeOpt GccAliasingArgs

Reply to: