Blame tools/check-settings-docs.sh

Packit 5756e2
#!/bin/sh
Packit 5756e2
Packit 5756e2
srcdir=$1
Packit 5756e2
builddir=$2
Packit 5756e2
doc_h=$3
Packit 5756e2
Packit 5756e2
if [ -z "$NMTST_NO_CHECK_SETTINGS_DOCS" ] ; then
Packit 5756e2
    if ! cmp -s "${srcdir}/${doc_h}.in" "${builddir}/${doc_h}"; then
Packit 5756e2
        if [ "$NM_TEST_REGENERATE" = 1 ] ; then
Packit 5756e2
            cp -f "${builddir}/${doc_h}" "${srcdir}/${doc_h}.in"
Packit 5756e2
        else
Packit 5756e2
            echo "*** Error: the generated file '${builddir}/${doc_h}' differs from the source file '${srcdir}/${doc_h}.in'. You probably should copy the generated file over to the source file. You can skip this test by setting NMTST_NO_CHECK_SETTINGS_DOCS=yes. You can also automatically copy the file by rerunning the test with NM_TEST_REGENERATE=1"
Packit 5756e2
            exit 1
Packit 5756e2
        fi
Packit 5756e2
    fi
Packit 5756e2
fi
Packit 5756e2
Packit 5756e2
exit 0
Packit 5756e2