2018-02-25 03:23:58 +01:00
|
|
|
{ stdenv, fetchFromGitHub, fetchhg, pidgin, glib, json-glib, mercurial, autoreconfHook } :
|
2016-10-08 18:10:31 +02:00
|
|
|
|
2017-03-06 22:23:02 +01:00
|
|
|
|
|
|
|
let
|
|
|
|
pidginHg = fetchhg {
|
|
|
|
url = "https://bitbucket.org/pidgin/main";
|
|
|
|
# take from VERSION file
|
|
|
|
rev = "c9b74a765767";
|
|
|
|
sha256 = "07bjz87jpslsb4gdqvcwp79mkahls2mfhlmpaa5w6n4xqhahw4j3";
|
|
|
|
};
|
|
|
|
|
|
|
|
in stdenv.mkDerivation rec {
|
2017-04-08 08:56:28 +02:00
|
|
|
name = "purple-facebook-0.9.3";
|
2016-10-08 18:10:31 +02:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "dequis";
|
|
|
|
repo = "purple-facebook";
|
2017-04-08 08:56:28 +02:00
|
|
|
rev = "v0.9.3-c9b74a765767";
|
|
|
|
sha256 = "10ncvg0arcxnd3cpb0nxry1plbws0mw9vhzjrhb40sv2i563dywb";
|
2016-10-08 18:10:31 +02:00
|
|
|
};
|
|
|
|
|
2017-03-06 22:23:02 +01:00
|
|
|
postPatch = ''
|
|
|
|
# we do all patching from update.sh in preAutoreconf
|
|
|
|
echo "#!/bin/sh" > update.sh
|
|
|
|
'';
|
|
|
|
|
|
|
|
preAutoreconf = ''
|
|
|
|
for FILE in $(cat MANIFEST_PIDGIN); do
|
|
|
|
install -Dm644 "${pidginHg}/$FILE" "pidgin/$FILE" || true
|
|
|
|
done
|
|
|
|
|
|
|
|
touch $(cat MANIFEST_VOIDS)
|
|
|
|
|
|
|
|
patchdir="$(pwd)/patches"
|
|
|
|
pushd pidgin
|
|
|
|
|
|
|
|
for patch in $(ls -1 "$patchdir"); do
|
|
|
|
patch -p1 -i "$patchdir/$patch"
|
|
|
|
done
|
|
|
|
popd
|
|
|
|
|
|
|
|
./autogen.sh
|
|
|
|
'';
|
2016-10-08 18:10:31 +02:00
|
|
|
|
|
|
|
makeFlags = [
|
|
|
|
"PLUGIN_DIR_PURPLE=/lib/pidgin/"
|
|
|
|
"DATA_ROOT_DIR_PURPLE=/share"
|
|
|
|
];
|
|
|
|
|
2017-03-06 22:23:02 +01:00
|
|
|
installPhase = ''
|
2016-10-08 18:10:31 +02:00
|
|
|
mkdir -p $out/lib/purple-2
|
|
|
|
cp pidgin/libpurple/protocols/facebook/.libs/*.so $out/lib/purple-2/
|
|
|
|
'';
|
|
|
|
|
2017-09-05 23:26:13 +02:00
|
|
|
nativeBuildInputs = [ autoreconfHook ];
|
2018-02-25 03:23:58 +01:00
|
|
|
buildInputs = [pidgin glib json-glib mercurial];
|
2016-10-08 18:10:31 +02:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
inherit (src.meta) homepage;
|
|
|
|
description = "Facebook protocol plugin for libpurple";
|
|
|
|
license = licenses.gpl2;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ davorb ];
|
|
|
|
};
|
|
|
|
}
|