X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS,TW_HD,TW_LC,TW_LG X-Spam-Check-By: sourceware.org To: cygwin AT cygwin DOT com From: Philipp Kraus Subject: Re: linker error libcygwin Date: Thu, 10 Nov 2011 22:19:32 +0100 Lines: 41 Message-ID: References: <8DB56F04-18E5-43C3-8080-05565BA1531D AT flashpixx DOT de> <4EBC3C61 DOT 3080404 AT gmail DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: 8bit User-Agent: Unison/2.1.5 X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: 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 On 2011-11-10 22:04:33 +0100, Marco Atzeri said: > On 11/10/2011 9:39 PM, Kraus Philipp wrote: >> Hello, >> >> I try to build a program with g++ under Cygwin. I added this libraries >> to the linker: >> -lcygboost_system >> -lcygboost_thread >> -lcygboost_iostreams >> -lcygboost_regex >> -lcygboost_program_options >> -lboost_exception >> -lcygboost_filesystem >> -llapack >> -lcblas >> -lf77blas >> -latlas >> -lgfortran >> -lhdf5_cpp >> -lhdf5 >> >> The linker create the error: >> >> /usr/lib/gcc/i686-pc-cygwin/4.5.3/../../../libcygwin.a(libcmain.o):(.text+0xa9): >> >> undefined reference to `_WinMain AT 16' >> collect2: ld returned 1 exit status > > http://cygwin.com/faq-nochunks.html#faq.programming.winmain > >> >> How can I find out, why / where the problem is? Can the order of my -l >> flags create the problem? > > always on windows yes, but I can add the -lm flag, but it does not solve the problem Phil -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple