blob: 97a3e6d65ca1b95743fcf57a2c1123292b5d76a3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
#!/usr/bin/bash
#
# Enable relocations at the linker for give llvm-bolt the possibility to reorder functions
#
[[ -n "$LIBMAKEPKG_BUILDENV_RELOCS_SH" ]] && return
LIBMAKEPKG_BUILDENV_RELOCS_SH=1
LIBRARY=${LIBRARY:-'/usr/share/makepkg'}
source "$LIBRARY/util/option.sh"
build_options+=('relocs')
buildenv_functions+=('buildenv_relocs')
buildenv_relocs() {
if check_buildoption "relocs" "y";then
relocsldflags=" -Wl,--emit-relocs"
LDFLAGS+="$relocsldflags"
fi
}
|