Martin, Thank you very much for your suggestion. You were right. It works without --with-openssl=/opt/local and the problem is exactly what you suggest. As I am not sure how to see the actual build command line I removed a semicolon at the end of a line in utf8-posix.cpp to induce a build error and have a look at the compiler command line.
With the --with-openssl=/opt/local in configure the line for the build line of utf8-posix.cpp contains '-I/opt/local/include'. So it pulls in the header for libiconv in /opt/local/lib. At link time the linker links libiconv.dylib from /Developer/SDKs/MacOSX10.6.sdk that does not match the header from /opt/local/include After I started this thread I saw that the very same problem was reported a while back and the suggested workaround by the person reporting the issue was to add /opt/local/lib as a lib path for the linker: http://comments.gmane.org/gmane.comp.emulators.virtualbox.devel/2862 I am not sure if this should be considered a bug but I feel that a flag for specifying the openssl location should not impact the build of a component that does not use openssl at all. Arend On Tue, Sep 13, 2011 at 10:41 AM, Martin Simmons <[email protected]>wrote: > >>>>> On Tue, 13 Sep 2011 09:17:53 -0700, Arend Dittmer said: > > > > Thanks again. It looks like you are right ... there are no function > > prototypes for the symbols libiconv, libiconv_open and libiconv_close > > in /Developer/SDKs/MacOSX10.6.sdk/usr/include/iconv.h which corresponds > to > > /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libiconv.dylib > > > > Question is ... which flag do I set to have the build pick up > > the MacOSX10.6.sdk version? > > > > Just not sure what VirtualBox build flag makes it pick up the right > header. > > Do you really need --with-openssl-dir=/opt/local in the configuration? I > suspect that option adds /opt/local/include to the include path, so the > compiler finds /opt/local/include/iconv.h by accident. > > __Martin > > > > > > On Tue, Sep 13, 2011 at 7:10 AM, François Revol <[email protected]> wrote: > > > > > Le 13/09/2011 16:05, Arend Dittmer a écrit : > > > > Thank you Darshan and Francois for getting back to me. For the build > that > > > > fails the linker tries to link with libiconv in > > > > /Developer/SDKs/MacOSX10.6.sdk: > > > [...] > > > > If I manually run the command in the same directory and force linking > > > with > > > > the macports libiconv it actually builds. The macports library is > > > universal: > > > > > > It's possible that it always finds the iconv headers from MacPorts > > > first regardless, then it fails linking with the SDK one due to > > > mismatched headers and lib. > > > > > > > The issue is that libiconv in /Developer/SDKs/MacOSX10.6.sdk* *does > not > > > have > > > > the _libiconv symbol (and the other symbols that are missing which > are > > > > _libiconv_open and _libiconv_close) for 64-bit: > > > > > > By experience, there are several "versions" of the iconv symbol names. > > > This is meant to make it possible to link with an external libiconv or > > > the one included with the libc on some platforms. > > > For ex. when defining LIBICONV_PLUG. > > > > > > If it picked up the wrong headers then it will try to use wrong > symbols. > > > > > > François. > > > > > > > > > > > -- > > Arend Dittmer > > TheMicroComputer > > Phone: 415 497 7797 > > e-mail: [email protected] > > http://www.mypocketxp.com > > > > _______________________________________________ > vbox-dev mailing list > [email protected] > http://vbox.innotek.de/mailman/listinfo/vbox-dev > -- Arend Dittmer TheMicroComputer Phone: 415 497 7797 e-mail: [email protected] http://www.mypocketxp.com
_______________________________________________ vbox-dev mailing list [email protected] http://vbox.innotek.de/mailman/listinfo/vbox-dev
