From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31384 invoked by alias); 10 Jul 2006 14:49:38 -0000 Received: (qmail 31376 invoked by uid 22791); 10 Jul 2006 14:49:37 -0000 X-Spam-Check-By: sourceware.org Received: from nf-out-0910.google.com (HELO nf-out-0910.google.com) (64.233.182.190) by sourceware.org (qpsmtpd/0.31) with ESMTP; Mon, 10 Jul 2006 14:49:36 +0000 Received: by nf-out-0910.google.com with SMTP id l37so467927nfc for ; Mon, 10 Jul 2006 07:49:33 -0700 (PDT) Received: by 10.78.151.3 with SMTP id y3mr1714722hud; Mon, 10 Jul 2006 07:49:33 -0700 (PDT) Received: by 10.78.154.7 with HTTP; Mon, 10 Jul 2006 07:49:32 -0700 (PDT) Message-ID: <4d77c5f20607100749v623c591dj4caf7a55492cd8e8@mail.gmail.com> Date: Mon, 10 Jul 2006 14:49:00 -0000 From: "Tzu-Chien Chiu" To: "Thiemo Seufer" Subject: Re: LD: function-level linking Cc: binutils@sourceware.org In-Reply-To: <20060710144420.GM4375@networkno.de> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <4d77c5f20607092350j26ab6056t9c9a3b40fdb5493@mail.gmail.com> <20060710081040.GK4375@networkno.de> <4d77c5f20607100737y79dd772ch2e0b5e239a27f6ed@mail.gmail.com> <20060710144420.GM4375@networkno.de> Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org X-SW-Source: 2006-07/txt/msg00121.txt.bz2 According to the manual at: http://sourceware.org/binutils/docs-2.16/ld/Options.html#Options [quote] For options whose names are multiple letters, either one dash or two can precede the option name; ... [/quote] By the way, I tested both (one and two dashes), ld complained both anway. 2006/7/10, Thiemo Seufer : > Tzu-Chien Chiu wrote: > > I got a warning from ld: "gc-sections option ignored." > > > > The compilation command: > > [quote] > > or32-elf-gcc -o a.o -c -ffunction-sections -fdata-sections a.c > > [/quote] > > > > The link command is: > > [quote] > > or32-elf-gcc -o program a.o b.o c.o -lfoo -Wl,-gc-sections, -Wl,-static > > [/quote] > > You missed the second dash in front of --gc-sections. > > > Thiemo > -- Tzu-Chien Chiu - SMedia Technology Corp. URL: http://www.csie.nctu.edu.tw/~jwchiu/