diff -ur licq-1.2.6.orig/configure.in licq-1.2.6/configure.in
--- licq-1.2.6.orig/configure.in	Sun Mar 23 21:39:14 2003
+++ licq-1.2.6/configure.in	Fri Mar 28 22:54:56 2003
@@ -64,15 +64,24 @@
  		CPPFLAGS="$CPPFLAGS -fPIC -DPIC -D_REENTRANT"
 		echo "Setting Linux compilation options"
 		;;
-  *-*-aix*)
-    CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE"
-    LIBS="$LIBS -lc_r"
-    echo "Setting AIX compilation options"
-    ;;
-  *-*-irix*)
-    LDFLAGS="$LDFLAGS -L/usr/lib32"
-    echo "Setting Irix compilation options"
-    ;;
+	*-*-nto-qnx*)
+		CC="qcc -Vgcc_ntox86"
+		CPP="qcc -Vgcc_ntox86 -E"
+		CXX="qcc -Vgcc_ntox86_gpp"
+		CXXCPP="qcc -Vgcc_ntox86_gpp -E"
+		CPPFLAGS="$CPPFLAGS -fPIC -DPIC"
+		echo "Setting QNX Neutrino compilation options"
+		LIBS="-lstdc++"
+		;;
+	*-*-aix*)
+	        CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE"
+	        LIBS="$LIBS -lc_r"
+	        echo "Setting AIX compilation options"
+	        ;;
+	*-*-irix*)
+	        LDFLAGS="$LDFLAGS -L/usr/lib32"
+	        echo "Setting Irix compilation options"
+	        ;;
 	*)
 		echo "Licq may not compile on this system. Good luck :-)"
 		;;
diff -ur licq-1.2.6.orig/include/licq_socket.h licq-1.2.6/include/licq_socket.h
--- licq-1.2.6.orig/include/licq_socket.h	Wed Mar 20 16:00:54 2002
+++ licq-1.2.6/include/licq_socket.h	Fri Mar 28 22:37:39 2003
@@ -5,6 +5,10 @@
 #include "config.h"
 #endif
 
+#ifdef __QNXNTO__
+#include <sys/select.h>
+#endif
+
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
diff -ur licq-1.2.6.orig/src/file.cpp licq-1.2.6/src/file.cpp
--- licq-1.2.6.orig/src/file.cpp	Tue Oct 15 18:05:39 2002
+++ licq-1.2.6/src/file.cpp	Fri Mar 28 22:41:23 2003
@@ -500,7 +500,7 @@
   }
   else
   {
-    if ((szPostEquals = strchr(_szLine, '=')) == NULL)
+    if ((szPostEquals = (char *)strchr(_szLine, '=')) == NULL)
     {
        Warn(INI_ExFORMAT, _szLine);
        return NULL;
diff -ur licq-1.2.6.orig/src/icqd-filetransfer.cpp licq-1.2.6/src/icqd-filetransfer.cpp
--- licq-1.2.6.orig/src/icqd-filetransfer.cpp	Sat Jan 25 19:02:48 2003
+++ licq-1.2.6/src/icqd-filetransfer.cpp	Fri Mar 28 22:41:55 2003
@@ -73,7 +73,7 @@
   struct stat buf;
 
   // Remove any path from the filename
-  if ( (pcNoPath = strrchr(_szFileName, '/')) != NULL)
+  if ( (pcNoPath = (char *)strrchr(_szFileName, '/')) != NULL)
     m_szFileName = strdup(pcNoPath + 1);
   else
     m_szFileName = strdup(_szFileName);
diff -ur licq-1.2.6.orig/src/icqpacket.cpp licq-1.2.6/src/icqpacket.cpp
--- licq-1.2.6.orig/src/icqpacket.cpp	Sun Mar  2 23:11:16 2003
+++ licq-1.2.6/src/icqpacket.cpp	Fri Mar 28 22:36:05 2003
@@ -3984,7 +3984,7 @@
   }
 
   // Remove path from filename (if it exists)
-  char *pcEndOfPath = strrchr(_szFilename, '/');
+  char *pcEndOfPath = (char*)strrchr(_szFilename, '/');
   if (pcEndOfPath != NULL)
      m_szFilename = strdup(pcEndOfPath + 1);
   else
diff -ur licq-1.2.6.orig/src/licq.cpp licq-1.2.6/src/licq.cpp
--- licq-1.2.6.orig/src/licq.cpp	Thu Feb 27 17:33:04 2003
+++ licq-1.2.6/src/licq.cpp	Fri Mar 28 23:41:03 2003
@@ -138,8 +138,8 @@
 int global_argc = 0;
 
 // Plugin variables
-pthread_cond_t LP_IdSignal;
-pthread_mutex_t LP_IdMutex;
+pthread_cond_t LP_IdSignal = PTHREAD_COND_INITIALIZER;
+pthread_mutex_t LP_IdMutex = PTHREAD_MUTEX_INITIALIZER;
 list<unsigned short> LP_Ids;
 
 CLicq::CLicq()
diff -ur licq-1.2.6.orig/src/translate.cpp licq-1.2.6/src/translate.cpp
--- licq-1.2.6.orig/src/translate.cpp	Thu Oct 17 03:43:52 2002
+++ licq-1.2.6/src/translate.cpp	Fri Mar 28 22:40:59 2003
@@ -62,7 +62,7 @@
 bool CTranslator::setTranslationMap(const char *_szMapFileName)
 {
   // Map name is the file name with no path
-  char *szMapName = strrchr(_szMapFileName, '/');
+  char *szMapName = (char *)strrchr(_szMapFileName, '/');
   if (szMapName == NULL)
     m_szMapName = strdup(_szMapFileName);
   else
diff -ur licq-1.2.6.orig/src/utility.cpp licq-1.2.6/src/utility.cpp
--- licq-1.2.6.orig/src/utility.cpp	Tue Oct 29 05:12:24 2002
+++ licq-1.2.6/src/utility.cpp	Fri Mar 28 22:38:40 2003
@@ -35,7 +35,7 @@
 //=====CUtilityManager==========================================================
 int SelectUtility(const struct dirent *d)
 {
-  char *pcDot = strrchr(d->d_name, '.');
+  char *pcDot = (char *)strrchr(d->d_name, '.');
   if (pcDot == NULL) return (0);
   return (strcmp(pcDot, ".utility") == 0);
 }
