Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
peterhoeg committed Apr 5, 2018
1 parent ea145b6 commit bb7d28e
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 102 deletions.
@@ -1,73 +1,39 @@
{ stdenv
, fetchgit
, which
, autoreconfHook
, pkgconfig
, automake
, libtool
, pjsip
, libyamlcpp
, alsaLib
, libpulseaudio
, libsamplerate
, libsndfile
, dbus
, dbus_cplusplus
, ffmpeg
, udev
, pcre
, gsm
, speex
, boost
, opendht
, libmsgpack
, gnutls
, zlib
, jsoncpp
, xorg
, libargon2
, cryptopp
, openssl
, perl
, python3
, bash
, libupnp
, speexdsp
, fetchFromGitHub
, cmake
, asio
}:
{ stdenv, fetchgit, which, autoreconfHook, pkgconfig, automake, libtool
, pjsip, libyamlcpp, alsaLib, libpulseaudio, libsamplerate, libsndfile, dbus
, dbus_cplusplus, ffmpeg, udev, pcre, gsm, speex, boost, opendht, libmsgpack
, gnutls, zlib, jsoncpp, xorg, libargon2, cryptopp, openssl, perl, python3, bash
, libupnp, speexdsp, fetchFromGitHub, cmake, asio }:

let
myPython = python3.withPackages (ps: with ps; [
pygobject3
dbus-python
]);

version = "4.0.9";

src = fetchgit {
url = https://gitlab.savoirfairelinux.com/ring/ring-daemon.git;
rev = "006b8dc7be08fe9beb68709af71004e7bc1ceb5c";
sha256 = "0ih9g0rismrhx6nqcy3jqfbcs166grg0shnfmrnmykl9h0xy8z47";
rev = "4.0.0";
sha256 = "1iyfh7yinvr0ww1w8068zci17jp7cz0k4qcrwwb1wmq813dichn8";
};

patchdir = "${src}/contrib/src";

restbed = import ./restbed.nix {
inherit stdenv fetchFromGitHub cmake asio openssl;
patches = [
"${patchdir}/restbed/CMakeLists.patch"
"${patchdir}/restbed/strand.patch"
"${patchdir}/restbed/uri_cpp.patch"
"${patchdir}/restbed/dns-resolution-error.patch"
"${patchdir}/restbed/string.patch"
# "${patchdir}/restbed/strand.patch"
# "${patchdir}/restbed/dns-resolution-error.patch"
"${patchdir}/restbed/string.patch"
];
};

pjsip' = stdenv.lib.overrideDerivation pjsip (old: {
patches = [
"${patchdir}/pjproject/gnutls.patch"
./notestsapps.patch # this one had to be modified
"${patchdir}/pjproject/fix_base64.patch"
# "${patchdir}/pjproject/gnutls.patch"
# ./notestsapps.patch # this one had to be modified
# "${patchdir}/pjproject/fix_base64.patch"
"${patchdir}/pjproject/ipv6.patch"
"${patchdir}/pjproject/ice_config.patch"
"${patchdir}/pjproject/multiple_listeners.patch"
Expand All @@ -76,53 +42,32 @@ let
"${patchdir}/pjproject/fix_ioqueue_ipv6_sendto.patch"
"${patchdir}/pjproject/add_dtls_transport.patch"
];
CFLAGS = "-g -DPJ_ICE_MAX_CAND=256 -DPJ_ICE_MAX_CHECKS=150 -DPJ_ICE_COMP_BITS=2 -DPJ_ICE_MAX_STUN=3 -DPJSIP_MAX_PKT_LEN=8000";
# CFLAGS = "-g -DPJ_ICE_MAX_CAND=256 -DPJ_ICE_MAX_CHECKS=150 -DPJ_ICE_COMP_BITS=2 -DPJ_ICE_MAX_STUN=3 -DPJSIP_MAX_PKT_LEN=8000";
});
in
stdenv.mkDerivation rec {
name = "ring-daemon-${version}";
version = "2017-07-11";

inherit src;

nativeBuildInputs = [
which
autoreconfHook
automake
libtool
# automake
# libtool
pkgconfig
];

buildInputs = [
pjsip'
libyamlcpp
alsaLib
libpulseaudio
libsamplerate
libsndfile
dbus
dbus_cplusplus
ffmpeg
udev
pcre
gsm
speex
boost
opendht
libmsgpack
gnutls
zlib
jsoncpp
restbed
xorg.libX11
libargon2
cryptopp
openssl
perl
libupnp
speexdsp
alsaLib boost cryptopp dbus dbus_cplusplus ffmpeg
gnutls gsm jsoncpp libargon2 libmsgpack libpulseaudio
libsamplerate libsndfile libupnp libyamlcpp opendht openssl
pcre perl pjsip' restbed speex speexdsp udev
xorg.libX11 zlib
];

enableParallelBuilding = true;

postInstall = ''
mkdir $out/bin
ln -s $out/lib/ring/dring $out/bin/dring
Expand All @@ -145,7 +90,5 @@ stdenv.mkDerivation rec {
license = licenses.gpl3Plus;
maintainers = with maintainers; [ taeer olynch ];
platforms = platforms.linux;
# pjsip' fails to compile with the supplied patch set, see: https://hydra.nixos.org/build/68667921/nixlog/4
broken = true;
};
}
@@ -1,35 +1,43 @@
{ stdenv
, fetchFromGitHub
, cmake
, asio
, openssl
, patches
}:

stdenv.mkDerivation rec {
{ stdenv, fetchFromGitHub, cmake, patches
, asio, openssl }:

let
kashmir = fetchFromGitHub {
owner = "Corvusoft";
repo = "kashmir-dependency";
rev = "2f3913f49c4ac7f9bff9224db5178f6f8f0ff3ee";
sha256 = "0f0x59p0lwxdjmqc4srpzxj67n795l15m88xgzswn49j8cdd0br1";
};

in stdenv.mkDerivation rec {
name = "restbed-${version}";
version = "2016-09-15";
version = "4.6";

src = fetchFromGitHub {
owner = "Corvusoft";
repo = "restbed";
rev = "34187502642144ab9f749ab40f5cdbd8cb17a54a";
sha256 = "1jb38331fcicyiisqdprhq6zwfc6g518fm3l4qw9aiv5k9nqim22";
owner = "Corvusoft";
repo = "restbed";
rev = version;
sha256 = "06h4pkrzshxlxyf0473x3bw9x1g8mb7l3hasy1bvqdlip3k47qi2";
};

prePatch = ''
rmdir dependency/kashmir
ln -s ${kashmir} dependency/kashmir
'';

inherit patches;

buildInputs = [
cmake
asio
openssl
];
buildInputs = [ asio openssl ];

nativeBuildInputs = [ cmake ];

enableParallelBuilding = true;

meta = with stdenv.lib; {
description = "HTTP framework for building networked applications";
longDescription = ''
HTTP framework for building networked applications that require seamless
and secure communication, with the flexability to model a range of
and secure communication, with the flexibility to model a range of
business processes. Targeting mobile, tablet, desktop, and embedded
production environments.
'';
Expand Down

0 comments on commit bb7d28e

Please sign in to comment.