summaryrefslogtreecommitdiff
blob: 61184c32be6a237ab6f4efd20d16cfd748960d1e (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
47
48
49
50
51
52
53
54
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-ada/florist/florist-2006.0.ebuild,v 1.3 2007/07/15 04:21:59 mr_bones_ Exp $

inherit gnat libtool

IUSE=""

DESCRIPTION="Posix bindings for Ada"
HOMEPAGE="http://libre2.adacore.com/"
SRC_URI="mirror://gentoo/${P}.tar.bz2"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86 ~amd64"

DEPEND="virtual/gnat"

lib_compile()
{
	elibtoolize
	econf || die "econf failed"
	emake || die "make failed"
	make floristlib || die "building library failed"
	einfo "lib_compile completed"
}

# NOTE: we are using $1 - the passed gnat profile name
lib_install()
{
	# install goal is just (access violating) mkdir and 2 cp's
	# instead move stuff properly here
	cp -rp ${SL}/floristlib/{libflorist.a,*.ali} ${DL}
	chmod 0444 ${DL}/*.ali
}

src_install ()
{
	cd ${S}
	# install sources
	dodir ${AdalibSpecsDir}/${PN}
	insinto ${AdalibSpecsDir}/${PN}
	doins -r *.ad{b,s} *.c *.gpb gnatsocks/

	#set up environment
	#echo "PATH=%DL%/bin" > ${LibEnv}
	echo "LDPATH=%DL%" >> ${LibEnv}
	echo "ADA_OBJECTS_PATH=%DL%" >> ${LibEnv}
	echo "ADA_INCLUDE_PATH=/usr/include/ada/${PN}" >> ${LibEnv}

	gnat_src_install

	dodoc COPYING README
}