Ver Fonte

Adding artificial Python2 support for 2020b

Pierre-Yves Barriat há 3 anos atrás
pai
commit
5391742a97

+ 70 - 0
foss-2020b/ELIC_Python-1-foss-2020b-Python-2.7.18.eb

@@ -0,0 +1,70 @@
+easyblock = 'PythonBundle'
+
+name = 'ELIC_Python'
+version = '1'
+versionsuffix = '-Python-%(pyver)s'
+
+homepage = 'https://gogs.elic.ucl.ac.be'
+description = """This repo provides additional Python and R extensions for ELIC ecosystem."""
+
+toolchain = {'name': 'foss', 'version': '2020b'}
+
+builddependencies = [
+    ('pkg-config', '0.29.2'),
+]
+
+dependencies = [
+    ('Python', '2.7.18'),
+    ('SciPy-bundle', '2019.10', versionsuffix),
+    ('GDAL', '3.0.0', versionsuffix),
+    #('NCL', '6.6.2'),
+    #('CDO', '1.9.9'),
+    #('NCO', '4.9.7'),
+    ('ncview', '2.1.7'),
+]
+
+exts_defaultclass = 'PythonPackage'
+exts_default_options = {
+    'source_tmpl': '%(name)s-%(version)s.tar.gz',
+}
+
+exts_list = [
+    # Python deps, order is important!
+    ('PyKE', '1.1.1', {
+        'source_tmpl': 'pyke-1.1.1.zip',
+        'source_urls': ['http://download.sourceforge.net/pyke'],
+        'checksums': ['b0b294f435c6e6d2d4a80badf57d92cb66814dfe21e644a521901209e6a3f8ae'],
+    }),
+    #('matplotlib', '2.2.4', {
+    #    'source_urls': ['https://pypi.python.org/packages/source/m/matplotlib/'],
+    #}),
+    #('basemap', '1.1.0', {
+    #    'modulename': 'mpl_toolkits.basemap',
+    #    'source_tmpl': 'v%(version)s.tar.gz',
+    #    'source_urls': ['https://github.com/matplotlib/basemap/archive'],
+    #    'checksums': ['6acdc3a08bfcebf0a1b52a05d73d51b7aa5e7240fedfa95537c92d16f2ef8778'],
+    #}),
+    #('scipy', '1.2.2', {
+    #    'source_urls': ['https://pypi.python.org/packages/source/s/scipy/'],
+    #    'checksums': ['a4331e0b8dab1ff75d2c67b5158a8bb9a83c799d7140094dda936d876c7cfbb1'],
+    #}),
+]
+
+modextrapaths = {
+    'PYTHONPATH': 'lib/python%(pyshortver)s/site-packages',
+    'PYTHONUSERBASE': '',
+}
+
+postinstallcmds = [
+    "cd %(installdir)s && " +
+    'pip install setuptools --upgrade && ' +
+    'pip install olefile pyproj pyshp chardet urllib3 --prefix="%(installdir)s" && ' +
+    'pip install OWSLib ' +
+                'netCDF4==1.4.3.2 ' +
+                'dask ' +
+                'cf-units ' +
+                'Cartopy ' +
+                '--prefix="%(installdir)s" '
+]
+
+moduleclass = 'numlib'

+ 58 - 0
foss-2020b/GDAL-3.0.0-foss-2020b-Python-2.7.18.eb

@@ -0,0 +1,58 @@
+easyblock = 'ConfigureMake'
+
+name = 'GDAL'
+version = '3.0.0'
+versionsuffix = '-Python-%(pyver)s'
+
+homepage = 'https://www.gdal.org'
+description = """GDAL is a translator library for raster geospatial data formats that is released under an X/MIT style
+ Open Source license by the Open Source Geospatial Foundation. As a library, it presents a single abstract data model
+ to the calling application for all supported formats. It also comes with a variety of useful commandline utilities for
+ data translation and processing."""
+
+toolchain = {'name': 'foss', 'version': '2020b'}
+toolchainopts = {'usempi': True}
+
+source_urls = ['https://download.osgeo.org/gdal/%(version)s/']
+sources = [SOURCELOWER_TAR_XZ]
+checksums = ['ad316fa052d94d9606e90b20a514b92b2dd64e3142dfdbd8f10981a5fcd5c43e']
+
+dependencies = [
+    ('Python', '2.7.18'),
+    ('netCDF', '4.7.4'),
+    ('expat', '2.2.9'),
+    ('GEOS', '3.8.1', versionsuffix),
+    ('SQLite', '3.33.0'),
+    ('libxml2', '2.9.10'),
+    ('libpng', '1.6.37'),
+    ('libjpeg-turbo', '2.0.5'),
+    ('JasPer', '2.0.14'),
+    ('LibTIFF', '4.1.0'),
+    ('zlib', '1.2.11'),
+    ('cURL', '7.72.0'),
+    ('PCRE', '8.44'),
+    ('PROJ', '7.2.0'),
+    ('libgeotiff', '1.6.0'),
+    ('SciPy-bundle', '2019.10', versionsuffix),
+    ('HDF5', '1.10.7'),
+]
+
+#osdependencies = [('openssl-devel', 'libssl-dev', 'libopenssl-devel')]
+
+configopts = '--with-expat=$EBROOTEXPAT --with-libz=$EBROOTLIBZ --with-hdf5=$EBROOTHDF5 --with-netcdf=$EBROOTNETCDF'
+configopts += ' --with-xml2=$EBROOTLIBXML2 --with-geos=$EBROOTGEOS/bin/geos-config --with-jpeg=$EBROOTLIBJPEGMINTURBO'
+configopts += ' --with-png=$EBROOTLIBPNG --with-sqlite3=$EBROOTSQLITE --with-jasper=$EBROOTJASPER'
+configopts += ' --with-libtiff=$EBROOTLIBTIFF --with-pcre=$EBROOTPCRE --with-python=$EBROOTPYTHON/bin/python'
+configopts += ' --with-libgeotiff=$EBROOTLIBGEOTIFF'
+
+modextrapaths = {'PYTHONPATH': 'lib/python%(pyshortver)s/site-packages'}
+
+sanity_check_paths = {
+    'files': ['lib/libgdal.a', 'lib/libgdal.%s' % SHLIB_EXT,
+              'lib/python%%(pyshortver)s/site-packages/osgeo/_gdal_array.%s' % SHLIB_EXT],
+    'dirs': ['bin', 'include', 'lib/python%(pyshortver)s/site-packages']
+}
+
+#sanity_check_commands = ["python -c 'from osgeo import gdal'"]
+
+moduleclass = 'data'

+ 29 - 0
foss-2020b/GEOS-3.8.1-GCC-10.2.0-Python-2.7.18.eb

@@ -0,0 +1,29 @@
+easyblock = 'ConfigureMake'
+
+name = 'GEOS'
+version = '3.8.1'
+versionsuffix = '-Python-%(pyver)s'
+
+homepage = 'https://trac.osgeo.org/geos'
+description = """GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS)"""
+
+toolchain = {'name': 'GCC', 'version': '10.2.0'}
+
+source_urls = ['https://download.osgeo.org/geos/']
+sources = [SOURCELOWER_TAR_BZ2]
+checksums = ['4258af4308deb9dbb5047379026b4cd9838513627cb943a44e16c40e42ae17f7']
+
+dependencies = [('Python', '2.7.18')]
+
+builddependencies = [('SWIG', '4.0.2')]
+
+configopts = '--enable-python'
+
+modextrapaths = {'PYTHONPATH': 'lib/python%(pyshortver)s/site-packages'}
+
+sanity_check_paths = {
+    'files': ['bin/geos-config', 'lib/libgeos.%s' % SHLIB_EXT, 'lib/libgeos.a', 'include/geos.h'],
+    'dirs': ['lib/python%(pyshortver)s/site-packages/geos'],
+}
+
+moduleclass = 'math'

+ 45 - 0
foss-2020b/SciPy-bundle-2019.10-foss-2020b-Python-2.7.18.eb

@@ -0,0 +1,45 @@
+easyblock = 'PythonBundle'
+
+name = 'SciPy-bundle'
+version = '2019.10'
+versionsuffix = '-Python-2.7.18'
+
+homepage = 'https://python.org/'
+description = "Bundle of Python packages for scientific software"
+
+toolchain = {'name': 'foss', 'version': '2020b'}
+toolchainopts = {'pic': True, 'lowopt': True}
+
+dependencies = [
+    ('Python', '2.7.18'),
+]
+
+use_pip = True
+
+# order is important!
+# package versions updated Sep 17th 2019 to latest versions compatible with python2
+exts_list = [
+    ('numpy', '1.16.5', {
+        'source_tmpl': '%(name)s-%(version)s.zip',
+        'source_urls': ['https://pypi.python.org/packages/source/n/numpy/'],
+        'checksums': ['8bb452d94e964b312205b0de1238dd7209da452343653ab214b5d681780e7a0c'],
+    }),
+    #('scipy', '1.2.2', {
+    #    'source_urls': ['https://pypi.python.org/packages/source/s/scipy/'],
+    #    'checksums': ['a4331e0b8dab1ff75d2c67b5158a8bb9a83c799d7140094dda936d876c7cfbb1'],
+    #}),
+    ('mpi4py', '3.0.2', {
+        'source_urls': ['https://bitbucket.org/mpi4py/mpi4py/downloads/'],
+        'checksums': ['f8d629d1e3e3b7b89cb99d0e3bc5505e76cc42089829807950d5c56606ed48e0'],
+    }),
+    ('pandas', '0.24.2', {
+        'source_urls': ['https://pypi.python.org/packages/source/p/pandas/'],
+        'checksums': ['4f919f409c433577a501e023943e582c57355d50a724c589e78bc1d551a535a2'],
+    }),
+    ('mpmath', '1.1.0', {
+        'source_urls': ['https://pypi.python.org/packages/source/m/mpmath/'],
+        'checksums': ['fc17abe05fbab3382b61a123c398508183406fa132e0223874578e20946499f6'],
+    }),
+]
+
+moduleclass = 'lang'