diff options
author | Raul Infante-Sainz <infantesainz@gmail.com> | 2019-03-06 17:12:19 +0000 |
---|---|---|
committer | Raul Infante-Sainz <infantesainz@gmail.com> | 2019-03-06 17:12:19 +0000 |
commit | 41865272cd80856eb466daef029a669225dbf139 (patch) | |
tree | bc77d553e92432c91530c9bbc4a466e16fa0d67d /reproduce/src | |
parent | a57c91cfdb05cf5cd790823f40d443648f3fc21a (diff) |
Astroquery, astropy, matplotlib and numpy are now in the pipeline
Until this commit, we had some of the python packages intalled
but they did not work properly because of the `PYTHONPATH' variables.
That is, the pipeline's `python' was the `python' of the system
instead of the pipeline's `python'.
With this commit this issue has been fixed by setting the correct
`PYTHONPATH'. In this commit we also modify the installation of
`bzip2' because `CMake' was complaining about some libraries built
statically.
Diffstat (limited to 'reproduce/src')
-rw-r--r-- | reproduce/src/make/dependencies-basic.mk | 37 | ||||
-rw-r--r-- | reproduce/src/make/dependencies-python.mk | 1 | ||||
-rw-r--r-- | reproduce/src/make/dependencies.mk | 3 | ||||
-rw-r--r-- | reproduce/src/make/initialize.mk | 13 |
4 files changed, 44 insertions, 10 deletions
diff --git a/reproduce/src/make/dependencies-basic.mk b/reproduce/src/make/dependencies-basic.mk index f02f68f..fefda6f 100644 --- a/reproduce/src/make/dependencies-basic.mk +++ b/reproduce/src/make/dependencies-basic.mk @@ -288,15 +288,34 @@ $(ibdir)/xz: $(tdir)/xz-$(xz-version).tar.gz $(call gbuild, $<, xz-$(xz-version), static) $(ibdir)/bzip2: $(tdir)/bzip2-$(bzip2-version).tar.gz - tdir=bzip2-$(bzip2-version); \ - if [ $(static_build) = yes ]; then \ - makecommand="make LDFLAGS=-static"; \ - else \ - makecommand="make"; \ - fi; \ - cd $(ddir) && rm -rf $$tdir && tar xf $< && cd $$tdir && \ - $$makecommand && make install PREFIX=$(idir) && \ - cd .. && rm -rf $$tdir + # Bzip2 doesn't have a `./configure' script, and its Makefile + # doesn't build a shared library. So we can't use the `gbuild' + # function here and we need to take some extra steps (inspired + # from the "Linux from Scratch" guide for Bzip2): + # 1) The `sed' call is for relative installed symbolic links. + # 2) The special Makefile-libbz2_so builds the shared library. + # + # NOTE: the major version number appears in the final symbolic + # link. + tdir=bzip2-$(bzip2-version); \ + if [ $(static_build) = yes ]; then \ + makecommand="make LDFLAGS=-static"; \ + makeshared="echo no-shared"; \ + else \ + makecommand="make"; \ + makeshared="make -f Makefile-libbz2_so"; \ + fi; \ + cd $(ddir) && rm -rf $$tdir && tar xf $< && cd $$tdir \ + && sed -i 's@\(ln -s -f \)$$(PREFIX)/bin/@\1@' Makefile \ + && $$makeshared \ + && cp -a libbz2* $(ildir)/ \ + && make clean \ + && $$makecommand \ + && make install PREFIX=$(idir) \ + && cd .. \ + && rm -rf $$tdir \ + && cd $(ildir) \ + && ln -fs libbz2.so.1.0 libbz2.so # GNU Tar: When built statically, tar gives a segmentation fault on # unpacking Bash. So we'll build it dynamically. diff --git a/reproduce/src/make/dependencies-python.mk b/reproduce/src/make/dependencies-python.mk index c45cc13..1e4f611 100644 --- a/reproduce/src/make/dependencies-python.mk +++ b/reproduce/src/make/dependencies-python.mk @@ -302,6 +302,7 @@ $(ipydir)/kiwisolver: $(tdir)/kiwisolver-$(kiwisolver-version).tar.gz \ $(ipydir)/matplotlib: $(tdir)/matplotlib-$(matplotlib-version).tar.gz \ $(ipydir)/cycler \ $(ilidir)/freetype \ + $(ipydir)/numpy \ $(ipydir)/pyparsing \ $(ipydir)/python-dateutil \ $(ipydir)/kiwisolver diff --git a/reproduce/src/make/dependencies.mk b/reproduce/src/make/dependencies.mk index e1b409e..deb9f39 100644 --- a/reproduce/src/make/dependencies.mk +++ b/reproduce/src/make/dependencies.mk @@ -242,7 +242,8 @@ $(ilidir)/libjpeg: $(tdir)/jpegsrc.$(libjpeg-version).tar.gz $(call gbuild, $<, jpeg-9b, static) && echo "Libjpeg is built" > $@ $(ilidir)/libpng: $(tdir)/libpng-$(libpng-version).tar.xz - $(call gbuild, $<, libpng, static) && echo "Libpng is built" > $@ + $(call gbuild, $<, libpng-$(libpng-version), static) \ + && echo "Libpng is built" > $@ $(ilidir)/libtiff: $(tdir)/tiff-$(libtiff-version).tar.gz \ $(ilidir)/libjpeg diff --git a/reproduce/src/make/initialize.mk b/reproduce/src/make/initialize.mk index 71cdbb8..638338b 100644 --- a/reproduce/src/make/initialize.mk +++ b/reproduce/src/make/initialize.mk @@ -116,6 +116,19 @@ export LDFLAGS := -L$(installdir)/lib export SHELL := $(installdir)/bin/bash export CPPFLAGS := -I$(installdir)/include +# Python enviroment +# So far we have found several other Python-related environment +# variables which might interfere. So we are just removing all +# of their values within the pipeline. +export PYTHONPATH := $(installdir)/lib/python/site-packages +export PYTHONPATH3 := $(PYTHONPATH) +export _LMFILES_ := +export PYTHONPATH2 := +export LOADEDMODULES := +export MPI_PYTHON_SITEARCH := +export MPI_PYTHON2_SITEARCH := +export MPI_PYTHON3_SITEARCH := + |