# This file is in the public domain

install_man(
    [
        'anastasis-dbconfig.1',
        'anastasis-dbinit.1',
        'anastasis-httpd.1',
        'anastasis-helper-authorization-iban.1',
        'anastasis-reducer.1',
        'anastasis.conf.5',
        'anastasis-config.1',
    ],
)

subdir('anastasis-figures')

configure_file(input: 'anastasis.texi', output: 'anastasis.texi', copy: true)

makeinfo = find_program('makeinfo', native: true, required: false)

if makeinfo.found()

    f_info = '@0@.info'.format('anastasis')
    f_texi = meson.current_build_dir() / '@0@.texi'.format('anastasis')

    custom_target(
        f_info,
        output: f_info,
        command: [
            makeinfo,
            '--no-split',
            '--no-headers',
            f_texi,
            '-o',
            '@OUTPUT0@',
        ],
        install: true,
        install_dir: get_option('infodir'),
    )

endif
