summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: b5ac5ec59511148b7cac3c8c2d332233ed48fb68 (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
# Maintainer: Dan McCurry <dan.mccurry at linux dot com>
pkgname=fullprof-suite
pkgver=2017.03
pkgrel=1
pkgdesc="Crystallographic tools for Rietveld, profile matching & integrated intensity refinements of X-Ray and/or neutron data."
arch=('x86_64')
url="https://www.ill.eu/sites/fullprof"
license=('custom')
groups=('science')
depends=('gcc-libs')
optdepends=('xterm: Needed to launch some programs from GUI')
provides=('fullprof')
conflicts=('fullprof')
install=${pkgname}.install

# You will need to download the .tgz file from the webpage directly:
# https://www.ill.eu/sites/fullprof/php/downloads.html

source=("file://FullProf_Suite_March2017_Linux64.tgz"
	"fullprof-bin")
noextract=("${source##*/}")
md5sums=('26e75738ffe284fb1399279c46f88391'
         'e91280ece6411983c74b3a8071402eb9')
PKGEXT=.pkg.tar

prepare() {
	mkdir -p ${srcdir}/${pkgname}
	mkdir -p ${srcdir}/bin

	tar -xzvf ${srcdir}/FullProf_Suite_*.tgz -C ${srcdir}/${pkgname}/

	for i in $(find ${srcdir}/${pkgname}/. \
		-maxdepth 1 -executable -type f -printf "%P "); do
		sed -e "s/\(exec.*\)/\1$i \"\$\@\"/" \
			${srcdir}/fullprof-bin > ${srcdir}/bin/fullprof-$i
	done
}	

package() {
	mkdir -p ${pkgdir}/opt/${pkgname}
	mkdir -p ${pkgdir}/usr/share/licenses/${pkgname}

	cp -R ${srcdir}/${pkgname}/. ${pkgdir}/opt/${pkgname}/
	ln -s /opt/${pkgname}/Docs/Readme_Fp_Suite.txt \
		${pkgdir}/usr/share/licenses/${pkgname}/README

	cd ${srcdir}/bin
	for i in *; do
		install -Dm755 $i ${pkgdir}/usr/bin/$i
	done
}