mingw-cross-env-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Mingw-cross-env-list] Support for sox/libsox


From: Tony Theodore
Subject: Re: [Mingw-cross-env-list] Support for sox/libsox
Date: Thu, 23 Jun 2011 23:15:34 +1000

2011/5/22 Robert Chéramy <address@hidden>:
> Hello,
>
> so here is my new proposal for sox. The resulting library has to be
> linked with libtool in order to resolve subdependencies. An example is
> in "sox.mk" (compiling sox-test.c).
> Note that libtool has to be configured for the "i686-pc-mingw32" target
> (/usr/bin/libtool won't do), but if you use autoconf/automake, this
> should not be a problem.

Hi tibob,

A couple of comments:

1. The static patch is unnecessary as ./configure will define the
STATIC_LIBSOX_ONLY if you pass the --disable-shared option (since
--enable-static is the default). You can verify this by checking
$(PREFIX)/$TARGET)/bin/sox.exe is actually a static executable when
built without the patch.

2. This exe (along with man pages etc.) should be excluded before
inclusion in mingw-cross-env, but it's a useful test while developing.

3. You've listed a few dependencies, but ./configure isn't detecting
them. This is an issue with GCC 4.6 and the --no-undefined linker
option [1] See exiv2 and xine-lib mentioned in that message for a
proper solution.

4. If you want a quick check of the dependency detection, add a line like:

$(SED) -i 's,-no-undefined,-Wl\,-no-undefined,g' '$(1)/configure'

before configure is run. You should see many more dependencies listed
in the config summary, and the sox.exe will go from about 1.9MB to
18.8MB.

5. The libtool approach to linking is unlikely to work outside of the
build tree and pkg-config is probably a better way to go. I haven't
had time to populate the sections of sox.pc.in properly, but the
attached hack should give you an idea of how to solve the linking
issues.

Hope this helps,

Tony


[1] 
http://lists.nongnu.org/archive/html/mingw-cross-env-list/2011-03/msg00125.html

Attachment: sox.mk
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]