diff options
| author | Alexander Egorenov <eaibmz@gmail.com> | 2022-10-26 15:44:05 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2022-10-26 21:07:28 -0700 |
| commit | 5c716ff64acaf8672a9fe96c21951be48b2b8d5e (patch) | |
| tree | 7c58c875bd3f6a19801d11ac127f002eade07ae3 /sys/linux | |
| parent | 729b89b837233450284c187958dce585b67bd50e (diff) | |
sys/targets: fix -static-pie for s390x arch
On s390x, position independent code needs to be built with -fPIC or
-fPIE for pie executables.
How to reproduce on s390x
-------------------------
$ git clone https://github.com/google/syzkaller.git
$ cd syzkaller
$ make executor
go list -f '{{.Stale}}' ./sys/syz-sysgen | grep -q false || go install ./sys/syz-sysgen
make .descriptions
make[1]: '.descriptions' is up to date.
mkdir -p ./bin/linux_s390x
gcc -o ./bin/linux_s390x/syz-executor executor/executor.cc \
-O2 -pthread -Wall -Werror -Wparentheses -Wunused-const-variable \
-Wframe-larger-than=16384 -Wno-stringop-overflow -Wno-array-bounds \
-Wno-format-overflow -static-pie -DGOOS_linux=1 -DGOARCH_s390x=1 \
-DHOSTGOOS_linux=1 -DGIT_REVISION=\"2159e4d29f58ffa1107fc2213dbc87185ff4498f\"
/usr/bin/ld: read-only segment has dynamic relocations
Signed-off-by: Alexander Egorenov <eaibmz@gmail.com>
Diffstat (limited to 'sys/linux')
0 files changed, 0 insertions, 0 deletions
