public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Mahmood Naderan <nt_mahmood@yahoo.com>
To: Jim Wilson <jimw@sifive.com>
Cc: "gcc-help@gcc.gnu.org" <gcc-help@gcc.gnu.org>
Subject: Re: Static linking of a custom glibc
Date: Thu, 4 Jun 2020 05:17:48 +0000 (UTC)	[thread overview]
Message-ID: <697504676.1728300.1591247868864@mail.yahoo.com> (raw)
In-Reply-To: <CAFyWVaYwt2pjUFUf_0LzhpYVZ7CjivGkv2qiT4Hv=VGD0pjtgQ@mail.gmail.com>

>This looks like more of a glibc question than a gcc question.  I would
>suggest reading
>  https://sourceware.org/glibc/wiki/Testing/Builds


Yes I am able to link to the new glibc with "-Wl,-rpath" and "-Wl,--dynamic-linker ".
But, even with the default libc on the system, I am not able to link statically.
$ gcc -o test -Wl,--emit-relocs -Wl,-Bstatic test.o              
/usr/bin/ld: cannot find -lgcc_s/usr/bin/ld: cannot find -lgcc_s
collect2: error: ld returned 1 exit status

I ask that on glibc list, but it seems that this is a gcc related problem.I am confused...

Regards,
Mahmood 
| 
| 
|  | 
Testing/Builds - glibc wiki


 |

 |

 |





  

  reply	other threads:[~2020-06-04  5:17 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <947270223.1380815.1591188243335.ref@mail.yahoo.com>
2020-06-03 12:44 ` Mahmood Naderan
2020-06-03 22:44   ` Jim Wilson
2020-06-04  5:17     ` Mahmood Naderan [this message]
2020-06-04 11:18       ` Andrew Haley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=697504676.1728300.1591247868864@mail.yahoo.com \
    --to=nt_mahmood@yahoo.com \
    --cc=gcc-help@gcc.gnu.org \
    --cc=jimw@sifive.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).