5 [[ -d ${0%/*} ]] && cd ${0%/*}
10 # GitHub workflows fetch a clone of the dracut repository which doesn't
11 # contain git tags, thus "breaking" the RPM build in certain situations
13 # DRACUT_MAIN_VERSION in Makefile is defined as an output of `git describe`,
14 # which in full git clone returns a tag with a numeric version. However,
15 # without tags it returns SHA of the last commit, which later propagates into
16 # `Provides:` attribute of the built RPM and can break dependency tree when
18 [[ -d .git
]] && git fetch
--tags && git describe
--tags
22 NCPU
=$
(getconf _NPROCESSORS_ONLN
)
24 if ! [[ $TESTS ]]; then
25 make -j$NCPU all syncheck rpm logtee
27 [[ $TESTS == "99" ]] && make_docs
=yes || make_docs
=no
28 make -j$NCPU enable_documentation
=$make_docs all logtee
32 time LOGTEE_TIMEOUT_MS
=590000 make \
33 enable_documentation
=$make_docs \
34 KVERSION
=$
(rpm
-qa kernel
--qf '%{VERSION}-%{RELEASE}.%{ARCH}\n' |
sort -rn |
head -1) \
37 ${TESTS:+TESTS="$TESTS"} \