aboutsummaryrefslogtreecommitdiffstats
path: root/testing/ngspice/APKBUILD
blob: 35ba19d8330f1e17a9b2f6f9b30a6d21a534eb0c (plain) (blame)
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
# Maintainer: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
pkgname=ngspice
pkgver=31
pkgrel=0
pkgdesc="open source spice simulator for electric and electronic circuits"
url="http://ngspice.sourceforge.net/"
arch="all"
license="BSD-3-Clause"
makedepends="libxaw-dev libedit-dev readline-dev"
depends="python3"
subpackages="$pkgname-doc $pkgname-dev"
source="
	https://downloads.sourceforge.net/project/$pkgname/ng-spice-rework/$pkgver/$pkgname-$pkgver.tar.gz
	"

build() {
	./configure \
		--prefix=/usr \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--with-readline=yes \
		--enable-xspice \
		--enable-cider \
		--enable-openmp \
		--with-ngshared

	make

	# build the binary ngspice, which is only build without --with-ngshared

	./configure \
		--prefix=/usr \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--with-readline=yes \
		--enable-xspice \
		--enable-cider \
		--enable-openmp

	make
}

check() {
	make check
}

package() {
	make DESTDIR="$pkgdir" install
	install -Dm755 src/.libs/libngspice.so.0.0.0 "$pkgdir/usr/lib/libngspice.so.0.0.0"
	ln -s "libngspice.so.0.0.0" "$pkgdir/usr/lib/libngspice.so.0"
	ln -s "libngspice.so.0.0.0" "$pkgdir/usr/lib/libngspice.so"
}

sha512sums="448024f398d267911d5d2a48da03eb0d87ba1133ce39d5132bd318dde8ad359d19c7f85f6b4ec88c08b081c9140f7b931334d84173019a22aa2ac98482bd7d5d  ngspice-31.tar.gz"