Hi Mark, > -----Message d'origine----- > De : [email protected] [mailto:fpc-devel- > [email protected]] De la part de Mark Morgan Lloyd > Envoyé : mercredi 7 janvier 2015 12:01 > À : [email protected] > Objet : Re: [fpc-devel] FPC on SPARC Linux > > Mark Morgan Lloyd wrote: > > Pierre Free Pascal wrote: > >> Hi Mark, > >> > >> did you try to generate the libraries needed to compile FP IDE with > >> GDB support by > >> using the script in fpcsrc/packages/gdbint/gen-gdblib-inc.sh ? > >> > >> If you have a build directory of a certain GDB version (let's say > 7.8.1 > >> as an example), simply copy the script over to build-gdb-7.8.1/gdb, > >> and run > >> it locally. > >> > >> This script tries to determine all the libraries needed > >> and generates a second script called copy-libs.sh > >> that you should call in turn, with a simple arg, the target > directory, > >> for example, ./copy-libs.sh ~/pas/libgdb-7.8.1 > >> > >> After that, > >> using make -C ./packages/gdbint GDBLIBDIR=~/pas/libgdb-7.8.1 > >> followed by > >> make -C ide GDBLIBDIR=~/pas/libgdb-7.8.1 > >> should makes the things much easier. > >> > >> One caveat is to avoid system installed libraries to be installed > >> instead of the ones inside this directory. > >> On systems on which I got this problem, I had to manually > >> remove all lines {$librarypath XXX} > >> where XXX resolved to /usr/lib or /lib > > I've found where we discussed this before, about August 2013. Part of > the solution at the time was to use -Xd but... > > >> In the hope this will help, > >> > >> Pierre Muller > > > > Thanks Pierre, I'll investigate. OTOH the existing GDB 6.7.1 > libraries > > appear sufficient for 2.2.4 through 2.4.4 and for 2.6.4, all on the > same > > system without any underlying adjustments. > > The problem is that there's now a -Xd being put in the internal command > line, without a -Fl for the location of libgcc.a since it's no longer > being picked up from fpc.cfg.
This should not matter if you use the script I was talking about, because GDB compilation also required libgcc, so that it should be inside the generated gdblib.inc > If I add an explicit -Fl/usr/lib/gcc/sparc-linux-gnu/4.4 (or whatever) > to match libgcc.a then fp builds and runs with libgcc, although I've > not > tested this aggressively. There was an outdated reference to 4.3.2 in > fpc.cfg which had been moved around between several generations of > machines, this could have affected some earlier builds. > > Is there a more appropriate way of doing this than using OPT=-Fl..., > and > is having a fixed path for libgcc in fpc.cfg still appropriate? Yes, see above. > Noting that the makefile is able to work around the case where it can't > find libgdb, could something similar be done for libgcc? In other > words, > a stern warning that something's not right without screwing the entire > build? > > I notice that on at least some systems (not limited to SPARC) the > libgcc > path in /etc/fpc.cfg is derived from the gcc version info even if this > doesn't match what's on disc, e.g. something like ...linux-gnu/4.3.2 > rather than ...linux-gnu/4.3 I must confess that I don't even know how this is done... Pierre _______________________________________________ fpc-devel maillist - [email protected] http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel
