RISC-V: Bind defined symbol locally in PIE

Reference commit 1dcb9720d62cd053a72c31881b7724ce9f74332c

bfd/
	* elfnn-riscv.c (RISCV_COPY_INPUT_RELOC): Bind defined symbol
	locally in PIE.

ld/
	* testsuite/ld-riscv-elf/pie-bind-locally-a.s: New test source.
	* testsuite/ld-riscv-elf/pie-bind-locally-b.s: Likewise.
	* testsuite/ld-riscv-elf/pie-bind-locally-rv32.d: New testcase.
	* testsuite/ld-riscv-elf/pie-bind-locally-rv64.d: Likewise.

Signed-off-by: Linsen Zhou <i@lin.moe>
6 files changed