This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ld issues


Jeff Sturm writes:
 > On Wed, 9 Jul 2003, Steve Pribyl wrote:
 > > What s the difference between
 > >
 > > $ gcj Hello.java -o Hello.o -g -fPIC  -c
 > > $ ld -shared -o libHello.so Hello.o
 > >
 > > and
 > >
 > > $ gcj ${GCJFLAGS} v1/Hello.java -o v1/libHello.so -shared -g -fPIC
 > 
 > Only the latter supplies DT_NEEDED entries.  Try "readelf -d libHello.so |
 > grep NEEDED" both ways.  (The former method isn't recommended btw.)

Indeed.  It fascinates me how often this question comes up -- why do
people want to invoke the linker directly instead of having gcj do the
job, when the latter obviously works and the former doesn't?

Andrew.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]