Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial copy of key parts of skare/py3 #13

Merged
merged 1 commit into from
Jul 3, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
124 changes: 124 additions & 0 deletions Makefile.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
NAME = skare
VERSION = `ska_version.py`
PREFIX = @prefix@
STDCONF = --prefix $(PREFIX)
# --allow-errors

install:
echo "Need to specify an explicit target"

# Full install of operational Ska runtime environment
# The order is important. Anaconda must create the root prefix dir.
all_32: python_32 perl

all_64: python_64 perl

basedirs:
./install.py --prefix $(PREFIX) --no-env-vars --config template

python_32: anaconda_32 basedirs python_libs_32 python_modules

python_64: anaconda_64 basedirs python_libs_64 python_modules

# Git is required for some version.py (this dependency should be changed!)
python_libs_64: xtime
# gtk pygtk

# No support for Gtk in 32-bit
python_libs_32: xtime git

# meld

perl_libs: libg2c_bin xtime pgplot gsl expat cfitsio

perl: perl_libs perl_from_source perl_modules libmysql perl_dbi

perl_from_source:
./install.py $(STDCONF) --config perl_from_source

anaconda_32:
./install.py --prefix $(PREFIX) --no-env-vars --installing-anaconda --config anaconda-32

anaconda_64:
./install.py --prefix $(PREFIX) --no-env-vars --installing-anaconda --config anaconda-64

hdf5:
./install.py $(STDCONF) --config hdf5

gtk:
./install.py $(STDCONF) --config gtk

pygtk:
./install.py $(STDCONF) --config pygtk

meld:
./install.py $(STDCONF) --config meld

libmysql:
./install.py $(STDCONF) --config mysql

expat:
./install.py $(STDCONF) --config expat

psycopg2:
./install.py $(STDCONF) --config psycopg2

wcstools:
./install.py $(STDCONF) --config wcstools

libg2c_bin:
./install.py $(STDCONF) --config libg2c_bin

xtime:
./install.py $(STDCONF) --config xtime

cfitsio:
./install.py $(STDCONF) --config cfitsio

gsl:
./install.py $(STDCONF) --config gsl

git:
./install.py $(STDCONF) --config git

pgplot:
./install.py $(STDCONF) --config pgplot

sherpa:
./install.py $(STDCONF) --config sherpa

sherpaX:
./install.py $(STDCONF) --config ciao-sherpa
./install.py $(STDCONF) --config sherpaX

# Optional packages for python modules
pycuda:
./install.py $(STDCONF) --config pycuda

python_modules:
./install.py $(STDCONF) --config python_modules

# Perl 5.8.x
perl_modules:
./install.py $(STDCONF) --config perl_modules

perl_dbi:
./install.py $(STDCONF) --config perl_dbi

dist:
mkdir $(NAME)-$(VERSION)
mkdir -p dist
tar --exclude .svn --exclude "*.pyc" --exclude "*~" --create --files-from=MANIFEST --file - \
| (tar --extract --directory $(NAME)-$(VERSION) --file - )
tar --create --verbose --gzip --file dist/$(NAME)-$(VERSION).tar.gz $(NAME)-$(VERSION)
rm -rf $(NAME)-$(VERSION)

bdist_32:
tar --create --bzip2 --file $(NAME)-$(VERSION)-32.tar.bz2 \
$(PREFIX)/bin $(PREFIX)/include $(PREFIX)/arch $(PREFIX)/lib \
$(PREFIX)/build/*/*/.installed

bdist_64:
tar --create --bzip2 --file $(NAME)-$(VERSION)-64.tar.bz2 \
$(PREFIX)/bin $(PREFIX)/include $(PREFIX)/arch $(PREFIX)/lib \
$(PREFIX)/build/*/*/.installed
22 changes: 22 additions & 0 deletions cfg/anaconda-64.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
##############################################################################
# Anaconda Python
#
---
content : python
cmds :
test : |
test -e .installed
cd $prefix
${prefix_arch}/bin/python -V
build : |
bash ./Miniconda3-latest-Linux-x86_64.sh -b -p ${prefix_arch}
cp ${installer_dir}/pkgs.pinned ${prefix_arch}/conda-meta/pinned
cp ${installer_dir}/dot_condarc ${prefix_arch}/.condarc
# Python seems to need to be installed on its own to update
${prefix_arch}/bin/conda install --quiet --yes --no-update-dependencies python=3.6.2_0
${prefix_arch}/bin/conda install --quiet --yes --no-update-dependencies --file=${installer_dir}/pkgs.conda
${prefix_arch}/bin/conda-env export --name root > ${prefix_arch}/conda_env.yml

modules:
- name : python
file : Miniconda3-64*
14 changes: 14 additions & 0 deletions cfg/template.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
##############################################################################
# Rsync a template version of Ska into the install area. These are mostly perl
# scripts and libraries that don't exist in packages.
#
---
content : template
cmds :
install : |
rsync --archive --verbose --exclude .svn --exclude '*~' template/bin template/lib template/include ${prefix}/
perl -pi -e "s+%{PREFIX}%+${prefix}+" ${prefix}/bin/ska_envs.*sh
mkdir -p ${prefix_arch}/pgplot

modules:
- name : template
Loading