public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
From: John Dallaway <john@dallaway.org.uk>
To: David Fernandez <david.fernandez.work@googlemail.com>
Cc: eCos Discussion <ecos-discuss@ecos.sourceware.org>
Subject: [ECOS] Re: configtool for linux building problems.
Date: Fri, 22 Jun 2012 19:42:00 -0000	[thread overview]
Message-ID: <4FE4CA79.7020809@dallaway.org.uk> (raw)
In-Reply-To: <4FE4C8BC.80600@dallaway.org.uk>

Hi David

On 22/06/12 19:26, David Fernandez wrote:

>>> 2.- Edit the makefile.gnu in ecos/host/tools/configtool/standalone, and
>>> add to the line EXTRALDFLAGS, at the end, after leaving a space, -lX11
>>> 
>> I have not found -lX11 to be necessary. The invocation of wx-config
>> within makefile.gnu should return all the flags necessary to link with
>> the X window system. Which Linux distro and version are you using? Can
>> you forward the link-time error you observe without this change
>> (including all the command-line arguments) please?
> 
> This is the "simplified" output:
> 
> c++ -o configtool <lots-of-files.o>  -LTCLDIR_use_system/lib -L/usr/local/lib
> -l<other-libs>... -ltcl `/usr/local/bin/wx-config --libs std,gizmos`
> /usr/bin/ld: /usr/local/lib/libwx_gtk2_core-2.8.a(corelib_utilsx11.o):
> undefined reference to symbol 'XGetWindowAttributes'
> /usr/bin/ld: note: 'XGetWindowAttributes' is defined in DSO
> /usr/lib/libX11.so.6 so try adding it to the linker command line
> /usr/lib/libX11.so.6: could not read symbols: Invalid operation
> collect2: ld returned 1 exit status
> make: *** [/<my-build -folder>] Error 1
> 
> I compiled this in Fedora14+wxGTK-2.8.12 and Fedora15+wxGTK-2.8.8, and I
> get the same problem in both of them (both wxGTK were compiled from
> sources and installed in /usr/local, I know that /usr/local/bin is in
> the PATH, but my LD_LIBRARY_PATH is empty, as I rely in the config
> scripts for wx and tcl).

This is almost certainly due to recent Fedora builds of GNU ld using
different DSO-linking semanics. Ref:

  http://fedoraproject.org/wiki/Features/ChangeInImplicitDSOLinking

Specifying -lX11 explictly for Linux builds seems reasonable and should
be safe for other users.

I've attached a patch at:

  http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001613

Thank you for reporting this.

John Dallaway
eCos maintainer
http://www.dallaway.org.uk/john

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

       reply	other threads:[~2012-06-22 19:42 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <4FE4C8BC.80600@dallaway.org.uk>
2012-06-22 19:42 ` John Dallaway [this message]
2013-07-11 10:24   ` scas
2013-07-11 12:54     ` John Dallaway
2013-07-11 13:32       ` scas
2013-07-13 19:28         ` scas
2012-06-20 16:21 [ECOS] " David Fernandez
2012-06-20 19:59 ` [ECOS] " David Fernandez
2012-06-21 22:57   ` David Fernandez
2012-06-22  7:54     ` John Dallaway
2012-06-22 18:26       ` David Fernandez
2012-06-22  9:18     ` Alex Schuilenburg

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=4FE4CA79.7020809@dallaway.org.uk \
    --to=john@dallaway.org.uk \
    --cc=david.fernandez.work@googlemail.com \
    --cc=ecos-discuss@ecos.sourceware.org \
    /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).