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]

order of arguments on command line when linking


When I change the order of arguments on the command line when linking, I may
get linking errors, which can be solved by changing the order of the
arguments. For example, I know the following won't work:

gcj -s -fCLASSPATH=cls libexample.a libswtwin32.a  libswtjniwin32.a
swt-win32.exp ...

I have to put the swt-win32.exp argument first:

gcj -s -fCLASSPATH=cls swt-win32.exp libexample.a libswtwin32.a
libswtjniwin32.a  ...

Sometimes it simpler than that:

gcj lib1.a lib2.a ... won't work. It must be: gcj lib2.a lib1.a ...

Is there a reason for this?


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