Skip to content

Commit

Permalink
Merge pull request #22049 from boegel/20241218133750_new_pr_EasyBuild…
Browse files Browse the repository at this point in the history
…500beta1

{tools}[system] EasyBuild v0.5.0.0beta1 (initial beta release of EasyBuild v5.0.0)
  • Loading branch information
jfgrimm authored Dec 24, 2024
2 parents ef644ae + 49011fa commit 51cd066
Show file tree
Hide file tree
Showing 2 changed files with 83 additions and 0 deletions.
59 changes: 59 additions & 0 deletions easybuild/easyconfigs/e/EasyBuild/EasyBuild-0.5.0.0beta1.eb
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
easyblock = 'EB_EasyBuildMeta'

name = 'EasyBuild'
version = '0.5.0.0beta1'

homepage = 'https://easybuild.io'
description = """EasyBuild is a software build and installation framework
written in Python that allows you to install software in a structured,
repeatable and robust way."""

toolchain = SYSTEM

sources = [
{
'filename': 'easybuild-framework-v%s.tar.gz' % version[2:],
'git_config': {
'url': 'https://github.com/easybuilders',
'repo_name': 'easybuild-framework',
'tag': 'easybuild-framework-v%s' % version[2:],
'keep_git_dir': True,
},
},
{
'filename': 'easybuild-easyblocks-v%s.tar.gz' % version[2:],
'git_config': {
'url': 'https://github.com/easybuilders',
'repo_name': 'easybuild-easyblocks',
'tag': 'easybuild-easyblocks-v%s' % version[2:],
'keep_git_dir': True,
},
},
{
'filename': 'easybuild-easyconfigs-v%s.tar.gz' % version[2:],
'git_config': {
'url': 'https://github.com/easybuilders',
'repo_name': 'easybuild-easyconfigs',
'tag': 'easybuild-easyconfigs-v%s' % version[2:],
'keep_git_dir': True,
},
},
]
checksums = [
None,
None,
None,
]

# EasyBuild is a (set of) Python packages, so it depends on Python
# usually, we want to use the system Python, so no actual Python dependency is listed
allow_system_deps = [('Python', SYS_PYTHON_VERSION)]

local_pyshortver = '.'.join(SYS_PYTHON_VERSION.split('.')[:2])

sanity_check_paths = {
'files': ['bin/eb'],
'dirs': ['lib/python%s/site-packages' % local_pyshortver],
}

moduleclass = 'tools'
24 changes: 24 additions & 0 deletions test/easyconfigs/easyconfigs.py
Original file line number Diff line number Diff line change
Expand Up @@ -1013,6 +1013,30 @@ def test_easyconfig_locations(self):
if not dirpath.endswith('/easybuild/easyconfigs'):
self.fail("There should be no easyconfig files in %s, found %s" % (dirpath, easyconfig_files))

def test_easybuild_easyconfigs_latest_release(self):
"""
Check which easyconfig file would be picked up by 'eb --install-latest-eb-release'
"""
# this mimics the logic used in the find_easybuild_easyconfig used by EasyBuild framework
# to obtain an easyconfig file when --install-latest-eb-release is used
topdir = os.path.dirname(os.path.dirname(os.path.dirname(__file__)))
easybuild_dir = os.path.join(topdir, 'easybuild', 'easyconfigs', 'e', 'EasyBuild')
ecs = os.listdir(easybuild_dir)

file_versions = []
for ec in ecs:
txt = read_file(os.path.join(easybuild_dir, ec))
for line in txt.split('\n'):
if re.search(r'^version\s*=', line):
scope = {}
exec(line, scope)
version = scope['version']
file_versions.append((LooseVersion(version), ec))

most_recent = sorted(file_versions)[-1]
self.assertEqual(most_recent[0], LooseVersion('4.9.4'))
self.assertEqual(most_recent[1], 'EasyBuild-4.9.4.eb')

def test_easyconfig_name_clashes(self):
"""Make sure there is not a name clash when all names are lowercase"""
topdir = os.path.dirname(os.path.dirname(os.path.dirname(__file__)))
Expand Down

0 comments on commit 51cd066

Please sign in to comment.