]> git.armaanb.net Git - asd-repo.git/blob - core/efivar/build
Adapt for asd linux
[asd-repo.git] / core / efivar / build
1 #!/bin/sh -e
2
3 # LTO is used when CFLAGS are unset causing a compilation
4 # error with GCC 10. LTO can be set by the user though
5 # '-flto-partition=none' is also needed.
6 sed -i 's/ -flto//' Make.defaults
7
8 for patch in *.patch; do
9     patch -p1 < "$patch"
10 done
11
12 # Avoid repeating ourselves.
13 mk() {
14     make \
15         libdir=/usr/lib/ \
16         bindir=/usr/bin/ \
17         mandir=/usr/share/man/ \
18         includedir=/usr/include/ \
19         "$@"
20 }
21
22 mk CC="${CC:-cc}"
23 mk DESTDIR="$1" install