Share

ANT Contrib

Tracker: Bugs

5 Cannot build DLLs on Win32 with MinGW - ID: 1223693
Last Update: Settings changed ( alanbur )

I'm trying to build a DLL using cpptasks on win32,
using the MinGW (gcc) compiler. cpptasks insists in
building me libfoo.so instead of foo.dll. Here's the
appropriate bit of my build.xml:

<cc link="shared" outtype="shared"
exceptions="true"
multithreaded="true" optimize="speed"
objdir="${dist.dir}"
outfile="${dist.dir}/Foo">
<sysincludepath
location="${java.home}/../include"/>
<sysincludepath
location="${java.home}/../include/win32"/>
<fileset dir="${src.dir}/com/foo"
includes="Foo.c"/>
</cc>

If I add the following workaround I get foo.dll being
generated instead of libfoo.so

<linker name="gcc">
<linkerarg value="-o foo.dll"/>
</linker>

but that shouldn't be necessary.


Alan Burlison ( alanbur ) - 2005-06-19 18:32

5

Open

None

Curt Arnold

cpptasks

None

Public


Comments ( 2 )




Date: 2005-06-19 18:49
Sender: alanbur

Logged In: YES
user_id=1294929

Found the following patches that look like they might help

[ 846330 ] fixes for mingw
[ 837534 ] platform independence for mingw

They look like they overlap, so I'm not sure which to apply...


Date: 2005-06-19 18:34
Sender: alanbur

Logged In: YES
user_id=1294929

See also support request 1192798


Log in to comment.

Attached File

No Files Currently Attached

Change ( 1 )

Field Old Value Date By
summary Cannot build DLLs on Win32 2005-06-19 18:49 alanbur