Skip to content

Commit

Permalink
Merge pull request #2061 from easybuilders/4.2.x
Browse files Browse the repository at this point in the history
release EasyBuild 4.2.1
  • Loading branch information
migueldiascosta authored May 20, 2020
2 parents 9a83802 + a75666c commit 31cf7f3
Show file tree
Hide file tree
Showing 34 changed files with 1,078 additions and 438 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ build/
dist/
*egg-info/
*.swp
.mypy_cache/
37 changes: 36 additions & 1 deletion RELEASE_NOTES
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,42 @@ For more detailed information, please see the git log.

These release notes can also be consulted at http://easybuild.readthedocs.org/en/latest/Release_notes.html.

The latest version of easybuild-easyblocks provides 219 software-specific easyblocks and 36 generic easyblocks.
The latest version of easybuild-easyblocks provides 219 software-specific easyblocks and 37 generic easyblocks.

v4.2.1 (May 20th 2020)
----------------------

update/bugfix release

- add generic easyblock for installing Go packages: GoPackage (#2042)
- minor enhancements, including:
- update config.guess for all R packages, required installing R + extensions on Linux/POWER systems (#1949)
- add support for preinstallopts and install in subdirectory to Tarball generic easyblock (#1989, #2049)
- rewrite GROMACS easyblock to install all four variations (single/double precision, with/without MPI) in the same directory (#1991)
- add custom 'subdir_version' easyconfig parameter for FLUENT (#2021)
- use updated config.guess in GCC easyblock (#2033, #2059)
- add extra question pattern to support installing CPLEX 12.10 (#2038)
- add support for building NWChem on top of external GlobalArrays + also define $LAPACK_LIB (required for NWChem 7.x) (#2043)
- execute minimal test in sanity check commands in impi easyblock (#2045)
- update for MotionCor2 easyblock for v1.3.1 (#2046)
- fixes + enhancements for PETSc easyblock (#2048)
- various bug fixes, including:
- use correct version in ELPA preprocessor flag used for QuantumESPRESSO v6.x (#2027)
- generically find the arch folder and add top-level bin/lib symlinks in PDT & TAU easyblocks (#2029)
- fix typo in LAMMPS easyblock preventing disabling the USER-INTEL package via configopts (#2031)
- let CMakeMake remove 'easybuild_obj' build directory if it already exists (#2032)
- include own lib dir in RPATH before system lib dirs in binutils easyblock (#2044)
- clean $CPATH before building ROOT to avoid clash between external LLVM loaded as a dependency and internal LLVM used by ROOT (#2047)
- don't let extract_file change directory in various easyblocks (#2051)
- make postinstallcmds available to Mathematica easyconfigs + add bin/Executables to $PATH (#2052)
- fix the extra dirs added to PATH in FreeSurfer easyblock (#2053)
- correct download url for test data in WPS easyblock (#2055)
- fix typo in warning in TensorFlow easyblock (#2057)
- fix failing sanity check under --module-only in GCC easyblock (#2059)
- other changes:
- add configure options for CubeLib/CubeWriter dependencies in Score-P easyblock (#2030)
- remove local find_glob_pattern in Blender & ROOT easyblocks, use function provided by filetools instead (#2037)


v4.2.0 (April 14th 2020)
------------------------
Expand Down
2 changes: 1 addition & 1 deletion easybuild/easyblocks/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
# recent setuptools versions will *TRANSFORM* something like 'X.Y.Zdev' into 'X.Y.Z.dev0', with a warning like
# UserWarning: Normalizing '2.4.0dev' to '2.4.0.dev0'
# This causes problems further up the dependency chain...
VERSION = LooseVersion('4.2.0')
VERSION = LooseVersion('4.2.1')
UNKNOWN = 'UNKNOWN'


Expand Down
21 changes: 17 additions & 4 deletions easybuild/easyblocks/b/binutils.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ def extra_options(extra_vars=None):
extra_vars = ConfigureMake.extra_options(extra_vars=extra_vars)
extra_vars.update({
'install_libiberty': [True, "Also install libiberty (implies building with -fPIC)", CUSTOM],
'use_debuginfod': [False, "Build with debuginfod (used from system)", CUSTOM],
})
return extra_vars

Expand All @@ -62,7 +63,11 @@ def configure_step(self):
# determine list of 'lib' directories to use rpath for;
# this should 'harden' the resulting binutils to bootstrap GCC
# (no trouble when other libstdc++ is build etc)
libdirs = []

# The installed lib dir must come first though to avoid taking system libs over installed ones, see:
# https://github.com/easybuilders/easybuild-easyconfigs/issues/10056
# Escaping: Double $$ for Make, \$ for shell to get literal $ORIGIN in the file
libdirs = [r'\$\$ORIGIN/../lib']
for libdir in ['/usr/lib', '/usr/lib64', '/usr/lib/x86_64-linux-gnu/']:
# also consider /lib, /lib64
alt_libdir = libdir.replace('usr/', '')
Expand All @@ -75,7 +80,8 @@ def configure_step(self):
elif os.path.exists(alt_libdir):
libdirs.append(alt_libdir)

libs += ' '.join('-Wl,-rpath=%s' % libdir for libdir in libdirs)
# Mind the single quotes
libs += ' '.join("-Wl,-rpath='%s'" % libdir for libdir in libdirs)

# configure using `--with-system-zlib` if zlib is a (build) dependency
zlibroot = get_software_root('zlib')
Expand All @@ -101,8 +107,9 @@ def configure_step(self):
else:
libs += ' ' + libz_path

self.cfg.update('preconfigopts', "env LIBS='%s'" % libs)
self.cfg.update('prebuildopts', "env LIBS='%s'" % libs)
# Using double quotes for LIBS to allow single quotes in libs
self.cfg.update('preconfigopts', 'LIBS="%s"' % libs)
self.cfg.update('prebuildopts', 'LIBS="%s"' % libs)

# use correct sysroot, to make sure 'ld' also considers system libraries
self.cfg.update('configopts', '--with-sysroot=/')
Expand All @@ -115,6 +122,12 @@ def configure_step(self):
if LooseVersion(self.version) > LooseVersion('2.24'):
self.cfg.update('configopts', "--enable-gold --enable-plugins --enable-ld=default")

if LooseVersion(self.version) >= LooseVersion('2.34'):
if self.cfg['use_debuginfod']:
self.cfg.update('configopts', '--with-debuginfod')
else:
self.cfg.update('configopts', '--without-debuginfod')

# complete configuration with configure_method of parent
super(EB_binutils, self).configure_step()

Expand Down
19 changes: 5 additions & 14 deletions easybuild/easyblocks/b/blender.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@
@author: Samuel Moors (Vrije Universiteit Brussel)
"""
import glob
import os

from easybuild.easyblocks.generic.cmakemake import CMakeMake
from easybuild.tools.build_log import EasyBuildError
from easybuild.tools.filetools import find_glob_pattern
from easybuild.tools.modules import get_software_root, get_software_version
from easybuild.tools.systemtools import get_shared_lib_ext

Expand All @@ -45,15 +45,6 @@ def extra_options():
extra_vars['separate_build_dir'][0] = True
return extra_vars

def find_glob_pattern(self, glob_pattern):
"""Find unique file/dir matching glob_pattern (raises error if more than one match is found)"""
if self.dry_run:
return glob_pattern
res = glob.glob(glob_pattern)
if len(res) != 1:
raise EasyBuildError("Was expecting exactly one match for '%s', found %d: %s", glob_pattern, len(res), res)
return res[0]

def configure_step(self):
"""Set CMake options for Blender"""

Expand Down Expand Up @@ -81,12 +72,12 @@ def configure_step(self):
site_packages = os.path.join(python_root, 'lib', 'python%s' % pyshortver, 'site-packages')

# We assume that numpy/requests are included with the Python installation (no longer true for 2019a)
numpy_root = self.find_glob_pattern(
numpy_root = find_glob_pattern(
os.path.join(site_packages, 'numpy-*-py%s-linux-x86_64.egg' % pyshortver))
requests_root = self.find_glob_pattern(os.path.join(site_packages, 'requests-*-py%s.egg' % pyshortver))
python_lib = self.find_glob_pattern(
requests_root = find_glob_pattern(os.path.join(site_packages, 'requests-*-py%s.egg' % pyshortver))
python_lib = find_glob_pattern(
os.path.join(python_root, 'lib', 'libpython%s*.%s' % (pyshortver, shlib_ext)))
python_include_dir = self.find_glob_pattern(os.path.join(python_root, 'include', 'python%s*' % pyshortver))
python_include_dir = find_glob_pattern(os.path.join(python_root, 'include', 'python%s*' % pyshortver))

self.cfg.update('configopts', '-DPYTHON_VERSION=%s' % pyshortver)
self.cfg.update('configopts', '-DPYTHON_LIBRARY=%s' % python_lib)
Expand Down
2 changes: 2 additions & 0 deletions easybuild/easyblocks/c/cplex.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ def install_step(self):
"PRESS <ENTER> TO EXIT THE INSTALLER:": '',
"CHOOSE LOCALE BY NUMBER:": '',
"Choose Instance Management Option:": '',
"No model content or proprietary data will be sent.\n1- Yes\n2- No\n"
"ENTER THE NUMBER OF THE DESIRED CHOICE:": '2',
}
noqanda = [r'Installing\.\.\..*\n.*------.*\n\n.*============.*\n.*$']

Expand Down
14 changes: 13 additions & 1 deletion easybuild/easyblocks/f/fluent.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,17 +32,29 @@
from distutils.version import LooseVersion

from easybuild.easyblocks.generic.packedbinary import PackedBinary
from easybuild.framework.easyconfig import CUSTOM
from easybuild.tools.filetools import adjust_permissions
from easybuild.tools.run import run_cmd


class EB_FLUENT(PackedBinary):
"""Support for installing FLUENT."""

@staticmethod
def extra_options():
extra_vars = PackedBinary.extra_options()
extra_vars['subdir_version'] = [None, "Version to use to determine installation subdirectory", CUSTOM]
return extra_vars

def __init__(self, *args, **kwargs):
"""Custom constructor for FLUENT easyblock, initialize/define class parameters."""
super(EB_FLUENT, self).__init__(*args, **kwargs)
self.fluent_verdir = 'v%s' % ''.join(self.version.split('.')[:2])

subdir_version = self.cfg['subdir_version']
if subdir_version is None:
subdir_version = ''.join(self.version.split('.')[:2])

self.fluent_verdir = 'v%s' % subdir_version

def install_step(self):
"""Custom install procedure for FLUENT."""
Expand Down
8 changes: 4 additions & 4 deletions easybuild/easyblocks/f/freesurfer.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,18 +44,18 @@ def extra_options():
extra_vars = {
'license_text': ['', "Text for required license file.", MANDATORY],
}
return EasyBlock.extra_options(extra_vars)
return Tarball.extra_options(extra_vars)

def install_step(self):
"""Custom installation procedure for FreeSurfer, which includes installed the license file '.license'."""
super(EB_FreeSurfer, self).install_step()
write_file(os.path.join(self.installdir, '.license'), self.cfg['license_text'])

def make_module_guesses(self):
def make_module_req_guess(self):
"""Include correct subdirectories to $PATH for FreeSurfer."""
guesses = super(EB_FreeSurfer, self).make_module_guesses()
guesses = super(EB_FreeSurfer, self).make_module_req_guess()

guesses['PATH'] = ['bin', 'fsfast/bin', 'mni/bin', 'tktools']
guesses['PATH'].extend([os.path.join('fsfast', 'bin'), os.path.join('mni', 'bin'), 'tktools'])

return guesses

Expand Down
45 changes: 33 additions & 12 deletions easybuild/easyblocks/g/gcc.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,10 @@
from easybuild.tools.filetools import apply_regex_substitutions, symlink, write_file
from easybuild.tools.modules import get_software_root
from easybuild.tools.run import run_cmd
from easybuild.tools.systemtools import check_os_dependency, get_os_name, get_os_type, get_platform_name
from easybuild.tools.systemtools import check_os_dependency, get_os_name, get_os_type
from easybuild.tools.systemtools import get_gcc_version, get_shared_lib_ext
from easybuild.tools.toolchain.compiler import OPTARCH_GENERIC
from easybuild.tools.utilities import nub


COMP_CMD_SYMLINKS = {
Expand Down Expand Up @@ -113,8 +114,6 @@ def __init__(self, *args, **kwargs):
if get_os_name() not in ['ubuntu', 'debian']:
self.cfg.update('unwanted_env_vars', ['LIBRARY_PATH'])

self.platform_lib = get_platform_name(withversion=True)

def create_dir(self, dirname):
"""
Create a dir to build in.
Expand Down Expand Up @@ -383,15 +382,17 @@ def configure_step(self):
else:
objdir = self.create_dir("obj")

# note: this also triggers the use of an updated config.guess script
# (unless both the 'build_type' and 'host_type' easyconfig parameters are specified)
build_type, host_type = self.determine_build_and_host_type()
if build_type:
configopts += ' --build=' + build_type
if host_type:
configopts += ' --host=' + host_type

# IV) actual configure, but not on default path
cmd = "../configure %s %s" % (self.configopts, configopts)

# instead of relying on uname, we run the same command GCC uses to
# determine the platform
out, ec = run_cmd("../config.guess", simple=False)
if ec == 0:
self.platform_lib = out.rstrip()

self.run_configure_cmd(cmd)

self.disable_lto_mpfr_old_gcc(objdir)
Expand Down Expand Up @@ -624,7 +625,26 @@ def sanity_check_step(self):

os_type = get_os_type()
sharedlib_ext = get_shared_lib_ext()
common_infix = os.path.join('gcc', self.platform_lib, self.version)

# determine "configuration name" directory, see https://sourceware.org/autobook/autobook/autobook_17.html
# this differs across GCC versions;
# x86_64-unknown-linux-gnu was common for old GCC versions,
# x86_64-pc-linux-gnu is more likely with an updated config.guess script;
# since this is internal to GCC, we don't really care how it is named exactly,
# we only care that it's actually there

# we may get multiple hits (libexec/, lib/), which is fine,
# but we expect the same configuration name subdirectory in each of them
glob_pattern = os.path.join(self.installdir, 'lib*', 'gcc', '*-linux-gnu', self.version)
matches = glob.glob(glob_pattern)
if matches:
cands = nub([os.path.basename(os.path.dirname(x)) for x in matches])
if len(cands) == 1:
config_name_subdir = cands[0]
else:
raise EasyBuildError("Found multiple candidates for configuration name: %s", ', '.join(cands))
else:
raise EasyBuildError("Failed to determine configuration name: no matches for '%s'", glob_pattern)

bin_files = ["gcov"]
lib_files = []
Expand All @@ -639,7 +659,7 @@ def sanity_check_step(self):
else:
lib_files.extend(["libasan.%s" % sharedlib_ext, "libasan.a"])
libexec_files = []
dirs = ['lib/%s' % common_infix]
dirs = [os.path.join('lib', 'gcc', config_name_subdir, self.version)]

if not self.cfg['languages']:
# default languages are c, c++, fortran
Expand Down Expand Up @@ -678,7 +698,8 @@ def sanity_check_step(self):
lib_files = [tuple([os.path.join(libdir, x) for libdir in libdirs]) for x in lib_files]
# lib on SuSE, libexec otherwise
libdirs = ['libexec', 'lib']
libexec_files = [tuple([os.path.join(libdir, common_infix, x) for libdir in libdirs]) for x in libexec_files]
common_infix = os.path.join('gcc', config_name_subdir, self.version)
libexec_files = [tuple([os.path.join(d, common_infix, x) for d in libdirs]) for x in libexec_files]

old_cmds = [os.path.join('bin', x) for x in COMP_CMD_SYMLINKS.keys()]

Expand Down
Loading

0 comments on commit 31cf7f3

Please sign in to comment.