Skip to content

[systools] [package list]

systools/23.12 (systools-23.12.eb)

To access module help and find out for which stacks and partitions the module is installed, use module spider systools/23.12.

EasyConfig:

easyblock = 'Bundle'

local_LUMI_version =        '23.12'

name =     'systools'
version =  local_LUMI_version

homepage = '(none)'

whatis = [
    "Description: A number of small and popular tools that just make life easier.",
    "Contains: gpp, htop, tree, proot",
]

local_systools_GPP_version =          '2.28'
local_systools_htop_version =         '3.3.0'
local_systools_libtree_version =      '3.1.1'
local_systools_tree_version =         '2.1.1'        # https://gitlab.com/OldManProgrammer/unix-tree/-/tags
local_systools_PRoot_version =        '5.4.0'        # https://github.com/proot-me/proot/releases

description = f"""
This module provides a number of popular tools to view and manage Linux processes
or files or to process files.

Overview of included tools:

  + gpp (version {local_systools_GPP_version}: a general-purpose preprocessor with customizable syntax, suitable for a
    wide range of preprocessing tasks. Its independence from any one programming
    language makes it much more versatile than the C preprocessor (cpp), while its
    syntax is lighter and more flexible than that of GNU m4. There are built-in
    macros for use with C/C++, LaTeX, HTML, XHTML, and Prolog files.

    GPP is Free Software. It is distributed under the terms of the GNU Lesser
    General Public Licence.

  + libtree (version {local_systools_libtree_version}) is a tool that turns ldd into a tree, explains why
    shared libraries are found and why not and optionally deploys executables and
    dependencies into a single directory.

  + tree (version {local_systools_tree_version}): a recursive directory listing command that produces a depth indented
    listing of files, which is colorized ala dircolors if the LS_COLORS environment
    variable is set and output is to tty.

  + PRoot (version {local_systools_PRoot_version}) is a user-space implementation of chroot, mount --bind, and 
    binfmt_misc. This means that users don't need any privileges or setup to do 
    things like using an arbitrary directory as the new root filesystem, making 
    files accessible somewhere else in the filesystem hierarchy, or executing 
    programs built for another CPU architecture transparently through QEMU 
    user-mode.

    It is provided in this module mainly for use with singularity.
"""

docurls = [
    'GPP:  Web-based documentation on: https://files.nothingisreal.com/software/gpp/gpp.html',
    'GPP:  Man page in section 1 (man 1 gpp)',
    #'htop: Man page in section 1 (man 1 htop)',
    'libtree: Man page in section 1 (man 1 libtree)',
    'tree: Man page in section 1 (man 1 tree)',
    'PRoot: Web-based documentation on: https://proot-me.github.io/',
]

toolchain = SYSTEM

dependencies = [
    ('buildtools', local_LUMI_version),
    ('syslibs',    local_LUMI_version, '-static'), # for libreadline
]


default_easyblock = 'ConfigureMake'

components = [
    ('GPP', local_systools_GPP_version, {
        'sources':       [ {
                            'filename':    SOURCELOWER_TAR_BZ2,
                            'source_urls': ['https://github.com/logological/gpp/releases/download/%(version)s']
                         }],
        'checksums':     ['343d33d562e2492ca9b51ff2cc4b06968a17a85fdc59d5d4e78eed3b1d854b70'],
        'start_dir':     '%(namelower)s-%(version)s',
        'preconfigopts': 'CFLAGS="-O2 -march=znver1" CXXFLAGS="-O2 -march=znver1" ',
        'installopts':   ' && mkdir -p %(installdir)s/share/licenses/%(name)s' +
                         ' && cp COPYING COPYING.LESSER NEWS THANKS %(installdir)s/share/licenses/%(name)s'
    }),
    #('htop', local_systools_htop_version, {
    #    'sources':       [ {
    #                        'download_filename': '%(version)s.tar.gz',
    #                        'filename':          SOURCE_TAR_GZ,
    #                        'source_urls':       ['https://github.com/htop-dev/htop/archive/refs/tags']
    #                     }],
    #    'checksums':     ['1e5cc328eee2bd1acff89f860e3179ea24b85df3ac483433f92a29977b14b045'],
    #    'start_dir':     '%(name)s-%(version)s',
    #    'preconfigopts': './autogen.sh && LDFLAGS="-L$EBROOTSYSLIBS/lib" LIBS="$LIBS -ltinfo" CFLAGS="-O2 -march=znver1" CXXFLAGS="-O2 -march=znver1" ',
    #    # Core dumps when compiled with unicode support, there must be something wrong in
    #    # our ncursesw library.
    #    'configopts':    '--disable-unicode',
    #    'installopts':   ' && mkdir -p %(installdir)s/share/licenses/%(name)s' +
    #                     ' && cp COPYING %(installdir)s/share/licenses/%(name)s'
    #}),
    ('libtree', local_systools_libtree_version, {
        'easyblock':     'MakeCp',
        'sources':       [ { # https://github.com/haampie/libtree/archive/refs/tags/v3.1.1.tar.gz
                            'download_filename': 'v%(version)s.tar.gz',
                            'filename':          '%(name)s-%(version)s.tar.gz',
                            'source_urls':       ['https://github.com/haampie/libtree/archive/refs/tags']
                         }],
        'checksums':     ['6148436f54296945d22420254dd78e1829d60124bb2f5b9881320a6550f73f5c'],
        'start_dir':     '%(name)s-%(version)s',
        'buildopts':     'CC="gcc" CFLAGS="-O2 -march=znver1" LDFLAGS="-static"',
        'files_to_copy': [(['libtree'], 'bin'), (['doc/libtree.1'], 'share/man/man1'), (['LICENSE'], 'share/licenses/%(name)s')]
    }),
    ('tree', local_systools_tree_version, {
        'easyblock':     'MakeCp',
        'sources':       [ { # https://gitlab.com/OldManProgrammer/unix-tree/-/archive/2.1.1/unix-tree-2.1.1.tar.bz2
                            'filename':    'unix-tree-%(version)s.tgz',
                            'source_urls': ['https://gitlab.com/OldManProgrammer/unix-tree/-/archive/%(version)s']
                         }],
        'checksums':     ['bcd2a0327ad40592a9c43e09a4d2ef834e6f17aa9a59012a5fb1007950b5eced'],
        'start_dir':     'unix-tree-%(version)s',
        'buildopts':     'CC="gcc" CFLAGS="-O2 -march=znver1 -ggdb -pedantic -Wall -DLINUX -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64"',
        'files_to_copy': [(['tree'], 'bin'), (['doc/tree.1'], 'share/man/man1'), (['LICENSE'], 'share/licenses/%(name)s')]
    }),
    ('PRoot', local_systools_PRoot_version, {
        'sources':       [ { # https://github.com/haampie/libtree/archive/refs/tags/v3.1.1.tar.gz
                            'download_filename': 'v%(version)s.zip',
                            'filename':          SOURCELOWER_ZIP,
                            'source_urls':       ['https://github.com/proot-me/proot/archive/refs/tags']
                         }],
        'checksums':     ['8812f3a6c224bdd6a316f13689377e7543e7e3cebcdef6ec98827abee60fa327'],
        'start_dir':     '%(namelower)s-%(version)s/src',
        'skipsteps':     [ 'configure' ],
        'prebuildopts':  'sed -e "s/.*GIT_.*//" -i GNUmakefile && ',
        'buildopts':     'proot V=1 CFLAGS="-O2 -march=znver1" VERSION="%(version)s"',
        'installopts':   'V=1 PREFIX="%(installdir)s"' +
                         ' && mkdir -p %(installdir)s/share/licenses/%(name)s' +
                         ' && cd ..'
                         ' && cp AUTHORS CHANGELOG.rst COPYING README.rst %(installdir)s/share/licenses/%(name)s',
    }),
]

sanity_check_paths = {
    'files': ['bin/gpp', 'share/man/man1/gpp.1', 'share/licenses/GPP/COPYING', 'share/licenses/GPP/COPYING.LESSER'] +
             #['bin/htop', 'share/man/man1/htop.1', 'share/licenses/htop/COPYING'] +
             ['bin/libtree', 'share/man/man1/libtree.1', 'share/licenses/libtree/LICENSE'] +
             ['bin/tree', 'share/man/man1/tree.1', 'share/licenses/tree/LICENSE'] +
             ['bin/proot', 'share/licenses/PRoot/COPYING'],
    'dirs':  []
}

sanity_check_commands = [
    'gpp --version',
    #'htop --version',
    'libtree --help',
    'libtree -v -p %(installdir)s/bin/libtree',
    'tree --version',
    'proot --version'
]

modluafooter = f"""
extensions( "GPP/{local_systools_GPP_version}, libtree/{local_systools_libtree_version}, tree/{local_systools_tree_version}, PRoot/{local_systools_PRoot_version}" )
"""

moduleclass = 'tools'

[systools] [package list]