git.iko.soy/typeable/nixpkgs
on master help sign in
neko: 2.1.0 -> 2.2.0
commite19f22c55ab197d962fecd49021b4e2458f1d833 authorvolth <volth@webmaster.ms> dateWed 20 Dec 2017, 17:55 (9 years ago) parent30b7624
2 files changed+7−92
pkgs/development/compilers/neko/default.nix+7−33 pkgs/development/compilers/neko/xlocale-fix.patch−59
pkgs/development/compilers/neko/default.nix+7−33
@@ -1,50 +1,24 @@
1−{ stdenv, fetchurl, fetchpatch, boehmgc, zlib, sqlite, pcre, cmake, pkgconfig
2−, git, apacheHttpd, apr, aprutil, mariadb, mbedtls, openssl, pkgs, gtk2
1+{ stdenv, fetchurl, boehmgc, zlib, sqlite, pcre, cmake, pkgconfig
2+, git, apacheHttpd, apr, aprutil, mariadb, mbedtls, openssl, pkgs, gtk2, libpthreadstubs
33}:
44
55stdenv.mkDerivation rec {
66 name = "neko-${version}";
7− version = "2.1.0";
7+ version = "2.2.0";
88
99 src = fetchurl {
1010 url = "http://nekovm.org/media/neko-${version}-src.tar.gz";
11− sha256 = "15ng9ad0jspnhj38csli1pvsv3nxm75f0nlps7i10194jvzdb4qc";
11+ sha256 = "1qv47zaa0vzhjlq5wb71627n7dbsxpc1gqpg0hsngjxnbnh1q46g";
1212 };
1313
14− # Patches backported with reference to https://github.com/HaxeFoundation/neko/issues/131
15− # They can probably be removed when bumping to next version
16− patches = [
17− (fetchpatch {
18− url = "https://github.com/HaxeFoundation/neko/commit/"
19− + "a8c71ad97faaccff6c6e9e09eba2d5efd022f8dc.patch";
20− sha256 = "0mnx15cdjs8mnl01mhc9z2gpzh4d1q0ygqnjackrqxz6x235ydyp";
21− })
22− (fetchpatch {
23− url = "https://github.com/HaxeFoundation/neko/commit/"
24− + "fe87462d9c7a6ee27e28f5be5e4fc0ac87b34574.patch";
25− sha256 = "1jbmq6j32vg3qv20dbh82cp54886lgrh7gkcqins8a2y4l4dl3sc";
26− })
27− # https://github.com/HaxeFoundation/neko/pull/165
28− (fetchpatch {
29− url = "https://github.com/HaxeFoundation/neko/commit/"
30− + "c6d9c6d796200990b3b6a53a4dc716c9192398e6.patch";
31− sha256 = "1pq0qhhb9gbhc3zbgylwp0amhwsz0q0ggpj6v2xgv0hfy7d63rcd";
32− })
33− # Glibc 2.26 no longer has xlocale.h, patch backported from upstream commit
34− # e286c8f3301fa443255a3101d14b7392467051b8.
35− ./xlocale-fix.patch
36− ];
37−
14+ nativeBuildInputs = [ cmake pkgconfig git ];
3815 buildInputs =
39− [ boehmgc zlib sqlite pcre cmake pkgconfig git apacheHttpd apr aprutil
40− mariadb.client mbedtls openssl ]
16+ [ boehmgc zlib sqlite pcre apacheHttpd apr aprutil
17+ mariadb.client mbedtls openssl libpthreadstubs ]
4118 ++ stdenv.lib.optional stdenv.isLinux gtk2
4219 ++ stdenv.lib.optionals stdenv.isDarwin [ pkgs.darwin.apple_sdk.frameworks.Security
4320 pkgs.darwin.apple_sdk.frameworks.Carbon];
4421 cmakeFlags = [ "-DRUN_LDCONFIG=OFF" ];
45− prePatch = ''
46− sed -i -e '/allocated = strdup/s|"[^"]*"|"'"$out/lib/neko:$out/bin"'"|' vm/load.c
47− '';
4822
4923 checkPhase = ''
5024 bin/neko bin/test.n
pkgs/development/compilers/neko/xlocale-fix.patchdeleted−59
@@ -1,59 +0,0 @@
1−commit 31d3ac3d691b2a1b07991e67302fd52b0f409cac
2−Author: Andy Li <andy@onthewings.net>
3−Date: Thu Jul 13 13:23:33 2017 +0800
4−
5− include xlocale.h only if it is available since it is removed in recent glibc
6−
7− see: https://bugzilla.redhat.com/show_bug.cgi?id=1464244
8−
9− (Backported from e286c8f3301fa443255a3101d14b7392467051b8)
10−
11−diff --git a/CMakeLists.txt b/CMakeLists.txt
12−index 8de1702..d64cab9 100644
13−--- a/CMakeLists.txt
14−+++ b/CMakeLists.txt
15−@@ -1,5 +1,6 @@
16− cmake_minimum_required(VERSION 2.8.7)
17−
18−+include(CheckIncludeFile)
19− project(neko C)
20−
21− set(CMAKE_OSX_ARCHITECTURES x86_64)
22−@@ -48,6 +49,8 @@ set(NEKO_VERSION_MAJOR 2)
23− set(NEKO_VERSION_MINOR 1)
24− set(NEKO_VERSION_PATCH 0)
25−
26−+check_include_file(xlocale.h HAVE_XLOCALE_H)
27−+
28− configure_file (
29− "${CMAKE_SOURCE_DIR}/vm/neko.h.in"
30− "${CMAKE_BINARY_DIR}/neko.h"
31−diff --git a/libs/std/sys.c b/libs/std/sys.c
32−index 8003d41..ae0cfee 100644
33−--- a/libs/std/sys.c
34−+++ b/libs/std/sys.c
35−@@ -41,7 +41,11 @@
36− # include <sys/time.h>
37− # include <sys/times.h>
38− # include <sys/wait.h>
39−+#ifdef HAVE_XLOCALE_H
40− # include <xlocale.h>
41−+#else
42−+# include <locale.h>
43−+#endif
44− #endif
45−
46− #ifdef NEKO_MAC
47−diff --git a/vm/neko.h.in b/vm/neko.h.in
48−index bb9ec1b..147ecce 100644
49−--- a/vm/neko.h.in
50−+++ b/vm/neko.h.in
51−@@ -88,6 +88,8 @@
52− # include <stdint.h>
53− #endif
54−
55−+#cmakedefine HAVE_XLOCALE_H
56−+
57− #define NEKO_VERSION_MAJOR @NEKO_VERSION_MAJOR@
58− #define NEKO_VERSION_MINOR @NEKO_VERSION_MINOR@
59− #define NEKO_VERSION_PATCH @NEKO_VERSION_PATCH@