delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
DomainKey-Signature: | a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id |
:list-unsubscribe:list-subscribe:list-archive:list-post | |
:list-help:sender:mime-version:in-reply-to:references:date | |
:message-id:subject:from:to:content-type; q=dns; s=default; b=sP | |
l5oVbhdSJNVz0oQZDMP42SxvIpfFg3iuanXYKfWXPEjjg1l549XDz6NvktYfyXGF | |
xfQCALQisCoY8y+zmiqv6r7AzWgU74Nh9kDNNddIl/2eIqOr6ITOjc+DJFx9jmjz | |
rnisQX2ZmARctKZJ+BJXBibduk/lPJ7cy7lMSczIE= | |
DKIM-Signature: | v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id |
:list-unsubscribe:list-subscribe:list-archive:list-post | |
:list-help:sender:mime-version:in-reply-to:references:date | |
:message-id:subject:from:to:content-type; s=default; bh=LTFsAmk1 | |
VJ3gfEw0GDBYcurfTOc=; b=AXQxjg5OfuyQKgU+DhazOq6fOvHsXrdhWpdZTW96 | |
V0PTX8hANjXOmzt/Zv9T98+r7SxIVpDOcr530rnCkGxKYYRA3PsWzZ8mpNwZQ2A1 | |
2ta0bm3I50GhPdtIsy4EdyxuBJ1YLCkCiKoo5WbZw5DECILva8lsNY5VOdpqBxsi | |
7sg= | |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
Authentication-Results: | sourceware.org; auth=none |
X-Virus-Found: | No |
X-Spam-SWARE-Status: | No, score=-2.3 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 |
X-HELO: | mail-wi0-f174.google.com |
MIME-Version: | 1.0 |
X-Received: | by 10.194.63.236 with SMTP id j12mr40600206wjs.5.1396856267822; Mon, 07 Apr 2014 00:37:47 -0700 (PDT) |
In-Reply-To: | <alpine.LFD.2.03.1404050922190.20917@KarmannGhia.org> |
References: | <alpine DOT LFD DOT 2 DOT 03 DOT 1404050922190 DOT 20917 AT KarmannGhia DOT org> |
Date: | Mon, 7 Apr 2014 09:37:47 +0200 |
Message-ID: | <CAEhDDbDZuKLtgW_9CujX7aJm2tD42orqjChaatiKOReepMN+Lg@mail.gmail.com> |
Subject: | Re: relocation truncated to fit: R_X86_64_PC32 against undefined symbol `len' |
From: | Csaba Raduly <rcsaba AT gmail DOT com> |
To: | cygwin list <cygwin AT cygwin DOT com> |
Hi Richard, On Sat, Apr 5, 2014 at 6:51 PM, Richard wrote: > > Hello Everyone, > > I recently (two weeks ago or so) upgraded the cygwin installation on an XP > 64 bit (corp edition) box and in getting things running on it again I've > been having various troubles, even though I was VERY careful to watch for > any installation errors - none were noticed. Normally I don't do development > on this box but copy over from other systems. I had at least one program > that was not behaving correctly - it would apparently hide output sent to > stdout among other mysteries. After fiddling with things I decided to just > rebuild on that box from sources - it's almost all gnu c. (Note that this > code needs to run unchanged on many different platforms.) > > At some point I get to the gcc call to bind together three object files into > an executable - all the object files having just been built with zero errors > - and I get this particular "undefined reference to `len'" error. Of course > I went hunting for the use of 'len' - which is a pretty absurd effort as a > simple grep matches on coutless noise such as 'filename' or 'strlen', etc. Have you tried the -w option of grep? > However, a thorough search revealed no uses of just 'len', yet I don't deny > I could possibly have overlooked it. Try the following in the directory where the object files are: nm *.o | grep -P '\.o:|\blen\b' > Even so, this directory was taken > wholesale from a 64 bit system (Win 7) with an older cygwin installation > where the code compiles and runs fine. So somehow I don't think it's > actually in my code but rather a library reference problem somehow. > > The specific set of error output from make is: > > $ gcc -o ctjc.exe ctjc.o hashc.o sha1.o; > ctjc.o:ctjc.c:(.text+0x2287): undefined reference to `len' > ctjc.o:ctjc.c:(.text+0x2287): relocation truncated to fit: R_X86_64_PC32 > against undefined symbol `len' You may have a mix of 32-bit and 64-bit object files. What does the following command print? file *.o Csaba -- GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++ The Tao of math: The numbers you can count are not the real numbers. Life is complex, with real and imaginary parts. "Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds "People disagree with me. I just ignore them." -- Linus Torvalds -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |