Skip to content
Snippets Groups Projects
Commit 01c7bf1b authored by Damian Alvarez's avatar Damian Alvarez
Browse files

Merge branch 'sa-CMake+Rust2023' into '2023'

{GCCcore} CMake and Rust

See merge request software-team/easybuild!1360
parents 382b78f9 f028b199
No related branches found
No related tags found
No related merge requests found
Showing
with 1691 additions and 0 deletions
name = 'bzip2'
version = '1.0.8'
homepage = 'https://sourceware.org/bzip2'
description = """
bzip2 is a freely available, patent free, high-quality data compressor. It
typically compresses files to within 10% to 15% of the best available
techniques (the PPM family of statistical compressors), whilst being around
twice as fast at compression and six times faster at decompression.
"""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
toolchainopts = {'pic': True}
source_urls = ['https://sourceware.org/pub/%(name)s/']
sources = [SOURCE_TAR_GZ]
patches = ['bzip2-%(version)s-pkgconfig.patch']
checksums = [
'ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269', # bzip2-1.0.8.tar.gz
'9299e8ee4d014ea973777b6ea90661fe329dfa991f822add4c763ea9ddb9aab1', # bzip2-1.0.8-pkgconfig.patch
]
builddependencies = [
('binutils', '2.38'),
]
moduleclass = 'tools'
#- Adds a pkgconfig/bzip2.pc file
#
# author: Jiri Furst <jiri.furst@gmail.com>
# inspired by OpenSUSE patch by Stanislav Brabec <sbrabec@suse.cz>, see
# http://ftp.suse.com/pub/people/sbrabec/bzip2/
diff -Nau bzip2-1.0.8.orig/bzip2.pc.in bzip2-1.0.6/bzip2.pc.in
--- bzip2-1.0.8.orig/bzip2.pc.in 1970-01-01 01:00:00.000000000 +0100
+++ bzip2-1.0.8/bzip2.pc.in 2019-05-01 11:47:29.795517973 +0200
@@ -0,0 +1,11 @@
+exec_prefix=${prefix}
+bindir=${exec_prefix}/bin
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
+
+Name: bzip2
+Description: Lossless, block-sorting data compression
+Version: 1.0.8
+Libs: -L${libdir} -lbz2
+Cflags: -I${includedir}
+
diff -Nau bzip2-1.0.8.orig/Makefile bzip2-1.0.6/Makefile
--- bzip2-1.0.8.orig/Makefile 2019-05-01 11:28:04.788206974 +0200
+++ bzip2-1.0.8/Makefile 2019-05-01 11:46:20.911324226 +0200
@@ -107,6 +107,9 @@
echo ".so man1/bzgrep.1" > $(PREFIX)/man/man1/bzfgrep.1
echo ".so man1/bzmore.1" > $(PREFIX)/man/man1/bzless.1
echo ".so man1/bzdiff.1" > $(PREFIX)/man/man1/bzcmp.1
+ if ( test ! -d $(PREFIX)/lib/pkgconfig ) ; then mkdir -p $(PREFIX)/lib/pkgconfig ; fi
+ echo "prefix=$(PREFIX)" > $(PREFIX)/lib/pkgconfig/bzip2.pc
+ cat bzip2.pc.in >> $(PREFIX)/lib/pkgconfig/bzip2.pc
clean:
rm -f *.o libbz2.a bzip2 bzip2recover \
name = 'CMake'
version = '3.23.1'
homepage = 'https://www.cmake.org'
description = """
CMake, the cross-platform, open-source build system. CMake is a family of
tools designed to build, test and package software.
"""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
source_urls = ['https://www.cmake.org/files/v%(version_major_minor)s']
sources = [SOURCELOWER_TAR_GZ]
checksums = ['33fd10a8ec687a4d0d5b42473f10459bb92b3ae7def2b745dc10b192760869f3']
builddependencies = [
('binutils', '2.38'),
]
dependencies = [
('ncurses', '6.3'),
('zlib', '1.2.12'),
('bzip2', '1.0.8'),
('cURL', '7.83.0'),
('libarchive', '3.6.1'),
('OpenSSL', '1.1', '', True),
]
moduleclass = 'devel'
easyblock = 'ConfigureMake'
name = 'cURL'
version = '7.83.0'
homepage = 'https://curl.haxx.se'
description = """
libcurl is a free and easy-to-use client-side URL transfer library,
supporting DICT, FILE, FTP, FTPS, Gopher, HTTP, HTTPS, IMAP, IMAPS, LDAP,
LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMTP, SMTPS, Telnet and TFTP.
libcurl supports SSL certificates, HTTP POST, HTTP PUT, FTP uploading, HTTP
form based upload, proxies, cookies, user+password authentication (Basic,
Digest, NTLM, Negotiate, Kerberos), file transfer resume, http proxy tunneling
and more.
"""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
source_urls = ['https://curl.haxx.se/download/']
sources = [SOURCELOWER_TAR_GZ]
checksums = ['c0e64302a33d2fb79e0fc4e674260a22941e92ee2f11b894bf94d32b8f5531af']
builddependencies = [
('binutils', '2.38'),
]
dependencies = [
('zlib', '1.2.12'),
('OpenSSL', '1.1', '', True),
]
configopts = '--with-zlib '
configopts += '--with-ssl=$EBROOTOPENSSL '
modextravars = {'CURL_INCLUDES': '%(installdir)s/include'}
sanity_check_paths = {
'files': ['bin/curl', 'lib/libcurl.a', 'lib/libcurl.%s' % SHLIB_EXT],
'dirs': ['lib/pkgconfig', 'include/curl'],
}
moduleclass = 'tools'
easyblock = 'ConfigureMake'
name = 'GMP'
version = '6.2.1'
homepage = 'https://gmplib.org/'
description = """
GMP is a free library for arbitrary precision arithmetic, operating on signed
integers, rational numbers, and floating point numbers.
"""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
toolchainopts = {'precise': True, 'pic': True}
source_urls = ['https://ftp.gnu.org/gnu/%(namelower)s']
sources = [SOURCELOWER_TAR_BZ2]
checksums = ['eae9326beb4158c386e39a356818031bd28f3124cf915f8c5b1dc4c7a36b4d7c']
builddependencies = [
('Autotools', '20220317'),
('binutils', '2.38'),
]
# enable C++ interface
configopts = '--enable-cxx'
# copy libgmp.so* to <installdir>/lib to make sure that it is picked up by tests
# when EasyBuild is configured with --rpath, and clean up afterwards (let 'make install' do its job)
pretestopts = "mkdir -p %%(installdir)s/lib && cp -a .libs/libgmp.%s* %%(installdir)s/lib && " % SHLIB_EXT
testopts = " && rm -r %(installdir)s/lib"
runtest = 'check'
sanity_check_paths = {
'files': ['lib/lib%s.%s' % (l, e) for l in ['gmp', 'gmpxx'] for e in [SHLIB_EXT, 'a']] +
['include/gmp.h', 'include/gmpxx.h'],
'dirs': ['share'],
}
moduleclass = 'math'
##
# Author: Robert Mijakovic <robert.mijakovic@lxp.lu>
##
# updated to 2.33.1
# J. Sassmannshausen / GSTT
easyblock = 'ConfigureMake'
name = 'git'
version = '2.36.0'
versionsuffix = '-nodocs'
homepage = 'https://git-scm.com/'
description = """Git is a free and open source distributed version control system designed
to handle everything from small to very large projects with speed and efficiency."""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
source_urls = ['https://github.com/git/git/archive']
sources = ['v%(version)s.tar.gz']
checksums = ['59dbc158dce293798570166fe7acfe225514f2868bc2d6e25c1a5a00c4ac0888']
builddependencies = [
('binutils', '2.38'),
('Autotools', '20220317'),
]
dependencies = [
('cURL', '7.83.0'),
('expat', '2.4.8'),
('gettext', '0.21'),
('Perl', '5.34.1'),
('OpenSSL', '1.1', '', True),
]
preconfigopts = 'make configure && '
# Work around git build system bug. If LIBS contains -lpthread, then configure
# will not append -lpthread to LDFLAGS, but Makefile ignores LIBS.
configopts = "--with-perl=${EBROOTPERL}/bin/perl --enable-pthreads='-lpthread'"
sanity_check_paths = {
'files': ['bin/git'],
'dirs': ['libexec/git-core', 'share'],
}
moduleclass = 'tools'
easyblock = 'ConfigureMake'
name = 'libarchive'
version = '3.6.1'
homepage = 'https://www.libarchive.org/'
description = """
Multi-format archive and compression library
"""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
source_urls = ['https://www.libarchive.org/downloads/']
sources = [SOURCE_TAR_GZ]
checksums = ['c676146577d989189940f1959d9e3980d28513d74eedfbc6b7f15ea45fe54ee2']
builddependencies = [
('binutils', '2.38'),
]
dependencies = [
('zlib', '1.2.12'),
('XZ', '5.2.5'),
('OpenSSL', '1.1', '', True),
]
sanity_check_paths = {
'files': ['include/archive.h', 'lib/libarchive.%s' % SHLIB_EXT],
'dirs': ['bin', 'share/man/man3'],
}
moduleclass = 'tools'
easyblock = 'ConfigureMake'
name = 'libffi'
version = '3.4.2'
homepage = 'https://sourceware.org/libffi/'
description = """The libffi library provides a portable, high level programming interface to
various calling conventions. This allows a programmer to call any function
specified by a call interface description at run-time."""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
toolchainopts = {'pic': True}
source_urls = ['https://github.com/libffi/libffi/releases/download/v3.4.2/']
sources = [SOURCELOWER_TAR_GZ]
checksums = ['540fb721619a6aba3bdeef7d940d8e9e0e6d2c193595bc243241b77ff9e93620']
builddependencies = [
('binutils', '2.38'),
]
configopts = '--disable-exec-static-tramp '
sanity_check_paths = {
'files': ['lib/libffi.a', 'lib/libffi.%s' % SHLIB_EXT],
'dirs': ['include', 'share'],
}
moduleclass = 'lib'
easyblock = 'ConfigureMake'
name = 'Rust'
version = '1.60.0'
homepage = 'https://www.rust-lang.org'
description = """Rust is a systems programming language that runs blazingly fast, prevents segfaults,
and guarantees thread safety."""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
source_urls = ['https://static.rust-lang.org/dist/']
sources = ['rustc-%(version)s-src.tar.gz']
patches = ['Rust-1.60_sysroot-fix-interpreter.patch']
checksums = [
'20ca826d1cf674daf8e22c4f8c4b9743af07973211c839b85839742314c838b7', # rustc-1.60.0-src.tar.gz
'b59ed4c2591fc9098277299be21dd6752654f6f193d8652b7d21cb0fa0dd8716', # Rust-1.60_sysroot-fix-interpreter.patch
]
builddependencies = [
('binutils', '2.38'),
('CMake', '3.23.1'),
('Python', '3.10.4', '-bare'),
('pkgconf', '1.8.0'),
]
dependencies = [
('OpenSSL', '1.1', '', True),
]
configopts = "--enable-extended --sysconfdir=%(installdir)s/etc "
# avoid build dependency on Ninja, which requires Python,
# since Rust is a build dependency for cryptography that is included with Python
configopts += "--set=llvm.ninja=false "
# Use ./x.py to bootstrap so that options like -j N are correctly passed through
# see: https://rustc-dev-guide.rust-lang.org/building/how-to-build-and-run.html#what-is-xpy
# (ConfigureMake already adds `-j %(parallel)s` to the `build_cmd`)
build_cmd = "./x.py build"
install_cmd = "./x.py install -j %(parallel)s"
# avoid failure when home directory is an NFS mount,
# see https://github.com/rust-lang/cargo/issues/6652
prebuildopts = "export CARGO_HOME=%(builddir)s/cargo && "
preinstallopts = prebuildopts
sanity_check_paths = {
'files': ['bin/cargo', 'bin/rustc', 'bin/rustdoc'],
'dirs': ['lib/rustlib', 'share/doc', 'share/man'],
}
sanity_check_commands = [
"cargo --version",
"rustc --version",
]
moduleclass = 'lang'
Use patchelf to fix interpreter of binaries that are used during Rust bootstrap procedure
when EasyBuild is configured to build in an alternate sysroot
This fixes problems like due to a clash with the interpreter from the host, and a more recent libc.so.6 that's picked up
from the alternate sysroot:
error: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by /tmp/easybuild/build/Rust/1.52.1/GCCcore-10.3.0/rustc-1.52.1-src/build/bootstrap/debug/deps/libproc_macro_error_attr-fbfef320d848b049.so)
author: Kenneth Hoste (HPC-UGent)
--- rustc-1.60.0-src/src/bootstrap/bootstrap.py.orig 2022-06-01 16:35:37.111817747 +0200
+++ rustc-1.60.0-src/src/bootstrap/bootstrap.py 2022-06-01 16:40:27.769571474 +0200
@@ -671,6 +671,18 @@
if ostype != "Linux":
return
+ sysroot = os.getenv("EASYBUILD_SYSROOT")
+ if sysroot and not fname.endswith(".so"):
+ # determine patch to interpreter in host via output produced by 'file -b /bin/bash'
+ readelf_out = subprocess.check_output(['readelf', '-l', '/bin/bash']).decode('ascii', 'ignore').strip()
+ regex = re.compile('.*program interpreter: ([^\]]+)', re.M)
+ res = regex.search(readelf_out)
+ interpreter_path = os.path.join(sysroot, res.group(1).lstrip('/'))
+ if not os.path.exists(interpreter_path):
+ raise Exception("Derived path to interpreter does not exist: %s" % interpreter_path)
+ cmd = ["patchelf", "--set-interpreter", interpreter_path, fname]
+ run(cmd, verbose=True)
+
# If the user has asked binaries to be patched for Nix, then
# don't check for NixOS or `/lib`, just continue to the patching.
if self.get_toml('patch-binaries-for-nix', 'build') != 'true':
easyblock = 'ConfigureMake'
name = 'SQLite'
version = '3.38.3'
local_filename_version = '3380300'
homepage = 'https://www.sqlite.org/'
description = "SQLite: SQL Database Engine in a C Library"
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
toolchainopts = {'pic': True}
source_urls = ['https://www.sqlite.org/2022/']
sources = ['%%(namelower)s-autoconf-%s.tar.gz' % (local_filename_version)]
checksums = ['61f2dd93a2e38c33468b7125967c3218bf9f4dd8365def6025e314f905dc942e']
builddependencies = [
('binutils', '2.38'),
]
dependencies = [
('libreadline', '8.1.2'),
('Tcl', '8.6.12'),
]
# enable additional APIs that provide access to meta-data about tables and queries
# needed for GDAL when it used as a dep for QGIS
buildopts = 'CC="$CC" CFLAGS="$CFLAGS -DSQLITE_ENABLE_COLUMN_METADATA"'
sanity_check_paths = {
'files': ['bin/sqlite3', 'include/sqlite3ext.h', 'include/sqlite3.h',
'lib/libsqlite3.a', 'lib/libsqlite3.%s' % SHLIB_EXT],
'dirs': ['lib/pkgconfig'],
}
sanity_check_commands = [
'sqlite3 --version | grep ^%(version)s',
]
moduleclass = 'devel'
easyblock = 'ConfigureMake'
name = 'Tcl'
version = '8.6.12'
homepage = 'https://www.tcl.tk/'
description = """
Tcl (Tool Command Language) is a very powerful but easy to learn dynamic
programming language, suitable for a very wide range of uses, including web
and desktop applications, networking, administration, testing and many more.
"""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
source_urls = ['http://prdownloads.sourceforge.net/%(namelower)s']
sources = ['%(namelower)s%(version)s-src.tar.gz']
checksums = ['26c995dd0f167e48b11961d891ee555f680c175f7173ff8cb829f4ebcde4c1a6']
builddependencies = [
('binutils', '2.38'),
]
dependencies = [
('zlib', '1.2.12'),
]
configopts = '--enable-threads EXTRA_INSTALL="install-private-headers"'
runtest = 'test'
start_dir = 'unix'
postinstallcmds = ['ln -s %(installdir)s/bin/tclsh%(version_major)s.%(version_minor)s %(installdir)s/bin/tclsh']
sanity_check_paths = {
'files': ['bin/tclsh%(version_major)s.%(version_minor)s', 'bin/tclsh',
'include/tcl.h', 'lib/libtcl%%(version_major)s.%%(version_minor)s.%s' % SHLIB_EXT,
'lib/tclConfig.sh', 'man/man1/tclsh.1'],
'dirs': ['share'],
}
moduleclass = 'lang'
easyblock = 'ConfigureMake'
name = 'UnZip'
version = '6.0'
homepage = 'http://www.info-zip.org/UnZip.html'
description = """UnZip is an extraction utility for archives compressed
in .zip format (also called "zipfiles"). Although highly compatible both
with PKWARE's PKZIP and PKUNZIP utilities for MS-DOS and with Info-ZIP's
own Zip program, our primary objectives have been portability and
non-MSDOS functionality."""
toolchain = {'name': 'GCCcore', 'version': '11.3.0'}
source_urls = ['https://download.sourceforge.net/infozip']
sources = ['%(namelower)s%(version_major)s%(version_minor)s.tar.gz']
patches = [
'UnZip-%(version)s_various-security-and-other-fixes-from-Ubuntu.patch',
]
checksums = [
'036d96991646d0449ed0aa952e4fbe21b476ce994abc276e49d30e686708bd37', # unzip60.tar.gz
# UnZip-6.0_various-security-and-other-fixes-from-Ubuntu.patch
'06b9307fd5aa018896bd4126818c00c1fd284a06cc3681cf0492f951ebb57ffe',
]
builddependencies = [
('binutils', '2.38'),
]
dependencies = [
('bzip2', '1.0.8'),
]
skipsteps = ['configure']
buildopts = '-f unix/Makefile CC="$CC" D_USE_BZ2=-DUSE_BZIP2 L_BZ2=-lbz2 '
buildopts += 'LF2="$LDFLAGS" '
# Note: CF is multiple lines
buildopts += 'CF="$CFLAGS $CPPFLAGS -I. -DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT '
buildopts += '-DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD '
buildopts += '-DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DIZ_HAVE_UXUIDGID -DNOMEMCPY -DNO_WORKING_ISPRINT" unzips '
installopts = '-f unix/Makefile prefix=%(installdir)s '
sanity_check_paths = {
'files': ['bin/unzip', 'bin/zipinfo'],
'dirs': ['man/man1']
}
sanity_check_commands = ["unzip -v"]
moduleclass = 'tools'
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment