[Patch] fix compile kdecore with msvc

Christian Ehrlicher Ch.Ehrlicher at gmx.de
Sat Oct 29 19:20:44 BST 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

i've attached a small patch which allows me to compile and link kdecore
with msvc.

Changes:
network/kresolver.cpp
- - masked '#warning' - is gnuc-specific
network/kresolver.h
- - don't export KResolverResults to avoid compiler errors (*)
network/ksocketdevice.cpp
- - don't include ksockssocketdevice in windows to avoid linker errors
- - indentation fixes (tabulator -> spaces)
- - add kde_ioctl because ioctl isn't available in windows
network/syssocket.h
- - add kde_ioctl (**)
SConscript
- - add 'DMAKE_KDECORE_LIB' to ccflags instead cxxflags

* there is imho no need to export KResolverResults because nobody
derivates a class from KResolverResults. And if you really want to
export this class, you have to implement all functions QList<T> defines
because otherwise when someone wants to use a function you forgot to
implement he will get a linker error.

** I don't know excatly if this is the correct place, but I wouldn't put
this into win/include/msvc and win/include/mingw. The problem here is,
that ioctl is defined as ioctlsocket(int fd, int cmd, u_long* argp) and
I have to use a temporary variable to map between int and long.

I've another question regarding some header files: In win/include/ we've
some headers which are empty. Wouldn't it be better to avoid including
them instead using empty headerfiles? Shouldn't be a problem to mask
them with '#ifdef HAVE_XXX', or?


Christian

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFDY718nNKwkgf+zVMRAs9YAJ4+ipupNJYM2YwBSFFj/LGEJWnZaACcCPYB
A5fl03/ntTmyPytXe6mEOYA=
=nrxd
-----END PGP SIGNATURE-----
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kdecore.patch
Type: text/x-diff
Size: 3841 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20051029/7f1de0e6/attachment.patch>


More information about the kde-core-devel mailing list