mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-26 01:20:25 +00:00
Ports: Update mbedtls' patches to use git patches
This commit is contained in:
parent
1f64b93b21
commit
79dc62af61
Notes:
sideshowbarker
2024-07-17 10:49:01 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/79dc62af61 Pull-request: https://github.com/SerenityOS/serenity/pull/14055 Reviewed-by: https://github.com/danners Reviewed-by: https://github.com/timschumi
5 changed files with 74 additions and 34 deletions
37
Ports/mbedtls/patches/0001-Add-missing-includes.patch
Normal file
37
Ports/mbedtls/patches/0001-Add-missing-includes.patch
Normal file
|
@ -0,0 +1,37 @@
|
|||
From 4f2b20f26ae7ba1f77fa69808f6d4dc926249c0b Mon Sep 17 00:00:00 2001
|
||||
From: Larkin <45925460+larb0b@users.noreply.github.com>
|
||||
Date: Tue, 24 Sep 2019 02:56:39 -0400
|
||||
Subject: [PATCH 1/2] Add missing includes
|
||||
|
||||
---
|
||||
library/ssl_tls.c | 1 +
|
||||
library/x509_crt.c | 1 +
|
||||
2 files changed, 2 insertions(+)
|
||||
|
||||
diff --git a/library/ssl_tls.c b/library/ssl_tls.c
|
||||
index 38690fa..5791783 100644
|
||||
--- a/library/ssl_tls.c
|
||||
+++ b/library/ssl_tls.c
|
||||
@@ -49,6 +49,7 @@
|
||||
#include "mbedtls/platform_util.h"
|
||||
|
||||
#include <string.h>
|
||||
+#include <stdint.h>
|
||||
|
||||
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
||||
#include "mbedtls/oid.h"
|
||||
diff --git a/library/x509_crt.c b/library/x509_crt.c
|
||||
index 97e1d72..9f81247 100644
|
||||
--- a/library/x509_crt.c
|
||||
+++ b/library/x509_crt.c
|
||||
@@ -75,6 +75,7 @@
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <dirent.h>
|
||||
+#include <unistd.h>
|
||||
#endif /* !_WIN32 || EFIX64 || EFI32 */
|
||||
#endif
|
||||
|
||||
--
|
||||
2.36.1
|
||||
|
25
Ports/mbedtls/patches/0002-Remove-NET_C-from-config.patch
Normal file
25
Ports/mbedtls/patches/0002-Remove-NET_C-from-config.patch
Normal file
|
@ -0,0 +1,25 @@
|
|||
From e889bf88c3eb76ab6646f2e99fb029b63dac7379 Mon Sep 17 00:00:00 2001
|
||||
From: Larkin <45925460+larb0b@users.noreply.github.com>
|
||||
Date: Tue, 24 Sep 2019 02:56:39 -0400
|
||||
Subject: [PATCH 2/2] Remove NET_C from config
|
||||
|
||||
---
|
||||
include/mbedtls/config.h | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/include/mbedtls/config.h b/include/mbedtls/config.h
|
||||
index 654f972..5b37f1f 100644
|
||||
--- a/include/mbedtls/config.h
|
||||
+++ b/include/mbedtls/config.h
|
||||
@@ -2460,7 +2460,7 @@
|
||||
*
|
||||
* This module provides networking routines.
|
||||
*/
|
||||
-#define MBEDTLS_NET_C
|
||||
+//#define MBEDTLS_NET_C
|
||||
|
||||
/**
|
||||
* \def MBEDTLS_OID_C
|
||||
--
|
||||
2.36.1
|
||||
|
12
Ports/mbedtls/patches/ReadMe.md
Normal file
12
Ports/mbedtls/patches/ReadMe.md
Normal file
|
@ -0,0 +1,12 @@
|
|||
# Patches for mbedtls on SerenityOS
|
||||
|
||||
## `0001-Add-missing-includes.patch`
|
||||
|
||||
Add missing includes
|
||||
|
||||
|
||||
## `0002-Remove-NET_C-from-config.patch`
|
||||
|
||||
Remove NET_C from config
|
||||
|
||||
|
|
@ -1,22 +0,0 @@
|
|||
diff -u -r mbedtls/library/ssl_tls.c mbedtls-patched/library/ssl_tls.c
|
||||
--- mbedtls/library/ssl_tls.c 2019-06-18 23:23:28.000000000 +1000
|
||||
+++ mbedtls-patched/library/ssl_tls.c 2019-08-05 00:36:37.049255960 +1000
|
||||
@@ -49,6 +49,7 @@
|
||||
#include "mbedtls/platform_util.h"
|
||||
|
||||
#include <string.h>
|
||||
+#include <stdint.h>
|
||||
|
||||
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
||||
#include "mbedtls/oid.h"
|
||||
diff -u -r mbedtls/library/x509_crt.c mbedtls-patched/library/x509_crt.c
|
||||
--- mbedtls/library/x509_crt.c 2019-06-18 23:23:28.000000000 +1000
|
||||
+++ mbedtls-patched/library/x509_crt.c 2019-08-05 00:24:22.606023827 +1000
|
||||
@@ -75,6 +75,7 @@
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <dirent.h>
|
||||
+#include <unistd.h>
|
||||
#endif /* !_WIN32 || EFIX64 || EFI32 */
|
||||
#endif
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
diff -u -r mbedtls/include/mbedtls/config.h mbedtls-patched/include/mbedtls/config.h
|
||||
--- mbedtls/include/mbedtls/config.h 2019-06-18 23:23:28.000000000 +1000
|
||||
+++ mbedtls-patched/include/mbedtls/config.h 2019-08-05 00:27:17.322830039 +1000
|
||||
@@ -2460,7 +2460,7 @@
|
||||
*
|
||||
* This module provides networking routines.
|
||||
*/
|
||||
-#define MBEDTLS_NET_C
|
||||
+//#define MBEDTLS_NET_C
|
||||
|
||||
/**
|
||||
* \def MBEDTLS_OID_C
|
Loading…
Reference in a new issue