bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/22263] New: -fpie -pie generates dynamic relocations in text sec


From: hjl.tools at gmail dot com
Subject: [Bug ld/22263] New: -fpie -pie generates dynamic relocations in text section
Date: Thu, 05 Oct 2017 10:27:07 +0000

https://sourceware.org/bugzilla/show_bug.cgi?id=22263

            Bug ID: 22263
           Summary: -fpie -pie generates dynamic relocations in text
                    section
           Product: binutils
           Version: 2.30 (HEAD)
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ld
          Assignee: unassigned at sourceware dot org
          Reporter: hjl.tools at gmail dot com
  Target Milestone: ---
            Target: tilepro

address@hidden build-tilepro-linux]$ cat x.c
__thread int * foo;

void
bar (void)
{
  *foo = 1;
}
address@hidden build-tilepro-linux]$ cat y.c
extern __thread int *foo;

static int x;

extern void bar (void);

int
main ()
{
  foo = &x;
  return 0;
}
address@hidden build-tilepro-linux]$
/export/gnu/import/git/toolchain/install/compilers/tilepro-linux-gnu/bin/tilepro-glibc-linux-gnu-gcc
-pie -fpie x.c y.c -O2 -Wl,-z,text
/export/gnu/import/git/toolchain/install/compilers/tilepro-linux-gnu/lib/gcc/tilepro-glibc-linux-gnu/7.2.1/../../../../tilepro-glibc-linux-gnu/bin/ld:
read-only segment has dynamic relocations.
collect2: error: ld returned 1 exit status
address@hidden build-tilepro-linux]$

-- 
You are receiving this mail because:
You are on the CC list for the bug.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]