1 |
commit: 24e573b450a6498e0fb504a59b1175461fa0151d |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Nov 1 05:17:55 2020 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Nov 1 05:17:55 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=24e573b4 |
7 |
|
8 |
app-editors/dav: fix build with gcc 10, compressed man |
9 |
|
10 |
Closes: https://bugs.gentoo.org/729246 |
11 |
Closes: https://bugs.gentoo.org/706846 |
12 |
Package-Manager: Portage-3.0.8, Repoman-3.0.2 |
13 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
14 |
|
15 |
app-editors/dav/dav-0.8.5-r2.ebuild | 19 ++++++++++------- |
16 |
app-editors/dav/files/dav-0.8.5-asneeded.patch | 5 ++--- |
17 |
.../files/dav-0.8.5-davrc-buffer-overflow.patch | 4 ++-- |
18 |
app-editors/dav/files/dav-0.8.5-fno-common.patch | 24 ++++++++++++++++++++++ |
19 |
app-editors/dav/files/dav-0.8.5-makefile.patch | 21 +++++++++++++++++++ |
20 |
5 files changed, 61 insertions(+), 12 deletions(-) |
21 |
|
22 |
diff --git a/app-editors/dav/dav-0.8.5-r2.ebuild b/app-editors/dav/dav-0.8.5-r2.ebuild |
23 |
index b04dad5486e..bab3b72d4bd 100644 |
24 |
--- a/app-editors/dav/dav-0.8.5-r2.ebuild |
25 |
+++ b/app-editors/dav/dav-0.8.5-r2.ebuild |
26 |
@@ -1,12 +1,12 @@ |
27 |
# Copyright 1999-2020 Gentoo Authors |
28 |
# Distributed under the terms of the GNU General Public License v2 |
29 |
|
30 |
-EAPI=6 |
31 |
+EAPI=7 |
32 |
+ |
33 |
inherit toolchain-funcs |
34 |
|
35 |
DESCRIPTION="A minimal console text editor" |
36 |
HOMEPAGE="http://dav-text.sourceforge.net/" |
37 |
- |
38 |
# The maintainer does not keep sourceforge's mirrors up-to-date, |
39 |
# so we point to the website's store of files. |
40 |
SRC_URI="http://dav-text.sourceforge.net/files/${P}.tar.gz" |
41 |
@@ -15,18 +15,20 @@ LICENSE="GPL-2" |
42 |
SLOT="0" |
43 |
KEYWORDS="~alpha amd64 ppc x86 ~amd64-linux ~x86-linux ~ppc-macos" |
44 |
|
45 |
+BDEPEND="virtual/pkgconfig" |
46 |
RDEPEND="sys-libs/ncurses:0=" |
47 |
-DEPEND=" |
48 |
- ${RDEPEND} |
49 |
- virtual/pkgconfig |
50 |
-" |
51 |
+DEPEND="${RDEPEND}" |
52 |
|
53 |
PATCHES=( |
54 |
"${FILESDIR}/${P}-asneeded.patch" |
55 |
"${FILESDIR}/${P}-davrc-buffer-overflow.patch" |
56 |
"${FILESDIR}/fix-Wformat-security-warnings.patch" |
57 |
+ "${FILESDIR}/${PN}-0.8.5-fno-common.patch" |
58 |
+ "${FILESDIR}/${PN}-0.8.5-makefile.patch" |
59 |
) |
60 |
|
61 |
+DOCS=( README ) |
62 |
+ |
63 |
# Makefile only |
64 |
src_configure() { :; } |
65 |
|
66 |
@@ -37,4 +39,7 @@ src_compile() { |
67 |
LDFLAGS="${LDFLAGS} $( $(tc-getPKG_CONFIG) --libs ncurses)" |
68 |
} |
69 |
|
70 |
-DOCS=( README ) |
71 |
+src_install() { |
72 |
+ default |
73 |
+ docompress -x /usr/share/man/man1/dav.1.gz |
74 |
+} |
75 |
|
76 |
diff --git a/app-editors/dav/files/dav-0.8.5-asneeded.patch b/app-editors/dav/files/dav-0.8.5-asneeded.patch |
77 |
index 75a43c67f43..92bc6ebfdac 100644 |
78 |
--- a/app-editors/dav/files/dav-0.8.5-asneeded.patch |
79 |
+++ b/app-editors/dav/files/dav-0.8.5-asneeded.patch |
80 |
@@ -1,6 +1,5 @@ |
81 |
-diff -u -r a/Makefile b/Makefile |
82 |
---- a/Makefile 2004-02-22 02:04:07.000000000 +0100 |
83 |
-+++ b/Makefile 2008-12-30 19:31:19.000000000 +0100 |
84 |
+--- a/Makefile |
85 |
++++ b/Makefile |
86 |
@@ -12,7 +12,7 @@ |
87 |
LDFLAGS=-lncurses -O3 -Wall |
88 |
|
89 |
|
90 |
diff --git a/app-editors/dav/files/dav-0.8.5-davrc-buffer-overflow.patch b/app-editors/dav/files/dav-0.8.5-davrc-buffer-overflow.patch |
91 |
index a32e78ebc81..7287d36cc60 100644 |
92 |
--- a/app-editors/dav/files/dav-0.8.5-davrc-buffer-overflow.patch |
93 |
+++ b/app-editors/dav/files/dav-0.8.5-davrc-buffer-overflow.patch |
94 |
@@ -1,5 +1,5 @@ |
95 |
---- dav-0.8.5.orig/main.c 2011-01-29 14:16:53.537725568 -0500 |
96 |
-+++ dav-0.8.5/main.c 2011-01-29 14:20:45.139125094 -0500 |
97 |
+--- a/main.c |
98 |
++++ b/main.c |
99 |
@@ -327,7 +327,7 @@ |
100 |
void loadSettings() |
101 |
{ |
102 |
|
103 |
diff --git a/app-editors/dav/files/dav-0.8.5-fno-common.patch b/app-editors/dav/files/dav-0.8.5-fno-common.patch |
104 |
new file mode 100644 |
105 |
index 00000000000..df58fa36098 |
106 |
--- /dev/null |
107 |
+++ b/app-editors/dav/files/dav-0.8.5-fno-common.patch |
108 |
@@ -0,0 +1,24 @@ |
109 |
+https://bugs.gentoo.org/706846 |
110 |
+https://sources.debian.org/patches/dav-text/0.9.0-2/gcc-10.patch/ |
111 |
+--- a/main.c |
112 |
++++ b/main.c |
113 |
+@@ -58,7 +58,7 @@ char displayWholeScreen = 0; |
114 |
+ struct buffer *buffers; |
115 |
+ struct buffer *currentBuffer; |
116 |
+ int currentBufferNum = 0; |
117 |
+- |
118 |
++ptrToFunction Fn_ptr[12]; //Bindings for the Fn keys; Fx = Fn_ptr[x-1] |
119 |
+ |
120 |
+ int main(int argc, char *argv[]) |
121 |
+ { |
122 |
+--- dav-text-0.9.0.orig/main.h |
123 |
++++ dav-text-0.9.0/main.h |
124 |
+@@ -47,7 +47,7 @@ void connectLines(struct line *baseline) |
125 |
+ void determineLineNum(struct position *p); |
126 |
+ void countTabs(struct line *l); |
127 |
+ void determineCursX(struct position *p); |
128 |
+-ptrToFunction Fn_ptr[12]; //Bindings for the Fn keys; Fx = Fn_ptr[x-1] |
129 |
++extern ptrToFunction Fn_ptr[12]; //Bindings for the Fn keys; Fx = Fn_ptr[x-1] |
130 |
+ |
131 |
+ extern int maxY,maxX; |
132 |
+ extern int helpBarUpdate; |
133 |
|
134 |
diff --git a/app-editors/dav/files/dav-0.8.5-makefile.patch b/app-editors/dav/files/dav-0.8.5-makefile.patch |
135 |
new file mode 100644 |
136 |
index 00000000000..8ff62de305e |
137 |
--- /dev/null |
138 |
+++ b/app-editors/dav/files/dav-0.8.5-makefile.patch |
139 |
@@ -0,0 +1,21 @@ |
140 |
+diff --git a/Makefile b/Makefile |
141 |
+index 8b1ff0a..7a57840 100644 |
142 |
+--- a/Makefile |
143 |
++++ b/Makefile |
144 |
+@@ -1,4 +1,4 @@ |
145 |
+-CC=gcc |
146 |
++CC?=gcc |
147 |
+ OBJECTS=main.o \ |
148 |
+ buffers.o \ |
149 |
+ fileIO.o \ |
150 |
+@@ -8,8 +8,8 @@ OBJECTS=main.o \ |
151 |
+ undo.o \ |
152 |
+ move.o |
153 |
+ |
154 |
+-CFLAGS=-O3 -Wall |
155 |
+-LDFLAGS=-lncurses -O3 -Wall |
156 |
++CFLAGS?=O3 -Wall |
157 |
++LDFLAGS?=lncurses -O3 -Wall |
158 |
+ |
159 |
+ dav: $(OBJECTS) |
160 |
+ $(CC) $(OBJECTS) $(LDFLAGS) -o dav |