summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'x11-wm/matchbox-panel')
-rw-r--r--x11-wm/matchbox-panel/Manifest1
-rw-r--r--x11-wm/matchbox-panel/files/matchbox-panel-0.9.3-gcc4-no-nested-functions.patch93
-rw-r--r--x11-wm/matchbox-panel/files/matchbox-panel-0.9.3-wifi.patch43
-rw-r--r--x11-wm/matchbox-panel/matchbox-panel-0.9.3-r1.ebuild52
-rw-r--r--x11-wm/matchbox-panel/metadata.xml9
5 files changed, 198 insertions, 0 deletions
diff --git a/x11-wm/matchbox-panel/Manifest b/x11-wm/matchbox-panel/Manifest
new file mode 100644
index 000000000000..781a6087c6ef
--- /dev/null
+++ b/x11-wm/matchbox-panel/Manifest
@@ -0,0 +1 @@
+DIST matchbox-panel-0.9.3.tar.bz2 162477 SHA256 319b656e2f1f25339d65802a3136f31169141fd54d1ca9131ff4aada62b25ce6 SHA512 370fbbef2434ae55cd6772b0b205c3ae3cfce1ef59fc72d2794847ec8bf67a74a471aec0d179a5177392a566abdfb4dc2c7647a89b76b56cad210067eac49e8d WHIRLPOOL 60e3c02540d66d4f566651414f33dcaebec5ed26d1d448e97b54f5cceb5e5e9602464b728d6d2c1813d1d87f4779ceec9bfd7387d8a53d318e7e1274531b03cb
diff --git a/x11-wm/matchbox-panel/files/matchbox-panel-0.9.3-gcc4-no-nested-functions.patch b/x11-wm/matchbox-panel/files/matchbox-panel-0.9.3-gcc4-no-nested-functions.patch
new file mode 100644
index 000000000000..8dcafbd7d93b
--- /dev/null
+++ b/x11-wm/matchbox-panel/files/matchbox-panel-0.9.3-gcc4-no-nested-functions.patch
@@ -0,0 +1,93 @@
+diff -Naurp matchbox-panel-0.9.3.orig/applets/mb-applet-battery.c matchbox-panel-0.9.3/applets/mb-applet-battery.c
+--- matchbox-panel-0.9.3.orig/applets/mb-applet-battery.c 2006-02-07 22:27:24.000000000 +0000
++++ matchbox-panel-0.9.3/applets/mb-applet-battery.c 2006-06-20 18:12:00.000000000 +0000
+@@ -157,50 +157,50 @@ struct avg_consumption {
+
+ static struct avg_consumption a;
+
++enum ac_state { AC_UNKNOWN = -1, AC_OFFLINE = 0, AC_ONLINE = 1 };
++enum bat_state { BAT_UNKNOWN = -1, BAT_CHARGING = 1, BAT_DISCHARGING = 2 };
++
++struct entry {
++ char *key;
++ char *value;
++ char *unit;
++};
++
++struct acpi_status {
++ enum ac_state ac_state;
++ enum bat_state bat_state;
++ unsigned long design_capacity;
++ unsigned long remaining_capacity;
++ unsigned long present_rate;
++};
++
+ static int
+-read_apm(int *values)
++line_parse(char *line, struct entry *e)
+ {
+- enum ac_state { AC_UNKNOWN = -1, AC_OFFLINE = 0, AC_ONLINE = 1 };
+- enum bat_state { BAT_UNKNOWN = -1, BAT_CHARGING = 1, BAT_DISCHARGING = 2 };
+-
+- struct entry {
+- char *key;
+- char *value;
+- char *unit;
+- };
+-
+- struct acpi_status {
+- enum ac_state ac_state;
+- enum bat_state bat_state;
+- unsigned long design_capacity;
+- unsigned long remaining_capacity;
+- unsigned long present_rate;
+- };
++ char *ptr;
+
+- static int
+- line_parse(char *line, struct entry *e)
+- {
+- char *ptr;
+-
+- ptr = strchr(line, ':');
+- if (!ptr)
+- return -1;
+- e->key = line;
+- *ptr = 0;
+- while (*++ptr && *ptr == ' ');
+- e->value = ptr;
+- while (*++ptr && *ptr != '\n' && *ptr != ' ');
++ ptr = strchr(line, ':');
++ if (!ptr)
++ return -1;
++ e->key = line;
++ *ptr = 0;
++ while (*++ptr && *ptr == ' ');
++ e->value = ptr;
++ while (*++ptr && *ptr != '\n' && *ptr != ' ');
++ *ptr = 0;
++ if (*++ptr) {
++ e->unit = ptr;
++ while (*++ptr && *ptr != '\n');
+ *ptr = 0;
+- if (*++ptr) {
+- e->unit = ptr;
+- while (*++ptr && *ptr != '\n');
+- *ptr = 0;
+- } else
+- e->unit = 0;
+-
+- return 0;
+- }
++ } else
++ e->unit = 0;
++
++ return 0;
++}
+
++static int
++read_apm(int *values)
++{
+ FILE *f;
+ char line[1024];
+ struct entry e;
diff --git a/x11-wm/matchbox-panel/files/matchbox-panel-0.9.3-wifi.patch b/x11-wm/matchbox-panel/files/matchbox-panel-0.9.3-wifi.patch
new file mode 100644
index 000000000000..d36a2eb8df0a
--- /dev/null
+++ b/x11-wm/matchbox-panel/files/matchbox-panel-0.9.3-wifi.patch
@@ -0,0 +1,43 @@
+diff -Naurp matchbox-panel-0.9.3.orig/configure.ac matchbox-panel-0.9.3/configure.ac
+--- matchbox-panel-0.9.3.orig/configure.ac 2006-03-07 18:46:39.000000000 +0000
++++ matchbox-panel-0.9.3/configure.ac 2010-05-18 13:10:59.000000000 +0000
+@@ -56,6 +56,10 @@ AC_ARG_ENABLE(acpi-linux,
+ [ --enable-acpi-linux Use Linux ACPI rather than APM for battery info],
+ enable_acpi_linux=$enableval, enable_acpi_linux=no )
+
++AC_ARG_ENABLE(wireless-tools,
++ [ --enable-wireless-tools enable building of wifi applet],
++ enable_wireless_tools=$enableval, enable_wireless_tools=no )
++
+ PKG_CHECK_MODULES(LIBMB, libmb >= 1.6,,
+ AC_MSG_ERROR([*** Required Matchbox Library (libmb) 1.6 not installed ***]))
+
+@@ -209,17 +213,20 @@ AM_CONDITIONAL(WANT_ACPI, test x$enable_
+
+ dnl ------ wireless checks --------------------------------------------------
+
+-wifi_enabled=no
+-
+-AC_CHECK_HEADERS(iwlib.h, have_iwlib_h=yes, have_iwlib_h=no)
+-AC_CHECK_LIB(iw, iw_sockets_open, have_libiw=yes, have_libiw=yes)
++if test x$enable_wireless_tools = xyes; then
++ AC_CHECK_HEADERS(iwlib.h, have_iwlib_h=yes,
++ AC_MSG_ERROR([Unable to find the wireless-tools headers]))
++ AC_CHECK_LIB(iw, iw_sockets_open, have_libiw=yes,
++ AC_MSG_ERROR([Unable to find the wireless-tools library]))
+
+-if test x$have_iwlib_h = x"yes" && test x$have_libiw = x"yes"; then
+- WIRELESS_LIBS="-liw"
+- wifi_enabled=yes
++ WIRELESS_LIBS="-liw"
++ wifi_enabled=yes
++else
++ WIRELESS_LIBS=""
++ wifi_enabled=no
+ fi
+-AC_SUBST(WIRELESS_LIBS)
+
++AC_SUBST(WIRELESS_LIBS)
+ AM_CONDITIONAL(WANT_WIFI, test x$wifi_enabled = x"yes")
+
+
diff --git a/x11-wm/matchbox-panel/matchbox-panel-0.9.3-r1.ebuild b/x11-wm/matchbox-panel/matchbox-panel-0.9.3-r1.ebuild
new file mode 100644
index 000000000000..624cc40a52cc
--- /dev/null
+++ b/x11-wm/matchbox-panel/matchbox-panel-0.9.3-r1.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit eutils autotools versionator
+
+DESCRIPTION="The Matchbox Panel"
+HOMEPAGE="http://matchbox-project.org/"
+SRC_URI="http://matchbox-project.org/sources/${PN}/$(get_version_component_range 1-2)/${P}.tar.bz2"
+LICENSE="GPL-2"
+SLOT="0"
+
+KEYWORDS="amd64 ~arm ~hppa ppc x86"
+IUSE="acpi debug dnotify lowres nls startup-notification wifi"
+
+DEPEND=">=x11-libs/libmatchbox-1.5
+ startup-notification? ( x11-libs/startup-notification )
+ nls? ( sys-devel/gettext )
+ wifi? ( net-wireless/wireless-tools )"
+
+RDEPEND="${DEPEND}
+ x11-wm/matchbox-common"
+
+src_unpack () {
+ unpack ${A}
+ cd "${S}"
+
+ epatch "${FILESDIR}/"${P}-gcc4-no-nested-functions.patch
+ epatch "${FILESDIR}/"${P}-wifi.patch
+ sed -e "s/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/" -i configure.ac || die
+
+ eautoreconf
+}
+
+src_compile() {
+ econf $(use_enable debug) \
+ $(use_enable nls) \
+ $(use_enable startup-notification) \
+ $(use_enable dnotify) \
+ $(use_enable acpi acpi-linux) \
+ $(use_enable lowres small-icons) \
+ $(use_enable wifi wireless-tools) \
+ || die "Configuration failed"
+
+ emake || die "Compilation failed"
+}
+
+src_install() {
+ make DESTDIR="${D}" install || die "Installation failed"
+
+ dodoc AUTHORS ChangeLog INSTALL NEWS README
+}
diff --git a/x11-wm/matchbox-panel/metadata.xml b/x11-wm/matchbox-panel/metadata.xml
new file mode 100644
index 000000000000..26f436c695d4
--- /dev/null
+++ b/x11-wm/matchbox-panel/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>gpe</herd>
+ <use>
+ <flag name="dnotify">Use the linux kernel directory notification feature.</flag>
+ <flag name="lowres">Optimize for low resolution screens.</flag>
+ </use>
+</pkgmetadata>