lol
at 17.09-beta 59 lines 1.8 kB view raw
1{ stdenv, fetchFromGitHub, autoreconfHook, libsodium, ncurses, libopus 2, libvpx, check, libconfig, pkgconfig }: 3 4let 5 version = "4c220e336330213b151a0c20307d0a1fce04ac9e"; 6 date = "20150126"; 7 8in stdenv.mkDerivation rec { 9 name = "tox-core-old-${date}-${builtins.substring 0 7 version}"; 10 11 src = fetchFromGitHub { 12 owner = "irungentoo"; 13 repo = "toxcore"; 14 rev = version; 15 sha256 = "152yamak9ykl8dgkx1qzyrpa3f4xr1s8lgcb5k58r9lb1iwnhvqc"; 16 }; 17 18 NIX_LDFLAGS = "-lgcc_s"; 19 20 postPatch = '' 21 # within Nix chroot builds, localhost is unresolvable 22 sed -i -e '/DEFTESTCASE(addr_resolv_localhost)/d' \ 23 auto_tests/network_test.c 24 # takes WAAAY too long (~10 minutes) and would timeout 25 sed -i -e '/DEFTESTCASE[^(]*(many_clients\>/d' \ 26 auto_tests/tox_test.c 27 ''; 28 29 configureFlags = [ 30 "--with-libsodium-headers=${libsodium.dev}/include" 31 "--with-libsodium-libs=${libsodium.out}/lib" 32 "--enable-ntox" 33 "--enable-daemon" 34 ]; 35 36 buildInputs = [ 37 autoreconfHook libsodium ncurses 38 check libconfig pkgconfig 39 ] ++ stdenv.lib.optionals (!stdenv.isArm) [ 40 libopus 41 ]; 42 43 propagatedBuildInputs = stdenv.lib.optionals (!stdenv.isArm) [ libvpx ]; 44 45 # Some tests fail randomly due to timeout. This kind of problem is well known 46 # by upstream: https://github.com/irungentoo/toxcore/issues/{950,1054} 47 # They don't recommend running tests on 50core machines with other cpu-bound 48 # tests running in parallel. 49 # 50 # NOTE: run the tests locally on your machine before upgrading this package! 51 doCheck = false; 52 53 meta = with stdenv.lib; { 54 description = "P2P FOSS instant messaging application aimed to replace Skype with crypto"; 55 license = licenses.gpl3Plus; 56 maintainers = with maintainers; [ viric jgeerds ]; 57 platforms = platforms.all; 58 }; 59}