summaryrefslogtreecommitdiff
path: root/system/libucontext/git.patch
blob: d42ee080329acb0667e30da527046a2f6151742a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
From d7688a41df4cbe51e52bfebbab7d411548ed7738 Mon Sep 17 00:00:00 2001
From: "A. Wilcox" <AWilcox@Wilcox-Tech.com>
Date: Mon, 30 Mar 2020 02:22:43 -0500
Subject: [PATCH 1/3] README: Remove support section

This is no longer a member of the gcompat family of projects;
remove the mention of that and the gcompat mailing list link.
---
 README.md | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/README.md b/README.md
index 97a03b6..1db0516 100644
--- a/README.md
+++ b/README.md
@@ -38,8 +38,3 @@ $ make ARCH=x86_64 check
 $ make ARCH=x86_64 DESTDIR=out install
 ```
 
-
-## support
-
-`libucontext` is offered as part of the `gcompat` project.  Accordingly, please address all questions
-and bug reports to gcompat@lists.adelielinux.org.

From e2178de76a7d3f41fed7cc5bef3e68eea623a72a Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Mon, 30 Mar 2020 08:21:20 +0000
Subject: [PATCH 2/3] Makefile: Add LIBDIR variable

This ensures that it can be installed into custom location and also

Upstream-Status: Submitted
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 Makefile | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/Makefile b/Makefile
index a8dedc2..74ebdbf 100644
--- a/Makefile
+++ b/Makefile
@@ -3,6 +3,7 @@ ifeq ($(ARCH),$(filter $(ARCH),i386 i686))
 	override ARCH = x86
 endif
 
+LIBDIR := /lib
 CFLAGS = -ggdb3 -O2 -Wall -Iarch/${ARCH} -Iarch/common
 
 LIBUCONTEXT_C_SRC = $(wildcard arch/${ARCH}/*.c)
@@ -13,8 +14,8 @@ LIBUCONTEXT_SOVERSION = 0
 LIBUCONTEXT_NAME = libucontext.so
 LIBUCONTEXT_STATIC_NAME = libucontext.a
 LIBUCONTEXT_SONAME = libucontext.so.${LIBUCONTEXT_SOVERSION}
-LIBUCONTEXT_PATH = /lib/${LIBUCONTEXT_SONAME}
-LIBUCONTEXT_STATIC_PATH = /lib/${LIBUCONTEXT_STATIC_NAME}
+LIBUCONTEXT_PATH = ${LIBDIR}/${LIBUCONTEXT_SONAME}
+LIBUCONTEXT_STATIC_PATH = ${LIBDIR}/${LIBUCONTEXT_STATIC_NAME}
 
 all: ${LIBUCONTEXT_SONAME} ${LIBUCONTEXT_STATIC_NAME}
 
@@ -39,9 +40,9 @@ clean:
 		${LIBUCONTEXT_OBJ} test_libucontext
 
 install: all
-	install -D -m755 ${LIBUCONTEXT_NAME} ${DESTDIR}/${LIBUCONTEXT_PATH}
-	install -D -m664 ${LIBUCONTEXT_STATIC_NAME} ${DESTDIR}/${LIBUCONTEXT_STATIC_PATH}
-	ln -sf ${LIBUCONTEXT_SONAME} ${DESTDIR}/lib/${LIBUCONTEXT_NAME}
+	install -D -m755 ${LIBUCONTEXT_NAME} ${DESTDIR}${LIBUCONTEXT_PATH}
+	install -D -m664 ${LIBUCONTEXT_STATIC_NAME} ${DESTDIR}${LIBUCONTEXT_STATIC_PATH}
+	ln -sf ${LIBUCONTEXT_SONAME} ${DESTDIR}${LIBDIR}/${LIBUCONTEXT_NAME}
 
 check: test_libucontext ${LIBUCONTEXT_SONAME}
 	env LD_LIBRARY_PATH=$(shell pwd) ./test_libucontext

From 467ee2916d0eacbd32af10ead14e5d86e365fa2b Mon Sep 17 00:00:00 2001
From: "A. Wilcox" <AWilcox@Wilcox-Tech.com>
Date: Mon, 30 Mar 2020 17:25:30 -0500
Subject: [PATCH 3/3] x86: Update copyright statement
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Commit d0ccf2f96f12bfa040cc056f7dc26b3fd25c168d contains the makecontext
fix from Adélie commit aaeb73ea701388e55b7640e32509a5f6a57f6350[1], as
seen at AdelieLinux/libucontext@aaeb73ea – but it didn't include the
addition of my author line.

The full commit text, for future documentation/reference, was:

```
x86: Write link pointer at correct stack offset

It must come *after* the parameters, not *before*.
```

Fixes: d0ccf2f96f12 ("x86: modernize")
Signed-off-by: A. Wilcox <AWilcox@Wilcox-Tech.com>

[1]: https://code.foxkit.us/adelie/libucontext/commit/aaeb73ea701388e55b7640e32509a5f6a57f6350
---
 arch/x86/makecontext.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/x86/makecontext.c b/arch/x86/makecontext.c
index ee9c2e2..bc8163c 100644
--- a/arch/x86/makecontext.c
+++ b/arch/x86/makecontext.c
@@ -1,5 +1,6 @@
 /*
  * Copyright (c) 2018 Ariadne Conill <ariadne@dereferenced.org>
+ * Copyright (c) 2019 A. Wilcox <awilfox@adelielinux.org>
  *
  * Permission to use, copy, modify, and/or distribute this software for any
  * purpose with or without fee is hereby granted, provided that the above