-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
82 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
From: https://github.com/bmwiedemann/openSUSE/blob/4eded4be9125b3e8b4e2e0730d07b4f1e536b052/packages/x/xorg-cf-files/u_riscv.patch | ||
Author: Andreas Schwab <schwab@suse.de> | ||
Subject: Add support for riscv64 | ||
Date: Mon, 09 Jan 2023 17:25:04 +0800 | ||
|
||
Index: xutils-dev/xorg-cf-files/Imake.cf | ||
=================================================================== | ||
--- xutils-dev.orig/xorg-cf-files/Imake.cf | ||
+++ xutils-dev/xorg-cf-files/Imake.cf | ||
@@ -1047,6 +1047,11 @@ XCOMM Keep cpp from replacing path eleme | ||
# endif | ||
# undef __sw_64__ | ||
# endif /* __sw_64__ */ | ||
+# if defined(__riscv) && __riscv_xlen == 64 | ||
+# define RiscV64Architecture | ||
+# undef __riscv | ||
+# undef __riscv_xlen | ||
+# endif | ||
#endif /* linux || __GLIBC__ */ | ||
|
||
#if (defined(__Lynx__) || defined(Lynx)) && (defined(i386) || defined(__i386__) || defined(__x86__) || defined(__powerpc__) || defined(__sparc__) || defined(sparc)) | ||
Index: xutils-dev/xorg-cf-files/linux.cf | ||
=================================================================== | ||
--- xutils-dev.orig/xorg-cf-files/linux.cf | ||
+++ xutils-dev/xorg-cf-files/linux.cf | ||
@@ -1139,6 +1139,15 @@ InstallNamedTargetNoClobber(install,file | ||
# endif | ||
#endif /* Sw64Architecture */ | ||
|
||
+#ifdef RiscV64Architecture | ||
+# ifndef OptimizedCDebugFlags | ||
+# define OptimizedCDebugFlags DefaultGcc2RiscV64Opt | ||
+# endif | ||
+# define LinuxMachineDefines -D__riscv -D__riscv_xlen=64 | ||
+# define ServerOSDefines XFree86ServerOSDefines -DDDXTIME | ||
+# define ServerExtraDefines -DGCCUSESGAS XFree86ServerDefines -D_XSERVER64 | ||
+#endif /* RiscV64Architecture */ | ||
+ | ||
#ifndef StandardDefines | ||
# ifdef __linux__ | ||
# define StandardDefines -Dlinux LinuxMachineDefines LinuxSourceDefines | ||
Index: xutils-dev/xorg-cf-files/xfree86.cf | ||
=================================================================== | ||
--- xutils-dev.orig/xorg-cf-files/xfree86.cf | ||
+++ xutils-dev/xorg-cf-files/xfree86.cf | ||
@@ -2091,6 +2091,12 @@ XFREE86JAPANESEDOCDIR = $(DOCDIR)/Japane | ||
# endif | ||
#endif | ||
|
||
+#if HasGcc2 && defined(RiscV64Architecture) | ||
+# ifndef DefaultGcc2RiscV64Opt | ||
+# define DefaultGcc2RiscV64Opt -O2 GccAliasingArgs | ||
+# endif | ||
+#endif | ||
+ | ||
#ifndef DefaultGcc2DebugOpt | ||
# define DefaultGcc2DebugOpt -g | ||
#endif | ||
Index: xutils-dev/xorg-cf-files/xorg.cf | ||
=================================================================== | ||
--- xutils-dev.orig/xorg-cf-files/xorg.cf | ||
+++ xutils-dev/xorg-cf-files/xorg.cf | ||
@@ -1663,6 +1663,12 @@ XFREE86JAPANESEDOCDIR = $(DOCDIR)/Japane | ||
# endif | ||
#endif | ||
|
||
+#if HasGcc2 && defined(RiscV64Architecture) | ||
+# ifndef DefaultGcc2RiscV64Opt | ||
+# define DefaultGcc2RiscV64Opt -O2 GccAliasingArgs | ||
+# endif | ||
+#endif | ||
+ | ||
#ifndef DefaultGcc2DebugOpt | ||
# define DefaultGcc2DebugOpt -g | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,4 @@ | |
06_font_path.diff | ||
07_gnu_manpath.diff | ||
09-add-sunway-support.diff | ||
10_riscv_support.diff |