Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
bitlbee + skype [solved]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
sdfg
Apprentice
Apprentice


Joined: 11 Feb 2005
Posts: 200

PostPosted: Wed Jul 04, 2012 3:48 pm    Post subject: bitlbee + skype [solved] Reply with quote

Hey everyone,

I'm having a bit of trouble setting up bitlbee to work with skype.

I compiled bitlbee with the skype use flag, which pulled in all the necessary deps. I ran skype first through vnc (so I could accept the licence agreement and allow skype4py access to the api). After that, skyped, skype4py, is supposed to be able to run skype via the api. However, whenever I try that, I get the following.

Code:

zeus .skyped # skyped -d -n -H 127.0.0.1 -p 2727
2012-07-04 14:39:05: Parsing config file '/root/.skyped/skyped.conf' done, username is 'myskypeusername'.
2012-07-04 14:39:05: skyped is started on port 2727
Traceback (most recent call last):
  File "/usr/bin/skyped", line 484, in <module>
    skype = SkypeApi()
  File "/usr/bin/skyped", line 278, in __init__
    self.skype.Client.Start()
  File "/usr/lib64/python2.7/site-packages/Skype4Py/client.py", line 273, in Start
    self._Skype._Api.startup(Minimized, Nosplash)
  File "/usr/lib64/python2.7/site-packages/Skype4Py/api/posix_dbus.py", line 179, in startup
    os.execlp('skype')
  File "/usr/lib64/python2.7/os.py", line 327, in execlp
    execvp(file, args)
  File "/usr/lib64/python2.7/os.py", line 344, in execvp
    _execvpe(file, args)
  File "/usr/lib64/python2.7/os.py", line 380, in _execvpe
    func(fullname, *argrest)
ValueError: execv() arg 2 must not be empty
Exiting.


When I run skype manually first, and then run skyped, skyped manages to connect and all seems well, until it comes time to add the skype account to bitlbee. Adding the account works no problem, however it can't actually contact the server. Whenever I turn the connection attempt off, bitlbee itself then falls over, only claiming

Code:

Jul  4 14:36:10 zeus bitlbee[26151]: Fatal signal received: 11. That's probably a bug.


in messages. Which isn't exactly helpful. Given it's python, I tried recompiling skype4py with both python 2.7 and 3.5, both gave the same error.

EDIT: Removed the plugin stuff, it's irrelevant. There are actually two separate issues here, first is skype4py not calling the API correctly, the second is bitlbee not connecting to skyped when it's running. The following post shows how to fix both.


Last edited by sdfg on Thu Jul 12, 2012 9:12 pm; edited 1 time in total
Back to top
View user's profile Send private message
sdfg
Apprentice
Apprentice


Joined: 11 Feb 2005
Posts: 200

PostPosted: Thu Jul 12, 2012 9:09 pm    Post subject: Reply with quote

Ok, solved it. Ignore bitlbee-skype, even 0.9 is ancient (it's currently on 3.x in bitlbee itself).

The problem lies with skype4py, as I suspected, and it's to do with differences between python 2.5 and 2.7. There is a patch file available https://raw.github.com/frugalware/frugalware-current/master/source/devel-extra/skype4py/skype4py-python27.patch. Pop it in /usr/portage/dev-python/skype4py/files. Then make a new ebuild (I called mine -r1 for consistency, and so portage would pick it up). Here is the ebuild:

Code:


# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-python/skype4py/skype4py-1.0.32.0.ebuild,v 1.3 2012/03/17 05:36:29 radhermit Exp $

EAPI="3"
PYTHON_DEPEND="2:2.5"
SUPPORT_PYTHON_ABIS="1"
# ctypes module required.
RESTRICT_PYTHON_ABIS="2.4 3.* *-jython"

inherit distutils autotools eutils

DESCRIPTION="Python wrapper for the Skype API"
HOMEPAGE="https://developer.skype.com/wiki/Skype4Py http://sourceforge.net/projects/skype4py/"
SRC_URI="mirror://sourceforge/${PN}/Skype4Py-${PV}.tar.gz
         doc? ( mirror://sourceforge/${PN}/Skype4Py-${PV}-htmldoc.zip )"

LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="doc"

DEPEND="net-im/skype"
RDEPEND="${DEPEND}"

S="${WORKDIR}/Skype4Py-${PV}"

PYTHON_MODNAME="Skype4Py"

src_prepare() {
        epatch "${FILESDIR}"/${PN}-python27.patch
}

src_install() {
    distutils_src_install

    if use doc; then
        dohtml "${WORKDIR}/Skype4Py-${PV}-htmldoc/"* || die "dohtml failed"
    fi
}


(I was following another ebuild that had patches, so it may not be pretty or the best way of doing it, but it works.)

Remember to change your python to 2.7 if it's not already - mine was on 3.5 and bitlbee couldn't talk to skyped.

Hope this helps someone, if I knew how to post patches and stuff upstream I would put it there.

Kasyx
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum