diff options
author | Daniel Gryniewicz <dang@gentoo.org> | 2006-11-28 18:53:37 +0000 |
---|---|---|
committer | Daniel Gryniewicz <dang@gentoo.org> | 2006-11-28 18:53:37 +0000 |
commit | a346c9101e58c4d1e0b1d6d49e22bd1c94605640 (patch) | |
tree | a7f0281e4b6edfa809fac26bf427517a6187b2a1 | |
parent | Liferea with xulrunner support (diff) | |
download | maintainer-a346c9101e58c4d1e0b1d6d49e22bd1c94605640.tar.gz maintainer-a346c9101e58c4d1e0b1d6d49e22bd1c94605640.tar.bz2 maintainer-a346c9101e58c4d1e0b1d6d49e22bd1c94605640.zip |
liferea with nm support
svn path=/maintainer/; revision=17
-rw-r--r-- | net-news/liferea/Manifest | 12 | ||||
-rw-r--r-- | net-news/liferea/files/digest-liferea-1.2_rc1-r1 | 3 | ||||
-rw-r--r-- | net-news/liferea/files/liferea-1.2_rc1-nm.patch | 191 | ||||
-rw-r--r-- | net-news/liferea/liferea-1.2_rc1-r1.ebuild | 86 |
4 files changed, 292 insertions, 0 deletions
diff --git a/net-news/liferea/Manifest b/net-news/liferea/Manifest index 4849203..4eb070e 100644 --- a/net-news/liferea/Manifest +++ b/net-news/liferea/Manifest @@ -2,11 +2,23 @@ AUX liferea-1.1.0-libnotify.patch 552 RMD160 0bf67b33913e08ed5528b86813aae306491 MD5 3a20454520ddb0c23157591a24516972 files/liferea-1.1.0-libnotify.patch 552 RMD160 0bf67b33913e08ed5528b86813aae30649123304 files/liferea-1.1.0-libnotify.patch 552 SHA256 73a54e020b045ee261f9444464a68f4f1aba831182498b8a103886b7c0108bab files/liferea-1.1.0-libnotify.patch 552 +AUX liferea-1.2_rc1-nm.patch 6209 RMD160 e8b2632fef56486e2b4f132b9181641b2a4d510b SHA1 0170305da4e4c67c7214e510da496d44deadff47 SHA256 b0712b4c3ce188c590ef98c4bf61c1a5c457aac821b077b55b72d35b84a354fb +MD5 c08620c6b085e7956bd4870e073c2ef3 files/liferea-1.2_rc1-nm.patch 6209 +RMD160 e8b2632fef56486e2b4f132b9181641b2a4d510b files/liferea-1.2_rc1-nm.patch 6209 +SHA256 b0712b4c3ce188c590ef98c4bf61c1a5c457aac821b077b55b72d35b84a354fb files/liferea-1.2_rc1-nm.patch 6209 DIST liferea-1.1.9b.tar.gz 1171943 RMD160 6ef65405f2f322fd17165af058460f06f9a9a6f1 SHA1 c7d45c63145234564e9acbb06aa5dccc567045c6 SHA256 85f2c74a3ecb91b8a975820c3fea20b183780a187303d5f6eaee069f1feb0d74 +DIST liferea-1.2-RC1.tar.gz 1226770 RMD160 e7edd8ee63600babc5c4a01a9b72941b22254567 SHA1 583eba352e7fac25b2675cfa56ba8c8bbe1c5e2c SHA256 f9bcd9e31c3d6bebfaf5114d422cba19a7be31b054c6074193a7ee55f715d6bb EBUILD liferea-1.1.9-r1.ebuild 2012 RMD160 68c13d39e54ef51958d54903838aa0a1083dea62 SHA1 d5be0681f67f88b8f0c5f7e00bb4f6b773d8bbe3 SHA256 e9f062cf706967635d2cee73b41a7a28064212eff0df710369b3c6d2d9a1a8e9 MD5 ac51ba745449c6ad70e40ab4d5e306fb liferea-1.1.9-r1.ebuild 2012 RMD160 68c13d39e54ef51958d54903838aa0a1083dea62 liferea-1.1.9-r1.ebuild 2012 SHA256 e9f062cf706967635d2cee73b41a7a28064212eff0df710369b3c6d2d9a1a8e9 liferea-1.1.9-r1.ebuild 2012 +EBUILD liferea-1.2_rc1-r1.ebuild 2349 RMD160 c41242241801a2d7195802f6bf0acebefb840b01 SHA1 956a5b9199ccf5bf7ed2041a87c277a9a65163f9 SHA256 c265e14fb9c0db2e792dcde9b0e3eaa3d7cc95617d5bc998090834294f1e850d +MD5 de43ef12e31b8aa77bfc6093408325e7 liferea-1.2_rc1-r1.ebuild 2349 +RMD160 c41242241801a2d7195802f6bf0acebefb840b01 liferea-1.2_rc1-r1.ebuild 2349 +SHA256 c265e14fb9c0db2e792dcde9b0e3eaa3d7cc95617d5bc998090834294f1e850d liferea-1.2_rc1-r1.ebuild 2349 MD5 1236ef79902564427f63f27765483b72 files/digest-liferea-1.1.9-r1 247 RMD160 ac5f088433f6b5a0904902ad103ee2425bc38c95 files/digest-liferea-1.1.9-r1 247 SHA256 ff429e9d8f61c00825102b68dd4c504054e6ed0a9ecad6f9a295acaf6cbc854b files/digest-liferea-1.1.9-r1 247 +MD5 f5e7bf64c98cec2afeadc2856a569aa3 files/digest-liferea-1.2_rc1-r1 250 +RMD160 8c593975578e396422b9ab143014bcbd9575742a files/digest-liferea-1.2_rc1-r1 250 +SHA256 0e2b5e17f6073d48d14067334cb45d2c6ee4e802ee14ff27d63847bad5d5bf3a files/digest-liferea-1.2_rc1-r1 250 diff --git a/net-news/liferea/files/digest-liferea-1.2_rc1-r1 b/net-news/liferea/files/digest-liferea-1.2_rc1-r1 new file mode 100644 index 0000000..4717ac3 --- /dev/null +++ b/net-news/liferea/files/digest-liferea-1.2_rc1-r1 @@ -0,0 +1,3 @@ +MD5 48225f5b3d923a9fb14360709dfc4c2a liferea-1.2-RC1.tar.gz 1226770 +RMD160 e7edd8ee63600babc5c4a01a9b72941b22254567 liferea-1.2-RC1.tar.gz 1226770 +SHA256 f9bcd9e31c3d6bebfaf5114d422cba19a7be31b054c6074193a7ee55f715d6bb liferea-1.2-RC1.tar.gz 1226770 diff --git a/net-news/liferea/files/liferea-1.2_rc1-nm.patch b/net-news/liferea/files/liferea-1.2_rc1-nm.patch new file mode 100644 index 0000000..35d4614 --- /dev/null +++ b/net-news/liferea/files/liferea-1.2_rc1-nm.patch @@ -0,0 +1,191 @@ +diff --exclude-from=/home/dang/.diffrc -up -ruN liferea-1.2-RC1.orig/configure.ac liferea-1.2-RC1/configure.ac +--- liferea-1.2-RC1.orig/configure.ac 2006-11-04 09:32:53.000000000 -0500 ++++ liferea-1.2-RC1/configure.ac 2006-11-24 13:00:18.000000000 -0500 +@@ -30,6 +30,7 @@ AC_SYS_LARGEFILE + + AC_ARG_ENABLE(sm, AS_HELP_STRING([--disable-sm],[compile without X session management support]),,enable_sm=yes) + AC_ARG_ENABLE(dbus, AS_HELP_STRING([--disable-dbus],[compile without DBUS support]),,enable_dbus=yes) ++AC_ARG_ENABLE(nm, AS_HELP_STRING([--disable-nm],[compile without NetworkManager support]),,enable_nm=yes) + AC_ARG_ENABLE(gtkhtml2, AS_HELP_STRING([--disable-gtkhtml2],[don't compile the gtkhtml2 backend]),,enable_gtkhtml2=yes) + AC_ARG_ENABLE(xulrunner, AS_HELP_STRING([--disable-xulrunner],[don't compile the xulrunner backend]),,enable_xulrunner=yes) + AC_ARG_ENABLE(gecko, AS_HELP_STRING([--disable-gecko],[don't compile the Gecko backend]),,enable_gecko=yes) +@@ -342,6 +343,20 @@ AC_SUBST(DBUS_CFLAGS) + AC_SUBST(DBUS_LIBS) + dnl AM_CONDITIONAL(WITH_DBUS, test "x$enable_dbus" != "xyes") + ++dnl **** ++dnl NetworkManager ++dnl **** ++if test "x$enable_nm" = "xyes"; then ++ AC_MSG_NOTICE([checking for NetworkManager]) ++ PKG_CHECK_MODULES([NM], [dbus-glib-1 libnm_glib],enable_nm=yes,enable_nm=no) ++fi ++ ++if test "x$enable_nm" = "xyes"; then ++ AC_DEFINE(USE_NM, 1, [Define if we're using NetworkManager.]) ++fi ++ ++AC_SUBST(NM_CFLAGS) ++AC_SUBST(NM_LIBS) + + dnl # + dnl # Check for GNUTLS if it's specified. +@@ -470,6 +485,7 @@ echo "Build LUA scripting Plugin ..... : + echo + echo "Use X Session Management........ : $enable_sm" + echo "Use DBUS........................ : $enable_dbus" ++echo "Use NetworkManager.............. : $enable_nm" + echo "GNUTLS SSL/HTTPS Support........ : $enable_gnutls" + echo + eval eval echo Liferea will be installed in $bindir. +diff --exclude-from=/home/dang/.diffrc -up -ruN liferea-1.2-RC1.orig/src/main.c liferea-1.2-RC1/src/main.c +--- liferea-1.2-RC1.orig/src/main.c 2006-11-07 18:30:35.000000000 -0500 ++++ liferea-1.2-RC1/src/main.c 2006-11-24 11:57:58.000000000 -0500 +@@ -136,6 +136,9 @@ int main(int argc, char *argv[]) { + #ifdef USE_DBUS + dbus_g_thread_init(); + #endif ++#ifdef USE_NM ++ update_nm_initialize(); ++#endif + gtk_init(&argc, &argv); + + bacon_connection = bacon_message_connection_new("liferea"); +diff --exclude-from=/home/dang/.diffrc -up -ruN liferea-1.2-RC1.orig/src/Makefile.am liferea-1.2-RC1/src/Makefile.am +--- liferea-1.2-RC1.orig/src/Makefile.am 2006-10-17 13:11:04.000000000 -0400 ++++ liferea-1.2-RC1/src/Makefile.am 2006-11-24 12:35:22.000000000 -0500 +@@ -15,6 +15,7 @@ AM_CPPFLAGS = \ + $(PACKAGE_CFLAGS) \ + $(X_CFLAGS) \ + $(DBUS_CFLAGS) \ ++ $(NM_CFLAGS) \ + $(GNUTLS_CFLAGS) + + bin_PROGRAMS = liferea-bin +@@ -39,7 +40,6 @@ liferea_bin_SOURCES = \ + itemset.c itemset.h \ + itemlist.c itemlist.h \ + itemview.c itemview.h \ +- main.c \ + metadata.c metadata.h \ + newsbin.c newsbin.h \ + node.c node.h \ +@@ -49,6 +49,7 @@ liferea_bin_SOURCES = \ + social.c social.h \ + support.c support.h \ + update.c update.h \ ++ main.c \ + vfolder.c vfolder.h + + liferea_bin_LDADD = net/liblinet.a \ +@@ -57,7 +58,7 @@ liferea_bin_LDADD = net/liblinet.a \ + notification/liblinotification.a \ + scripting/libliscript.a \ + ui/libliui.a \ +- $(PACKAGE_LIBS) $(X_LIBS) $(X_PRE_LIBS) -lX11 $(X_EXTRA_LIBS) $(DBUS_LIBS) $(INTLLIBS) $(GNUTLS_LIBS) ++ $(PACKAGE_LIBS) $(X_LIBS) $(X_PRE_LIBS) -lX11 $(X_EXTRA_LIBS) $(DBUS_LIBS) $(NM_LIBS) $(INTLLIBS) $(GNUTLS_LIBS) + + if PLATFORM_WIN32 + +Files liferea-1.2-RC1.orig/src/.Makefile.am.swp and liferea-1.2-RC1/src/.Makefile.am.swp differ +diff --exclude-from=/home/dang/.diffrc -up -ruN liferea-1.2-RC1.orig/src/update.c liferea-1.2-RC1/src/update.c +--- liferea-1.2-RC1.orig/src/update.c 2006-09-11 18:57:03.000000000 -0400 ++++ liferea-1.2-RC1/src/update.c 2006-11-24 12:46:22.000000000 -0500 +@@ -34,6 +34,10 @@ + #include <sys/wait.h> + #include <string.h> + ++#ifdef USE_NM ++#include <NetworkManager/libnm_glib.h> ++#endif ++ + #include "common.h" + #include "conf.h" + #include "debug.h" +@@ -60,6 +64,12 @@ static GMutex *cond_mutex = NULL; + static GCond *offline_cond = NULL; + static gboolean online = TRUE; + ++#ifdef USE_NM ++/* State for NM support */ ++static libnm_glib_ctx *nm_ctx = NULL; ++static guint nm_id = 0; ++#endif ++ + /* update state interface */ + + updateStatePtr update_state_new(void) { +@@ -583,3 +593,49 @@ void update_init(void) { + NULL, + NULL); + } ++ ++#ifdef USE_NM ++static void update_network_monitor(libnm_glib_ctx *ctx, gpointer user_data) ++{ ++ libnm_glib_state state; ++ gboolean online; ++ ++ g_return_if_fail(ctx != NULL); ++ ++ state = libnm_glib_get_network_state(ctx); ++ online = update_is_online(); ++ ++ if (online && state == LIBNM_NO_NETWORK_CONNECTION) { ++ update_set_online(FALSE); ++ } else if (!online && state == LIBNM_ACTIVE_NETWORK_CONNECTION) { ++ update_set_online(TRUE); ++ } ++} ++ ++ ++gboolean update_nm_initialize(void) ++{ ++ if (!nm_ctx) ++ { ++ nm_ctx = libnm_glib_init(); ++ if (!nm_ctx) { ++ fprintf(stderr, "Could not initialize libnm.\n"); ++ return FALSE; ++ } ++ } ++ ++ nm_id = libnm_glib_register_callback(nm_ctx, update_network_monitor, NULL, NULL); ++ ++ return TRUE; ++} ++ ++void update_nm_cleanup(void) ++{ ++ if (nm_id != 0 && nm_ctx != NULL) { ++ libnm_glib_unregister_callback(nm_ctx, nm_id); ++ libnm_glib_shutdown(nm_ctx); ++ nm_ctx = NULL; ++ nm_id = 0; ++ } ++} ++#endif +diff --exclude-from=/home/dang/.diffrc -up -ruN liferea-1.2-RC1.orig/src/update.h liferea-1.2-RC1/src/update.h +--- liferea-1.2-RC1.orig/src/update.h 2006-09-11 18:12:25.000000000 -0400 ++++ liferea-1.2-RC1/src/update.h 2006-11-24 12:28:40.000000000 -0500 +@@ -245,4 +245,20 @@ void update_cancel_requests(gpointer own + */ + gboolean update_request_cancel_retry(struct request *request); + ++#ifdef USE_NM ++/** ++ * Initialize NetworkManager support ++ * Set up NM support, so that offline state can be set based on availability of ++ * a network ++ * ++ * @return TRUE if successfully initialized NM support ++ */ ++gboolean update_nm_initialize(void); ++ ++/** ++ * Clean up NetworkManager support ++ */ ++void update_nm_cleanup(void); ++#endif // USE_NM ++ + #endif diff --git a/net-news/liferea/liferea-1.2_rc1-r1.ebuild b/net-news/liferea/liferea-1.2_rc1-r1.ebuild new file mode 100644 index 0000000..c8d1142 --- /dev/null +++ b/net-news/liferea/liferea-1.2_rc1-r1.ebuild @@ -0,0 +1,86 @@ +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-news/liferea/liferea-1.2_rc1-r1.ebuild,v 1.2 2006/11/20 23:07:24 dang Exp $ + +inherit gnome2 flag-o-matic eutils autotools + +MY_P=${PN}-1.2-RC1 +DESCRIPTION="News Aggregator for RDF/RSS/CDF/Atom/Echo/etc feeds" +HOMEPAGE="http://liferea.sourceforge.net/" +SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz" +LICENSE="GPL-2" + +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="dbus firefox gnutls gtkhtml libnotify networkmanager seamonkey xulrunner" + +RDEPEND=">=x11-libs/gtk+-2.8 + x11-libs/pango + >=gnome-base/gconf-2 + >=dev-libs/libxml2-2.5.10 + dev-libs/libxslt + >=dev-libs/glib-2 + xulrunner? ( net-libs/xulrunner ) + !xulrunner? ( firefox? ( www-client/mozilla-firefox ) ) + !xulrunner? ( !firefox? ( seamonkey? ( www-client/seamonkey ) ) ) + !xulrunner? ( !firefox? ( !seamonkey? ( =gnome-extra/gtkhtml-2* ) ) ) + gtkhtml? ( =gnome-extra/gtkhtml-2* ) + dbus? ( || ( >=dev-libs/dbus-glib-0.71 + ( <sys-apps/dbus-0.90 >=sys-apps/dbus-0.36 ) ) + networkmanager? ( net-misc/networkmanager ) + ) + libnotify? ( >=x11-libs/libnotify-0.3.2 ) + gnutls? ( net-libs/gnutls )" + +DEPEND="${RDEPEND} + dev-util/pkgconfig + >=dev-util/intltool-0.35 + =sys-devel/automake-1.7*" + +DOCS="AUTHORS ChangeLog NEWS README" + +S=${WORKDIR}/${MY_P} +src_unpack() { + unpack ${A} + + cd ${S} + + epatch "${FILESDIR}/${PN}-1.1.0-libnotify.patch" + epatch "${FILESDIR}/${P}-nm.patch" + + eautoreconf || die "Autoreconf failed" +} + +pkg_setup() { + # if you don't choose a gecko to use, we will automatically + # use gtkhtml2 as the backend. + if ! use seamonkey && ! use firefox || use gtkhtml ; then + G2CONF="${G2CONF} --enable-gtkhtml2" + else + G2CONF="${G2CONF} --disable-gtkhtml2" + fi + + # we prefer xulrunner over firefox over seamonkey + if use xulrunner ; then + G2CONF="${G2CONF} --enable-gecko=xulrunner" + elif use firefox ; then + G2CONF="${G2CONF} --enable-gecko=firefox" + elif use seamonkey ; then + G2CONF="${G2CONF} --enable-gecko=seamonkey" + else + G2CONF="${G2CONF} --disable-gecko" + fi + + G2CONF="${G2CONF} \ + $(use_enable dbus) \ + $(use_enable gnutls) \ + $(use_enable gnutls) \ + $(use_enable networkmanager nm) \ + $(use_enable libnotify)" +} + +src_install() { + gnome2_src_install + rm -f ${D}/usr/bin/${PN} + mv ${D}/usr/bin/${PN}-bin ${D}/usr/bin/${PN} +} |