1
1
{
2
- pkgs ? import "${ ./nixpkgs.nix } " { } ,
2
+ pkgs ? import "${ ./nixpkgs.nix } " { } ,
3
3
loadJSBuiltinsDynamically ? true , # Load `lib/**.js` from disk instead of embedding
4
4
ncu-path ? null , # Provide this if you want to use a local version of NCU
5
5
icu ? pkgs . icu ,
19
19
uvwasi
20
20
zlib
21
21
zstd
22
- ;
22
+ ;
23
23
http-parser = pkgs . llhttp ;
24
24
} ,
25
25
ccache ? pkgs . ccache ,
30
30
pkgs . git
31
31
pkgs . jq
32
32
pkgs . shellcheck
33
- ] ++ ( if ( ncu-path == null ) then [
34
- pkgs . node-core-utils
35
- ] else [
36
- ( pkgs . writeShellScriptBin "git-node" "exec \" ${ ncu-path } /bin/git-node.js\" \" $@\" " )
37
- ( pkgs . writeShellScriptBin "ncu-ci" "exec \" ${ ncu-path } /bin/ncu-ci.js\" \" $@\" " )
38
- ( pkgs . writeShellScriptBin "ncu-config" "exec \" ${ ncu-path } /bin/ncu-config.js\" \" $@\" " )
39
- ] ) ,
33
+ ]
34
+ ++ (
35
+ if ( ncu-path == null ) then
36
+ [ pkgs . node-core-utils ]
37
+ else
38
+ [
39
+ ( pkgs . writeShellScriptBin "git-node" "exec \" ${ ncu-path } /bin/git-node.js\" \" $@\" " )
40
+ ( pkgs . writeShellScriptBin "ncu-ci" "exec \" ${ ncu-path } /bin/ncu-ci.js\" \" $@\" " )
41
+ ( pkgs . writeShellScriptBin "ncu-config" "exec \" ${ ncu-path } /bin/ncu-config.js\" \" $@\" " )
42
+ ]
43
+ ) ,
40
44
benchmarkTools ? [
41
45
pkgs . R
42
46
pkgs . rPackages . ggplot2
@@ -61,38 +65,56 @@ pkgs.mkShell {
61
65
62
66
packages = [
63
67
ccache
64
- ] ++ devTools ++ benchmarkTools ;
68
+ ]
69
+ ++ devTools
70
+ ++ benchmarkTools ;
65
71
66
- shellHook = if ( ccache != null ) then ''
67
- export CC="${ pkgs . lib . getExe ccache } $CC"
68
- export CXX="${ pkgs . lib . getExe ccache } $CXX"
69
- '' else "" ;
72
+ shellHook =
73
+ if ( ccache != null ) then
74
+ ''
75
+ export CC="${ pkgs . lib . getExe ccache } $CC"
76
+ export CXX="${ pkgs . lib . getExe ccache } $CXX"
77
+ ''
78
+ else
79
+ "" ;
70
80
71
81
BUILD_WITH = if ( ninja != null ) then "ninja" else "make" ;
72
82
NINJA = if ( ninja != null ) then "${ pkgs . lib . getExe ninja } " else "" ;
73
- CI_SKIP_TESTS = pkgs . lib . concatStringsSep "," ( [
74
- ] ++ pkgs . lib . optionals useSharedAda [
83
+ CI_SKIP_TESTS = pkgs . lib . concatStringsSep "," (
84
+ [ ]
85
+ ++ pkgs . lib . optionals useSharedAda [
75
86
# Different versions of Ada affect the WPT tests
76
87
"test-url"
77
- ] ++ pkgs . lib . optionals useSharedOpenSSL [
88
+ ]
89
+ ++ pkgs . lib . optionals useSharedOpenSSL [
78
90
# Path to the openssl.cnf is different from the expected one
79
91
"test-strace-openat-openssl"
80
- ] ) ;
81
- CONFIG_FLAGS = builtins . toString ( [
82
- ( if icu == null
83
- then "--without-intl"
84
- else "--with-intl=${ if useSharedICU then "system" else icu } -icu" )
85
- ] ++ extraConfigFlags ++ pkgs . lib . optionals ( ninja != null ) [
86
- "--ninja"
87
- ] ++ pkgs . lib . optionals loadJSBuiltinsDynamically [
88
- "--node-builtin-modules-path=${ builtins . toString ./. } "
89
- ] ++ pkgs . lib . concatMap ( name : [
90
- "--shared-${ builtins . replaceStrings [ "c-ares" ] [ "cares" ] name } "
91
- "--shared-${ builtins . replaceStrings [ "c-ares" ] [ "cares" ] name } -libpath=${
92
- pkgs . lib . getLib sharedLibDeps . ${ name }
93
- } /lib"
94
- "--shared-${ builtins . replaceStrings [ "c-ares" ] [ "cares" ] name } -include=${
95
- pkgs . lib . getInclude sharedLibDeps . ${ name }
96
- } /include"
97
- ] ) ( builtins . attrNames sharedLibDeps ) ) ;
92
+ ]
93
+ ) ;
94
+ CONFIG_FLAGS = builtins . toString (
95
+ [
96
+ (
97
+ if icu == null then
98
+ "--without-intl"
99
+ else
100
+ "--with-intl=${ if useSharedICU then "system" else icu } -icu"
101
+ )
102
+ ]
103
+ ++ extraConfigFlags
104
+ ++ pkgs . lib . optionals ( ninja != null ) [
105
+ "--ninja"
106
+ ]
107
+ ++ pkgs . lib . optionals loadJSBuiltinsDynamically [
108
+ "--node-builtin-modules-path=${ builtins . toString ./. } "
109
+ ]
110
+ ++ pkgs . lib . concatMap ( name : [
111
+ "--shared-${ builtins . replaceStrings [ "c-ares" ] [ "cares" ] name } "
112
+ "--shared-${ builtins . replaceStrings [ "c-ares" ] [ "cares" ] name } -libpath=${
113
+ pkgs . lib . getLib sharedLibDeps . ${ name }
114
+ } /lib"
115
+ "--shared-${ builtins . replaceStrings [ "c-ares" ] [ "cares" ] name } -include=${
116
+ pkgs . lib . getInclude sharedLibDeps . ${ name }
117
+ } /include"
118
+ ] ) ( builtins . attrNames sharedLibDeps )
119
+ ) ;
98
120
}
0 commit comments