repo/extra/efivar/build
Dylan Araps 520617e74c
efivar: Force -j1
This /apparently/ fixes build errors for some users. I can't
reproduce (even with -j$(nproc)).
2021-07-13 10:36:17 +03:00

22 lines
487 B
Bash
Executable File

#!/bin/sh -e
# LTO is used when CFLAGS are unset causing a compilation
# error with GCC 10. LTO can be set by the user though
# '-flto-partition=none' is also needed.
sed 's/ -flto//' src/include/defaults.mk > _
mv -f _ src/include/defaults.mk
# Avoid repeating ourselves.
mk() {
make \
-j1 \
libdir=/usr/lib/ \
bindir=/usr/bin/ \
mandir=/usr/share/man/ \
includedir=/usr/include/ \
"$@"
}
mk CC="${CC:-cc}"
mk DESTDIR="$1" install