summaryrefslogtreecommitdiff
blob: fcee9f1cbba76d603ed6f39b983b4182795bcf8e (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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sci-electronics/ng-spice-rework/ng-spice-rework-9999.ebuild,v 1.1 2006/05/10 11:28:50 calchan Exp $

inherit eutils cvs

ECVS_SERVER="cvs.sourceforge.net:/cvsroot/ngspice"
ECVS_MODULE="ngspice/ng-spice-rework"
ECVS_USER="anonymous"

DESCRIPTION="The Next Generation Spice (Electronic Circuit Simulator) from CVS HEAD."
SRC_URI=""
HOMEPAGE="http://ngspice.sourceforge.net"
LICENSE="BSD GPL-2"

SLOT="0"
IUSE="readline debug"
KEYWORDS="-*"

DEPEND="readline? ( >=sys-libs/readline-5.0 )"

S=${WORKDIR}/ngspice/ng-spice-rework

src_unpack() {
	cvs_src_unpack
	cd ${S}
	epatch ${FILESDIR}/${PN}-com_let.patch
	epatch ${FILESDIR}/${PN}-numparam.patch
	epatch ${FILESDIR}/${PN}-pipemode.patch
	epatch ${FILESDIR}/${PN}-postscript.patch

	# Getting rid of this for now
	sed -i -e "/src\/spicelib\/devices\/adms\//d" configure.in
}

src_compile() {
	./autogen.sh
	econf \
		--enable-maintainer-mode \
		--enable-numparam \
		--enable-dot-global \
		--disable-dependency-tracking \
		$(use_with debug) \
		$(use_with readline) || die "econf failed"
	emake || die "emake failed"
}

src_install () {
	local infoFile
	for infoFile in doc/ngspice.info*; do
		echo 'INFO-DIR-SECTION EDA' >> ${infoFile}
		echo 'START-INFO-DIR-ENTRY' >> ${infoFile}
		echo '* NGSPICE: (ngspice). Electronic Circuit Simulator.' >> ${infoFile}
		echo 'END-INFO-DIR-ENTRY' >> ${infoFile}
	done

	make DESTDIR="${D}" install || die "make install failed"
	dodoc ANALYSES AUTHORS BUGS ChangeLog DEVICES NEWS \
		README Stuarts_Poly_Notes || die "failed to install documentation"

	# We don't need makeidx to be installed
	rm ${D}/usr/bin/makeidx
}

src_test () {
	# Bug 108405
	true
}