From: Philipp Kraus <philipp.kraus@flashpixx.de>
To: cygwin@cygwin.com
Subject: Re: linker error libcygwin
Date: Sun, 13 Nov 2011 11:44:00 -0000 [thread overview]
Message-ID: <j9oah9$trp$1@dough.gmane.org> (raw)
In-Reply-To: <4EBC730C.4070701@sbcglobal.net>
On 2011-11-11 01:57:48 +0100, Greg Chicares said:
> On 2011-11-10 21:22Z, Philipp Kraus wrote:
>> On 2011-11-10 22:11:48 +0100, Greg Chicares said:
>>
>>> On 2011-11-10 20:39Z, Kraus Philipp wrote:
>>>>
>>>> undefined reference to `_WinMain@16'
>>>> collect2: ld returned 1 exit status
>>>
>>> Does this thread
>>> http://cygwin.com/ml/cygwin/2011-10/threads.html#00440
>>> contain the answer?
>>
>> no, sorry.
>>
>>> If this is a console application, does it have
>>> an implementation of main()?
>>
>> yes the signature of the main is in this example:
>> int main(int argc, char* argv[])
>
> Please show the full linker command, and indicate the name of
> the object file that contains main().
The full linker command shows (I split the flags for a better reading):
g++ -o build/target.exe -mconsole -enable-stdcall-fixup -mthread
examples/other/target.o
-L/usr/local/bin
-L/usr/bin
-L/cygdrive/c/Windows/system32
-L/cygdrive/c/Windows
-L/cygdrive/c/Windows/system32/Wbem
-L/cygdrive/c/Windows/system32/WindowsPowerShell/v1.0
"-L/cygdrive/c/Program Files/TortoiseSVN/bin"
"-L/cygdrive/c/Program Files/Java/jdk1.6.0_29/bin"
-L/cygdrive/c/opt/scons/bin
-L/cygdrive/c/opt/library/atlas/3.9.51/lib
-L/cygdrive/c/opt/library/boost/1.47.0/bin
-L/cygdrive/c/opt/library/boost/1.47.0/lib
-L/cygdrive/c/opt/library/cln/1.3.2/lib
-L/cygdrive/c/opt/library/ginac/1.6.1/lib
-L/cygdrive/c/opt/library/hdf/5-1.8.7/lib
-L/cygdrive/c/opt/library/xml2/2.7.8/bin
-L/cygdrive/c/opt/library/xml2/2.7.8/lib
-L/cygdrive/c/opt/library/jsoncpp/0.5.0/lib
-lboost_system
-lboost_thread
-lboost_iostreams
-lboost_regex
-lboost_program_options
-lboost_exception
-lboost_filesystem
-llapack
-lcblas
-lf77blas
-latlas
-lgfortran
-lhdf5_cpp
-lhdf5
I have tested the same call with another example (only the *.cpp / *.o
file changes) and it works. The difference is the cpp code, but
a compiler call run's without an error. I don't understand why
different sources with the same linker command creates different
results.
The linking process should be deterministic, so the compiled object
code creates the same linker calls.
Thanks
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
next prev parent reply other threads:[~2011-11-13 11:44 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-10 20:39 Kraus Philipp
2011-11-10 21:04 ` Marco Atzeri
2011-11-10 21:20 ` Philipp Kraus
2011-11-10 21:12 ` Greg Chicares
2011-11-10 21:25 ` Philipp Kraus
2011-11-11 0:58 ` Greg Chicares
2011-11-11 11:48 ` Philipp Kraus
2011-11-13 11:44 ` Philipp Kraus [this message]
2011-11-13 12:59 ` Philipp Kraus
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='j9oah9$trp$1@dough.gmane.org' \
--to=philipp.kraus@flashpixx.de \
--cc=cygwin@cygwin.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).