-
Notifications
You must be signed in to change notification settings - Fork 13
/
conda.mk
40 lines (29 loc) · 1.12 KB
/
conda.mk
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
# Makefile to setting up a conda environment.
export PATH := $(PWD)/conda/bin:$(PATH)
Miniconda3-latest-Linux-x86_64.sh:
wget -c https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O .Miniconda3-latest-Linux-x86_64.sh
mv -f .Miniconda3-latest-Linux-x86_64.sh Miniconda3-latest-Linux-x86_64.sh
conda/bin/conda: Miniconda3-latest-Linux-x86_64.sh
chmod a+x Miniconda3-latest-Linux-x86_64.sh
./Miniconda3-latest-Linux-x86_64.sh -p conda -b
conda/.condarc: conda.mk
conda config --system --set always_yes yes --set changeps1 no
conda config --system --add channels timvideos
conda/bin/%: conda/bin/conda conda/.condarc
conda install $(shell basename $@)
conda/.modules/%: conda/bin/conda conda/.condarc
mkdir -p $(shell dirname $@)
pip install $(shell basename $@)
touch $@
PYTHON_MODULES = pyusb pep8 autopep8 setuptools-pep8
DEPS := \
$(foreach P,$(PYTHON_PACKAGES),conda/.modules/$(P)) \
$(foreach P,$(CONDA_PACKAGES),conda/bin/$(P))
conda: $(DEPS)
python setup.py develop
check-conda:
[ -d conda ]
clean-conda:
rm -rf Miniconda3-latest-Linux-x86_64.sh
rm -rf conda
.PHONY: check-conda clean-conda