build 889 Bytes
Newer Older
bliven_s's avatar
bliven_s committed
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
#!/usr/bin/env modbuild

pbuild::add_to_group 'EM'
pbuild::prep() {
	echo "prepping"
	mkdir -p "$SRC_DIR"
	curl -fsSLo "$SRC_DIR/miniconda.sh" 'https://repo.anaconda.com/miniconda/Miniconda2-latest-Linux-x86_64.sh'
	curl -fsSLo "$SRC_DIR/cryoloBM.tgz" 'ftp://ftp.gwdg.de/pub/misc/sphire/crYOLO_BM_V1_1_1/cryoloBM-1.1.1.tar.gz'
	curl -fsSLo "$SRC_DIR/cryolo.tgz" 'ftp://ftp.gwdg.de/pub/misc/sphire/crYOLO_V1_2_3/cryolo-1.2.3.tar.gz'
	:
}

pbuild::configure() {
	:
}

pbuild::compile() {
	:
}

pbuild::install() {
	mkdir -p $PREFIX

	# Install conda
	bash "$SRC_DIR/miniconda.sh" -b -p $PREFIX/conda

	# Create environment
	$PREFIX/conda/bin/conda create -y --name crYOLO anaconda python=3.6 pyqt=5 cudnn=7.1.2 numpy
	
	# Activate
	source $PREFIX/conda/bin/activate crYOLO
	
	# Install
	pip install $SRC_DIR/cryolo.tgz
	pip install $SRC_DIR/cryoloBM.tgz

	# Deactivate
	source deactivate
}