1 |
commit: 1fec602e63cd09995570cc551bb073ffd68252e1 |
2 |
Author: Andrey Grozin <grozin <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Jan 3 10:46:11 2023 +0000 |
4 |
Commit: Andrey Grozin <grozin <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Jan 3 10:46:11 2023 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1fec602e |
7 |
|
8 |
app-text/crwx-ng: compilation fixes |
9 |
|
10 |
Closes: https://bugs.gentoo.org/888561 |
11 |
Closes: https://bugs.gentoo.org/888551 |
12 |
Signed-off-by: Andrey Grozin <grozin <AT> gentoo.org> |
13 |
|
14 |
app-text/crwx-ng/crwx-ng-0.2.0-r2.ebuild | 23 +++++++++++ |
15 |
app-text/crwx-ng/files/crwx-ng-0.2.0.patch | 62 ++++++++++++++++++++++++++++++ |
16 |
2 files changed, 85 insertions(+) |
17 |
|
18 |
diff --git a/app-text/crwx-ng/crwx-ng-0.2.0-r2.ebuild b/app-text/crwx-ng/crwx-ng-0.2.0-r2.ebuild |
19 |
new file mode 100644 |
20 |
index 000000000000..c362c9d43f6d |
21 |
--- /dev/null |
22 |
+++ b/app-text/crwx-ng/crwx-ng-0.2.0-r2.ebuild |
23 |
@@ -0,0 +1,23 @@ |
24 |
+# Copyright 1999-2023 Gentoo Authors |
25 |
+# Distributed under the terms of the GNU General Public License v2 |
26 |
+ |
27 |
+EAPI=8 |
28 |
+WX_GTK_VER="3.0-gtk3" |
29 |
+inherit cmake wxwidgets |
30 |
+ |
31 |
+DESCRIPTION="Cross-platform e-book reader" |
32 |
+HOMEPAGE="https://gitlab.com/coolreader-ng/crwx-ng" |
33 |
+SRC_URI="https://gitlab.com/coolreader-ng/${PN}/-/archive/${PV}/${P}.tar.bz2" |
34 |
+ |
35 |
+LICENSE="GPL-2" |
36 |
+SLOT="0" |
37 |
+KEYWORDS="~amd64 ~x86" |
38 |
+IUSE="+gif +svg +chm +harfbuzz +libunibreak +fribidi +zstd +libutf8proc" |
39 |
+ |
40 |
+CDEPEND=">=app-text/crengine-ng-0.9.3[png,jpeg,fontconfig,gif=,svg=,chm=,harfbuzz=,fribidi=,zstd=,libutf8proc=] |
41 |
+ x11-libs/wxGTK:${WX_GTK_VER}[X]" |
42 |
+BDEPEND="${CDEPEND}" |
43 |
+RDEPEND="${CDEPEND} |
44 |
+ virtual/ttf-fonts" |
45 |
+ |
46 |
+PATCHES=( "${FILESDIR}"/${P}.patch ) |
47 |
|
48 |
diff --git a/app-text/crwx-ng/files/crwx-ng-0.2.0.patch b/app-text/crwx-ng/files/crwx-ng-0.2.0.patch |
49 |
new file mode 100644 |
50 |
index 000000000000..f754ceb88d0b |
51 |
--- /dev/null |
52 |
+++ b/app-text/crwx-ng/files/crwx-ng-0.2.0.patch |
53 |
@@ -0,0 +1,62 @@ |
54 |
+From 146f22a7c56a3402c75b4a51b8b1940144dfd9fd Mon Sep 17 00:00:00 2001 |
55 |
+From: Aleksey Chernov <valexlin@×××××.com> |
56 |
+Date: Tue, 27 Dec 2022 10:11:16 +0400 |
57 |
+Subject: [PATCH] Compile error/warn fixed. |
58 |
+ |
59 |
+--- |
60 |
+ src/cr3.cpp | 25 +++++++++++-------------- |
61 |
+ 1 file changed, 11 insertions(+), 14 deletions(-) |
62 |
+ |
63 |
+diff --git a/src/cr3.cpp b/src/cr3.cpp |
64 |
+index 19d5c4a..00e733b 100644 |
65 |
+--- a/src/cr3.cpp |
66 |
++++ b/src/cr3.cpp |
67 |
+@@ -341,14 +341,17 @@ void testFormatting() { |
68 |
+ LFormattedText txt; |
69 |
+ void addLine(const lChar32* str, int flags, LVFontRef font) { |
70 |
+ lString32 s(str); |
71 |
+- txt.AddSourceLine(s.c_str(), /* pointer to unicode text string */ |
72 |
+- s.length(), /* number of chars in text, 0 for auto(strlen) */ |
73 |
+- 0x000000, /* text color */ |
74 |
+- 0xFFFFFF, /* background color */ |
75 |
+- font.get(), /* font to draw string */ |
76 |
+- NULL, flags, 16, /* interline space, *16 (16=single, 32=double) */ |
77 |
+- 30, /* first line margin */ |
78 |
+- NULL, 0); |
79 |
++ txt.AddSourceLine(s.c_str(), /* pointer to unicode text string */ |
80 |
++ s.length(), /* number of chars in text, 0 for auto(strlen) */ |
81 |
++ 0x000000, /* text color */ |
82 |
++ 0xFFFFFF, /* background color */ |
83 |
++ font.get(), /* font to draw string */ |
84 |
++ NULL, /* pointer to text lang config */ |
85 |
++ flags, /* flags */ |
86 |
++ 16, /* line height in screen pixels; *16 (16=single, 32=double) */ |
87 |
++ 0, /* drift y from baseline */ |
88 |
++ 30, /* first line margin */ |
89 |
++ NULL, 0, 0); |
90 |
+ } |
91 |
+ void dump() { |
92 |
+ formatted_text_fragment_t* buf = txt.GetBuffer(); |
93 |
+@@ -1380,9 +1383,6 @@ void cr3Frame::OnFileOpen(wxCommandEvent& WXUNUSED(event)) { |
94 |
+ wxT(""), //const wxString& defaultFile = "", |
95 |
+ wxT("All supported files|*.fb2;*.fbz;*.txt;*.zip;*.rtf;*.epub;*.tcr;*.html;*.htm;*.shtml;*.xhtml|FictionBook files (*.fb2)|*.fb2;*.fbz|RTF files (*.rtf)|*.rtf|Text files (*.txt, *.tcr)|*.txt;*.tcr|HTML files|*.html;*.htm;*.shtml;*.xhtml|EPUB files (*.epub)|*.epub|ZIP archieves (*.zip)|*.zip"), //const wxString& wildcard = "*.*", |
96 |
+ wxFD_OPEN | wxFD_FILE_MUST_EXIST //long style = wxFD_DEFAULT_STYLE, |
97 |
+- //const wxPoint& pos = wxDefaultPosition, |
98 |
+- //const wxSize& sz = wxDefaultSize, |
99 |
+- //const wxString& name = "filedlg" |
100 |
+ ); |
101 |
+ |
102 |
+ if (dlg.ShowModal() == wxID_OK) { |
103 |
+@@ -1410,9 +1410,6 @@ void cr3Frame::OnFileSave(wxCommandEvent& WXUNUSED(event)) { |
104 |
+ wxT(""), //const wxString& defaultFile = "", |
105 |
+ wxT("Wolf EBook files (*.wol)|*.wol"), //const wxString& wildcard = "*.*", |
106 |
+ wxFD_SAVE | wxFD_OVERWRITE_PROMPT //long style = wxFD_DEFAULT_STYLE, |
107 |
+- //const wxPoint& pos = wxDefaultPosition, |
108 |
+- //const wxSize& sz = wxDefaultSize, |
109 |
+- //const wxString& name = "filedlg" |
110 |
+ ); |
111 |
+ WolOptions opts(this); |
112 |
+ if (dlg.ShowModal() == wxID_OK && opts.ShowModal() == wxID_OK) { |
113 |
+-- |
114 |
+2.38.2 |
115 |
+ |