1 |
commit: 55acb241f28752fa4d0cd5f09a21f273f1ab00fa |
2 |
Author: Azamat H. Hackimov <azamat.hackimov <AT> gmail <DOT> com> |
3 |
AuthorDate: Wed Aug 31 20:04:20 2016 +0000 |
4 |
Commit: Azamat H. Hackimov <winterheart <AT> gentoo <DOT> ru> |
5 |
CommitDate: Wed Aug 31 20:04:20 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/gamerlay.git/commit/?id=55acb241 |
7 |
|
8 |
dev-games/aseprite: Bump to 1.17, remove old. |
9 |
|
10 |
Package-Manager: portage-2.2.28 |
11 |
Manifest-Sign-Key: A018DE8C |
12 |
|
13 |
...aseprite-1.1.6.ebuild => aseprite-1.1.7.ebuild} | 22 +++++++++++++---- |
14 |
.../files/aseprite-1.1.7_type-punned_pointer.patch | 28 ++++++++++++++++++++++ |
15 |
dev-games/aseprite/metadata.xml | 3 ++- |
16 |
3 files changed, 47 insertions(+), 6 deletions(-) |
17 |
|
18 |
diff --git a/dev-games/aseprite/aseprite-1.1.6.ebuild b/dev-games/aseprite/aseprite-1.1.7.ebuild |
19 |
similarity index 76% |
20 |
rename from dev-games/aseprite/aseprite-1.1.6.ebuild |
21 |
rename to dev-games/aseprite/aseprite-1.1.7.ebuild |
22 |
index 97b21ca..45b24cd 100644 |
23 |
--- a/dev-games/aseprite/aseprite-1.1.6.ebuild |
24 |
+++ b/dev-games/aseprite/aseprite-1.1.7.ebuild |
25 |
@@ -17,10 +17,10 @@ LICENSE="BSD GPL-2 MIT" |
26 |
SLOT="0" |
27 |
KEYWORDS="~amd64 ~x86" |
28 |
|
29 |
-IUSE="debug kde gtk3 test webp" |
30 |
+IUSE="bundled-libs debug kde gtk3 test webp" |
31 |
|
32 |
RDEPEND="dev-libs/tinyxml |
33 |
- media-libs/allegro:0[X,png] |
34 |
+ !bundled-libs? ( media-libs/allegro:0[X,png] ) |
35 |
media-libs/freetype |
36 |
media-libs/giflib:= |
37 |
webp? ( media-libs/libwebp ) |
38 |
@@ -35,7 +35,9 @@ RDEPEND="dev-libs/tinyxml |
39 |
dev-qt/qtcore:5 |
40 |
kde-frameworks/kio:5 )" |
41 |
DEPEND="${RDEPEND} |
42 |
- app-arch/unzip" |
43 |
+ app-arch/unzip |
44 |
+ gtk3? ( virtual/pkgconfig ) |
45 |
+ webp? ( virtual/pkgconfig )" |
46 |
|
47 |
DOCS=( docs/files/ase.txt |
48 |
docs/files/fli.txt |
49 |
@@ -46,6 +48,8 @@ DOCS=( docs/files/ase.txt |
50 |
|
51 |
S="${WORKDIR}" |
52 |
|
53 |
+PATCHES=( "${FILESDIR}/${P}_type-punned_pointer.patch" ) |
54 |
+ |
55 |
src_prepare() { |
56 |
cmake-utils_src_prepare |
57 |
|
58 |
@@ -63,7 +67,7 @@ src_configure() { |
59 |
local mycmakeargs=( |
60 |
-DENABLE_UPDATER=OFF |
61 |
-DFULLSCREEN_PLATFORM=ON |
62 |
- -DUSE_SHARED_ALLEGRO4=ON |
63 |
+ -DUSE_SHARED_ALLEGRO4=$(usex !bundled-libs) |
64 |
-DUSE_SHARED_CURL=ON |
65 |
-DUSE_SHARED_FREETYPE=ON |
66 |
-DUSE_SHARED_GIFLIB=ON |
67 |
@@ -85,6 +89,14 @@ src_configure() { |
68 |
} |
69 |
|
70 |
src_install() { |
71 |
- newicon "${S}/data/icons/ase64.png" "${PN}.png" |
72 |
+ newicon -s 64 "${S}/data/icons/ase64.png" "${PN}.png" |
73 |
cmake-utils_src_install |
74 |
} |
75 |
+ |
76 |
+pkg_postinst() { |
77 |
+ if use !bundled-libs ; then |
78 |
+ ewarn "Aseprite has been built with system-wide Allegro 4." |
79 |
+ ewarn "Please note that you will not be able to resize the main window." |
80 |
+ ewarn "To enable resizing enable USE-flag bundled-libs and rebuild package." |
81 |
+ fi |
82 |
+} |
83 |
|
84 |
diff --git a/dev-games/aseprite/files/aseprite-1.1.7_type-punned_pointer.patch b/dev-games/aseprite/files/aseprite-1.1.7_type-punned_pointer.patch |
85 |
new file mode 100644 |
86 |
index 0000000..0a05914 |
87 |
--- /dev/null |
88 |
+++ b/dev-games/aseprite/files/aseprite-1.1.7_type-punned_pointer.patch |
89 |
@@ -0,0 +1,28 @@ |
90 |
+diff --git a/src/allegro/src/x/xkeyboard.c b/src/allegro/src/x/xkeyboard.c |
91 |
+index f121e62..86fa4f7 100644 |
92 |
+--- a/src/allegro/src/x/xkeyboard.c |
93 |
++++ b/src/allegro/src/x/xkeyboard.c |
94 |
+@@ -356,6 +356,14 @@ static int find_unknown_key_assignment (int i) |
95 |
+ return _xwin.keycode_to_scancode[i]; |
96 |
+ } |
97 |
+ |
98 |
++/* unicode_getc: |
99 |
++ * Reads a character from a Unicode string. |
100 |
++ */ |
101 |
++static int unicode_getc(AL_CONST char *s) |
102 |
++{ |
103 |
++ return *((unsigned short *)s); |
104 |
++} |
105 |
++ |
106 |
+ |
107 |
+ |
108 |
+ /* _xwin_keyboard_handler: |
109 |
+@@ -412,7 +420,7 @@ void _xwin_keyboard_handler(XKeyEvent *event, int dga2_hack) |
110 |
+ } |
111 |
+ buffer[len] = '\0'; |
112 |
+ uconvert(buffer, U_UTF8, buffer2, U_UNICODE, sizeof buffer2); |
113 |
+- unicode = *(unsigned short *)buffer2; |
114 |
++ unicode = unicode_getc(buffer2); |
115 |
+ |
116 |
+ #ifdef ALLEGRO_XWINDOWS_WITH_XIM |
117 |
+ r = XFilterEvent((XEvent *)event, _xwin.window); |
118 |
|
119 |
diff --git a/dev-games/aseprite/metadata.xml b/dev-games/aseprite/metadata.xml |
120 |
index 7f80b35..d20ad44 100644 |
121 |
--- a/dev-games/aseprite/metadata.xml |
122 |
+++ b/dev-games/aseprite/metadata.xml |
123 |
@@ -14,7 +14,8 @@ |
124 |
Animated sprite editor and pixel art tool |
125 |
</longdescription> |
126 |
<use> |
127 |
- <flag name="gtk3">Enable support for the experimental native GTK File Dialog</flag> |
128 |
+ <flag name="bundled-libs">Use the upstream provided bundled version of allegro 4.4.2</flag> |
129 |
+ <flag name="gtk3">Enable support for the experimental native GTK File Dialog</flag> |
130 |
<flag name="webp">Enable webp image format support</flag> |
131 |
</use> |
132 |
<upstream> |