summarylogtreecommitdiffstats
path: root/makepkg-riscv64.patch
blob: f3aa91a66c13d618bc9a98fe501317c0822837d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
--- /usr/share/devtools/makepkg.conf.d/x86_64.conf	2024-02-10 08:01:05.000000000 +0800
+++ riscv64.conf	2024-02-11 00:37:44.643963368 +0800
@@ -35,14 +35,14 @@
 # ARCHITECTURE, COMPILE FLAGS
 #########################################################################
 #
-CARCH="x86_64"
-CHOST="x86_64-pc-linux-gnu"
+CARCH="riscv64"
+CHOST="riscv64-unknown-linux-gnu"
 
 #-- Compiler and Linker Flags
 #CPPFLAGS=""
-CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions \
+CFLAGS="-march=rv64gc -mabi=lp64d -O2 -pipe -fno-plt -fexceptions \
         -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security \
-        -fstack-clash-protection -fcf-protection"
+        -fstack-clash-protection"
 CXXFLAGS="$CFLAGS -Wp,-D_GLIBCXX_ASSERTIONS"
 LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now \
          -Wl,-z,pack-relative-relocs"