Re: libsoup on MS Windows problems
- From: Egon Andersen <ean talura dk>
- To: Tor Lillqvist <tml iki fi>
- Cc: libsoup-list gnome org
- Subject: Re: libsoup on MS Windows problems
- Date: Fri, 19 Mar 2010 10:56:54 +0100
Tor Lillqvist wrote:
But I found it a little strange that I had to add
PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
Why do you find that strange? Which pkg-config are you using and where
do you have the pkg-config.exe? Unless pkg-config.exe is located at
/usr/local/bin/pkg-config.exe, pkg-config won't search in
/usr/local/lib/pkgconfig.
I find it a little strange, as I would expect that a series of default
installations of packages that depends on each other would be working
without having to add any options or environment variables to the
configure script.
And traditionally the configure script by default uses /usr/local as
prefix for installation.
Therefore it would be natural for me that the configure script would
ensure that dependency packages would be found if they vere located in
such traditional default location.
So my expectation has nothing to do with pkg-config as such, eventhough
pkg-config is used under the hood.
The first three warnings about libshlwapi.a, libdnsapi.a and libole32.a I
find a little strange, at they are part of the w32api downloaded from the
MinGW site, and do not have these as shared libraries.
Yes you have, in $WINDIR/system32. shlwapi.dll, dnsapi.dll and ole32.dll.
Okay, I searched for libshlwapi.dll etc. so that explains why I couldn't
find them.
It's just libtool that is being over-protective and silly. You can
tell it to stop that by passing the environment variable
lt_cv_deplibs_check_method='pass_all' when running configure, for
instance.
Thanks, that did the trick :-)
Well, the make didn't end with an error,
Yeah, but you ended up with a static libsoup, which probably is not
what you wanted. As such, I *think* libsoup should work also as a
static library, it doesn't seem to need to call DllMain() to find out
its run-time location.
I can confirm that libsoup do work as a static library with my application.
And yes, I would like it to use dynamic linking. I tried to do that, but
got into some problems. See later in this email.
> undefined reference to `g_cancellable_cancel'
Well, do you link with -lgio-2.0, where this function is?
undefined reference to `htons 4'
This should be in -lws2_32.
Oh yes, of cause. Was confused by the fact that I couldn't find the
dynamic linked libraries and was not thinking of the flags.
Furthermore, on Linux, I have no problems with libsoup and my application.
Well, you have developed the code originally on Linux, and only now
tried building it on Windows, so why does this surprise you?.
It wasn't to say I was surprised, it was just to inform that the program
code for my application wasn't totally untested in relation to libsoup.
Problem in relation to shared library
*************************************
I tried to build libsoup as shared library. I did as follows:
./configure PKG_CONFIG_PATH=/usr/local/lib/pkgconfig \
lt_cv_deplibs_check_method='pass_all'
This went fine without the warnings seen before.
Hereafter I did the make stage:
$ make
make all-recursive
make[1]: Entering directory
`/home/ean/Projects/libraries/libsoup/libsoup-2.29.91'
Making all in libsoup
make[2]: Entering directory
`/home/ean/Projects/libraries/libsoup/libsoup-2.29.91/libsoup'
make all-am
make[3]: Entering directory
`/home/ean/Projects/libraries/libsoup/libsoup-2.29.91/libsoup'
CC soup-marshal.lo
CC soup-enum-types.lo
CC soup-address.lo
CC soup-auth.lo
CC soup-auth-basic.lo
CC soup-auth-digest.lo
CC soup-auth-ntlm.lo
CC soup-auth-domain.lo
CC soup-auth-domain-basic.lo
CC soup-auth-domain-digest.lo
CC soup-auth-manager.lo
CC soup-auth-manager-ntlm.lo
CC soup-coding.lo
CC soup-coding-gzip.lo
CC soup-connection.lo
CC soup-content-decoder.lo
CC soup-content-sniffer.lo
CC soup-cookie.lo
CC soup-cookie-jar.lo
CC soup-cookie-jar-text.lo
CC soup-date.lo
CC soup-form.lo
CC soup-gnutls.lo
CC soup-headers.lo
CC soup-logger.lo
CC soup-message.lo
CC soup-message-body.lo
CC soup-message-client-io.lo
CC soup-message-headers.lo
CC soup-message-io.lo
CC soup-message-queue.lo
CC soup-message-server-io.lo
CC soup-method.lo
CC soup-misc.lo
CC soup-multipart.lo
CC soup-nossl.lo
CC soup-password-manager.lo
CC soup-path-map.lo
CC soup-proxy-resolver.lo
CC soup-proxy-resolver-static.lo
CC soup-proxy-uri-resolver.lo
CC soup-server.lo
CC soup-session.lo
CC soup-session-async.lo
CC soup-session-feature.lo
CC soup-session-sync.lo
CC soup-socket.lo
soup-socket.c: In function `soup_socket_connect_sync':
soup-socket.c:843: warning: 'cancel_id' might be used uninitialized in
this function
CC soup-status.lo
CC soup-uri.lo
CC soup-value-utils.lo
CC soup-xmlrpc.lo
CCLD libsoup-2.4.la
Opretter biblioteksfil: .libs/libsoup-2.4.dll.a
make[3]: Leaving directory
`/home/ean/Projects/libraries/libsoup/libsoup-2.29.91/libsoup'
make[2]: Leaving directory
`/home/ean/Projects/libraries/libsoup/libsoup-2.29.91/libsoup'
Making all in tests
make[2]: Entering directory
`/home/ean/Projects/libraries/libsoup/libsoup-2.29.91/tests'
CC chunk-test.o
CC test-utils.o
test-utils.c: In function `soup_test_session_abort_unref':
test-utils.c:254: warning: dereferencing type-punned pointer will break
strict-aliasing rules
test-utils.c:262: warning: dereferencing type-punned pointer will break
strict-aliasing rules
test-utils.c: In function `test_server_shutdown':
test-utils.c:338: warning: dereferencing type-punned pointer will break
strict-aliasing rules
test-utils.c:352: warning: dereferencing type-punned pointer will break
strict-aliasing rules
CCLD chunk-test.exe
chunk-test.o:chunk-test.c:(.text+0x95): undefined reference to
`soup_message_body_append_buffer'
chunk-test.o:chunk-test.c:(.text+0xa4): undefined reference to
`soup_buffer_free'
chunk-test.o:chunk-test.c:(.text+0xc7): undefined reference to
`soup_message_body_complete'
chunk-test.o:chunk-test.c:(.text+0x1ea): undefined reference to
`soup_buffer_new_with_owner'
chunk-test.o:chunk-test.c:(.text+0x24b): undefined reference to
`soup_buffer_new_with_owner'
chunk-test.o:chunk-test.c:(.text+0x328): undefined reference to
`soup_message_body_get_chunk'
chunk-test.o:chunk-test.c:(.text+0x334): undefined reference to
`soup_buffer_free'
chunk-test.o:chunk-test.c:(.text+0x391): undefined reference to
`soup_session_abort'
chunk-test.o:chunk-test.c:(.text+0x3a9): undefined reference to
`_SOUP_METHOD_GET'
chunk-test.o:chunk-test.c:(.text+0x3c0): undefined reference to
`_SOUP_METHOD_PUT'
chunk-test.o:chunk-test.c:(.text+0x415): undefined reference to
`soup_message_set_response'
chunk-test.o:chunk-test.c:(.text+0x420): undefined reference to
`soup_message_body_flatten'
chunk-test.o:chunk-test.c:(.text+0x428): undefined reference to
`soup_buffer_free'
chunk-test.o:chunk-test.c:(.text+0x43c): undefined reference to
`soup_message_set_status'
chunk-test.o:chunk-test.c:(.text+0x46f): undefined reference to
`soup_message_headers_append'
chunk-test.o:chunk-test.c:(.text+0x48e): undefined reference to
`_SOUP_METHOD_GET'
chunk-test.o:chunk-test.c:(.text+0x49b): undefined reference to
`_SOUP_METHOD_PUT'
chunk-test.o:chunk-test.c:(.text+0x4bd): undefined reference to
`_SOUP_METHOD_PUT'
chunk-test.o:chunk-test.c:(.text+0x4dd): undefined reference to
`soup_message_set_status'
chunk-test.o:chunk-test.c:(.text+0x558): undefined reference to
`soup_server_add_handler'
chunk-test.o:chunk-test.c:(.text+0x560): undefined reference to
`soup_server_get_port'
chunk-test.o:chunk-test.c:(.text+0x586): undefined reference to
`soup_uri_new'
chunk-test.o:chunk-test.c:(.text+0x597): undefined reference to
`soup_uri_set_port'
chunk-test.o:chunk-test.c:(.text+0x59c): undefined reference to
`soup_session_async_get_type'
chunk-test.o:chunk-test.c:(.text+0x670): undefined reference to
`soup_message_new_from_uri'
chunk-test.o:chunk-test.c:(.text+0x683): undefined reference to
`soup_message_headers_set_encoding'
chunk-test.o:chunk-test.c:(.text+0x695): undefined reference to
`soup_message_body_set_accumulate'
chunk-test.o:chunk-test.c:(.text+0x6b2): undefined reference to
`soup_message_set_chunk_allocator'
chunk-test.o:chunk-test.c:(.text+0x73d): undefined reference to
`soup_session_send_message'
chunk-test.o:chunk-test.c:(.text+0x7c9): undefined reference to
`soup_message_headers_get_one'
chunk-test.o:chunk-test.c:(.text+0x884): undefined reference to
`soup_message_new_from_uri'
chunk-test.o:chunk-test.c:(.text+0x897): undefined reference to
`soup_message_body_set_accumulate'
chunk-test.o:chunk-test.c:(.text+0x8b2): undefined reference to
`soup_message_set_chunk_allocator'
chunk-test.o:chunk-test.c:(.text+0x8e9): undefined reference to
`soup_session_send_message'
chunk-test.o:chunk-test.c:(.text+0x912): undefined reference to
`soup_message_headers_get_content_length'
chunk-test.o:chunk-test.c:(.text+0x949): undefined reference to
`soup_message_headers_get_one'
chunk-test.o:chunk-test.c:(.text+0x9e6): undefined reference to
`soup_message_new_from_uri'
chunk-test.o:chunk-test.c:(.text+0xa0e): undefined reference to
`soup_message_body_append'
chunk-test.o:chunk-test.c:(.text+0xa31): undefined reference to
`soup_message_body_append'
chunk-test.o:chunk-test.c:(.text+0xa42): undefined reference to
`soup_message_body_set_accumulate'
chunk-test.o:chunk-test.c:(.text+0xa94): undefined reference to
`soup_session_send_message'
chunk-test.o:chunk-test.c:(.text+0xab9): undefined reference to
`soup_message_headers_get_one'
chunk-test.o:chunk-test.c:(.text+0xb22): undefined reference to
`soup_uri_free'
chunk-test.o:chunk-test.c:(.text+0xb5f): undefined reference to
`soup_message_headers_get_content_length'
chunk-test.o:chunk-test.c:(.text+0x40): undefined reference to
`soup_buffer_new'
chunk-test.o:chunk-test.c:(.text+0xba): undefined reference to
`soup_session_unpause_message'
chunk-test.o:chunk-test.c:(.text+0xda): undefined reference to
`soup_session_unpause_message'
chunk-test.o:chunk-test.c:(.text+0x3e5): undefined reference to
`soup_message_set_status'
test-utils.o:test-utils.c:(.text+0x29c): undefined reference to
`soup_logger_new'
test-utils.o:test-utils.c:(.text+0x2aa): undefined reference to
`soup_session_feature_get_type'
test-utils.o:test-utils.c:(.text+0x2c7): undefined reference to
`soup_session_add_feature'
test-utils.o:test-utils.c:(.text+0x2dd): undefined reference to
`soup_session_feature_get_type'
test-utils.o:test-utils.c:(.text+0x2fa): undefined reference to
`soup_session_add_feature'
test-utils.o:test-utils.c:(.text+0x330): undefined reference to
`soup_session_abort'
test-utils.o:test-utils.c:(.text+0x39d): undefined reference to
`soup_server_run'
test-utils.o:test-utils.c:(.text+0x3bd): undefined reference to
`soup_server_quit'
test-utils.o:test-utils.c:(.text+0x410): undefined reference to
`soup_server_get_async_context'
test-utils.o:test-utils.c:(.text+0x42b): undefined reference to
`soup_add_completion'
test-utils.o:test-utils.c:(.text+0x45d): undefined reference to
`soup_server_quit'
test-utils.o:test-utils.c:(.text+0x523): undefined reference to
`soup_server_new'
test-utils.o:test-utils.c:(.text+0x549): undefined reference to
`soup_server_run_async'
collect2: ld returned 1 exit status
make[2]: *** [chunk-test.exe] Error 1
make[2]: Leaving directory
`/home/ean/Projects/libraries/libsoup/libsoup-2.29.91/tests'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory
`/home/ean/Projects/libraries/libsoup/libsoup-2.29.91'
make: *** [all] Error 2
The test programs in libsoup have problems to find functions defined in
libsoup? That seems to be bad news :-(
Just to see what happened I did:
make install
And libsoup-2.4-1.dll and friends were installed.
Trying to compile my own application and run it, gave similar errors as
the test programs supplied in libsoup - not surprising :-(
Do you have some idea about what went wrong in this make stage and why
the included test programs failed?
Best regards
Egon Andersen
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]