mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-29 16:21:29 +00:00
Ports: Update sam's patches to use git patches
This commit is contained in:
parent
57bbe11933
commit
0068f7f764
Notes:
sideshowbarker
2024-07-17 10:47:33 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/0068f7f764 Pull-request: https://github.com/SerenityOS/serenity/pull/14055 Reviewed-by: https://github.com/danners Reviewed-by: https://github.com/timschumi
|
@ -1,24 +1,18 @@
|
|||
diff --git a/Makefile b/Makefile
|
||||
index 1153e0c..9c70190 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -3,8 +3,8 @@ OBJS = reciter.o sam.o render.o main.o debug.o processframes.o createtransitions
|
||||
CC = gcc
|
||||
|
||||
# libsdl present
|
||||
-CFLAGS = -Wall -O2 -DUSESDL `sdl-config --cflags`
|
||||
-LFLAGS = `sdl-config --libs`
|
||||
+CFLAGS = -Wall -O2 -DUSESDL -I../../SDL2/SDL-main-serenity/include -D_REENTRANT
|
||||
+LFLAGS = -L../../SDL2 -lSDL2
|
||||
|
||||
# no libsdl present
|
||||
#CFLAGS = -Wall -O2
|
||||
From e9875cfafe88de258da81b2b366a534d7f1edfc4 Mon Sep 17 00:00:00 2001
|
||||
From: Timothy <timmot@users.noreply.github.com>
|
||||
Date: Thu, 3 Jun 2021 14:20:09 -0700
|
||||
Subject: [PATCH 1/2] Enable the windows function stubs for serenity
|
||||
|
||||
---
|
||||
src/main.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/main.c b/src/main.c
|
||||
index 3e8fdde..3432fe8 100644
|
||||
--- a/src/main.c
|
||||
+++ b/src/main.c
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
|
||||
|
||||
// Approximations of some Windows functions to ease portability
|
||||
-#if defined __GNU_LIBRARY__ || defined __GLIBC__
|
||||
|
@ -26,3 +20,6 @@ index 3e8fdde..3432fe8 100644
|
|||
static int min(int l, int r) { return l < r ? l : r; }
|
||||
static void strcat_s(char * dest, int size, char * str) {
|
||||
unsigned int dlen = strlen(dest);
|
||||
--
|
||||
2.36.1
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
From e588447c853b3df909747002985f833a428c8c37 Mon Sep 17 00:00:00 2001
|
||||
From: Timothy <timmot@users.noreply.github.com>
|
||||
Date: Mon, 16 May 2022 23:23:21 +0430
|
||||
Subject: [PATCH 2/2] Manually set the SDL2 include path and library dir
|
||||
|
||||
---
|
||||
Makefile | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index 1153e0c..9c70190 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -3,8 +3,8 @@ OBJS = reciter.o sam.o render.o main.o debug.o processframes.o createtransitions
|
||||
CC = gcc
|
||||
|
||||
# libsdl present
|
||||
-CFLAGS = -Wall -O2 -DUSESDL `sdl-config --cflags`
|
||||
-LFLAGS = `sdl-config --libs`
|
||||
+CFLAGS = -Wall -O2 -DUSESDL -I../../SDL2/SDL-main-serenity/include -D_REENTRANT
|
||||
+LFLAGS = -L../../SDL2 -lSDL2
|
||||
|
||||
# no libsdl present
|
||||
#CFLAGS = -Wall -O2
|
||||
--
|
||||
2.36.1
|
||||
|
12
Ports/sam/patches/ReadMe.md
Normal file
12
Ports/sam/patches/ReadMe.md
Normal file
|
@ -0,0 +1,12 @@
|
|||
# Patches for sam on SerenityOS
|
||||
|
||||
## `0001-Enable-the-windows-function-stubs-for-serenity.patch`
|
||||
|
||||
Enable the windows function stubs for serenity
|
||||
|
||||
|
||||
## `0002-Manually-set-the-SDL2-include-path-and-library-dir.patch`
|
||||
|
||||
Manually set the SDL2 include path and library dir
|
||||
|
||||
|
Loading…
Reference in a new issue