about summary refs log tree commit diff
path: root/pkgs/development/interpreters/io/default.nix
blob: 8ed50b886876b915ef5d394b5c94e58d6bfb49d2 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{ stdenv, fetchFromGitHub, cmake, zlib, sqlite, gmp, libffi, cairo,
  ncurses, freetype, mesa, libpng, libtiff, libjpeg, readline, libsndfile,
  libxml2, freeglut, libsamplerate, pcre, libevent, libedit, yajl,
  python3, openssl, glfw, pkgconfig, libpthreadstubs, libXdmcp, libmemcached
}:

stdenv.mkDerivation {
  name = "io-2015.11.11";
  src = fetchFromGitHub {
    owner = "stevedekorte";
    repo = "io";
    rev = "1fc725e0a8635e2679cbb20521f4334c25273caa";
    sha256 = "0ll2kd72zy8vf29sy0nnx3awk7nywpwpv21rvninjjaqkygrc0qw";
  };

  buildInputs = [
    cmake zlib sqlite gmp libffi cairo ncurses freetype
    mesa libpng libtiff libjpeg readline libsndfile libxml2
    freeglut libsamplerate pcre libevent libedit yajl
    pkgconfig glfw openssl libpthreadstubs libXdmcp
    libmemcached python3
  ];

  configurePhase=''
  # The Addon generation (AsyncRequest and a others checked) seems to have
  # trouble with building on Virtual machines. Disabling them until it
  # can be fully investigated.
  sed -ie \
        "s/add_subdirectory(addons)/#add_subdirectory(addons)/g" \
        CMakeLists.txt
  mkdir build
  cd build
  cmake  -DCMAKE_INSTALL_PREFIX="$out" ..
  '';

  installPhase=''
  make install
  '';

  # for gcc5; c11 inline semantics breaks the build
  NIX_CFLAGS_COMPILE = "-fgnu89-inline";

  meta = with stdenv.lib; {
    description = "Io programming language";
    maintainers = with maintainers; [
      raskin
      z77z
      vrthra
    ];
    platforms = platforms.linux;
  };
}