Hi there...
Its being a while we spoke about this and I end up deciding to build a linux
box to do the cross compiling, instead of OSX.
Things are way smoother now, but I'm running into trouble with ilmbase
again.
This time, I followed Doug Siemer advice and I setup
--host=i686-w64-mingw32.
This seemed to make the whole thing better and I got it
all building without any patching, but I'm now running into one issue:
when g++ builds libHalf.dll.a, it generates the libHalf.la and libHalf.dll.a
correctly (not a single error), but I get no .dll.
the dll should be named libHalf-6.dll, but nothing...
this is libHalf.la file:
# libHalf.la - a libtool library file
# Generated by ltmain.sh - GNU libtool 1.5.14 (1.1220.2.195 2005/02/12
12:12:33)
#
# Please DO NOT delete this file!
# It is necessary for linking the library.
# The name that we can dlopen(3).
dlname='libHalf-6.dll'
# Names of this library.
library_names='libHalf.dll.a'
# The name of the static archive.
old_library='libHalf.lib'
# Libraries that this one depends upon.
dependency_libs='
/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2/../../../../i686-w64-mingw32/lib/../lib32//libstdc++.la'
# Version information for libHalf.
current=6
age=0
revision=0
# Is this an already installed library?
installed=no
# Should we warn about portability when linking against -modules?
shouldnotlink=no
# Files to dlopen/dlpreopen
dlopen=''
dlpreopen=''
this is the build output when building libHalf:
/bin/bash ../libtool --tag=CXX --mode=link
/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.current32/bin/i686-w64-mingw32-g++
-I./src/include -DWINAPI=__stdcall -D__MINGW32__ -D_WIN32 -DMINGW
-DHAVE_STRUCT_TIMESPEC
-I/media/MyBook2TB_2/Mirror/cortex4all/trunk/OIIO/externals/dist/mingw/include/zlib-1.2.3
-L/media/MyBook2TB_2/Mirror/cortex4all/trunk/OIIO/externals/build/mingw/obj/zlib-1.2.3
-pipe -g -O2 -o libHalf.la -rpath
/media/MyBook2TB_2/Mirror/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/lib
-version-info 6:0:0 -no-undefined half.lo
libtool: link: warning: library
`/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2/../../../../i686-w64-mingw32/lib/../lib32//libstdc++.la'
was moved.
/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.current32/bin/i686-w64-mingw32-g++
-I./src/include -DWINAPI=__stdcall -D__MINGW32__ -D_WIN32 -DMINGW
-DHAVE_STRUCT_TIMESPEC
-I/media/MyBook2TB_2/Mirror/cortex4all/trunk/OIIO/externals/dist/mingw/include/zlib-1.2.3
-L/media/MyBook2TB_2/Mirror/cortex4all/trunk/OIIO/externals/build/mingw/obj/zlib-1.2.3
-shared -nostdlib
/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2/../../../../i686-w64-mingw32/lib/dllcrt2.o
/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2/crtbegin.o
.libs/half.o
-L/media/MyBook2TB_2/Mirror/cortex4all/trunk/OIIO/externals/build/mingw/obj/zlib-1.2.3
-L/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2
-L/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc
-L/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2/../../../../i686-w64-mingw32/lib/../lib32
-L/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2/../../../../i686-w64-mingw32/lib
/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2/../../../../i686-w64-mingw32/lib/../lib32//libstdc++.dll.a
-lmingw32 -lgcc_s -lgcc -lmoldname -lmingwex -lmsvcrt -luser32 -lkernel32
-ladvapi32 -lshell32 -lmingw32 -lgcc_s -lgcc -lmoldname -lmingwex -lmsvcrt
/media/MyBook2TB_2/Mirror/cortex4all/trunk/compilers/linux.mingw32.4.5.2_20100917/bin/../lib/gcc/i686-w64-mingw32/4.5.2/crtend.o
-o .libs/libHalf.dll.a
lib /OUT:.libs/libHalf.lib half.o
fixme:heap:HeapSetInformation (nil) 1 (nil) 0
fixme:heap:HeapSetInformation (nil) 1 (nil) 0
Microsoft (R) Library Manager Version 9.00.30729.01
Copyright (C) Microsoft Corporation. All rights reserved.
creating libHalf.la
(cd .libs && rm -f libHalf.la && ln -s ../libHalf.la libHalf.la)
as you can see, there's no errors at this point, but later when installing
it complains about not finding the dll.
any thoughts?
-H
On Tue, Jun 8, 2010 at 9:39 AM, Hradec <[email protected]> wrote:
> I fixed the "::_Exit" error in cstdlib by replacing line 165 by the _Exit
> declaration found at line 163, which defines a proper _Exit function that
> trows an exception... seems to be compiling correctly now.
>
> Now I got something really weird... Libtool found an weird path that seems
> to be hardcoded into gcc:
>
> /bin/sh ../libtool --tag=CXX --mode=link i686-w64-mingw32-g++
> -I/Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/pthreads/build/GC_x86_4.6.0_20100528/include/
> -L/Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/pthreads/build/GC_x86_4.6.0_20100528/lib/
> -I./src/include -DWINAPI=__stdcall -D__MINGW32__ -D_WIN32 -DMINGW
> -DHAVE_STRUCT_TIMESPEC
> -I/Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/dist/mingw/include/zlib-1.2.3
> -L/Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/dist/mingw/lib/zlib-1.2.3
> -pipe -g -O2
> -I/Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/include/OpenEXR
> -L/Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/lib
> -L/usr/local/lib -o libIlmImf.la -rpath
> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/openexr-1.6.1/lib
> -L/Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/lib
> -L/usr/local/lib -version-info 6:0:0 -no-undefined ImfAttribute.lo
> ImfBoxAttribute.lo ImfCRgbaFile.lo ImfChannelList.lo
> ImfChannelListAttribute.lo ImfFloatAttribute.lo ImfFrameBuffer.lo
> ImfHeader.lo ImfIO.lo ImfInputFile.lo ImfIntAttribute.lo
> ImfLineOrderAttribute.lo ImfMatrixAttribute.lo ImfOpaqueAttribute.lo
> ImfOutputFile.lo ImfRgbaFile.lo ImfStringAttribute.lo ImfVecAttribute.lo
> ImfHuf.lo ImfThreading.lo ImfWav.lo ImfLut.lo ImfCompressor.lo
> ImfRleCompressor.lo ImfZipCompressor.lo ImfPizCompressor.lo
> ImfB44Compressor.lo ImfMisc.lo ImfCompressionAttribute.lo
> ImfDoubleAttribute.lo ImfConvert.lo ImfPreviewImage.lo
> ImfPreviewImageAttribute.lo ImfVersion.lo ImfChromaticities.lo
> ImfChromaticitiesAttribute.lo ImfKeyCode.lo ImfKeyCodeAttribute.lo
> ImfTimeCode.lo ImfTimeCodeAttribute.lo ImfRational.lo
> ImfRationalAttribute.lo ImfFramesPerSecond.lo ImfStandardAttributes.lo
> ImfStdIO.lo ImfEnvmap.lo ImfEnvmapAttribute.lo ImfScanLineInputFile.lo
> ImfTiledInputFile.lo ImfTiledMisc.lo ImfTiledOutputFile.lo
> ImfTiledRgbaFile.lo ImfTileDescriptionAttribute.lo ImfTileOffsets.lo
> ImfRgbaYca.lo ImfPxr24Compressor.lo ImfTestFile.lo -lz -lImath -lHalf -lIex
> -lIlmThread -lImath -lHalf -lIex -lIlmThread
>
> grep:
> /Users/jchesney/mingw-w64-buildslave/darwin-x86-x86/build/build/root/i686-w64-mingw32/lib/../lib/libstdc++.la:
> No such file or directory
> sed:
> /Users/jchesney/mingw-w64-buildslave/darwin-x86-x86/build/build/root/i686-w64-mingw32/lib/../lib/libstdc++.la:
> No such file or directory
> libtool: link:
> `/Users/jchesney/mingw-w64-buildslave/darwin-x86-x86/build/build/root/i686-w64-mingw32/lib/../lib/libstdc++.la'
> is not a valid libtool archive
>
> make[3]: *** [libIlmImf.la] Error 1
>
>
> theres no /Users/jchesney/ folder on my computer... I'm using the
> "automated build" binary distribution and seems to me that path is the
> original path used in the original build of the mingw64. Is there any way I
> can avoid gcc to return that?
>
>
>
> On Tue, Jun 8, 2010 at 12:26 AM, Hradec <[email protected]> wrote:
>
>> Hi there... I got it building past that point... thanks a lot for all the
>> help!!!
>>
>> But now I'm getting this when compiling another source:
>>
>> In file included from
>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/compilers/darwin.mingw32.4.6.0_20100605/bin/../lib/gcc/i686-w64-mingw32/4.6.0/../../../../i686-w64-mingw32/include/c++/4.6.0/bits/stl_algo.h:60:0,
>> from
>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/compilers/darwin.mingw32.4.6.0_20100605/bin/../lib/gcc/i686-w64-mingw32/4.6.0/../../../../i686-w64-mingw32/include/c++/4.6.0/algorithm:63,
>> from ImfPxr24Compressor.cpp:75:
>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/compilers/darwin.mingw32.4.6.0_20100605/bin/../lib/gcc/i686-w64-mingw32/4.6.0/../../../../i686-w64-mingw32/include/c++/4.6.0/cstdlib:165:11:
>> error: '::_Exit' has not been declared
>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/compilers/darwin.mingw32.4.6.0_20100605/bin/../lib/gcc/i686-w64-mingw32/4.6.0/../../../../i686-w64-mingw32/include/c++/4.6.0/cstdlib:203:22:
>> error: '__gnu_cxx::_Exit' has not been declared
>> make[3]: *** [ImfPxr24Compressor.lo] Error 1
>>
>> Seems like some miss-declaration... Am I missing something or this is a
>> bug?
>>
>> -H
>>
>>
>> On Wed, Jun 2, 2010 at 6:50 AM, Doug Semler <[email protected]> wrote:
>>
>>> On Tue, Jun 1, 2010 at 10:13 PM, Hradec <[email protected]> wrote:
>>> > also, by doing a grep _eLut, this is the result:
>>> >
>>> > hradec$ grep '_eLut'
>>> >
>>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/lib/*
>>> >
>>> > Binary file
>>> >
>>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/lib/libHalf.a
>>> > matches
>>> > Binary file
>>> >
>>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/lib/libHalf.so
>>> > matches
>>> > Binary file
>>> >
>>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/lib/libHalf.so.6
>>> > matches
>>> > Binary file
>>> >
>>> /Volumes/Data/Users/hradec/dev/svn/cortex4all/trunk/OIIO/externals/./build/mingw/ilmbase-1.0.1/lib/libHalf.so.6.0.0
>>> > matches
>>> >
>>> >
>>> > this is the lib folder from ilmbase:
>>> > -rw-r--r-- 1 hradec admin 280K 1 Jun 03:44 libHalf.a
>>> > -rwxr-xr-x 1 hradec admin 986B 1 Jun 03:44 libHalf.la
>>> > lrwxr-xr-x 1 hradec admin 16B 1 Jun 03:44 libHalf.so ->
>>> > libHalf.so.6.0.0
>>> > lrwxr-xr-x 1 hradec admin 16B 1 Jun 03:44 libHalf.so.6 ->
>>> > libHalf.so.6.0.0
>>> > -rwxr-xr-x 1 hradec admin 352K 1 Jun 03:44 libHalf.so.6.0.0
>>> > -rw-r--r-- 1 hradec admin 227K 1 Jun 03:44 libIex.a
>>> > -rwxr-xr-x 1 hradec admin 979B 1 Jun 03:44 libIex.la
>>> > lrwxr-xr-x 1 hradec admin 15B 1 Jun 03:44 libIex.so ->
>>> libIex.so.6.0.0
>>> > lrwxr-xr-x 1 hradec admin 15B 1 Jun 03:44 libIex.so.6 ->
>>> > libIex.so.6.0.0
>>> > -rwxr-xr-x 1 hradec admin 249K 1 Jun 03:44 libIex.so.6.0.0
>>> > -rw-r--r-- 1 hradec admin 142K 1 Jun 03:45 libIlmThread.a
>>> > -rwxr-xr-x 1 hradec admin 1.1K 1 Jun 03:45 libIlmThread.la
>>> > lrwxr-xr-x 1 hradec admin 21B 1 Jun 03:45 libIlmThread.so ->
>>> > libIlmThread.so.6.0.0
>>> > lrwxr-xr-x 1 hradec admin 21B 1 Jun 03:45 libIlmThread.so.6 ->
>>> > libIlmThread.so.6.0.0
>>> > -rwxr-xr-x 1 hradec admin 255K 1 Jun 03:45 libIlmThread.so.6.0.0
>>> > -rw-r--r-- 1 hradec admin 164K 1 Jun 03:44 libImath.a
>>> > -rwxr-xr-x 1 hradec admin 1.1K 1 Jun 03:44 libImath.la
>>> > lrwxr-xr-x 1 hradec admin 17B 1 Jun 03:44 libImath.so ->
>>> > libImath.so.6.0.0
>>> > lrwxr-xr-x 1 hradec admin 17B 1 Jun 03:44 libImath.so.6 ->
>>> > libImath.so.6.0.0
>>> > -rwxr-xr-x 1 hradec admin 283K 1 Jun 03:44 libImath.so.6.0.0
>>> > drwxr-xr-x 3 hradec admin 102B 1 Jun 03:45 pkgconfig
>>> >
>>> > I got no bin folder and no dll's... only this lib and the include.
>>> >
>>> >
>>>
>>> It's looking like the package built for the native system. Either
>>> that or you're trying to mix and match the target libraries in the
>>> same directory (bad idea). The .so files are not for the windows
>>> target. Maybe you misconfigured the library package - when cross
>>> compiling you probably need to specify
>>> --host=x86_64-w64-mingw32
>>>
>>> not
>>>
>>> --target=x86_64-w64-mingw32
>>>
>>> The --target parameter is used only when creating a cross compiler
>>> (telling the compiler what it's going to be targeting). While
>>> normally you'll specify --host, which tells the configuration routines
>>> what the machine you will be RUNNING the result on.
>>>
>>
>>
>>
>> --
>> Hradec
>>
>
>
>
> --
> Hradec
>
--
Hradec
------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public