summaryrefslogtreecommitdiff
blob: 45bd1bf757a35e00c5db4cd806e502227b59b092 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-arch/xar/xar-20050423.ebuild,v 1.4 2006/10/08 16:08:18 grobian Exp $

inherit eutils flag-o-matic autotools

DESCRIPTION="The XAR project aims to provide an easily extensible archive format."
HOMEPAGE="http://www.opendarwin.org/projects/xar/"
SRC_URI="http://www.opendarwin.org/projects/xar/${P}.tar.gz"

LICENSE="as-is"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~ppc64 ~sparc ~x86"
IUSE="debug"

RDEPEND="virtual/libc"
DEPEND="${RDEPEND}
	dev-libs/openssl
	dev-libs/libxml2
	sys-libs/zlib"

src_unpack() {
	unpack ${A}
	cd ${S}
	epatch ${FILESDIR}/${P}-amd64.patch
	epatch "${FILESDIR}/${P}-ldflags.patch"

	eautoreconf
}

src_compile() {
	use debug && myconf="${myconf} --enable-symbols"
	use ppc64 && myconf="${myconf} --enable-64bit"
	use sparc && myconf="${myconf} --enable-64bit-vis"

	# This is a var used by AMD64-multilib, unset this
	# or we'll have problems during econf/emake
	unset SYMLINK_LIB

	econf ${myconf} || die
	emake CFLAGS_OPTIMIZE="${CFLAGS}" LDFLAGS_OPTIMIZE="${LDFLAGS}" || die
}

src_install() {
	make DESTDIR=${D} install || die
}