Trying to compile the dlfcn-win32

Erik van Pienbroek erik at vanpienbroek.nl
Sun Apr 10 11:01:05 UTC 2011


Jay Higley schreef op wo 06-04-2011 om 16:11 [-0400]:
> I have a separate project that I am working on that would use dlfcn,
> so that is why I'm trying to port it. I am running Core 15.
> 
> Thanks for looking at this. Any help is greatly appreciated.
> 
> The actual error message is ...
> + ../configure --host=i686-w64-mingw32
> --build=x86_64-unknown-linux-gnu --target=i686-w64-mingw32
> --prefix=/usr/i686-w64-mingw32/sys-root/mingw
> --exec-prefix=/usr/i686-w64-mingw32/sys-root/mingw
> --bindir=/usr/i686-w64-mingw32/sys-root/mingw/bin
> --sbindir=/usr/i686-w64-mingw32/sys-root/mingw/sbin
> --sysconfdir=/usr/i686-w64-mingw32/sys-root/mingw/etc
> --datadir=/usr/i686-w64-mingw32/sys-root/mingw/share
> --includedir=/usr/i686-w64-mingw32/sys-root/mingw/include
> --libdir=/usr/i686-w64-mingw32/sys-root/mingw/lib
> --libexecdir=/usr/i686-w64-mingw32/sys-root/mingw/libexec
> --localstatedir=/usr/i686-w64-mingw32/sys-root/mingw/var
> --sharedstatedir=/usr/i686-w64-mingw32/sys-root/mingw/com
> --mandir=/usr/i686-w64-mingw32/sys-root/mingw/share/man
> --infodir=/usr/i686-w64-mingw32/sys-root/mingw/share/info
> --disable-shared --enable-static
> /tmp/test.c:1:21: fatal error: windows.h: No such file or directory
> compilation terminated.
> prefix: /usr/i686-w64-mingw32/sys-root/mingw
> libdir: /usr/i686-w64-mingw32/sys-root/mingw/lib
> incdir: /mingw/include
> cc:     gcc
> static: yes
> shared: no
> error: Bad exit status from /var/tmp/rpm-tmp.nVuZgi (%build)

Hi,

This is one of those packages which uses custom-written Makefiles and
don't support cross-compilation out of the box (as can be seen in the
native .spec file at
http://pkgs.fedoraproject.org/gitweb/?p=mingw32-dlfcn.git;a=blob;f=mingw32-dlfcn.spec;h=d78256d10423ba13753df232d5205592e7c816be;hb=HEAD )

I've just customized your .spec file so that the build of dlfcn can be
done succesfully for both mingw32 and mingw64 targets. You can find the
source RPM at
http://www.ftd4linux.nl/contrib/cross-dlfcn-0-0.8.r11.fc15.src.rpm

This SRPM is compatible with the testing repository, but not with the
new packaging guidelines which are currently under review at
https://fedorahosted.org/fpc/ticket/71 (as there are some small changes
in the naming)

Kind regards,

Erik van Pienbroek






More information about the mingw mailing list