summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuli Suominen <ssuominen@gentoo.org>2010-06-29 15:49:10 +0000
committerSamuli Suominen <ssuominen@gentoo.org>2010-06-29 15:49:10 +0000
commitf5af68fe34dcbadec73f9a76ef1180f88ac6a3f6 (patch)
tree733485e08b4e16a7a662b44ca85153acd413fe9e
parentRemoved unneeded version (diff)
downloadgentoo-2-f5af68fe34dcbadec73f9a76ef1180f88ac6a3f6.tar.gz
gentoo-2-f5af68fe34dcbadec73f9a76ef1180f88ac6a3f6.tar.bz2
gentoo-2-f5af68fe34dcbadec73f9a76ef1180f88ac6a3f6.zip
Fix building with -Wl,--as-needed wrt #276506 by Kacper Kowalik.
(Portage version: 2.2_rc67/cvs/Linux x86_64)
-rw-r--r--app-admin/lsyncd/ChangeLog6
-rw-r--r--app-admin/lsyncd/files/lsyncd-1.33-libxml2.patch62
-rw-r--r--app-admin/lsyncd/lsyncd-1.33.ebuild24
3 files changed, 85 insertions, 7 deletions
diff --git a/app-admin/lsyncd/ChangeLog b/app-admin/lsyncd/ChangeLog
index 5b39dcea2083..fedb91c365ef 100644
--- a/app-admin/lsyncd/ChangeLog
+++ b/app-admin/lsyncd/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for app-admin/lsyncd
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/lsyncd/ChangeLog,v 1.3 2010/06/10 22:00:58 spatz Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/lsyncd/ChangeLog,v 1.4 2010/06/29 15:49:10 ssuominen Exp $
+
+ 29 Jun 2010; Samuli Suominen <ssuominen@gentoo.org> lsyncd-1.33.ebuild,
+ +files/lsyncd-1.33-libxml2.patch:
+ Fix building with -Wl,--as-needed wrt #276506 by Kacper Kowalik.
*lsyncd-1.33 (10 Jun 2010)
diff --git a/app-admin/lsyncd/files/lsyncd-1.33-libxml2.patch b/app-admin/lsyncd/files/lsyncd-1.33-libxml2.patch
new file mode 100644
index 000000000000..b233cbfa2869
--- /dev/null
+++ b/app-admin/lsyncd/files/lsyncd-1.33-libxml2.patch
@@ -0,0 +1,62 @@
+--- configure.in
++++ configure.in
+@@ -3,25 +3,24 @@
+ m4_define(LSYNCD_VERSION,1.26)
+ AM_INIT_AUTOMAKE(LSYNCD_PACKAGE,LSYNCD_VERSION)
+
+-AC_ARG_ENABLE([xml_config],
+-[ --enable-xml-config Lsyncd is able to parse lsyncd.conf files (default: enabled)],
+-[case "${enableval}" in
+- yes) xml_config=true ;;
+- no) xml_config=false ;;
+- *) AC_MSG_ERROR([bad value ${enableval} for --enable-xml-config]) ;;
+-esac],[xml_config=true])
+-AM_CONDITIONAL(XML_CONFIG,[test x$xml_config = xtrue])
+-
+-#if test x$xml_config = xtrue; then
+-#AM_PATH_XML2(2.5.0,,AC_MSG_ERROR([*** Libxml is required if you do not --disable-xml-config]))
+-#fi
+-
+ AM_MAINTAINER_MODE
+
+ AC_PROG_CC
++AM_PROG_CC_C_O
+ AC_PROG_INSTALL
+ AC_CHECK_HEADERS([sys/inotify.h])
+
++AC_MSG_CHECKING([checking whether to use libxml2])
++AC_ARG_ENABLE([xml],
++ [ --enable-xml Lsyncd is able to parse lsyncd.conf files],
++ [enable_xml=$enableval],
++ [enable_xml="no"])
++AC_MSG_RESULT($enable_xml)
++if test "$enable_xml" = "yes"; then
++ AC_DEFINE(XML_CONFIG)
++ AM_PATH_XML2(2.4.0)
++fi
++
+ AC_CONFIG_HEADERS([config.h])
+
+ AC_OUTPUT(Makefile)
+--- Makefile.am
++++ Makefile.am
+@@ -1,6 +1,8 @@
+ ## Makefile.am -- Process this file with automake to produce Makefile.in
+ bin_PROGRAMS = lsyncd
+ lsyncd_SOURCES = lsyncd.c
++lsyncd_CPPFLAGS = $(XML_CPPFLAGS)
++lsyncd_LDADD = $(XML_LIBS)
+ TESTS = tests/help.sh \
+ tests/directorymv.sh \
+ tests/directorycpr.sh \
+@@ -33,10 +35,3 @@
+ $(XP) -o $@ $(DB2MAN) $<
+
+ AM_CFLAGS=-Wall
+-AM_LDFLAGS=
+-if XML_CONFIG
+-DEFS+=-DXML_CONFIG
+-AM_CFLAGS += `xml2-config --cflags`
+-AM_LDFLAGS += `xml2-config --libs`
+-endif
+-
diff --git a/app-admin/lsyncd/lsyncd-1.33.ebuild b/app-admin/lsyncd/lsyncd-1.33.ebuild
index 6651c6eff393..7a21616f8497 100644
--- a/app-admin/lsyncd/lsyncd-1.33.ebuild
+++ b/app-admin/lsyncd/lsyncd-1.33.ebuild
@@ -1,22 +1,34 @@
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/lsyncd/lsyncd-1.33.ebuild,v 1.1 2010/06/10 22:00:58 spatz Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/lsyncd/lsyncd-1.33.ebuild,v 1.2 2010/06/29 15:49:10 ssuominen Exp $
EAPI=2
+inherit autotools eutils
DESCRIPTION="Live Syncing (Mirror) Daemon"
HOMEPAGE="http://code.google.com/p/lsyncd/"
-SRC_URI="http://${PN}.googlecode.com/files/${P}.tar.gz"
+SRC_URI="http://lsyncd.googlecode.com/files/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
-IUSE=""
+IUSE="xml"
-DEPEND=""
-RDEPEND="net-misc/rsync"
+DEPEND="xml? ( dev-libs/libxml2 )"
+RDEPEND="${DEPEND}
+ net-misc/rsync"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-libxml2.patch
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ $(use_enable xml)
+}
src_install() {
- emake DESTDIR="${D}" install || die "Install failed"
+ emake DESTDIR="${D}" install || die
dodoc AUTHORS NEWS README TODO ChangeLog || die
}