From 9bc5ecf3bcb25abbf868d52e7db076248e0ef174 Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Tue, 13 Feb 2018 11:21:01 +0000 Subject: RISC-V: define _REENTRANT with -pthread This is expected by the AX_PTHREAD autoconf macro from . * config/riscv/linux.h (CPP_SPEC): Define. From-SVN: r257621 --- gcc/config/riscv/linux.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gcc/config/riscv') diff --git a/gcc/config/riscv/linux.h b/gcc/config/riscv/linux.h index 1da1b0a..ad03654 100644 --- a/gcc/config/riscv/linux.h +++ b/gcc/config/riscv/linux.h @@ -47,6 +47,8 @@ along with GCC; see the file COPYING3. If not see #define ICACHE_FLUSH_FUNC "__riscv_flush_icache" +#define CPP_SPEC "%{pthread:-D_REENTRANT}" + #define LINK_SPEC "\ -melf" XLEN_SPEC "lriscv \ %{shared} \ -- cgit v1.1