Skip to content

[syslibs] [package list]

syslibs/15.1.1-static (syslibs-15.1.1-static.eb)

This software is archived in the LUMI-SoftwareStack GitHub repository as easybuild/easyconfigs/__archive__/s/syslibs/syslibs-15.1.1-static.eb. The corresponding module would be syslibs/15.1.1-static.

easyblock = 'Bundle'

name =          'syslibs'
version =       '15.1.1'
versionsuffix = '-static'

import os as local_os

# The first line below is a dirty trick not very much loved by the EasyBuild developers but
# it helps to make this EasyConfig indpendent of the LUMI software stack version as there is
# no other reference to that version in the file that we can use since it relies on the
# SYSTEM toolchain.
local_LUMI_version = local_os.environ['LUMI_STACK_CPE_VERSION']

homepage = '(none)'

# We list all libraries in a whatis line so that they can be found by module keyword.
# Contrary to what the LMOD documentation makes you believe, it seems that help is
# not searched when using module keyword.
whatis = [
    "Description: A number of libraries that are mostly also on the system but as static libraries to be used as build dependencies.",
    "Contains: ncurses/ncursesw, readline, bzip2, zlib, lz4, expat, APR/APR-util, file, PCRE2, SQLite3",
]

local_SUSE_ncurses_version =      '6.1'           # https://ftp.gnu.org/pub/gnu/ncurses/
local_SUSE_libreadline_version =  '7.0'           # https://ftp.gnu.org/pub/gnu/readline/
local_SUSE_bzip2_version =        '1.0.8'         # http://www.bzip.org/downloads.html
local_SUSE_zlib_version =         '1.2.11'        # https://zlib.net/
local_SUSE_lz4_version =          '1.9.3'         # https://github.com/lz4/lz4/releases
local_SUSE_expat_version =        '2.4.1'         # https://github.com/libexpat/libexpat/releases
local_SUSE_APR_version =          '1.7.0'         # http://apr.apache.org/
local_SUSE_APR_util_version =     '1.6.1'         # http://apr.apache.org/
local_SUSE_file_version =         '5.32'          # http://ftp.astron.com/pub/file/
local_SUSE_PCRE2_version =        '10.31'         # https://ftp.pcre.org/pub/pcre/
local_SUSE_Serf_version =         '1.3.9'         # http://serf.apache.org/
local_SUSE_SQLite3_version =      '3.36.0'        # http://www.sqlite.org/
local_SQLite3_filename_version =  '3360000'

description = """
This module provides a number of libraries that are mostly also found on the
system but as static libraries meant to be used as build dependencies for a
number of tools that should not introduce dependencies when being used so that
their impact on other software remains minimal.

Versions often correspond to those on LUMI with the OS release equal to the
manjor and minor version number of this module.

Overview of included libraries:

* Terminal I/O
  + ncurses (version %(ncurses)s): The Ncurses (new curses) library is a free software
    emulation of curses in System V Release 4.0, and more. It uses Terminfo
    format, supports pads and color and multiple highlights and forms characters
    and function-key mapping, and has all the other SYSV-curses enhancements
    over BSD Curses.
    Documentation is available through man pages in sections 3, 5 and 7.
  + libreadline (version %(libreadline)s): The GNU Readline library provides a set of
    functions for use by applications that allow users to edit command lines as
    they are typed in. Both Emacs and vi editing modes are available.
    The Readline library includes additional functions to maintain a list of
    previously-entered command lines, to recall and perhaps reedit those lines,
    and perform csh-like history expansion on previous commands.
    There are manual pages for readline and history and help via info.
* File compression tools and libraries
  + bzip2 (version %(bzip2)s): Patent-free high-quailty data compressor
    with very good compression yet fast compression and decompression
    (.bz2 files)
  + zlib (version %(zlib)s): Free lossless data compression library, not
    covered by any patents, for the popular .gz files.
  + lz4 (version %(lz4)s): LZ4 is lossless compression algorithm, providing compression
    speed at 400 MB/s per core. It features an extremely fast decoder, with
    speed in multiple GB/s per core.
* Networking, security and XML
  + expat (version %(expat)s): Expat is an XML parser library written in C.
    It is a stream-oriented parser in which an application registers handlers
    for things the parser might find in the XML document (like start tags).
    It provides the command line tool xmlwf and static and shared libraries.
* Miscellaneous
  + APR (version %(APR)s) and APR-util (version %(APR_util)s): Apache Portable
    Runtime and its util libraries.

    The mission of the Apache Portable Runtime (APR) project is to create and
    maintain software libraries that provide a predictable and consistent
    interface to underlying platform-specific implementations. The primary goal
    is to provide an API to which software developers may code and be assured
    of predictable if not identical behaviour regardless of the platform on
    which their software is built, relieving them of the need to code
    special-case conditions to work around or take advantage of platform-specific
    deficiencies or features.
  + file (version %(filev)s): The file command is "a file type guesser", that
    is, a command-line tool that tells you in words what kind of data a file
    contains. Unlike most GUI systems, command-line UNIX systems - with this
    program leading the charge - don't rely on filename extentions to tell you
    the type of a file, but look at the file's actual contents. This is, of
    course, more reliable, but requires a bit of I/O.This is a
    re-implementation of the original file command shipped with Bell Labs UNIX.
  + PCRE2 (version %(PCRE2)s: More modern version of PCRE.
    The package includes the command line tools pcre2grep, pcre2test and
    pcre2-config, documented through man pages. API documentation is available
    through man pcre2.
  + Serf (version %(Serf)s): The serf library is a high performance C-based HTTP client library
    built upon the Apache Portable Runtime (APR) library.

    Key features are:
      * multiplexed, asynchronous connections
      * SSL/TLS support
      * full HTTP pipelining
      * multiple authentication modes (Basic, Digest, Kerberos/NTLM)
      * zero-copy support for increased throughput

    Its main uses are in other Apache software such as subversion and Open
    Office.

    The Serf library is permissively licensed under the Apache License, v2.
  + SQLite3 (version %(SQLite3)s): SQLite is a C-language library that implements a small, fast, self-contained,
    high-reliability, full-featured, SQL database engine. SQLite is the most used
    database engine in the world. SQLite is built into all mobile phones and most
    computers and comes bundled inside countless other applications that people
    use every day. More Information...

    The SQLite file format is stable, cross-platform, and backwards compatible and
    the developers pledge to keep it that way through the year 2050. SQLite database
    files are commonly used as containers to transfer rich content between systems
    and as a long-term archival format for data. There are over 1 trillion (1e12)
    SQLite databases in active use.

    SQLite source code is in the public-domain and is free to everyone to use for
    any purpose.

    NOTE: This is not a full-featured build but serves to build svn
""" % {
    'ncurses':      local_SUSE_ncurses_version,
    'libreadline':  local_SUSE_libreadline_version,
    'bzip2':        local_SUSE_bzip2_version,
    'zlib':         local_SUSE_zlib_version,
    'lz4':          local_SUSE_lz4_version,
    'expat':        local_SUSE_expat_version,
    'APR':          local_SUSE_APR_version,
    'APR_util':     local_SUSE_APR_util_version,
    'filev':        local_SUSE_file_version,
    'PCRE2':        local_SUSE_PCRE2_version,
    'Serf':         local_SUSE_Serf_version,
    'SQLite3':      local_SUSE_SQLite3_version,
}

docurls = [
    'ncurses:       Web-based documentation on https://www.gnu.org/software/ncurses/',
    'libreadline:   Web-based readline user interface documentation: https://tiswww.cwru.edu/php/chet/readline/rluserman.html',
    'libreadline:   Web-based libreadline documentation: https://tiswww.cwru.edu/php/chet/readline/readline.html',
    'libreadline:   Web-based libhistory documentation: https://tiswww.cwru.edu/php/chet/readline/history.html',
    'bzip2:         Web-based documentation on http://www.bzip.org/docs.html',
    'zlib:          Web-based manual on https://zlib.net/manual.html',
    'lz4:           Manual page for the lz4 command in section 1',
    'expat:         Web-based documentation: https://libexpat.github.io/doc/',
    'expat:         Man page for xmlwf',
    'file:          Home page is https://www.darwinsys.com/file/',
    'PCRE2:         Web-based documentation: http://www.pcre.org/current/doc/html/',
    'PCRE2:         Manual pages in section 1 (pcre2grep, pcre2test) and 3 (API, start with pcre2)',
    'SQLite3:       Manual page for the sqlite3 command in section 1',
]

local_SUSE_bzip2_major_minor = '.'.join(local_SUSE_bzip2_version.split('.')[:2])

toolchain = SYSTEM

builddependencies = [
    ('buildtools', local_LUMI_version),   # Needed for Serf, useful for the rest.
]

default_easyblock = 'ConfigureMake'

components = [
#
# Terminal libraries
#
    ('ncurses', local_SUSE_ncurses_version, {
        'sources':       [ {
                            'filename':    SOURCE_TAR_GZ,
                            'source_urls': [GNU_SOURCE]
                         } ],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'CFLAGS="-O2 -march=znver1 -fPIC" CXXFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--without-shared --with-normal --with-termlib --with-ticlib  --enable-overwrite' +
                         '--without-ada --enable-symlinks --with-versioned-syms ' +
                         '--enable-pc-files --with-pkg-config-libdir=%(installdir)s/lib/pkgconfig ', # First build: default build.
    }),
    ('ncurses', local_SUSE_ncurses_version, {
        'sources':       [ {
                            'filename':    SOURCE_TAR_GZ,
                            'source_urls': [GNU_SOURCE]
                         } ],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'make distclean && CFLAGS="-O2 -march=znver1 -fPIC" CXXFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--without-shared --with-normal --with-termlib --with-ticlib --enable-overwrite ' +
                         '--without-ada --enable-symlinks --with-versioned-syms ' +
                         '--enable-pc-files --with-pkg-config-libdir=%(installdir)s/lib/pkgconfig ' +
                         '--enable-ext-colors --enable-widec --includedir=%(installdir)s/include/ncursesw/', # Second build: the UTF-8 enabled version (ncursesw)
        'installopts':   ' && cd %(installdir)s && /bin/rm -rf bin lib/*.so*'
    }),
    ('libreadline', local_SUSE_libreadline_version, {
        'sources':       [ {
                            'filename':    'readline-%(version)s.tar.gz',
                            'source_urls': ['http://ftp.gnu.org/gnu/readline']
                         }],
        'start_dir':     'readline-%(version)s',
        'preconfigopts': "LD_LIBRARY_PATH=%(installdir)s/lib:$LD_LIBRARY_PATH LDFLAGS='-L%(installdir)s/lib -lncurses' " +
                         "CFLAGS='-O2 -march=znver1 -fPIC' CXXFLAGS='-O2 -march=znver1 -fPIC' ",
        'configopts':    '--enable-static --disable-shared',
        'buildopts':     "SHLIB_LIBS='-lncurses'",
    }),
    ('bzip2', local_SUSE_bzip2_version, {
        'easyblock':   'ConfigureMake',
        # The bzip2 EasyBlock does not work in a bundle since there is a problem with with_shared_libs
        # https://sourceforge.net/projects/bzip2/files/bzip2-1.0.6.tar.gz/download
        'sources':     [ {
                          'filename':    SOURCE_TAR_GZ,
                          'source_urls': ['https://sourceware.org/pub/%(name)s/']
                       } ],
        'patches':     ['bzip2-%(version)s-pkgconfig.patch'],
        'start_dir':   '%(namelower)s-%(version)s',
        'skipsteps':   ['configure'],
        'buildopts':   'CC="$CC" CFLAGS="-Wall -Winline -O2 -march=znver1 -fPIC -g \$(BIGFILES)"',
        'installopts': 'PREFIX="%(installdir)s" ',
    }),
    ('zlib', local_SUSE_zlib_version, {
        'sources':       [ {
                            # https://www.zlib.net/zlib-1.2.11.tar.gz
                            'filename':    SOURCELOWER_TAR_GZ,
                            'source_urls': ['https://www.zlib.net/']
                         } ],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'CFLAGS="-O2 -march=znver1 -fPIC" CXXFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--static'
    }),
    ('lz4', local_SUSE_lz4_version, {
        # The bzip2 EasyBlock does not work in a bundle since there is a problem with with_shared_libs
        # https://sourceforge.net/projects/bzip2/files/bzip2-1.0.6.tar.gz/download
        'sources':     [ {
                          'download_filename': 'v%(version)s.tar.gz',
                          'filename':          SOURCELOWER_TAR_GZ,
                          'source_urls':       ['https://github.com/lz4/lz4/archive/']
                       } ],
        'start_dir':   '%(namelower)s-%(version)s',
        'skipsteps':   ['configure'],
        'buildopts':   'BUILD_STATIC="yes" BUILD_SHARED="no" CFLAGS="-O3 -march=znver1 -fPIC" ',
        'runtest':     'check',
        'installopts': 'PREFIX=%(installdir)s BUILD_STATIC="yes" BUILD_SHARED="no"',
    }),
    ('expat', local_SUSE_expat_version, {
        'sources':       [ {
                            'filename':    SOURCELOWER_TAR_BZ2,
                            'source_urls': [SOURCEFORGE_SOURCE]
                         }],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'CFLAGS="-O2 -march=znver1 -fPIC" CXXFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--enable-static --disable-shared'
    }),
    ('APR', local_SUSE_APR_version, {
        'sources':       [ {
                            'filename':    SOURCELOWER_TAR_BZ2,
                            'source_urls': ['https://downloads.apache.org/apr']
                         }],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'CC="gcc" CFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--enable-static --disable-shared'
    }),
    ('APR-util', local_SUSE_APR_util_version, {
        'sources':       [ {
                            'filename':    SOURCELOWER_TAR_BZ2,
                            'source_urls': ['https://downloads.apache.org/apr']
                         }],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'CC="gcc" CFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--with-apr=%(installdir)s/bin/apr-1-config --enable-static --disable-shared',
        'installopts':   ' && cd %(installdir)s/lib/pkgconfig && sed -i -e "s|-lexpat|-L%(installdir)s/lib -lexpat|" apr-util-1.pc' +
                         ' && cd %(installdir)s/bin           && sed -i -e "s|-lexpat|-L%(installdir)s/lib -lexpat|" apu-1-config'

    }),
    ('Serf', local_SUSE_Serf_version, {
        'easyblock':     'SCons',
        'sources':       [ {
                            'filename':    SOURCELOWER_TAR_BZ2,
                            'source_urls': ['https://archive.apache.org/dist/%(namelower)s']
                         }],
        'patches':       ['Serf-%(version)s_python3_scons.patch'],
        'start_dir':     '%(namelower)s-%(version)s',
        'buildopts':     'APR=%(installdir)s/bin/apr-1-config APU=%(installdir)s/bin/apu-1-config APR_STATIC=True ' +
                         'ZLIB=%(installdir)s ' +
                         'CFLAGS="-O3 -march=znver1 -fPIC -Wno-pointer-sign" ',
        'installopts':   ' && cd %(installdir)s/lib && /bin/rm *.so*'
    }),
    ('file', local_SUSE_file_version, {
        'sources':       [ {
                            'filename':    SOURCE_TAR_GZ,
                            'source_urls': ['http://ftp.astron.com/pub/file/']
                         } ],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'CFLAGS="-O2 -march=znver1 -fPIC" CXXFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--enable-static --disable-shared'
    }),
    ('PCRE2', local_SUSE_PCRE2_version, {
        'sources':       [ {
                            'filename':    SOURCELOWER_TAR_BZ2,
                            'source_urls': ['https://ftp.pcre.org/pub/pcre/']
                         } ],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'CFLAGS="-O2 -march=znver1 -fPIC" CXXFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--with-pic --disable-cpp --enable-newline-is-any ' + \
                         '--enable-pcre2-16 --enable-pcre2-32 --enable-jit ' + \
                         '--enable-pcre2grep-libz --enable-pcre2grep-libbz2 --enable-pcre2test-libreadline ' + \
                         '--disable-shared --enable-static '
    }),
    ('SQLite3', local_SUSE_SQLite3_version, {
        'sources':       [ {
                            'filename':    'sqlite-autoconf-%s.tar.gz' % local_SQLite3_filename_version,
                            'source_urls': ['https://www.sqlite.org/2021']
                         } ],
        'start_dir':     'sqlite-autoconf-' + local_SQLite3_filename_version,
        'preconfigopts': 'CC="gcc" CFLAGS="-O2 -march=znver1 -fPIC" ',
        'configopts':    '--enable-static --disable-shared',
        'parallel':      1,
    }),
]

sanity_check_paths = {
    'files': # ncurses
             ['lib/lib%s%s.a' % (x, y) for x in ["form", "menu", "ncurses", "panel"] for y in ['', '_g', 'w', 'w_g']] +
             ['lib/libncurses++%s.a' % x for x in ['', 'w']] +
             ['lib/pkgconfig/%s%s.pc' % (x, y) for x in ['form', 'menu', 'ncurses', 'ncurses++', 'panel'] for y in ['', 'w']] +
             # libreadline
             ['lib/libreadline.a', 'lib/libhistory.a'] +
             ['include/readline/%s' % x
              for x in ['chardefs.h', 'history.h', 'keymaps.h', 'readline.h',
                        'rlconf.h', 'rlstdc.h', 'rltypedefs.h', 'tilde.h']] +
             # bzip2 libraries
             ['lib/libbz2.a', 'lib/pkgconfig/bzip2.pc', 'include/bzlib.h'] +
             # zlib
             ['include/zconf.h', 'include/zlib.h', 'lib/libz.a', 'lib/pkgconfig/zlib.pc'] +
             # lz4
             ["bin/lz4", "lib/liblz4.a", "include/lz4.h"] +
             # expat
             ['bin/xmlwf', 'include/expat.h', 'lib/libexpat.a', 'lib/pkgconfig/expat.pc'] +
             ['bin/file', 'lib/libmagic.a', 'lib/libmagic.la', 'include/magic.h'] +
             ['share/man/man1/file.1', 'share/man/man3/libmagic.3', 'share/man/man4/magic.4'] +
             # APR
             ["bin/apr-1-config", "lib/libapr-1.a"] +
             # APR-util
             ["bin/apu-1-config", "lib/libaprutil-1.a"] +
             # Serf
             ['include/serf-1/serf.h', 'lib/libserf-1.a'] +
             # PCRE2
             ['bin/%s' %x for x in ['pcre2-config', 'pcre2grep', 'pcre2test']] +
             ['share/man/man1/%s.1' % x for x in ['pcre2-config', 'pcre2grep', 'pcre2test']] +
             ['lib/libpcre2-%s.%s' % (x,y) for x in ['posix', '8', '16', '32'] for y in ['a', 'la']] +
             ['lib/pkgconfig/libpcre2-%s.pc' % x for x in ['posix', '8', '16', '32']] +
             ['include/pcre2.h', 'include/pcre2posix.h'] +
             # SQLite3
             ['bin/sqlite3', 'include/sqlite3ext.h', 'include/sqlite3.h', 'lib/libsqlite3.a'],
    'dirs':  # ncurses
             ['include/ncursesw'] +
             # lz4
             ['lib/pkgconfig'] +
             # expat
             ['lib/cmake/expat-%s' % local_SUSE_expat_version] +
             # APR
             ["include/apr-1"]
}

sanity_check_commands = [
    # ncurses
    'pkg-config --libs %s%s' % (x, y) for x in ['form', 'menu', 'ncurses', 'ncurses++', 'panel'] for y in ['', 'w'] ] + [
    # bzip2
    'pkg-config --libs bzip2'] + [
    # zlib
    'pkg-config --libs zlib'] + [
    # lz4
    'lz4 --version',
    'unlz4 --version',
    'pkg-config --libs liblz4' ] + [
    # expat
    'xmlwf -h',
    'pkg-config --libs expat'] + [
    # APR
    'apr-1-config --help',
    'pkg-config --libs apr-1' ] + [
    # APR-util
    'apu-1-config --help',
    'pkg-config --libs apr-util-1' ] + [
    # Serf
    'pkg-config --libs serf-1' ] + [
    # file
    'file --version' ] + [
    # PCRE2
    '%s --version' % x for x in ['pcre2-config', 'pcre2grep', 'pcre2test']] + [
    'pkg-config --libs libpcre2-%s' % x for x in ['posix', '8', '16', '32']] + [
    # SQLite3
    'sqlite3 -version',
    'pkg-config --libs sqlite3' ]

modextravars = {
# Bad idea to add the variables below as they confuse get_software_libdir
# in some EasyBlocks. It will be very tricy to only add those that
# we need for certain packages and avoid others...
#    # For increased compatibility with standard EasyBuild recipes
    'EBROOTNCURSES':                '%(installdir)s',
    'EBVERSIONNCURSES':             local_SUSE_ncurses_version,
    'EBROOTLIBREADLINE':            '%(installdir)s',
    'EBVERSIONLIBREADLINE':         local_SUSE_libreadline_version,
    'EBROOTBZIP2':                  '%(installdir)s',
    'EBVERSIONBZIP2':               local_SUSE_bzip2_version,
    'EBROOTZLIB':                   '%(installdir)s',
    'EBVERSIONZLIB':                local_SUSE_zlib_version,
    'EBROOTLZ4':                    '%(installdir)s',
    'EBVERSIONLZ4':                 local_SUSE_zlib_version,
    'EBROOTEXPAT':                  '%(installdir)s',
    'EBVERSIONEXPAT':               local_SUSE_expat_version,
    'EBROOTAPR':                    '%(installdir)s',
    'EBVERSIONAPR':                 local_SUSE_APR_version,
    'EBROOTAPRMINUTIL':             '%(installdir)s',
    'EBVERSIONAPRMINUTIL':          local_SUSE_APR_util_version,
    'EBROOTFILE':                   '%(installdir)s',
    'EBVERSIONFILE':                local_SUSE_file_version,
    'EBROOTPCRE2':                  '%(installdir)s',
    'EBVERSIONPCRE2':               local_SUSE_PCRE2_version,
    'EBROOTSQLITE3':                '%(installdir)s',
    'EBVERSIONSQLITE3':             local_SUSE_SQLite3_version,
}

moduleclass = 'lib'

[syslibs] [package list]