# IT4Innovations
# LK 2024

easyblock = 'ConfigureMake'

name = 'XZ'
version = '5.4.5'

homepage = 'https://tukaani.org/xz/'
description = "xz: XZ utilities"

toolchain = {'name': 'GCCcore', 'version': '14.2.0'}

source_urls = ['https://tukaani.org/xz/']
sources = [SOURCELOWER_TAR_BZ2]
checksums = ['8ccf5fff868c006f29522e386fb4c6a1b66463fbca65a4cfc3c4bd596e895e79']

builddependencies = [
    # use gettext built with system toolchain as build dep to avoid cyclic dependency (XZ -> gettext -> libxml2 -> XZ)
    ('gettext', '0.22.5', '', SYSTEM),
    ('binutils', '2.42'),
]

# may become useful in non-x86 archs
# configopts = ' --disable-assembler '

sanity_check_paths = {
    'files': ['bin/lzmainfo', 'bin/unxz', 'bin/xz'],
    'dirs': []
}

sanity_check_commands = [
    "xz --help",
    "unxz --help",
]

moduleclass = 'tools'
