Re: [PING][PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-06-07 Thread Renlin Li
Ping ~ On 14/12/16 15:33, Renlin Li wrote: Ping~ Regards, Renlin On 16/06/16 12:04, Renlin Li wrote: Hi all, GCC has startfile and endfile spec string built into it. startfile is used to specify objects files to include at the start of the link process. While endfile, on the other hand, is

Re: [PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-01-13 Thread Christophe Lyon
On 13 January 2017 at 13:26, Renlin Li wrote: > Hi Christophe, > > > On 13/01/17 11:14, Christophe Lyon wrote: >> >> On 13 January 2017 at 11:22, Renlin Li wrote: >>> >>> Hi Christophe, >>> >>> Thanks for testing the patch! >>> I check the test

Re: [PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-01-13 Thread Renlin Li
Hi Christophe, On 13/01/17 11:14, Christophe Lyon wrote: On 13 January 2017 at 11:22, Renlin Li wrote: Hi Christophe, Thanks for testing the patch! I check the test case gcc.dg/lto/pr54709, it seems the test case is not properly written. It add extra ld option

Re: [PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-01-13 Thread Christophe Lyon
On 13 January 2017 at 11:22, Renlin Li wrote: > Hi Christophe, > > Thanks for testing the patch! > I check the test case gcc.dg/lto/pr54709, it seems the test case is not > properly written. > > It add extra ld option -shared without checking the target support for that. >

Re: [PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-01-13 Thread Renlin Li
Hi Christophe, Thanks for testing the patch! I check the test case gcc.dg/lto/pr54709, it seems the test case is not properly written. It add extra ld option -shared without checking the target support for that. After the change, this compilation will fail as a regression. IIUC, '-shared'

Re: [PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-01-13 Thread Christophe Lyon
Hi Renlin, On 12 January 2017 at 16:50, Renlin Li wrote: > Hi Kugan, > > some of the targets do include pie, and use the same crtbegin file as shared > object. > For example, alpha/elf.h > > And there are targets which don't do that, > For example, sh/elf.h > > Most of

Re: [PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-01-12 Thread Renlin Li
Hi Kugan, some of the targets do include pie, and use the same crtbegin file as shared object. For example, alpha/elf.h And there are targets which don't do that, For example, sh/elf.h Most of the elf target seem only consider the simple case. The purpose of this patch is to make it possible

Re: [PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-01-12 Thread kugan
Hi, On 16/06/16 21:04, Renlin Li wrote: /* Now we define the strings used to build the spec file. */ -#define UNKNOWN_ELF_STARTFILE_SPEC " crti%O%s crtbegin%O%s crt0%O%s" +#define UNKNOWN_ELF_STARTFILE_SPEC \ + "crti%O%s \ + %{!shared:crtbegin%O%s} %{shared:crtbeginS%O%s} \ +

Re: [PING][PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2017-01-12 Thread Renlin Li
~ Ping https://gcc.gnu.org/ml/gcc-patches/2016-06/msg01227.html Regards, Renlin On 14/12/16 15:33, Renlin Li wrote: Ping~ Regards, Renlin On 16/06/16 12:04, Renlin Li wrote: Hi all, GCC has startfile and endfile spec string built into it. startfile is used to specify objects files to

[PING][PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2016-12-14 Thread Renlin Li
Ping~ Regards, Renlin On 16/06/16 12:04, Renlin Li wrote: Hi all, GCC has startfile and endfile spec string built into it. startfile is used to specify objects files to include at the start of the link process. While endfile, on the other hand, is used to specify objects files to include at

[PATCH][ARM]Use different startfile and endfile for elf target when generating shared object.

2016-06-16 Thread Renlin Li
Hi all, GCC has startfile and endfile spec string built into it. startfile is used to specify objects files to include at the start of the link process. While endfile, on the other hand, is used to specify objects files to include at the end of the link process. crtbegin.o is one of the