mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 02:37:35 +00:00
Ports: Update tinycc's patches to use git patches
This commit is contained in:
parent
3531aa2b84
commit
a20773b5ce
5 changed files with 62 additions and 22 deletions
|
@ -0,0 +1,25 @@
|
||||||
|
From efa276eb16b2857f2fb2c8bc372debf0b14574d9 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Sergey Bugaev <bugaevc@gmail.com>
|
||||||
|
Date: Wed, 2 Oct 2019 22:50:20 +0300
|
||||||
|
Subject: [PATCH 1/2] Disable backtrace on serenity
|
||||||
|
|
||||||
|
---
|
||||||
|
tcc.h | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/tcc.h b/tcc.h
|
||||||
|
index ccb3b60..efc54be 100644
|
||||||
|
--- a/tcc.h
|
||||||
|
+++ b/tcc.h
|
||||||
|
@@ -184,7 +184,7 @@ extern long double strtold (const char *__nptr, char **__endptr);
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-#if defined TCC_IS_NATIVE && !defined CONFIG_TCCBOOT
|
||||||
|
+#if defined TCC_IS_NATIVE && !defined CONFIG_TCCBOOT && !define __serenity__
|
||||||
|
# define CONFIG_TCC_BACKTRACE
|
||||||
|
# if (defined TCC_TARGET_I386 || defined TCC_TARGET_X86_64 || \
|
||||||
|
defined TCC_TARGET_ARM || defined TCC_TARGET_ARM64 || \
|
||||||
|
--
|
||||||
|
2.36.1
|
||||||
|
|
|
@ -0,0 +1,25 @@
|
||||||
|
From 45136fa3e435eaad300fd8866879e4ef817f885b Mon Sep 17 00:00:00 2001
|
||||||
|
From: Sergey Bugaev <bugaevc@gmail.com>
|
||||||
|
Date: Wed, 2 Oct 2019 22:50:20 +0300
|
||||||
|
Subject: [PATCH 2/2] Manually set the target os instead of using uname
|
||||||
|
|
||||||
|
---
|
||||||
|
configure | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/configure b/configure
|
||||||
|
index 5673d17..9bd864f 100755
|
||||||
|
--- a/configure
|
||||||
|
+++ b/configure
|
||||||
|
@@ -52,7 +52,7 @@ cc_name="gcc"
|
||||||
|
ar_set=
|
||||||
|
|
||||||
|
# OS specific
|
||||||
|
-targetos=`uname`
|
||||||
|
+targetos=Serenity
|
||||||
|
case $targetos in
|
||||||
|
Darwin)
|
||||||
|
confvars="$confvars OSX"
|
||||||
|
--
|
||||||
|
2.36.1
|
||||||
|
|
12
Ports/tinycc/patches/ReadMe.md
Normal file
12
Ports/tinycc/patches/ReadMe.md
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
# Patches for tinycc on SerenityOS
|
||||||
|
|
||||||
|
## `0001-Disable-backtrace-on-serenity.patch`
|
||||||
|
|
||||||
|
Disable backtrace on serenity
|
||||||
|
|
||||||
|
|
||||||
|
## `0002-Manually-set-the-target-os-instead-of-using-uname.patch`
|
||||||
|
|
||||||
|
Manually set the target os instead of using uname
|
||||||
|
|
||||||
|
|
|
@ -1,11 +0,0 @@
|
||||||
--- tinycc-dev/tcc.h 2019-05-14 22:40:39.000000000 +0300
|
|
||||||
+++ tinycc-dev-serenity/tcc.h 2019-10-02 13:37:16.919990212 +0300
|
|
||||||
@@ -162,7 +162,7 @@
|
|
||||||
# endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
-#if defined TCC_IS_NATIVE && !defined CONFIG_TCCBOOT
|
|
||||||
+#if defined TCC_IS_NATIVE && !defined CONFIG_TCCBOOT && !defined __serenity__
|
|
||||||
# define CONFIG_TCC_BACKTRACE
|
|
||||||
# if (defined TCC_TARGET_I386 || defined TCC_TARGET_X86_64) \
|
|
||||||
&& !defined TCC_UCLIBC && !defined TCC_MUSL
|
|
|
@ -1,11 +0,0 @@
|
||||||
--- tinycc-dev/configure 2019-05-14 22:40:39.000000000 +0300
|
|
||||||
+++ tinycc-dev-serenity/configure 2019-10-02 13:31:15.464543005 +0300
|
|
||||||
@@ -49,7 +49,7 @@
|
|
||||||
gcc_minor=0
|
|
||||||
|
|
||||||
# OS specific
|
|
||||||
-targetos=`uname`
|
|
||||||
+targetos=Serenity
|
|
||||||
case $targetos in
|
|
||||||
Darwin)
|
|
||||||
confvars="$confvars OSX"
|
|
Loading…
Add table
Add a link
Reference in a new issue