1 |
commit: 49c92a7901348324311adeadc254a0e5c41574b1 |
2 |
Author: Marek Szuba <marecki <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Jan 12 14:45:43 2022 +0000 |
4 |
Commit: Marek Szuba <marecki <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Jan 12 21:52:18 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=49c92a79 |
7 |
|
8 |
media-gfx/darktable: support gamepad and MIDI input devices |
9 |
|
10 |
Closes: https://bugs.gentoo.org/830635 |
11 |
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org> |
12 |
|
13 |
...e-3.8.0-r1.ebuild => darktable-3.8.0-r2.ebuild} | 10 ++++-- |
14 |
.../darktable-3.8.0_libs-deps-automagic.patch | 37 ++++++++++++++++++++++ |
15 |
media-gfx/darktable/metadata.xml | 2 ++ |
16 |
3 files changed, 46 insertions(+), 3 deletions(-) |
17 |
|
18 |
diff --git a/media-gfx/darktable/darktable-3.8.0-r1.ebuild b/media-gfx/darktable/darktable-3.8.0-r2.ebuild |
19 |
similarity index 93% |
20 |
rename from media-gfx/darktable/darktable-3.8.0-r1.ebuild |
21 |
rename to media-gfx/darktable/darktable-3.8.0-r2.ebuild |
22 |
index b2adbe18b7ed..b972b07d4be7 100644 |
23 |
--- a/media-gfx/darktable/darktable-3.8.0-r1.ebuild |
24 |
+++ b/media-gfx/darktable/darktable-3.8.0-r2.ebuild |
25 |
@@ -1,4 +1,4 @@ |
26 |
-# Copyright 1999-2021 Gentoo Authors |
27 |
+# Copyright 1999-2022 Gentoo Authors |
28 |
# Distributed under the terms of the GNU General Public License v2 |
29 |
|
30 |
EAPI=8 |
31 |
@@ -35,8 +35,7 @@ else |
32 |
LANGS=" de eo es fi fr he hu it ja pl pt-BR sl uk zh-CN" |
33 |
fi |
34 |
|
35 |
-IUSE="avif colord cpu_flags_x86_avx cpu_flags_x86_sse3 cups doc flickr geolocation gmic gnome-keyring gphoto2 graphicsmagick jpeg2k kwallet |
36 |
- lto lua nls opencl openmp openexr test tools webp |
37 |
+IUSE="avif colord cpu_flags_x86_avx cpu_flags_x86_sse3 cups doc flickr gamepad geolocation gmic gnome-keyring gphoto2 graphicsmagick jpeg2k kwallet lto lua midi nls opencl openmp openexr test tools webp |
38 |
${LANGS// / l10n_}" |
39 |
|
40 |
REQUIRED_USE="lua? ( ${LUA_REQUIRED_USE} )" |
41 |
@@ -68,6 +67,7 @@ DEPEND="dev-db/sqlite:3 |
42 |
colord? ( x11-libs/colord-gtk:0= ) |
43 |
cups? ( net-print/cups ) |
44 |
flickr? ( media-libs/flickcurl ) |
45 |
+ gamepad? ( media-libs/libsdl2 ) |
46 |
geolocation? ( >=sci-geosciences/osm-gps-map-1.1.0 ) |
47 |
gmic? ( media-gfx/gmic ) |
48 |
gnome-keyring? ( >=app-crypt/libsecret-0.18 ) |
49 |
@@ -75,6 +75,7 @@ DEPEND="dev-db/sqlite:3 |
50 |
graphicsmagick? ( media-gfx/graphicsmagick ) |
51 |
jpeg2k? ( media-libs/openjpeg:2= ) |
52 |
lua? ( ${LUA_DEPS} ) |
53 |
+ midi? ( media-libs/portmidi ) |
54 |
opencl? ( virtual/opencl ) |
55 |
openexr? ( media-libs/openexr:= ) |
56 |
webp? ( media-libs/libwebp:0= )" |
57 |
@@ -87,6 +88,7 @@ PATCHES=( |
58 |
"${FILESDIR}"/${PN}-3.4.0_jsonschema-automagic.patch |
59 |
"${FILESDIR}"/${PN}-3.4.1_libxcf-cmake.patch |
60 |
"${FILESDIR}"/${PN}-3.6.1_openexr.patch |
61 |
+ "${FILESDIR}"/${PN}-3.8.0_libs-deps-automagic.patch |
62 |
) |
63 |
|
64 |
S="${WORKDIR}/${P/_/~}" |
65 |
@@ -140,6 +142,8 @@ src_configure() { |
66 |
-DUSE_OPENEXR=$(usex openexr) |
67 |
-DUSE_OPENJPEG=$(usex jpeg2k) |
68 |
-DUSE_OPENMP=$(usex openmp) |
69 |
+ -DUSE_PORTMIDI=$(usex midi) |
70 |
+ -DUSE_SDL2=$(usex gamepad) |
71 |
-DUSE_WEBP=$(usex webp) |
72 |
-DWANT_JSON_VALIDATION=$(usex test) |
73 |
) |
74 |
|
75 |
diff --git a/media-gfx/darktable/files/darktable-3.8.0_libs-deps-automagic.patch b/media-gfx/darktable/files/darktable-3.8.0_libs-deps-automagic.patch |
76 |
new file mode 100644 |
77 |
index 000000000000..25b89731a7c8 |
78 |
--- /dev/null |
79 |
+++ b/media-gfx/darktable/files/darktable-3.8.0_libs-deps-automagic.patch |
80 |
@@ -0,0 +1,37 @@ |
81 |
+--- a/src/libs/CMakeLists.txt |
82 |
++++ b/src/libs/CMakeLists.txt |
83 |
+@@ -83,11 +83,14 @@ |
84 |
+ add_library(timeline MODULE "tools/timeline.c") |
85 |
+ add_library(image_infos MODULE "tools/image_infos.c") |
86 |
+ |
87 |
++if (USE_PORTMIDI) |
88 |
+ find_path(PORTMIDI_INCLUDE_DIR NAMES portmidi.h |
89 |
+ DOC "The Portmidi include directory" |
90 |
++ REQUIRED |
91 |
+ ) |
92 |
+ find_library(PORTMIDI_LIBRARY NAMES portmidi |
93 |
+ DOC "The Portmidi library" |
94 |
++ REQUIRED |
95 |
+ ) |
96 |
+ if(PORTMIDI_INCLUDE_DIR) |
97 |
+ add_definitions("-DHAVE_PORTMIDI") |
98 |
+@@ -96,8 +99,10 @@ |
99 |
+ add_library(midi MODULE "tools/midi.c") |
100 |
+ target_link_libraries (midi ${PORTMIDI_LIBRARY}) |
101 |
+ endif() |
102 |
++endif() |
103 |
+ |
104 |
+-find_package(SDL2) |
105 |
++if (USE_SDL2) |
106 |
++find_package(SDL2 REQUIRED) |
107 |
+ if(SDL2_INCLUDE_DIRS) |
108 |
+ add_definitions("-DHAVE_SDL") |
109 |
+ include_directories(${SDL2_INCLUDE_DIRS}) |
110 |
+@@ -105,6 +110,7 @@ |
111 |
+ add_library(gamepad MODULE "tools/gamepad.c") |
112 |
+ target_link_libraries(gamepad ${SDL2_LIBRARIES}) |
113 |
+ endif() |
114 |
++endif() |
115 |
+ |
116 |
+ if(BUILD_BATTERY_INDICATOR) |
117 |
+ add_library(battery_indicator MODULE "tools/battery_indicator.c") |
118 |
|
119 |
diff --git a/media-gfx/darktable/metadata.xml b/media-gfx/darktable/metadata.xml |
120 |
index 7fa51feb6f79..c20058315b0b 100644 |
121 |
--- a/media-gfx/darktable/metadata.xml |
122 |
+++ b/media-gfx/darktable/metadata.xml |
123 |
@@ -12,10 +12,12 @@ |
124 |
<use> |
125 |
<flag name="avif">Support importing and exporting AVIF images</flag> |
126 |
<flag name="flickr">Add support for uploading photos to flickr</flag> |
127 |
+ <flag name="gamepad">Support using game controllers as input devices</flag> |
128 |
<flag name="geolocation">Enable geotagging support</flag> |
129 |
<flag name="gmic">Use the G'MIC image-processing framework (<pkg>media-gfx/gmic</pkg>), e.g. to support Colour LUTs compressed using their compression scheme</flag> |
130 |
<flag name="kwallet">Enable encrypted storage of passwords with <pkg>kde-frameworks/kwallet</pkg></flag> |
131 |
<flag name="lto">Enable link-time optimisations in the RawSpeed library</flag> |
132 |
+ <flag name="midi">Support using MIDI input devices such as Behringer X-Touch Mini, Arturia Beatstep or Korg nanoKONTROL2, as input devices</flag> |
133 |
<flag name="opencl">Enable opencl support</flag> |
134 |
<flag name="tools">Install tools for generating base curves and noise profiles</flag> |
135 |
</use> |