Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com X-Injected-Via-Gmane: http://gmane.org/ To: cygwin AT cygwin DOT com From: "Hans Horn" Subject: undefined reference to '_... Date: Sun, 8 Jun 2003 10:22:58 -0700 Lines: 30 Message-ID: X-Complaints-To: usenet AT main DOT gmane DOT org X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 Hi folks, I'm trying to port a collection of unix applications to cygwin, and in doing so, I'm having a hard time to get the stuff to link. It's a bunch of fortran and c sources, that call each other wildly. some mains are in c, some mains are in fortran. Compiling and archiving everything works like a charm, When I'm trying to link the first executable (main in c) against the libraries I have created, I get tons of undefined reference complaints, all starting with '_', and all are non-system symbols. I've confirmed by running nm on the libraries in question, that the missing symbols are actually in the library. The linker command is : gcc -ofoo foomain.o -L../lib -lfoo1 -lfoo2 -lg2c -lc -lgsl -lm Do I have to do something special to a libraries after archival of object files, before I can link against it? I'm probably doing something very stupid. But since my head is already hurting from banging it against the concrete wall for a while, I'd rather ask. anybody any clues? H. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/