public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug build/9744] New: Building gdb/sim/arm/run does not respect the environments LDFLAGS
@ 2009-01-14 21:18 rje at crystalfontz dot com
  2009-01-15  9:27 ` [Bug build/9744] " pedro at codesourcery dot com
  0 siblings, 1 reply; 2+ messages in thread
From: rje at crystalfontz dot com @ 2009-01-14 21:18 UTC (permalink / raw)
  To: gdb-prs

I've set up my environment on OS X to find some headers and libraries in other
places.  I did this as so:

CFLAGS=-I/sw/include -I/usr/local/ftdi/include
LDFLAGS=-L/sw/lib -L/usr/local/ftdi/lib
CXXFLAGS=$(CFLAGS)
CPPFLAGS=$(CXXFLAGS) 

When building gdb-6.8 it makes correctly down until the sim/arm directory. 
There it is using gcc to link together the "run" executable but it is not using
the LDFLAGS. Without those it cannot find that libintl is in /sw/lib.

gcc -DHAVE_CONFIG_H     -DPROFILE=1 -DWITH_PROFILE=-1         
-DDEFAULT_INLINE=0           -DMODET -DNEED_UI_LOOP_HOOK -DSIM_TARGET_SWITCHES 
 -I. -I../../../../gdb/sim/arm -I../common -I../../../../gdb/sim/arm/../common
-I../../include -I../../../../gdb/sim/arm/../../include -I../../bfd
-I../../../../gdb/sim/arm/../../bfd -I../../opcodes
-I../../../../gdb/sim/arm/../../opcodes  -I/sw/include -I/usr/local/ftdi/include
-o run \
          run.o libsim.a ../../bfd/libbfd.a ../../opcodes/libopcodes.a -lintl
-liconv -lc ../../libiberty/libiberty.a  
ld: library not found for -lintl
collect2: ld returned 1 exit status
make[5]: *** [run] Error 1
make[4]: *** [all] Error 1
make[3]: *** [all-sim] Error 2
make[2]: *** [all] Error 2
make[1]: *** [cross-gdb] Error 2
make: *** [tools] Error 2

I can work around this by modifying the generated Makefile in sim/arm and adding
the -L/sw/lib to this block.

run$(EXEEXT): $(SIM_RUN_OBJS) libsim.a $(LIBDEPS)
        $(CC) -L/sw/lib $(ALL_CFLAGS) -o run$(EXEEXT) \
          $(SIM_RUN_OBJS) libsim.a $(EXTRA_LIBS)

I'm not sure how to patch it correctly in the configure scripts to pass the
LDFLAGS and have the generated Makefile respect them.

-- 
           Summary: Building gdb/sim/arm/run does not respect the
                    environments LDFLAGS
           Product: gdb
           Version: 6.8
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: build
        AssignedTo: unassigned at sourceware dot org
        ReportedBy: rje at crystalfontz dot com
                CC: gdb-prs at sourceware dot org
 GCC build triplet: i386-apple-darwin9.6.0
  GCC host triplet: i386-apple-darwin9.6.0
GCC target triplet: arm-unknown-eabi


http://sourceware.org/bugzilla/show_bug.cgi?id=9744

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug build/9744] Building gdb/sim/arm/run does not respect the environments LDFLAGS
  2009-01-14 21:18 [Bug build/9744] New: Building gdb/sim/arm/run does not respect the environments LDFLAGS rje at crystalfontz dot com
@ 2009-01-15  9:27 ` pedro at codesourcery dot com
  0 siblings, 0 replies; 2+ messages in thread
From: pedro at codesourcery dot com @ 2009-01-15  9:27 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From pedro at codesourcery dot com  2009-01-15 09:27 -------


*** This bug has been marked as a duplicate of 8751 ***

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |DUPLICATE


http://sourceware.org/bugzilla/show_bug.cgi?id=9744

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-01-15  9:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-14 21:18 [Bug build/9744] New: Building gdb/sim/arm/run does not respect the environments LDFLAGS rje at crystalfontz dot com
2009-01-15  9:27 ` [Bug build/9744] " pedro at codesourcery dot com

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).