Jump to content


Photo
- - - - -

using QQ with gaim


  • Please log in to reply
9 replies to this topic

#1 Dr. Z2A

Dr. Z2A

    Dangerous free thinker

  • Members
  • 845 posts
  • Gender:Male
  • Location:San Francisco

Posted 18 November 2006 - 05:47 PM

Recently I heard about a chinese IM protocol called QQ. I am running Ubuntu, so I went looking for a gaim plugin that would let me use QQ with gaim. I found OpenQ, but it had no .deb files, all there were was .rpm and .tar.gz. So I downloaded the .tar.gz and tried to build from source. When I put in "make" I got the following errors at the end:

make[2]: *** [buddy_info.lo] Error 1
make[2]: Leaving directory `/usr/src/openq-0.3.2/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/openq-0.3.2'
make: *** [all] Error 2

Then I downloaded the src rpm but it only gave out a .tar.gz. I've also heard the the OpenQ plugin isn't supported very well. Does anyone know where to find a .deb file, or if the redhat rpm is safe to try installing, or how I can fix those make errors, or any other way to use QQ with gaim?

#2 Ohm

Ohm

    I could have written a book with all of these posts

  • Members
  • 3,209 posts
  • Gender:Male
  • Location:Maine, USA

Posted 18 November 2006 - 06:56 PM

You didn't include the actual error message in that. It will be a gcc or ld error message, not a make error message, so look up a bit.

#3 Dr. Z2A

Dr. Z2A

    Dangerous free thinker

  • Members
  • 845 posts
  • Gender:Male
  • Location:San Francisco

Posted 18 November 2006 - 07:05 PM

I don't know which is the main error is, but here is the full output of make:

make all-recursive
make[1]: Entering directory `/usr/src/openq-0.3.2'
Making all in intl
make[2]: Entering directory `/usr/src/openq-0.3.2/intl'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/usr/src/openq-0.3.2/intl'
Making all in nsis
make[2]: Entering directory `/usr/src/openq-0.3.2/nsis'
Making all in translations
make[3]: Entering directory `/usr/src/openq-0.3.2/nsis/translations'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/usr/src/openq-0.3.2/nsis/translations'
make[3]: Entering directory `/usr/src/openq-0.3.2/nsis'
make[3]: Nothing to be done for `all-am'.
make[3]: Leaving directory `/usr/src/openq-0.3.2/nsis'
make[2]: Leaving directory `/usr/src/openq-0.3.2/nsis'
Making all in po
make[2]: Entering directory `/usr/src/openq-0.3.2/po'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/usr/src/openq-0.3.2/po'
Making all in src
make[2]: Entering directory `/usr/src/openq-0.3.2/src'
source='buddy_info.c' object='buddy_info.lo' libtool=yes \
depfile='.deps/buddy_info.Plo' tmpdepfile='.deps/buddy_info.TPlo' \
depmode=gcc3 /bin/bash ../depcomp \
/bin/bash ../libtool --silent --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/gaim -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/gaim -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -DDATADIR=\"/usr/local/share\" -DLIBDIR=\"/usr/local/lib/gaim/\" -DLOCALEDIR=\"/usr/local/share/locale\" -DSYSCONFDIR=\"/usr/local/etc\" -DGAIM_PLUGINS -Wall -g -O2 -Wall -g3 -c -o buddy_info.lo `test -f 'buddy_info.c' || echo './'`buddy_info.c
buddy_info.c:25:47: error: internal.h: No such file or directory
In file included from buddy_opt.h:31,
from buddy_info.h:30,
from buddy_info.c:31:
qq.h:71: error: field 'dest_sin' has incomplete type
buddy_info.c: In function 'qq_send_packet_get_info':
buddy_info.c:66: warning: implicit declaration of function 'strlen'
buddy_info.c:66: warning: incompatible implicit declaration of built-in function 'strlen'
buddy_info.c:66: warning: pointer targets in passing argument 6 of 'qq_send_cmd' differ in signedness
buddy_info.c: In function 'qq_send_packet_modify_info':
buddy_info.c:111: warning: implicit declaration of function 'memmove'
buddy_info.c:111: warning: incompatible implicit declaration of built-in function 'memmove'
buddy_info.c:113: warning: incompatible implicit declaration of built-in function 'strlen'
buddy_info.c:116: warning: pointer targets in passing argument 3 of 'create_packet_data' differ in signedness
buddy_info.c:118: warning: pointer targets in passing argument 3 of 'create_packet_data' differ in signedness
buddy_info.c:124: warning: pointer targets in passing argument 3 of 'create_packet_data' differ in signedness
buddy_info.c: In function 'qq_process_modify_info_reply':
buddy_info.c:148: warning: pointer targets in passing argument 1 of 'atoi' differ in signedness
buddy_info.c:150: warning: implicit declaration of function '_'
buddy_info.c:150: warning: passing argument 4 of 'gaim_notify_message' makes pointer from integer without a cast
make[2]: *** [buddy_info.lo] Error 1
make[2]: Leaving directory `/usr/src/openq-0.3.2/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/openq-0.3.2'
make: *** [all] Error 2



#4 Ohm

Ohm

    I could have written a book with all of these posts

  • Members
  • 3,209 posts
  • Gender:Male
  • Location:Maine, USA

Posted 18 November 2006 - 07:21 PM

qq.h:71: error: field 'dest_sin' has incomplete type

That's your error right there. Looks like they forgot to include an inet header, maybe net/inet.h or something. Paste that line or maybe just the whole file. Looks like a minor problem.

#5 Dr. Z2A

Dr. Z2A

    Dangerous free thinker

  • Members
  • 845 posts
  • Gender:Male
  • Location:San Francisco

Posted 18 November 2006 - 08:55 PM

qq.h:

/**
* The QQ2003C protocol plugin
*
* for gaim
*
* Copyright © 2004 Puzzlebird
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/

// START OF FILE
/*****************************************************************************/
#ifndef _QQ_QQ_H_
#define _QQ_QQ_H_

#include <glib.h>
#include "proxy.h" // GaimProxyType
#include "internal.h" // socket
#include "roomlist.h" // GaimRoomlist
#include "ft.h" // GaimXfer

#define QQ_KEY_LENGTH 16
#define QQ_DEBUG 1 // whether we are doing DEBUG

typedef struct _qq_data qq_data;
typedef struct _qq_buddy qq_buddy;

struct _qq_buddy {
guint32 uid;
guint8 icon; // index: 01 - 85
guint8 age;
guint8 gender;
gchar *nickname;
guint8 ip[4];
guint16 port;
guint8 status;
guint8 flag1;
guint8 comm_flag; // details in qq_buddy_list.c
time_t signon;
time_t idle;
time_t last_refresh;
};

struct _qq_data {
gint fd; // socket file handler
guint32 uid; // QQ number
guint8 *inikey; // initial key to encrypt login packet
guint8 *pwkey; // password in md5 (or md5' md5)
guint8 *session_key; // later use this as key in this session

guint16 send_seq; // send sequence number
guint8 login_mode; // online of invisible
guint8 status; //
gboolean logged_in; // used by qq-add_buddy
gboolean use_tcp; // network in tcp or udp

GaimProxyType proxy_type; // proxy type
GaimXfer *xfer; // file transfer handler
struct sockaddr_in dest_sin; //line 71

// from real connction
gchar *server_ip;
guint16 server_port;
// get from login reply packet
time_t login_time;
time_t last_login_time;
gchar *last_login_ip;
// get from keep_alive packet
gchar *my_ip; // my ip address detected by server
guint16 my_port; // my port detected by server
guint8 my_icon; // my icon index
guint32 all_online; // the number of online QQ users
time_t last_get_online; // last time send get_friends_online packet

guint8 window[1 << 13]; // check up for duplicated packet
gint sendqueue_timeout;

GaimRoomlist *roomlist;
gint channel; // the id for opened chat conversation

GList *groups;
GList *group_packets;
GList *buddies;
GList *contact_info_window;
GList *qun_info_window;
GList *sendqueue;
GList *info_query;
GList *add_buddy_request;
GQueue *before_login_packets;
};

void qq_function_not_implemented(GaimConnection * gc);

#endif
/*****************************************************************************/
// END OF FILE


Edited by Dr. Z2A, 18 November 2006 - 08:58 PM.


#6 Ohm

Ohm

    I could have written a book with all of these posts

  • Members
  • 3,209 posts
  • Gender:Male
  • Location:Maine, USA

Posted 18 November 2006 - 09:08 PM

Try adding an include for netinet/in.h to the top of that file, or in internal.h. I think that should fix it.

#7 Dr. Z2A

Dr. Z2A

    Dangerous free thinker

  • Members
  • 845 posts
  • Gender:Male
  • Location:San Francisco

Posted 19 November 2006 - 02:24 AM

odd... I think the problem is that there is no internal.h

#8 Ohm

Ohm

    I could have written a book with all of these posts

  • Members
  • 3,209 posts
  • Gender:Male
  • Location:Maine, USA

Posted 19 November 2006 - 04:07 AM

It'll be somewhere in the QQ source code. Use the find command to locate it. It has to be there, or there would have been an error.

#9 Dr. Z2A

Dr. Z2A

    Dangerous free thinker

  • Members
  • 845 posts
  • Gender:Male
  • Location:San Francisco

Posted 19 November 2006 - 04:19 PM

I did do a locate for it, its not there. Theres also a line in the make output saying "buddy_info.c:25:47: error: internal.h: No such file or directory"

Edited by Dr. Z2A, 19 November 2006 - 04:21 PM.


#10 Ohm

Ohm

    I could have written a book with all of these posts

  • Members
  • 3,209 posts
  • Gender:Male
  • Location:Maine, USA

Posted 19 November 2006 - 04:35 PM

That explains everything.

http://gaim.sourcefo...nternal_8h.html

It's a gaim header. You do have the gaim headers installed, right? You'll probably need to install a gaim-dev package before you can compile gaim plugins.




BinRev is hosted by the great people at Lunarpages!