summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Szuba <marecki@gentoo.org>2022-01-12 14:45:43 +0000
committerMarek Szuba <marecki@gentoo.org>2022-01-12 21:52:18 +0000
commit49c92a7901348324311adeadc254a0e5c41574b1 (patch)
tree52c61c236c68464a2b58b25c20f92b3d483b265f /media-gfx/darktable
parentnet-p2p/syncthing: add 1.18.6 (diff)
downloadgentoo-49c92a7901348324311adeadc254a0e5c41574b1.tar.gz
gentoo-49c92a7901348324311adeadc254a0e5c41574b1.tar.bz2
gentoo-49c92a7901348324311adeadc254a0e5c41574b1.zip
media-gfx/darktable: support gamepad and MIDI input devices
Closes: https://bugs.gentoo.org/830635 Signed-off-by: Marek Szuba <marecki@gentoo.org>
Diffstat (limited to 'media-gfx/darktable')
-rw-r--r--media-gfx/darktable/darktable-3.8.0-r2.ebuild (renamed from media-gfx/darktable/darktable-3.8.0-r1.ebuild)10
-rw-r--r--media-gfx/darktable/files/darktable-3.8.0_libs-deps-automagic.patch37
-rw-r--r--media-gfx/darktable/metadata.xml2
3 files changed, 46 insertions, 3 deletions
diff --git a/media-gfx/darktable/darktable-3.8.0-r1.ebuild b/media-gfx/darktable/darktable-3.8.0-r2.ebuild
index b2adbe18b7ed..b972b07d4be7 100644
--- a/media-gfx/darktable/darktable-3.8.0-r1.ebuild
+++ b/media-gfx/darktable/darktable-3.8.0-r2.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -35,8 +35,7 @@ else
LANGS=" de eo es fi fr he hu it ja pl pt-BR sl uk zh-CN"
fi
-IUSE="avif colord cpu_flags_x86_avx cpu_flags_x86_sse3 cups doc flickr geolocation gmic gnome-keyring gphoto2 graphicsmagick jpeg2k kwallet
- lto lua nls opencl openmp openexr test tools webp
+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
${LANGS// / l10n_}"
REQUIRED_USE="lua? ( ${LUA_REQUIRED_USE} )"
@@ -68,6 +67,7 @@ DEPEND="dev-db/sqlite:3
colord? ( x11-libs/colord-gtk:0= )
cups? ( net-print/cups )
flickr? ( media-libs/flickcurl )
+ gamepad? ( media-libs/libsdl2 )
geolocation? ( >=sci-geosciences/osm-gps-map-1.1.0 )
gmic? ( media-gfx/gmic )
gnome-keyring? ( >=app-crypt/libsecret-0.18 )
@@ -75,6 +75,7 @@ DEPEND="dev-db/sqlite:3
graphicsmagick? ( media-gfx/graphicsmagick )
jpeg2k? ( media-libs/openjpeg:2= )
lua? ( ${LUA_DEPS} )
+ midi? ( media-libs/portmidi )
opencl? ( virtual/opencl )
openexr? ( media-libs/openexr:= )
webp? ( media-libs/libwebp:0= )"
@@ -87,6 +88,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-3.4.0_jsonschema-automagic.patch
"${FILESDIR}"/${PN}-3.4.1_libxcf-cmake.patch
"${FILESDIR}"/${PN}-3.6.1_openexr.patch
+ "${FILESDIR}"/${PN}-3.8.0_libs-deps-automagic.patch
)
S="${WORKDIR}/${P/_/~}"
@@ -140,6 +142,8 @@ src_configure() {
-DUSE_OPENEXR=$(usex openexr)
-DUSE_OPENJPEG=$(usex jpeg2k)
-DUSE_OPENMP=$(usex openmp)
+ -DUSE_PORTMIDI=$(usex midi)
+ -DUSE_SDL2=$(usex gamepad)
-DUSE_WEBP=$(usex webp)
-DWANT_JSON_VALIDATION=$(usex test)
)
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
new file mode 100644
index 000000000000..25b89731a7c8
--- /dev/null
+++ b/media-gfx/darktable/files/darktable-3.8.0_libs-deps-automagic.patch
@@ -0,0 +1,37 @@
+--- a/src/libs/CMakeLists.txt
++++ b/src/libs/CMakeLists.txt
+@@ -83,11 +83,14 @@
+ add_library(timeline MODULE "tools/timeline.c")
+ add_library(image_infos MODULE "tools/image_infos.c")
+
++if (USE_PORTMIDI)
+ find_path(PORTMIDI_INCLUDE_DIR NAMES portmidi.h
+ DOC "The Portmidi include directory"
++ REQUIRED
+ )
+ find_library(PORTMIDI_LIBRARY NAMES portmidi
+ DOC "The Portmidi library"
++ REQUIRED
+ )
+ if(PORTMIDI_INCLUDE_DIR)
+ add_definitions("-DHAVE_PORTMIDI")
+@@ -96,8 +99,10 @@
+ add_library(midi MODULE "tools/midi.c")
+ target_link_libraries (midi ${PORTMIDI_LIBRARY})
+ endif()
++endif()
+
+-find_package(SDL2)
++if (USE_SDL2)
++find_package(SDL2 REQUIRED)
+ if(SDL2_INCLUDE_DIRS)
+ add_definitions("-DHAVE_SDL")
+ include_directories(${SDL2_INCLUDE_DIRS})
+@@ -105,6 +110,7 @@
+ add_library(gamepad MODULE "tools/gamepad.c")
+ target_link_libraries(gamepad ${SDL2_LIBRARIES})
+ endif()
++endif()
+
+ if(BUILD_BATTERY_INDICATOR)
+ add_library(battery_indicator MODULE "tools/battery_indicator.c")
diff --git a/media-gfx/darktable/metadata.xml b/media-gfx/darktable/metadata.xml
index 7fa51feb6f79..c20058315b0b 100644
--- a/media-gfx/darktable/metadata.xml
+++ b/media-gfx/darktable/metadata.xml
@@ -12,10 +12,12 @@
<use>
<flag name="avif">Support importing and exporting AVIF images</flag>
<flag name="flickr">Add support for uploading photos to flickr</flag>
+ <flag name="gamepad">Support using game controllers as input devices</flag>
<flag name="geolocation">Enable geotagging support</flag>
<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>
<flag name="kwallet">Enable encrypted storage of passwords with <pkg>kde-frameworks/kwallet</pkg></flag>
<flag name="lto">Enable link-time optimisations in the RawSpeed library</flag>
+ <flag name="midi">Support using MIDI input devices such as Behringer X-Touch Mini, Arturia Beatstep or Korg nanoKONTROL2, as input devices</flag>
<flag name="opencl">Enable opencl support</flag>
<flag name="tools">Install tools for generating base curves and noise profiles</flag>
</use>