app-misc/mx5000tools: New package
authorConrad Kostecki <conrad@kostecki.com>
Tue, 30 Oct 2018 11:27:26 +0000 (12:27 +0100)
committerMichał Górny <mgorny@gentoo.org>
Sat, 10 Nov 2018 18:15:44 +0000 (19:15 +0100)
Tools for controlling the LCD on a Logitech MX5000 keyboard.

Closes: https://bugs.gentoo.org/667808
Signed-off-by: Conrad Kostecki <conrad@kostecki.com>
Package-Manager: Portage-2.3.51, Repoman-2.3.11
Signed-off-by: Michał Górny <mgorny@gentoo.org>
app-misc/mx5000tools/Manifest [new file with mode: 0644]
app-misc/mx5000tools/files/mx5000tools-0.1.2-find-netpbm-header.patch [new file with mode: 0644]
app-misc/mx5000tools/metadata.xml [new file with mode: 0644]
app-misc/mx5000tools/mx5000tools-0.1.2.ebuild [new file with mode: 0644]

diff --git a/app-misc/mx5000tools/Manifest b/app-misc/mx5000tools/Manifest
new file mode 100644 (file)
index 0000000..7190e16
--- /dev/null
@@ -0,0 +1 @@
+DIST mx5000tools-0.1.2.tar.gz 343118 BLAKE2B 74316ca3c730b5e03aa73a8cf5422eb3690b0e088254f9078da549f2d964df065ca7cd09f5f822cb3e66ad5bac0eab546c49703eaf837a132a61ab0755e729b8 SHA512 3773b8b233f02711bb7a768a68ccd3bf72e3d51fbb64ee2a70197d1b51e884a4f40048ba6b7dcde4be0703f25672ccb0fac9b0d6612b8a94f9e01b6a9f463613
diff --git a/app-misc/mx5000tools/files/mx5000tools-0.1.2-find-netpbm-header.patch b/app-misc/mx5000tools/files/mx5000tools-0.1.2-find-netpbm-header.patch
new file mode 100644 (file)
index 0000000..9fb03d5
--- /dev/null
@@ -0,0 +1,22 @@
+--- a/configure.ac     2006-12-05 05:37:05.000000000 +0100
++++ b/configure.ac     2018-10-05 14:42:12.449181591 +0200
+@@ -13,7 +13,7 @@
+ AC_CHECK_HEADER([linux/hiddev.h], [], [AC_MSG_ERROR([You need kernel headers that supports hiddev\, that is Linux 2.4 or greater])], [#include <asm/types.h>]) 
+ 
+ 
+-AC_CHECK_HEADER([pbm.h], [], [AC_MSG_ERROR([You need pbm.h from the netpbm package\, possible the netpbm-devel package of your distribution])])
++AC_CHECK_HEADER([netpbm/pbm.h], [], [AC_MSG_ERROR([You need pbm.h from the netpbm package\, possible the netpbm-devel package of your distribution])])
+ AC_CHECK_LIB([netpbm],[pbm_readpbm], [], [AC_MSG_ERROR([You need netpbm installed])])
+ 
+ 
+--- a/libmx5000/mx5000image.c  2006-12-05 05:13:50.000000000 +0100
++++ b/libmx5000/mx5000image.c  2018-10-05 14:48:44.093392505 +0200
+@@ -3,7 +3,7 @@
+ #include <string.h>
+ #include <stdlib.h>
+ 
+-#include <pbm.h>
++#include <netpbm/pbm.h>
+ #include "config.h"
+ 
+ 
diff --git a/app-misc/mx5000tools/metadata.xml b/app-misc/mx5000tools/metadata.xml
new file mode 100644 (file)
index 0000000..eb2ca7b
--- /dev/null
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+       <maintainer type="person">
+               <email>ck+gentoo@bl4ckb0x.de</email>
+               <name>Conrad Kostecki</name>
+       </maintainer>
+       <maintainer type="project">
+               <email>proxy-maint@gentoo.org</email>
+               <name>Proxy Maintainers</name>
+       </maintainer>
+       <longdescription>
+               The Logitech Cordless Desktop MX 5000 Laser comes with a keyboard that has a nice LCD.
+               But Logitech did not provide any way to control the LCD on a Free operating system.
+               These tools make it possible to control what is displayed on the LCD and to use some
+               of the keys that are not recognized by the stock Linux HID driver.
+       </longdescription>
+</pkgmetadata>
diff --git a/app-misc/mx5000tools/mx5000tools-0.1.2.ebuild b/app-misc/mx5000tools/mx5000tools-0.1.2.ebuild
new file mode 100644 (file)
index 0000000..bcb95fa
--- /dev/null
@@ -0,0 +1,38 @@
+# Copyright 1999-2018 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools
+
+DESCRIPTION="Tools for controlling the LCD on a Logitech MX5000 keyboard"
+HOMEPAGE="https://web.archive.org/web/20160409073317/http://home.gna.org/mx5000tools/"
+SRC_URI="https://web.archive.org/web/20170225160711/http://download.gna.org/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
+
+DEPEND="media-libs/netpbm:="
+DEPEND="${RDEPEND}"
+
+PATCHES=( "${FILESDIR}/${P}-find-netpbm-header.patch" )
+
+src_prepare() {
+       default
+
+       eautoreconf
+}
+src_configure() {
+       local myeconfargs=(
+               --disable-static
+       )
+
+       econf "${myeconfargs[@]}"
+}
+
+src_install() {
+       default
+
+       find "${D}" -name '*.la' -delete || die
+}