Bug 112749 - Compile error on Solaris 2.9 in dcctransfersend.cpp (fix included)
Summary: Compile error on Solaris 2.9 in dcctransfersend.cpp (fix included)
Status: RESOLVED FIXED
Alias: None
Product: konversation
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Solaris
: NOR normal
Target Milestone: ---
Assignee: Konversation Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-16 18:51 UTC by Bernd Kuhls
Modified: 2005-09-17 09:52 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bernd Kuhls 2005-09-16 18:51:56 UTC
Version:           0.18 (using KDE KDE 3.4.2)
Installed from:    Compiled From Sources
Compiler:          gcc 3.3.5 
OS:                Solaris

if g++ -DHAVE_CONFIG_H -I. -I. -I../..  -Ilinkaddressbook -I./linkaddressbook -I/usr/local/KDE-3.4.2/include -I/usr/local/qt-050201/include    -DQT_THREAD_SUPPORT  -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -DUSE_SOLARIS -DSVR4  -Wnon-virtual-dtor -Wno-long-long -Wundef -Wall -W -Wpointer-arith -Wno-non-virtual-dtor -O2 -fno-exceptions -fno-check-new -fno-common -DQT_CLEAN_NAMESPACE -DQT_NO_ASCII_CAST -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION -DQT_NO_TRANSLATION -DQT_CLEAN_NAMESPACE -DQT_NO_ASCII_CAST -DQT_NO_COMPAT  -MT dcctransfersend.o -MD -MP -MF ".deps/dcctransfersend.Tpo" -c -o dcctransfersend.o dcctransfersend.cpp; \
then mv -f ".deps/dcctransfersend.Tpo" ".deps/dcctransfersend.Po"; else rm -f ".deps/dcctransfersend.Tpo"; exit 1; fi
dcctransfersend.cpp: In constructor `
   DccTransferSend::DccTransferSend(DccPanel*, const QString&, const KURL&,
   const QString&, const QString&, unsigned int)':
dcctransfersend.cpp:68: error: `SIOCGIFADDR' undeclared (first use this
   function)
dcctransfersend.cpp:68: error: (Each undeclared identifier is reported only
   once for each function it appears in.)
dcctransfersend.cpp:68: error: `ioctl' undeclared (first use this function)
make[4]: *** [dcctransfersend.o] Error 1

Including these lines on top of the file fixes the problem, Konversation works fine on Solaris/Sparc:

#include <unistd.h>
#include <sys/sockio.h>
Comment 1 Ismail Donmez 2005-09-17 09:50:02 UTC
Thank you for your patch, I will commit when KDE SVN is up again, it seems to be down at the moment.
Comment 2 Ismail Donmez 2005-09-17 09:51:59 UTC
SVN commit 461280 by cartman:

Compile on Solaris 2.9 . Patch by Bernd Kuhls. Thanks!
BUG:112749



 M  +4 -0      dcctransfersend.cpp  


--- trunk/extragear/network/konversation/src/dcctransfersend.cpp #461279:461280
@@ -14,6 +14,10 @@
   (at your option) any later version.
 */
 
+#ifdef USE_SOLARIS
+#include <unistd.h>
+#include <sys/sockio.h>
+#endif
 #include <stdlib.h>
 #include <sys/types.h>
 #include <netinet/in.h>