3
0
Fork 0
forked from mirrors/nixpkgs

Merge remote-tracking branch 'upstream/master' into staging

This commit is contained in:
Tuomas Tynkkynen 2016-04-28 00:13:53 +03:00
commit 4ff8f377af
167 changed files with 48315 additions and 22496 deletions

View file

@ -1,6 +1,9 @@
###### Things done
- [ ] Tested using sandboxing (`nix-build --option build-use-sandbox true` or [nix.useSandbox](http://nixos.org/nixos/manual/options.html#opt-nix.useSandbox) on NixOS)
- [ ] Tested using sandboxing
([nix.useSandbox](http://nixos.org/nixos/manual/options.html#opt-nix.useSandbox) on NixOS,
or option `build-use-sandbox` in [`nix.conf`](http://nixos.org/nix/manual/#sec-conf-file)
on non-NixOS)
- Built on platform(s)
- [ ] NixOS
- [ ] OS X

376
doc/beam-users-guide.xml Normal file
View file

@ -0,0 +1,376 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="users-guide-to-the-erlang-infrastructure">
<title>User's Guide to the Beam Infrastructure</title>
<section xml:id="beam-introduction">
<title>Beam Languages (Erlang &amp; Elixir) on Nix</title>
<para>
In this document and related Nix expressions we use the term
<emphasis>Beam</emphasis> to describe the environment. Beam is
the name of the Erlang Virtial Machine and, as far as we know,
from a packaging perspective all languages that run on Beam are
interchangable. The things that do change, like the build
system, are transperant to the users of the package. So we make
no distinction.
</para>
</section>
<section xml:id="build-tools">
<title>Build Tools</title>
<section xml:id="build-tools-rebar3">
<title>Rebar3</title>
<para>
By default Rebar3 wants to manage it's own dependencies. In the
normal non-Nix, this is perfectly acceptable. In the Nix world it
is not. To support this we have created two versions of rebar3,
<literal>rebar3</literal> and <literal>rebar3-open</literal>. The
<literal>rebar3</literal> version has been patched to remove the
ability to download anything from it. If you are not running it a
nix-shell or a nix-build then its probably not going to work for
you. <literal>rebar3-open</literal> is the normal, un-modified
rebar3. It should work exactly as would any other version of
rebar3. Any Erlang package should rely on
<literal>rebar3</literal> and thats really what you should be
using too.
</para>
</section>
<section xml:id="build-tools-other">
<title>Mix &amp; Erlang.mk</title>
<para>
Both Mix and Erlang.mk work exactly as you would expect. There
is a bootstrap process that needs to be run for both of
them. However, that is supported by the
<literal>buildMix</literal> and <literal>buildErlangMk</literal> derivations.
</para>
</section>
</section>
<section xml:id="how-to-install-beam-packages">
<title>How to install Beam packages</title>
<para>
Beam packages are not registered in the top level simply because
they are not relevant to the vast majority of Nix users. They are
installable using the <literal>beamPackages</literal> attribute
set.
You can list the avialable packages in the
<literal>beamPackages</literal> with the following command:
</para>
<programlisting>
$ nix-env -f &quot;&lt;nixpkgs&gt;&quot; -qaP -A beamPackages
beamPackages.esqlite esqlite-0.2.1
beamPackages.goldrush goldrush-0.1.7
beamPackages.ibrowse ibrowse-4.2.2
beamPackages.jiffy jiffy-0.14.5
beamPackages.lager lager-3.0.2
beamPackages.meck meck-0.8.3
beamPackages.rebar3-pc pc-1.1.0
</programlisting>
<para>
To install any of those packages into your profile, refer to them by
their attribute path (first column):
</para>
<programlisting>
$ nix-env -f &quot;&lt;nixpkgs&gt;&quot; -iA beamPackages.ibrowse
</programlisting>
<para>
The attribute path of any Beam packages corresponds to the name
of that particular package in Hex or its OTP Application/Release name.
</para>
</section>
<section xml:id="packaging-beam-applications">
<title>Packaging Beam Applications</title>
<section xml:id="packaging-erlang-applications">
<title>Erlang Applications</title>
<section xml:id="rebar3-packages">
<title>Rebar3 Packages</title>
<para>
There is a Nix functional called
<literal>buildRebar3</literal>. We use this function to make a
derivation that understands how to build the rebar3 project. For
example, the epression we use to build the <link
xlink:href="https://github.com/erlang-nix/hex2nix">hex2nix</link>
project follows.
</para>
<programlisting>
{stdenv, fetchFromGitHub, buildRebar3, ibrowse, jsx, erlware_commons }:
buildRebar3 rec {
name = "hex2nix";
version = "0.0.1";
src = fetchFromGitHub {
owner = "ericbmerritt";
repo = "hex2nix";
rev = "${version}";
sha256 = "1w7xjidz1l5yjmhlplfx7kphmnpvqm67w99hd2m7kdixwdxq0zqg";
};
beamDeps = [ ibrowse jsx erlware_commons ];
}
</programlisting>
<para>
The only visible difference between this derivation and
something like <literal>stdenv.mkDerivation</literal> is that we
have added <literal>erlangDeps</literal> to the derivation. If
you add your Beam dependencies here they will be correctly
handled by the system.
</para>
<para>
If your package needs to compile native code via Rebar's port
compilation mechenism. You should add <literal>compilePort =
true;</literal> to the derivation.
</para>
</section>
<section xml:id="erlang-mk-packages">
<title>Erlang.mk Packages</title>
<para>
Erlang.mk functions almost identically to Rebar. The only real
difference is that <literal>buildErlangMk</literal> is called
instead of <literal>buildRebar3</literal>
</para>
<programlisting>
{ buildErlangMk, fetchHex, cowlib, ranch }:
buildErlangMk {
name = "cowboy";
version = "1.0.4";
src = fetchHex {
pkg = "cowboy";
version = "1.0.4";
sha256 =
"6a0edee96885fae3a8dd0ac1f333538a42e807db638a9453064ccfdaa6b9fdac";
};
beamDeps = [ cowlib ranch ];
meta = {
description = ''Small, fast, modular HTTP server written in
Erlang.'';
license = stdenv.lib.licenses.isc;
homepage = "https://github.com/ninenines/cowboy";
};
}
</programlisting>
</section>
<section xml:id="mix-packages">
<title>Mix Packages</title>
<para>
Mix functions almost identically to Rebar. The only real
difference is that <literal>buildMix</literal> is called
instead of <literal>buildRebar3</literal>
</para>
<programlisting>
{ buildMix, fetchHex, plug, absinthe }:
buildMix {
name = "absinthe_plug";
version = "1.0.0";
src = fetchHex {
pkg = "absinthe_plug";
version = "1.0.0";
sha256 =
"08459823fe1fd4f0325a8bf0c937a4520583a5a26d73b193040ab30a1dfc0b33";
};
beamDeps = [ plug absinthe];
meta = {
description = ''A plug for Absinthe, an experimental GraphQL
toolkit'';
license = stdenv.lib.licenses.bsd3;
homepage = "https://github.com/CargoSense/absinthe_plug";
};
}
</programlisting>
</section>
</section>
</section>
<section xml:id="how-to-develop">
<title>How to develop</title>
<section xml:id="accessing-an-environment">
<title>Accessing an Environment</title>
<para>
Often, all you want to do is be able to access a valid
environment that contains a specific package and its
dependencies. we can do that with the <literal>env</literal>
part of a derivation. For example, lets say we want to access an
erlang repl with ibrowse loaded up. We could do the following.
</para>
<programlisting>
~/w/nixpkgs nix-shell -A beamPackages.ibrowse.env --run "erl"
Erlang/OTP 18 [erts-7.0] [source] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false]
Eshell V7.0 (abort with ^G)
1> m(ibrowse).
Module: ibrowse
MD5: 3b3e0137d0cbb28070146978a3392945
Compiled: January 10 2016, 23:34
Object file: /nix/store/g1rlf65rdgjs4abbyj4grp37ry7ywivj-ibrowse-4.2.2/lib/erlang/lib/ibrowse-4.2.2/ebin/ibrowse.beam
Compiler options: [{outdir,"/tmp/nix-build-ibrowse-4.2.2.drv-0/hex-source-ibrowse-4.2.2/_build/default/lib/ibrowse/ebin"},
debug_info,debug_info,nowarn_shadow_vars,
warn_unused_import,warn_unused_vars,warnings_as_errors,
{i,"/tmp/nix-build-ibrowse-4.2.2.drv-0/hex-source-ibrowse-4.2.2/_build/default/lib/ibrowse/include"}]
Exports:
add_config/1 send_req_direct/7
all_trace_off/0 set_dest/3
code_change/3 set_max_attempts/3
get_config_value/1 set_max_pipeline_size/3
get_config_value/2 set_max_sessions/3
get_metrics/0 show_dest_status/0
get_metrics/2 show_dest_status/1
handle_call/3 show_dest_status/2
handle_cast/2 spawn_link_worker_process/1
handle_info/2 spawn_link_worker_process/2
init/1 spawn_worker_process/1
module_info/0 spawn_worker_process/2
module_info/1 start/0
rescan_config/0 start_link/0
rescan_config/1 stop/0
send_req/3 stop_worker_process/1
send_req/4 stream_close/1
send_req/5 stream_next/1
send_req/6 terminate/2
send_req_direct/4 trace_off/0
send_req_direct/5 trace_off/2
send_req_direct/6 trace_on/0
trace_on/2
ok
2>
</programlisting>
<para>
Notice the <literal>-A beamPackages.ibrowse.env</literal>.That
is the key to this functionality.
</para>
</section>
<section xml:id="creating-a-shell">
<title>Creating a Shell</title>
<para>
Getting access to an environment often isn't enough to do real
development. Many times we need to create a
<literal>shell.nix</literal> file and do our development inside
of the environment specified by that file. This file looks a lot
like the packageing described above. The main difference is that
<literal>src</literal> points to project root and we call the
package directly.
</para>
<programlisting>
{ pkgs ? import &quot;&lt;nixpkgs&quot;&gt; {} }:
with pkgs;
let
f = { buildRebar3, ibrowse, jsx, erlware_commons }:
buildRebar3 {
name = "hex2nix";
version = "0.1.0";
src = ./.;
erlangDeps = [ ibrowse jsx erlware_commons ];
};
drv = beamPackages.callPackage f {};
in
drv
</programlisting>
<section xml:id="building-in-a-shell">
<title>Building in a shell</title>
<para>
We can leveral the support of the Derivation, regardless of
which build Derivation is called by calling the commands themselv.s
</para>
<programlisting>
# =============================================================================
# Variables
# =============================================================================
NIX_TEMPLATES := "$(CURDIR)/nix-templates"
TARGET := "$(PREFIX)"
PROJECT_NAME := thorndyke
NIXPKGS=../nixpkgs
NIX_PATH=nixpkgs=$(NIXPKGS)
NIX_SHELL=nix-shell -I "$(NIX_PATH)" --pure
# =============================================================================
# Rules
# =============================================================================
.PHONY= all test clean repl shell build test analyze configure install \
test-nix-install publish plt analyze
all: build
guard-%:
@ if [ "${${*}}" == "" ]; then \
echo "Environment variable $* not set"; \
exit 1; \
fi
clean:
rm -rf _build
rm -rf .cache
repl:
$(NIX_SHELL) --run "iex -pa './_build/prod/lib/*/ebin'"
shell:
$(NIX_SHELL)
configure:
$(NIX_SHELL) --command 'eval "$$configurePhase"'
build: configure
$(NIX_SHELL) --command 'eval "$$buildPhase"'
install:
$(NIX_SHELL) --command 'eval "$$installPhase"'
test:
$(NIX_SHELL) --command 'mix test --no-start --no-deps-check'
plt:
$(NIX_SHELL) --run "mix dialyzer.plt --no-deps-check"
analyze: build plt
$(NIX_SHELL) --run "mix dialyzer --no-compile"
</programlisting>
<para>
If you add the <literal>shell.nix</literal> as described and
user rebar as follows things should simply work. Aside from the
<literal>test</literal>, <literal>plt</literal>, and
<literal>analyze</literal> the talks work just fine for all of
the build Derivations.
</para>
</section>
</section>
</section>
<section xml:id="generating-packages-from-hex-with-hex2nix">
<title>Generating Packages from Hex with Hex2Nix</title>
<para>
Updating the Hex packages requires the use of the
<literal>hex2nix</literal> tool. Given the path to the Erlang
modules (usually
<literal>pkgs/development/erlang-modules</literal>). It will
happily dump a file called
<literal>hex-packages.nix</literal>. That file will contain all
the packages that use a recognized build system in Hex. However,
it can't know whether or not all those packages are buildable.
</para>
<para>
To make life easier for our users, it makes good sense to go
ahead and attempt to build all those packages and remove the
ones that don't build. To do that, simply run the command (in
the root of your <literal>nixpkgs</literal> repository). that follows.
</para>
<programlisting>
$ nix-build -A beamPackages
</programlisting>
<para>
That will build every package in
<literal>beamPackages</literal>. Then you can go through and
manually remove the ones that fail. Hopefully, someone will
improve <literal>hex2nix</literal> in the future to automate
that.
</para>
</section>
</chapter>

View file

@ -1,305 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="users-guide-to-the-erlang-infrastructure">
<title>User's Guide to the Erlang Infrastructure</title>
<section xml:id="build-tools">
<title>Build Tools</title>
<para>
By default Rebar3 wants to manage it's own dependencies. In the
normal non-Nix, this is perfectly acceptable. In the Nix world it
is not. To support this we have created two versions of rebar3,
<literal>rebar3</literal> and <literal>rebar3-open</literal>. The
<literal>rebar3</literal> version has been patched to remove the
ability to download anything from it. If you are not running it a
nix-shell or a nix-build then its probably not going to work for
you. <literal>rebar3-open</literal> is the normal, un-modified
rebar3. It should work exactly as would any other version of
rebar3. Any Erlang package should rely on
<literal>rebar3</literal> and thats really what you should be
using too.
</para>
</section>
<section xml:id="how-to-install-erlang-packages">
<title>How to install Erlang packages</title>
<para>
Erlang packages are not registered in the top level simply because
they are not relevant to the vast majority of Nix users. They are
installable using the <literal>erlangPackages</literal> attribute set.
You can list the avialable packages in the
<literal>erlangPackages</literal> with the following command:
</para>
<programlisting>
$ nix-env -f &quot;&lt;nixpkgs&gt;&quot; -qaP -A erlangPackages
erlangPackages.esqlite esqlite-0.2.1
erlangPackages.goldrush goldrush-0.1.7
erlangPackages.ibrowse ibrowse-4.2.2
erlangPackages.jiffy jiffy-0.14.5
erlangPackages.lager lager-3.0.2
erlangPackages.meck meck-0.8.3
erlangPackages.rebar3-pc pc-1.1.0
</programlisting>
<para>
To install any of those packages into your profile, refer to them by
their attribute path (first column):
</para>
<programlisting>
$ nix-env -f &quot;&lt;nixpkgs&gt;&quot; -iA erlangPackages.ibrowse
</programlisting>
<para>
The attribute path of any Erlang packages corresponds to the name
of that particular package in Hex or its OTP Application/Release name.
</para>
</section>
<section xml:id="packaging-erlang-applications">
<title>Packaging Erlang Applications</title>
<section xml:id="rebar3-packages">
<title>Rebar3 Packages</title>
<para>
There is a Nix functional called
<literal>buildRebar3</literal>. We use this function to make a
derivation that understands how to build the rebar3 project. For
example, the epression we use to build the <link
xlink:href="https://github.com/erlang-nix/hex2nix">hex2nix</link>
project follows.
</para>
<programlisting>
{stdenv, fetchFromGitHub, buildRebar3, ibrowse, jsx, erlware_commons }:
buildRebar3 rec {
name = "hex2nix";
version = "0.0.1";
src = fetchFromGitHub {
owner = "ericbmerritt";
repo = "hex2nix";
rev = "${version}";
sha256 = "1w7xjidz1l5yjmhlplfx7kphmnpvqm67w99hd2m7kdixwdxq0zqg";
};
erlangDeps = [ ibrowse jsx erlware_commons ];
}
</programlisting>
<para>
The only visible difference between this derivation and
something like <literal>stdenv.mkDerivation</literal> is that we
have added <literal>erlangDeps</literal> to the derivation. If
you add your Erlang dependencies here they will be correctly
handled by the system.
</para>
<para>
If your package needs to compile native code via Rebar's port
compilation mechenism. You should add <literal>compilePort =
true;</literal> to the derivation.
</para>
</section>
<section xml:id="hex-packages">
<title>Hex Packages</title>
<para>
Hex packages are based on Rebar packages. In fact, at the moment
we can only compile Hex packages that are buildable with
Rebar3. Packages that use Mix and other build systems are not
supported. That being said, we know a lot more about Hex and can
do more for you.
</para>
<programlisting>
{ buildHex }:
buildHex {
name = "esqlite";
version = "0.2.1";
sha256 = "1296fn1lz4lz4zqzn4dwc3flgkh0i6n4sydg501faabfbv8d3wkr";
compilePort = true;
}
</programlisting>
<para>
For Hex packages you need to provide the name, the version, and
the Sha 256 digest of the package and use
<literal>buildHex</literal> to build it. Obviously, the package
needs to have already been published to Hex.
</para>
</section>
</section>
<section xml:id="how-to-develop">
<title>How to develop</title>
<section xml:id="accessing-an-environment">
<title>Accessing an Environment</title>
<para>
Often, all you want to do is be able to access a valid
environment that contains a specific package and its
dependencies. we can do that with the <literal>env</literal>
part of a derivation. For example, lets say we want to access an
erlang repl with ibrowse loaded up. We could do the following.
</para>
<programlisting>
~/w/nixpkgs nix-shell -A erlangPackages.ibrowse.env --run "erl"
Erlang/OTP 18 [erts-7.0] [source] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false]
Eshell V7.0 (abort with ^G)
1> m(ibrowse).
Module: ibrowse
MD5: 3b3e0137d0cbb28070146978a3392945
Compiled: January 10 2016, 23:34
Object file: /nix/store/g1rlf65rdgjs4abbyj4grp37ry7ywivj-ibrowse-4.2.2/lib/erlang/lib/ibrowse-4.2.2/ebin/ibrowse.beam
Compiler options: [{outdir,"/tmp/nix-build-ibrowse-4.2.2.drv-0/hex-source-ibrowse-4.2.2/_build/default/lib/ibrowse/ebin"},
debug_info,debug_info,nowarn_shadow_vars,
warn_unused_import,warn_unused_vars,warnings_as_errors,
{i,"/tmp/nix-build-ibrowse-4.2.2.drv-0/hex-source-ibrowse-4.2.2/_build/default/lib/ibrowse/include"}]
Exports:
add_config/1 send_req_direct/7
all_trace_off/0 set_dest/3
code_change/3 set_max_attempts/3
get_config_value/1 set_max_pipeline_size/3
get_config_value/2 set_max_sessions/3
get_metrics/0 show_dest_status/0
get_metrics/2 show_dest_status/1
handle_call/3 show_dest_status/2
handle_cast/2 spawn_link_worker_process/1
handle_info/2 spawn_link_worker_process/2
init/1 spawn_worker_process/1
module_info/0 spawn_worker_process/2
module_info/1 start/0
rescan_config/0 start_link/0
rescan_config/1 stop/0
send_req/3 stop_worker_process/1
send_req/4 stream_close/1
send_req/5 stream_next/1
send_req/6 terminate/2
send_req_direct/4 trace_off/0
send_req_direct/5 trace_off/2
send_req_direct/6 trace_on/0
trace_on/2
ok
2>
</programlisting>
<para>
Notice the <literal>-A erlangPackages.ibrowse.env</literal>.That
is the key to this functionality.
</para>
</section>
<section xml:id="creating-a-shell">
<title>Creating a Shell</title>
<para>
Getting access to an environment often isn't enough to do real
development. Many times we need to create a
<literal>shell.nix</literal> file and do our development inside
of the environment specified by that file. This file looks a lot
like the packageing described above. The main difference is that
<literal>src</literal> points to project root and we call the
package directly.
</para>
<programlisting>
{ pkgs ? import &quot;&lt;nixpkgs&quot;&gt; {} }:
with pkgs;
let
f = { buildHex, ibrowse, jsx, erlware_commons }:
buildHex {
name = "hex2nix";
version = "0.1.0";
src = ./.;
erlangDeps = [ ibrowse jsx erlware_commons ];
};
drv = erlangPackages.callPackage f {};
in
drv
</programlisting>
<section xml:id="building-in-a-shell">
<title>Building in a shell</title>
<para>
Unfortunatly for us users of Nix, Rebar isn't very cooperative
with us from the standpoint of building a hermetic
environment. When building the rebar3 support we had to do some
sneaky things to get it not to go out and pull packages on its
own. Also unfortunately, you have to do some of the same things
when building a project inside of a Nix shell.
<orderedlist numeration="arabic">
<listitem>
<para>Run <literal>rebar3-nix-bootstrap</literal> every time
dependencies change</para>
</listitem>
<listitem>
<para>Set Home to the current directory.</para>
</listitem>
</orderedlist>
If you do these two things then Rebar will be happy with you. I
codify these into a makefile. Forunately, rebar3-nix-bootstrap
is idempotent and fairly quick. so you can run it as often as
you like.
</para>
<programlisting>
# =============================================================================
# Rules
# =============================================================================
.PHONY= all test clean repl shell build test analyze bootstrap
all: test
clean:
rm -rf _build
rm -rf .cache
repl:
nix-shell --run "erl"
shell:
nix-shell --run "bash"
bootstrap:
nix-shell --pure --run "rebar3-nix-bootstrap"
build: bootstrap
nix-shell --pure --run "HOME=$(CURDIR) rebar3 compile"
analyze: bootstrap
nix-shell --pure --run "HOME=$(CURDIR) rebar3 do compile,dialyzer"
test: bootstrap
nix-shell --pure --run "HOME=$(CURDIR) rebar3 do compile,dialyzer,eunit"
</programlisting>
<para>
If you add the <literal>shell.nix</literal> as described and
user rebar as follows things should simply work.
</para>
</section>
</section>
</section>
<section xml:id="generating-packages-from-hex-with-hex2nix">
<title>Generating Packages from Hex with Hex2Nix</title>
<para>
Updating the Hex packages requires the use of the
<literal>hex2nix</literal> tool. Given the path to the Erlang
modules (usually
<literal>pkgs/development/erlang-modules</literal>). It will
happily dump a file called
<literal>hex-packages.nix</literal>. That file will contain all
the packages that use a recognized build system in Hex. However,
it can't know whether or not all those packages are buildable.
</para>
<para>
To make life easier for our users, it makes good sense to go
ahead and attempt to build all those packages and remove the
ones that don't build. To do that, simply run the command (in
the root of your <literal>nixpkgs</literal> repository). that follows.
</para>
<programlisting>
$ nix-build -A erlangPackages
</programlisting>
<para>
That will build every package in
<literal>erlangPackages</literal>. Then you can go through and
manually remove the ones that fail. Hopefully, someone will
improve <literal>hex2nix</literal> in the future to automate
that.
</para>
</section>
</chapter>

View file

@ -108,7 +108,7 @@ toolz = buildPythonPackage rec{
version = "0.7.4";
src = pkgs.fetchurl{
url = "https://pypi.python.org/packages/source/t/toolz/toolz-${version}.tar.gz";
url = "mirror://pypi/t/toolz/toolz-${version}.tar.gz";
sha256 = "43c2c9e5e7a16b6c88ba3088a9bfc82f7db8e13378be7c78d6c14a5f8ed05afd";
};
@ -146,7 +146,7 @@ pkgs.python35Packages.buildPythonPackage rec {
version = "0.7.4";
src = pkgs.fetchurl{
url = "https://pypi.python.org/packages/source/t/toolz/toolz-${version}.tar.gz";
url = "mirror://pypi/t/toolz/toolz-${version}.tar.gz";
sha256 = "43c2c9e5e7a16b6c88ba3088a9bfc82f7db8e13378be7c78d6c14a5f8ed05afd";
};
@ -175,7 +175,7 @@ with import <nixpkgs> {};
version = "0.7.4";
src = pkgs.fetchurl{
url = "https://pypi.python.org/packages/source/t/toolz/toolz-${version}.tar.gz";
url = "mirror://pypi/t/toolz/toolz-${version}.tar.gz";
sha256 = "43c2c9e5e7a16b6c88ba3088a9bfc82f7db8e13378be7c78d6c14a5f8ed05afd";
};
@ -220,7 +220,7 @@ datashape = buildPythonPackage rec {
version = "0.4.7";
src = pkgs.fetchurl {
url = "https://pypi.python.org/packages/source/D/DataShape/${name}.tar.gz";
url = "mirror://pypi/D/DataShape/${name}.tar.gz";
sha256 = "14b2ef766d4c9652ab813182e866f493475e65e558bed0822e38bf07bba1a278";
};
@ -251,7 +251,7 @@ lxml = buildPythonPackage rec {
name = "lxml-3.4.4";
src = pkgs.fetchurl {
url = "http://pypi.python.org/packages/source/l/lxml/${name}.tar.gz";
url = "mirror://pypi/l/lxml/${name}.tar.gz";
sha256 = "16a0fa97hym9ysdk3rmqz32xdjqmy4w34ld3rm3jf5viqjx65lxk";
};
@ -282,7 +282,7 @@ pyfftw = buildPythonPackage rec {
version = "0.9.2";
src = pkgs.fetchurl {
url = "https://pypi.python.org/packages/source/p/pyFFTW/pyFFTW-${version}.tar.gz";
url = "mirror://pypi/p/pyFFTW/pyFFTW-${version}.tar.gz";
sha256 = "f6bbb6afa93085409ab24885a1a3cdb8909f095a142f4d49e346f2bd1b789074";
};
@ -373,7 +373,7 @@ buildPythonPackage rec {
version = "0.7.4";
src = pkgs.fetchurl{
url = "https://pypi.python.org/packages/source/t/toolz/toolz-${version}.tar.gz";
url = "mirror://pypi/t/toolz/toolz-${version}.tar.gz";
sha256 = "43c2c9e5e7a16b6c88ba3088a9bfc82f7db8e13378be7c78d6c14a5f8ed05afd";
};

View file

@ -21,7 +21,7 @@
<xi:include href="coding-conventions.xml" />
<xi:include href="submitting-changes.xml" />
<xi:include href="haskell-users-guide.xml" />
<xi:include href="erlang-users-guide.xml" />
<xi:include href="beam-users-guide.xml" />
<xi:include href="contributing.xml" />
</book>

View file

@ -14,6 +14,7 @@
adev = "Adrien Devresse <adev@adev.name>";
Adjective-Object = "Maxwell Huang-Hobbs <mhuan13@gmail.com>";
aespinosa = "Allan Espinosa <allan.espinosa@outlook.com>";
adnelson = "Allen Nelson <ithinkican@gmail.com>";
aflatter = "Alexander Flatter <flatter@fastmail.fm>";
aforemny = "Alexander Foremny <alexanderforemny@googlemail.com>";
afranchuk = "Alex Franchuk <alex.franchuk@gmail.com>";

View file

@ -1,22 +0,0 @@
#! /usr/bin/perl -w
use strict;
my %map;
open LIST1, "<$ARGV[0]" or die;
while (<LIST1>) {
/^(\S+)\s+(.*)$/;
$map{$1} = $2;
}
open LIST1, "<$ARGV[1]" or die;
while (<LIST1>) {
/^(\S+)\s+(.*)$/;
if (!defined $map{$1}) {
print STDERR "missing file: $2\n";
next;
}
print "$2\n";
print "$map{$1}\n";
}

View file

@ -134,7 +134,7 @@ in {
}
(mkIf cfg.enable {
environment.systemPackages = [ cfg.package.out ];
environment.systemPackages = [ cfg.package ];
environment.etc = singleton {
target = "asound.conf";
@ -158,7 +158,7 @@ in {
wantedBy = [ "default.target" ];
serviceConfig = {
Type = "notify";
ExecStart = "${cfg.package}/bin/pulseaudio --daemonize=no";
ExecStart = "${cfg.package.out}/bin/pulseaudio --daemonize=no";
Restart = "on-failure";
};
};

View file

@ -22,7 +22,11 @@ with lib;
###### implementation
config = mkIf config.hardware.enableAllFirmware {
hardware.firmware = [ pkgs.firmwareLinuxNonfree pkgs.intel2200BGFirmware ];
hardware.firmware = with pkgs; [
firmwareLinuxNonfree
intel2200BGFirmware
rtl8723bs-firmware
];
};
}

View file

@ -338,6 +338,7 @@
./services/networking/kippo.nix
./services/networking/lambdabot.nix
./services/networking/libreswan.nix
./services/networking/logmein-hamachi.nix
./services/networking/mailpile.nix
./services/networking/mfi.nix
./services/networking/mjpg-streamer.nix

View file

@ -50,11 +50,8 @@ with lib;
ensureDir ${crashplan.vardir}/log 777
cp -avn ${crashplan}/conf.template/* ${crashplan.vardir}/conf
for x in app.asar bin EULA.txt install.vars lang lib libjniwrap64.so libjniwrap.so libjtux64.so libjtux.so libmd564.so libmd5.so share skin upgrade; do
if [ -e ${crashplan.vardir}/$x ]; then
true;
else
ln -s ${crashplan}/$x ${crashplan.vardir}/$x;
fi;
rm -f ${crashplan.vardir}/$x;
ln -sf ${crashplan}/$x ${crashplan.vardir}/$x;
done
'';

View file

@ -242,7 +242,7 @@ in
if test -e "${cfg.dataDir}/.first_startup"; then
${optionalString (cfg.initialScript != null) ''
cat "${cfg.initialScript}" | psql --port=${toString cfg.port} postgres
psql -f "${cfg.initialScript}" --port=${toString cfg.port} postgres
''}
rm -f "${cfg.dataDir}/.first_startup"
fi

View file

@ -11,7 +11,10 @@ let
rm $out/logcheck.*
'';
rulesDir = pkgs.symlinkJoin "logcheck-rules-dir" ([ defaultRules ] ++ cfg.extraRulesDirs);
rulesDir = pkgs.symlinkJoin
{ name = "logcheck-rules-dir";
paths = ([ defaultRules ] ++ cfg.extraRulesDirs);
};
configFile = pkgs.writeText "logcheck.conf" cfg.config;

View file

@ -63,8 +63,10 @@ let
cfg.extraConfig
];
modulesDir = pkgs.symlinkJoin "dovecot-modules"
(map (pkg: "${pkg}/lib/dovecot") ([ dovecotPkg ] ++ map (module: module.override { dovecot = dovecotPkg; }) cfg.modules));
modulesDir = pkgs.symlinkJoin {
name = "dovecot-modules";
paths = map (pkg: "${pkg}/lib/dovecot") ([ dovecotPkg ] ++ map (module: module.override { dovecot = dovecotPkg; }) cfg.modules);
};
in
{

View file

@ -0,0 +1,50 @@
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.services.logmein-hamachi;
in
{
###### interface
options = {
services.logmein-hamachi.enable = mkOption {
type = types.bool;
default = false;
description =
''
Whether to enable LogMeIn Hamachi, a proprietary
(closed source) commercial VPN software.
'';
};
};
###### implementation
config = mkIf cfg.enable {
systemd.services.logmein-hamachi = {
description = "LogMeIn Hamachi Daemon";
wantedBy = [ "multi-user.target" ];
after = [ "network.target" "local-fs.target" ];
serviceConfig = {
Type = "forking";
ExecStart = "${pkgs.logmein-hamachi}/bin/hamachid";
};
};
environment.systemPackages = [ pkgs.logmein-hamachi ];
};
}

View file

@ -121,7 +121,7 @@ in
security.setuidOwners = singleton
{ program = "dbus-daemon-launch-helper";
source = "${pkgs.dbus_daemon.lib}/libexec/dbus-daemon-launch-helper";
source = "${pkgs.dbus_daemon.out}/libexec/dbus-daemon-launch-helper";
owner = "root";
group = "messagebus";
setuid = true;

View file

@ -36,7 +36,7 @@ in
type = types.loaOf types.optionSet;
default = {};
example = literalExample ''
{ hosts =
{ example-configuration-file =
{ source = "/nix/store/.../etc/dir/file.conf.example";
mode = "0440";
};

View file

@ -523,7 +523,7 @@ in
networking.bonds = mkOption {
default = { };
example = {
example = literalExample {
bond0 = {
interfaces = [ "eth0" "wlan0" ];
miimon = 100;
@ -598,7 +598,7 @@ in
networking.macvlans = mkOption {
type = types.attrsOf types.optionSet;
default = { };
example = {
example = literalExample {
wan = {
interface = "enp2s0";
mode = "vepa";
@ -629,7 +629,7 @@ in
networking.sits = mkOption {
type = types.attrsOf types.optionSet;
default = { };
example = {
example = literalExample {
hurricane = {
remote = "10.0.0.1";
local = "10.0.0.22";
@ -688,7 +688,7 @@ in
networking.vlans = mkOption {
default = { };
example = {
example = literalExample {
vlan0 = {
id = 3;
interface = "enp3s0";
@ -727,7 +727,7 @@ in
networking.wlanInterfaces = mkOption {
default = { };
example = {
example = literalExample {
"wlan-station0" = {
device = "wlp6s0";
};

View file

@ -31,7 +31,8 @@ in rec {
inherit (nixos') channel manual iso_minimal dummy;
tests = {
inherit (nixos'.tests)
containers
containers-imperative
containers-ipv4
firewall
ipv6
login

View file

@ -1,22 +1,14 @@
{ stdenv, buildEnv, deadbeef, makeWrapper, plugins }:
{ stdenv, symlinkJoin, deadbeef, makeWrapper, plugins }:
let
drv = buildEnv {
name = "deadbeef-with-plugins-" + (builtins.parseDrvName deadbeef.name).version;
symlinkJoin {
name = "deadbeef-with-plugins-${deadbeef.version}";
paths = [ deadbeef ] ++ plugins;
buildInputs = [ makeWrapper ];
postBuild = ''
# TODO: This could be avoided if buildEnv could be forced to create all directories
if [ -L $out/bin ]; then
rm $out/bin
mkdir $out/bin
for i in ${deadbeef}/bin/*; do
ln -s $i $out/bin
done
fi
wrapProgram $out/bin/deadbeef \
--set DEADBEEF_PLUGIN_DIR "$out/lib/deadbeef"
'';
};
in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; })
}

View file

@ -9,10 +9,10 @@ assert portaudioSupport -> portaudio != null;
stdenv.mkDerivation rec {
name = "fmit-${version}";
version = "1.0.8";
version = "1.0.13";
src = fetchFromGitHub {
sha256 = "04s7xcgmi5g58lirr48vf203n1jwdxf981x1p6ysbax24qwhs2kd";
sha256 = "04cj70q60sqns68nvw4zfy6078x4cc2q1y2y13z3rs5n80jw27by";
rev = "v${version}";
repo = "fmit";
owner = "gillesdegottex";

View file

@ -1,23 +1,16 @@
{ stdenv, buildEnv, puredata, makeWrapper, plugins }:
{ stdenv, symlinkJoin, puredata, makeWrapper, plugins }:
let
puredataFlags = map (x: "-path ${x}/") plugins;
drv = buildEnv {
name = "puredata-with-plugins-" + (builtins.parseDrvName puredata.name).version;
in symlinkJoin {
name = "puredata-with-plugins-${puredata.version}";
paths = [ puredata ] ++ plugins;
buildInputs = [ makeWrapper ];
postBuild = ''
# TODO: This could be avoided if buildEnv could be forced to create all directories
if [ -L $out/bin ]; then
rm $out/bin
mkdir $out/bin
for i in ${puredata}/bin/*; do
ln -s $i $out/bin
done
fi
wrapProgram $out/bin/pd \
--add-flags "${toString puredataFlags}"
'';
};
in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; })
}

View file

@ -2,14 +2,14 @@
let
version = "4.6.0";
rev = "2"; #tracks unversioned changes that occur on download.code42.com from time to time
rev = "3"; #tracks unversioned changes that occur on download.code42.com from time to time
in stdenv.mkDerivation rec {
name = "crashplan-${version}-r${rev}";
crashPlanArchive = fetchurl {
url = "https://download.code42.com/installs/linux/install/CrashPlan/CrashPlan_${version}_Linux.tgz";
sha256 = "13rmmdj048r8k4v7ig4i6pnvwyzc1vasfgksf070bx6ksklgbq47";
sha256 = "0crrx8gy132xcpjfah08qhsl8g2arx14p5mpypcihl9j6mldi6mz";
};
srcs = [ crashPlanArchive ];

File diff suppressed because it is too large Load diff

View file

@ -2,12 +2,13 @@
# Updating
To update the list of packages from ELPA,
To update the list of packages from MELPA,
1. Clone https://github.com/ttuegel/emacs2nix
2. Run `./elpa-packages.sh` from emacs2nix
3. Copy the new elpa-packages.json file into Nixpkgs
4. `git commit -m "elpa-packages $(date -Idate)"`
1. Clone https://github.com/ttuegel/emacs2nix.
2. Run `./elpa-packages.sh` from emacs2nix.
3. Copy the new `elpa-generated.nix` file into Nixpkgs.
4. Check for evaluation errors: `nix-instantiate ./. -A emacsPackagesNg.elpaPackages`.
5. `git add pkgs/applications/editors/emacs-modes/elpa-generated.nix && git commit -m "elpa-packages $(date -Idate)"`
*/
@ -40,6 +41,7 @@ self:
midi-kbd = markBroken super.midi-kbd; # requires emacs-25
stream = markBroken super.stream; # requires emacs-25
cl-lib = null; # builtin
tle = null; # builtin
};
elpaPackages = super // overrides;

File diff suppressed because it is too large Load diff

View file

@ -4,11 +4,12 @@
To update the list of packages from MELPA,
1. Clone https://github.com/ttuegel/emacs2nix
2. Clone https://github.com/milkypostman/melpa
3. Run `./melpa-packages.sh PATH_TO_MELPA_CLONE` from emacs2nix
4. Copy the new melpa-packages.json file into Nixpkgs
5. `git commit -m "melpa-packages $(date -Idate)"`
1. Clone https://github.com/ttuegel/emacs2nix.
2. Clone https://github.com/milkypostman/melpa.
3. Run `./melpa-packages.sh --melpa PATH_TO_MELPA_CLONE` from emacs2nix.
4. Copy the new `melpa-generated.nix` file into Nixpkgs.
5. Check for evaluation errors: `nix-instantiate ./. -A emacsPackagesNg.melpaPackages`.
6. `git add pkgs/applications/editors/emacs-modes/melpa-generated.nix && git commit -m "melpa-packages $(date -Idate)"`
*/

View file

@ -2,15 +2,14 @@
# Updating
To update the list of packages from MELPA Stable,
To update the list of packages from MELPA,
1. Clone https://github.com/ttuegel/emacs2nix
2. Clone https://github.com/milkypostman/melpa
3. Run `./melpa-stable-packages.sh PATH_TO_MELPA_CLONE` from emacs2nix.
Error messages about missing versions are normal; most packages in
MELPA do not have a stable version.
4. Copy the new melpa-stable-packages.json file into Nixpkgs
5. `git commit -m "melpa-stable-packages $(date -Idate)"`
1. Clone https://github.com/ttuegel/emacs2nix.
2. Clone https://github.com/milkypostman/melpa.
3. Run `./melpa-stable-packages.sh --melpa PATH_TO_MELPA_CLONE` from emacs2nix.
4. Copy the new `melpa-stable-generated.nix` file into Nixpkgs.
5. Check for evaluation errors: `nix-instantiate ./. -A emacsPackagesNg.melpaStablePackages`.
6. `git add pkgs/applications/editors/emacs-modes/melpa-stable-generated.nix && git commit -m "melpa-stable-packages $(date -Idate)"`
*/

View file

@ -4,7 +4,8 @@
, python, pygtk, libart_lgpl, libexif, gettext, xorg, wrapPython }:
stdenv.mkDerivation rec {
name = "gimp-2.8.16";
name = "gimp-${version}";
version = "2.8.16";
# This declarations for `gimp-with-plugins` wrapper,
# (used for determining $out/lib/gimp/${majorVersion}/ paths)

View file

@ -1,24 +1,18 @@
{ stdenv, lib, buildEnv, gimp, makeWrapper, gimpPlugins, plugins ? null}:
{ stdenv, lib, symlinkJoin, gimp, makeWrapper, gimpPlugins, plugins ? null}:
let
allPlugins = lib.filter (pkg: builtins.isAttrs pkg && pkg.type == "derivation") (lib.attrValues gimpPlugins);
selectedPlugins = if plugins == null then allPlugins else plugins;
extraArgs = map (x: x.wrapArgs or "") selectedPlugins;
drv = buildEnv {
name = "gimp-with-plugins-" + (builtins.parseDrvName gimp.name).version;
in symlinkJoin {
name = "gimp-with-plugins-${gimp.version}";
paths = [ gimp ] ++ selectedPlugins;
buildInputs = [ makeWrapper ];
postBuild = ''
# TODO: This could be avoided if buildEnv could be forced to create all directories
if [ -L $out/bin ]; then
rm $out/bin
mkdir $out/bin
for i in ${gimp}/bin/*; do
ln -s $i $out/bin
done
fi
for each in gimp-2.8 gimp-console-2.8; do
wrapProgram $out/bin/$each \
--set GIMP2_PLUGINDIR "$out/lib/gimp/2.0" \
@ -29,5 +23,4 @@ drv = buildEnv {
ln -sf "$each-2.8" $out/bin/$each
done
'';
};
in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; })
}

View file

@ -3,11 +3,11 @@
stdenv.mkDerivation rec {
name = "simple-scan-${version}";
version = "3.20.0";
version = "3.21.1";
src = fetchurl {
sha256 = "0b5ndrjwi7yipkr9bhyifpbdil65izdm677if23yj832n2jsbxcd";
url = "https://launchpad.net/simple-scan/3.20/${version}/+download/${name}.tar.xz";
sha256 = "00w206isni8m8qd9m8x0644s1gqg11pvgnw6zav33b0bs2h2kk79";
url = "https://launchpad.net/simple-scan/3.21/${version}/+download/${name}.tar.xz";
};
buildInputs = [ cairo colord glib gusb gtk3 libusb1 libxml2 sane-backends

View file

@ -1,5 +1,5 @@
{ stdenv, fetchurl, python, pyqt5, sip_4_16, poppler_utils, pkgconfig, libpng
, imagemagick, libjpeg, fontconfig, podofo, qtbase, icu, sqlite
, imagemagick, libjpeg, fontconfig, podofo, qtbase, qmakeHook, icu, sqlite
, makeWrapper, unrarSupport ? false, chmlib, pythonPackages, xz, libusb1, libmtp
, xdg_utils
}:
@ -26,7 +26,14 @@ stdenv.mkDerivation rec {
setup/build_environment.py
'';
nativeBuildInputs = [ makeWrapper pkgconfig ];
dontUseQmakeConfigure = true;
# hack around a build problem
preBuild = ''
mkdir -p ../tmp.*/lib
ln -s '${qtbase.out}/lib/libQt5PlatformSupport.a' ../tmp.*/lib/
'';
nativeBuildInputs = [ makeWrapper pkgconfig qmakeHook ];
buildInputs =
[ python pyqt5 sip_4_16 poppler_utils libpng imagemagick libjpeg

View file

@ -5,7 +5,7 @@ let
version = "0.1.7";
name = "jsonrpclib-${version}";
src = fetchurl {
url = "https://pypi.python.org/packages/source/j/jsonrpclib/${name}.tar.gz";
url = "mirror://pypi/j/jsonrpclib/${name}.tar.gz";
sha256 = "02vgirw2bcgvpcxhv5hf3yvvb4h5wzd1lpjx8na5psdmaffj6l3z";
};
propagatedBuildInputs = [ pythonPackages.cjson ];

View file

@ -1,22 +1,14 @@
{ lib, buildEnv, k3b-original, cdrtools, makeWrapper }:
{ lib, symlinkJoin, k3b-original, cdrtools, makeWrapper }:
let
binPath = lib.makeBinPath [ cdrtools ];
in buildEnv {
in symlinkJoin {
name = "k3b-${k3b-original.version}";
paths = [ k3b-original ];
buildInputs = [ makeWrapper ];
postBuild = ''
# TODO: This could be avoided if buildEnv could be forced to create all directories
if [ -L $out/bin ]; then
rm $out/bin
mkdir $out/bin
for i in ${k3b-original}/bin/*; do
ln -s $i $out/bin
done
fi
wrapProgram $out/bin/k3b \
--prefix PATH ':' ${binPath}
'';

View file

@ -5,7 +5,7 @@ python3Packages.buildPythonApplication rec {
name = "khal-${version}";
src = fetchurl {
url = "https://pypi.python.org/packages/source/k/khal/khal-${version}.tar.gz";
url = "mirror://pypi/k/khal/khal-${version}.tar.gz";
sha256 = "00llxj7cv31mjsx0j6zxmyi9s1q20yvfkn025xcy8cv1ylfwic66";
};

View file

@ -16,7 +16,7 @@ buildPythonApplication rec {
namePrefix = "";
src = fetchurl {
url = "http://pypi.python.org/packages/source/p/pitz/${name}.tar.gz";
url = "mirror://pypi/p/pitz/${name}.tar.gz";
sha256 = "1k7f3h4acllzqy3mjqnjd4w5jskp03s79b7dx3c85vlmd7824smr";
};

View file

@ -1,15 +1,17 @@
{ stdenv, fetchurl, git, gnupg, makeQtWrapper, pass, qtbase, qtsvg, qttools, qmakeHook }:
{ stdenv, fetchzip, git, gnupg, makeQtWrapper, pass, qtbase, qtsvg, qttools, qmakeHook }:
stdenv.mkDerivation rec {
name = "qtpass-${version}";
version = "1.1.0";
version = "1.1.1";
src = fetchurl {
src = fetchzip {
url = "https://github.com/IJHack/qtpass/archive/v${version}.tar.gz";
sha256 = "60b458062f54184057e55dbd9c93958a8bf845244ffd70b9cb31bf58697f0dc6";
sha256 = "1x1ic9as0a60gz664sf8d1qiq64ji7q60g19x0rlm3bvcp2612c8";
};
buildInputs = [ git gnupg makeQtWrapper pass qtbase qtsvg qttools qmakeHook ];
buildInputs = [ git gnupg pass qtbase qtsvg qttools ];
nativeBuildInputs = [ makeQtWrapper qmakeHook ];
preConfigure = ''
qmakeFlags="$qmakeFlags CONFIG+=release DESTDIR=$out"
@ -18,9 +20,12 @@ stdenv.mkDerivation rec {
installPhase = ''
mkdir $out/bin
mv $out/qtpass $out/bin
install -D {,$out/share/applications/}qtpass.desktop
install -D artwork/icon.svg $out/share/icons/hicolor/scalable/apps/qtpass-icon.svg
runHook postInstall
'';
postFixup = ''
postInstall = ''
wrapQtProgram $out/bin/qtpass \
--suffix PATH : ${git}/bin \
--suffix PATH : ${gnupg}/bin \
@ -29,7 +34,7 @@ stdenv.mkDerivation rec {
meta = with stdenv.lib; {
description = "A multi-platform GUI for pass, the standard unix password manager";
homepage = https://github.com/IJHack/qtpass;
homepage = https://qtpass.org;
license = licenses.gpl3;
maintainers = [ maintainers.hrdinka ];
platforms = platforms.all;

View file

@ -1,28 +1,21 @@
{ stdenv, buildEnv, rxvt_unicode, makeWrapper, plugins }:
{ stdenv, symlinkJoin, rxvt_unicode, makeWrapper, plugins }:
let
rxvt = rxvt_unicode.override {
perlSupport = true;
};
drv = buildEnv {
name = "${rxvt.name}-with-plugins";
in symlinkJoin {
name = "${rxvt.name}-with-plugins";
paths = [ rxvt ] ++ plugins;
paths = [ rxvt ] ++ plugins;
postBuild = ''
# TODO: This could be avoided if buildEnv could be forced to create all directories
if [ -L $out/bin ]; then
rm $out/bin
mkdir $out/bin
for i in ${rxvt}/bin/*; do
ln -s $i $out/bin
done
fi
wrapProgram $out/bin/urxvt \
--suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl"
wrapProgram $out/bin/urxvtd \
--suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl"
'';
};
in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; })
buildInputs = [ makeWrapper ];
postBuild = ''
wrapProgram $out/bin/urxvt \
--suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl"
wrapProgram $out/bin/urxvtd \
--suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl"
'';
}

View file

@ -1,24 +1,17 @@
{ stdenv, buildEnv, pidgin, makeWrapper, plugins }:
{ stdenv, symlinkJoin, pidgin, makeWrapper, plugins }:
let
extraArgs = map (x: x.wrapArgs or "") plugins;
drv = buildEnv {
name = "pidgin-with-plugins-" + (builtins.parseDrvName pidgin.name).version;
in symlinkJoin {
name = "pidgin-with-plugins-${pidgin.version}";
paths = [ pidgin ] ++ plugins;
buildInputs = [ makeWrapper ];
postBuild = ''
# TODO: This could be avoided if buildEnv could be forced to create all directories
if [ -L $out/bin ]; then
rm $out/bin
mkdir $out/bin
for i in ${pidgin}/bin/*; do
ln -s $i $out/bin
done
fi
wrapProgram $out/bin/pidgin \
--suffix-each PURPLE_PLUGIN_PATH ':' "$out/lib/purple-${pidgin.majorVersion} $out/lib/pidgin" \
${toString extraArgs}
'';
};
in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; })
}

View file

@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
buildInputs = [
breakpad ffmpeg openalSoft openssl zlib libexif lzma libopus
gtk2 glib libappindicator-gtk2 libunity cairo pango gdk_pixbuf atk
dee libdbusmenu-glib libva qmakeHook
dee libdbusmenu-glib libva qtbase qmakeHook
# Qt dependencies
libxcb xcbutilwm xcbutilimage xcbutilkeysyms libxkbcommon
libpng libjpeg freetype harfbuzz pcre16 xproto libX11

View file

@ -1,4 +1,4 @@
{ stdenv, fetchurl, cmake, pkgconfig, qt4, boost, bzip2, libX11, pcre, libidn, lua5, miniupnpc, aspell, gettext }:
{ stdenv, fetchurl, cmake, pkgconfig, qt4, boost, bzip2, libX11, pcre-cpp, libidn, lua5, miniupnpc, aspell, gettext }:
stdenv.mkDerivation rec {
name = "eiskaltdcpp-2.2.9";
@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
sha256 = "3d9170645450f9cb0a605278b8646fec2110b9637910d86fd27cf245cbe24eaf";
};
buildInputs = [ cmake pkgconfig qt4 boost bzip2 libX11 pcre libidn lua5 miniupnpc aspell gettext ];
buildInputs = [ cmake pkgconfig qt4 boost bzip2 libX11 pcre-cpp libidn lua5 miniupnpc aspell gettext ];
cmakeFlags = ''
-DUSE_ASPELL=ON

View file

@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
url = "https://github.com/jonsterling/JonPRL.git";
deepClone = true;
rev = "refs/tags/v${version}";
sha256 = "1z0d8dq1nb4dycic58nnk617hbfgafz0vmwr8gkl0i6405gfg1zy";
sha256 = "09m1vb41vxvqnk78gm9inip1abknkywij30rghvym93q460cl2hm";
};
buildInputs = [ smlnj which ];

View file

@ -43,5 +43,6 @@ stdenv.mkDerivation {
license = stdenv.lib.licenses.publicDomain ;
maintainers = [stdenv.lib.maintainers.raskin];
platforms = stdenv.lib.platforms.linux;
broken = true;
};
}

View file

@ -12,8 +12,14 @@ stdenv.mkDerivation rec {
buildInputs = [ cmake pkgconfig python libX11 libXpm libXft libXext zlib lzma ];
preConfigure = ''
patchShebangs build/unix/
'';
cmakeFlags = [
"-Drpath=ON"
"-DCMAKE_INSTALL_LIBDIR=lib"
"-DCMAKE_INSTALL_INCLUDEDIR=include"
]
++ stdenv.lib.optional (stdenv.cc.libc != null) "-DC_INCLUDE_DIRS=${stdenv.cc.libc}/include";

View file

@ -13,7 +13,7 @@ buildPythonApplication rec {
namePrefix = "";
src = fetchurl {
url = "https://pypi.python.org/packages/source/s/spyder/${name}.zip";
url = "mirror://pypi/s/spyder/${name}.zip";
sha256 = "99fdae2cea325c0f2842c77bd67dd22db19fef3d9c0dde1545b1a2650eae517e";
};

View file

@ -11,7 +11,7 @@ pythonPackages.buildPythonApplication rec {
src = fetchurl {
url =
"https://pypi.python.org/packages/source/b/bugs-everywhere/bugs-everywhere-${version}.tar.gz";
"mirror://pypi/b/bugs-everywhere/bugs-everywhere-${version}.tar.gz";
sha256 = "1ikm3ckwpimwcvx32vy7gh5gbp7q750j3327m17nvrj99g3daz2d";
};

View file

@ -1,4 +1,4 @@
{stdenv, fetchurl, zlib, openssl, tcl, readline, sqlite, withJson ? true}:
{stdenv, libiconv, fetchurl, zlib, openssl, tcl, readline, sqlite, withJson ? true}:
stdenv.mkDerivation rec {
name = "fossil-1.33";
@ -12,7 +12,8 @@ stdenv.mkDerivation rec {
sha256 = "0gkzd9nj3xyznh9x8whv0phdnj11l5c8164rc3l0jvs5i61c95b2";
};
buildInputs = [ zlib openssl readline sqlite ];
buildInputs = [ zlib openssl readline sqlite ]
++ stdenv.lib.optional stdenv.isDarwin libiconv;
nativeBuildInputs = [ tcl ];
doCheck = true;

View file

@ -1,4 +1,4 @@
{ buildEnv, avidemux_unwrapped, makeWrapper
{ symlinkJoin, avidemux_unwrapped, makeWrapper
# GTK version is broken upstream, see https://bugzilla.redhat.com/show_bug.cgi?id=1244340
, withUi ? "qt4"
}:
@ -7,24 +7,14 @@ let ui = builtins.getAttr "avidemux_${withUi}" avidemux_unwrapped; in
assert ui.isUi;
buildEnv {
name = "avidemux-${withUi}-" + ui.version;
symlinkJoin {
name = "avidemux-${withUi}-${ui.version}";
paths = [ ui avidemux_unwrapped.avidemux_common avidemux_unwrapped.avidemux_settings ];
ignoreCollisions = true;
buildInputs = [ makeWrapper ];
postBuild = ''
# TODO: This could be avoided if buildEnv could be forced to create all directories
if [ -L $out/bin ]; then
rm $out/bin
mkdir $out/bin
for i in ${ui}/bin/*; do
ln -s $i $out/bin
done
fi
for i in $out/bin/*; do
wrapProgram $i --set ADM_ROOT_DIR $out
done

View file

@ -7,7 +7,7 @@ python3Packages.buildPythonApplication rec {
disabled = !python3Packages.isPy3k;
src = fetchurl {
url = "https://pypi.python.org/packages/source/i/${pname}/${name}.tar.gz";
url = "mirror://pypi/i/${pname}/${name}.tar.gz";
sha256 = "1bpkkf9q4zqq7fh65zynbv26nq24rfznmw71jjvda7g8kjrwjdk5";
};

View file

@ -340,4 +340,9 @@ rec {
http://repo.steampowered.com/steamrt/
https://abbradar.net/steamrt/
];
# Python PyPI mirrors
pypi = [
https://pypi.io/packages/source/
];
}

View file

@ -47,16 +47,24 @@ rec {
# Create a forest of symlinks to the files in `paths'.
symlinkJoin = name: paths:
symlinkJoin =
{ name
, paths
, preferLocalBuild ? true
, allowSubstitutes ? false
, postBuild ? ""
, buildInputs ? []
, meta ? {}
}:
runCommand name
{ inherit paths;
preferLocalBuild = true; allowSubstitutes = false;
{ inherit paths preferLocalBuild allowSubstitutes buildInputs meta;
}
''
mkdir -p $out
for i in $paths; do
${lndir}/bin/lndir $i $out
done
${postBuild}
'';

View file

@ -2,13 +2,13 @@
stdenv.mkDerivation rec {
name = "hack-font-${version}";
version = "2.019";
version = "2.020";
src = let
version_ = with stdenv.lib;
concatStringsSep "_" (splitString "." version);
in fetchurl {
sha256 = "0fhrl7y5z3d5fkiycbsi621f8nzfnpz8khxpd6hkc1hrg7nzmrk4";
sha256 = "16kkmc3psckw1b7k07ccn1gi5ymhlg9djh43nqjzg065g6p6d184";
url = "https://github.com/chrissimpkins/Hack/releases/download/v${version}/Hack-v${version_}-ttf.zip";
};

View file

@ -51,8 +51,10 @@ let
let
version = (builtins.parseDrvName breeze-qt5.name).version;
in
symlinkJoin "breeze-${version}"
(map (pkg: pkg.out or pkg) [ breeze-gtk breeze-qt4 breeze-qt5 ]);
symlinkJoin {
name = "breeze-${version}";
paths = map (pkg: pkg.out or pkg) [ breeze-gtk breeze-qt4 breeze-qt5 ];
};
kactivitymanagerd = callPackage ./kactivitymanagerd.nix {};
kde-cli-tools = callPackage ./kde-cli-tools.nix {};
kde-gtk-config = callPackage ./kde-gtk-config {};

View file

@ -6,7 +6,7 @@ buildPythonApplication rec {
namePrefix = "";
src = fetchurl {
url = "http://pypi.python.org/packages/source/i/ino/${name}.tar.gz";
url = "mirror://pypi/i/ino/${name}.tar.gz";
sha256 = "0k6lzfcn55favbj0w4afrvnmwyskf7bgzg9javv2ycvskp35srwv";
};

View file

@ -0,0 +1,86 @@
{ stdenv, writeText, erlang, perl, which, gitMinimal, wget }:
{ name, version
, src
, setupHook ? null
, buildInputs ? []
, beamDeps ? []
, postPatch ? ""
, compilePorts ? false
, installPhase ? null
, meta ? {}
, ... }@attrs:
with stdenv.lib;
let
shell = drv: stdenv.mkDerivation {
name = "interactive-shell-${drv.name}";
buildInputs = [ drv ];
};
pkg = self: stdenv.mkDerivation ( attrs // {
app_name = "${name}";
name = "${name}-${version}";
inherit version;
dontStrip = true;
inherit src;
setupHook = if setupHook == null
then writeText "setupHook.sh" ''
addToSearchPath ERL_LIBS "$1/lib/erlang/lib"
''
else setupHook;
buildInputs = [ erlang perl which gitMinimal wget ];
propagatedBuildInputs = beamDeps;
configurePhase = ''
runHook preConfigure
# We shouldnt need to do this, but it seems at times there is a *.app in
# the repo/package. This ensures we start from a clean slate
make SKIP_DEPS=1 clean
runHook postConfigure
'';
buildPhase = ''
runHook preBuild
make SKIP_DEPS=1
runHook postBuild
'';
installPhase = ''
runHook preInstall
mkdir -p $out/lib/erlang/lib/${name}
cp -r ebin $out/lib/erlang/lib/${name}/
cp -r src $out/lib/erlang/lib/${name}/
if [ -d include ]; then
cp -r include $out/lib/erlang/lib/${name}/
fi
if [ -d priv ]; then
cp -r priv $out/lib/erlang/lib/${name}/
fi
if [ -d doc ]; then
cp -r doc $out/lib/erlang/lib/${name}/
fi
runHook postInstall
'';
passthru = {
packageName = name;
env = shell self;
inherit beamDeps;
};
});
in fix pkg

View file

@ -0,0 +1,85 @@
{ stdenv, writeText, elixir, erlang, hexRegistrySnapshot, hex }:
{ name
, version
, src
, setupHook ? null
, buildInputs ? []
, beamDeps ? []
, postPatch ? ""
, compilePorts ? false
, meta ? {}
, ... }@attrs:
with stdenv.lib;
let
shell = drv: stdenv.mkDerivation {
name = "interactive-shell-${drv.name}";
buildInputs = [ drv ];
};
bootstrapper = ./mix-bootstrap;
pkg = self: stdenv.mkDerivation ( attrs // {
name = "${name}-${version}";
inherit version;
dontStrip = true;
inherit src;
setupHook = if setupHook == null
then writeText "setupHook.sh" ''
addToSearchPath ERL_LIBS "$1/lib/erlang/lib"
''
else setupHook;
inherit buildInputs;
propagatedBuildInputs = [ hexRegistrySnapshot hex elixir ] ++ beamDeps;
configurePhase = ''
runHook preConfigure
${erlang}/bin/escript ${bootstrapper}
runHook postConfigure
'';
buildPhase = ''
runHook preBuild
export HEX_OFFLINE=1
export HEX_HOME=`pwd`
export MIX_ENV=prod
MIX_ENV=prod mix compile --debug-info --no-deps-check
runHook postBuild
'';
installPhase = ''
runHook preInstall
MIXENV=prod
if [ -d "_build/shared" ]; then
MIXENV=shared
fi
mkdir -p "$out/lib/erlang/lib/${name}-${version}"
for reldir in src ebin priv include; do
fd="_build/$MIXENV/lib/${name}/$reldir"
[ -d "$fd" ] || continue
cp -Hrt "$out/lib/erlang/lib/${name}-${version}" "$fd"
success=1
done
runHook postInstall
'';
passthru = {
packageName = name;
env = shell self;
inherit beamDeps;
};
});
in fix pkg

View file

@ -1,10 +1,10 @@
{ stdenv, writeText, erlang, rebar3, openssl, libyaml, fetchHex, fetchFromGitHub,
{ stdenv, writeText, erlang, rebar3, openssl, libyaml,
pc, buildEnv }:
{ name, version
, src
, setupHook ? null
, buildInputs ? [], erlangDeps ? [], buildPlugins ? []
, buildInputs ? [], beamDeps ? [], buildPlugins ? []
, postPatch ? ""
, compilePorts ? false
, installPhase ? null
@ -27,8 +27,9 @@ let
inherit version;
buildInputs = buildInputs ++ [ erlang rebar3 openssl libyaml ];
propagatedBuildInputs = unique (erlangDeps ++ ownPlugins);
propagatedBuildInputs = unique (beamDeps ++ ownPlugins);
dontStrip = true;
# The following are used by rebar3-nix-bootstrap
inherit compilePorts;
buildPlugins = ownPlugins;
@ -47,7 +48,7 @@ let
configurePhase = ''
runHook preConfigure
rebar3-nix-bootstrap
${erlang}/bin/escript ${rebar3.bootstrapper}
runHook postConfigure
'';
@ -81,7 +82,7 @@ let
passthru = {
packageName = name;
env = shell self;
inherit erlangDeps;
inherit beamDeps;
};
});
in

View file

@ -0,0 +1,16 @@
{ stdenv, pkgs }:
let
self = rec {
hexPackages = import ./hex-packages.nix { stdenv = stdenv; callPackage = self.callPackage; pkgs = pkgs; };
callPackage = pkgs.lib.callPackageWith (pkgs // self // hexPackages);
buildRebar3 = callPackage ./build-rebar3.nix {};
buildHex = callPackage ./build-hex.nix {};
buildErlangMk = callPackage ./build-erlang-mk.nix {};
buildMix = callPackage ./build-mix.nix {};
## Non hex packages
hex = callPackage ./hex {};
webdriver = callPackage ./webdriver {};
};
in self // self.hexPackages

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,23 @@
{stdenv, writeText, fetchFromGitHub }:
stdenv.mkDerivation rec {
name = "hex-registry";
rev = "59b836d";
version = "0.0.0+build.${rev}";
src = fetchFromGitHub {
owner = "erlang-nix";
repo = "hex-pm-registry-snapshots";
inherit rev;
sha256 = "1l8m6ckn5ivhfiv3k4dymi6b7wg511fwymnpxd6ymfd39dq0n5b0";
};
installPhase = ''
mkdir -p "$out/var/hex"
zcat "registry.ets.gz" > "$out/var/hex/registry.ets"
'';
setupHook = writeText "setupHook.sh" ''
export HEX_REGISTRY_SNAPSHOT="$1/var/hex/registry.ets"
'';
}

View file

@ -0,0 +1,58 @@
{stdenv, fetchFromGitHub, writeText, elixir }:
let
shell = drv: stdenv.mkDerivation {
name = "interactive-shell-${drv.name}";
buildInputs = [ drv ];
};
pkg = self: stdenv.mkDerivation rec {
name = "hex";
version = "v0.11.3";
src = fetchFromGitHub {
owner = "hexpm";
repo = "hex";
rev = "f5e200ad95f030f0a7ab88a86545dd0dde1ee521";
sha256 = "0n4cgmnbmglarydls9pmxznbzp49pv85ncbd4f2lp1fm7qr08xfw";
};
setupHook = writeText "setupHook.sh" ''
addToSearchPath ERL_LIBS "$1/lib/erlang/lib/"
'';
dontStrip = true;
buildInputs = [ elixir ];
buildPhase = ''
runHook preBuild
export HEX_OFFLINE=1
export HEX_HOME=./
export MIX_ENV=prod
mix compile
runHook postBuild
'';
installPhase = ''
runHook preInstall
mkdir -p $out/lib/erlang/lib
cp -r ./_build/prod/lib/hex $out/lib/erlang/lib/
runHook postInstall
'';
meta = {
description = "Package manager for the Erlang VM https://hex.pm";
license = stdenv.lib.licenses.mit;
homepage = "https://github.com/hexpm/hex";
maintainers = with stdenv.lib.maintainers; [ ericbmerritt ];
};
passthru = {
env = shell self;
};
};
in stdenv.lib.fix pkg

View file

@ -0,0 +1,112 @@
#!/usr/bin/env escript
%% -*- erlang-indent-level: 4;indent-tabs-mode: nil -*-
%%! -smp enable
%%% ---------------------------------------------------------------------------
%%% @doc
%%% The purpose of this command is to prepare a rebar3 project so that
%%% rebar3 understands that the dependencies are all already
%%% installed. If you want a hygienic build on nix then you must run
%%% this command before running rebar3. I suggest that you add a
%%% `Makefile` to your project and have the bootstrap command be a
%%% dependency of the build commands. See the nix documentation for
%%% more information.
%%%
%%% This command designed to have as few dependencies as possible so
%%% that it can be a dependency of root level packages like rebar3. To
%%% that end it does many things in a fairly simplistic way. That is
%%% by design.
%%%
%%% ### Assumptions
%%%
%%% This command makes the following assumptions:
%%%
%%% * It is run in a nix-shell or nix-build environment
%%% * that all dependencies have been added to the ERL_LIBS
%%% Environment Variable
-record(data, {version
, erl_libs
, root
, name
, registry_snapshot}).
-define(LOCAL_HEX_REGISTRY, "registry.ets").
main(Args) ->
{ok, RequiredData} = gather_required_data_from_the_environment(Args),
ok = bootstrap_libs(RequiredData).
%% @doc
%% This takes an app name in the standard OTP <name>-<version> format
%% and returns just the app name. Why? because rebar is doesn't
%% respect OTP conventions in some cases.
-spec fixup_app_name(file:name()) -> string().
fixup_app_name(Path) ->
BaseName = filename:basename(Path),
case string:tokens(BaseName, "-") of
[Name, _Version] -> Name;
Name -> Name
end.
-spec gather_required_data_from_the_environment([string()]) -> {ok, #data{}}.
gather_required_data_from_the_environment(_) ->
{ok, #data{ version = guard_env("version")
, erl_libs = os:getenv("ERL_LIBS", [])
, root = code:root_dir()
, name = guard_env("name")
, registry_snapshot = guard_env("HEX_REGISTRY_SNAPSHOT")}}.
-spec guard_env(string()) -> string().
guard_env(Name) ->
case os:getenv(Name) of
false ->
stderr("Expected Environment variable ~s! Are you sure you are "
"running in a Nix environment? Either a nix-build, "
"nix-shell, etc?~n", [Name]),
erlang:halt(1);
Variable ->
Variable
end.
-spec bootstrap_libs(#data{}) -> ok.
bootstrap_libs(#data{erl_libs = ErlLibs}) ->
io:format("Bootstrapping dependent libraries~n"),
Target = "_build/prod/lib/",
Paths = string:tokens(ErlLibs, ":"),
CopiableFiles =
lists:foldl(fun(Path, Acc) ->
gather_directory_contents(Path) ++ Acc
end, [], Paths),
lists:foreach(fun (Path) ->
ok = link_app(Path, Target)
end, CopiableFiles).
-spec gather_directory_contents(string()) -> [{string(), string()}].
gather_directory_contents(Path) ->
{ok, Names} = file:list_dir(Path),
lists:map(fun(AppName) ->
{filename:join(Path, AppName), fixup_app_name(AppName)}
end, Names).
%% @doc
%% Makes a symlink from the directory pointed at by Path to a
%% directory of the same name in Target. So if we had a Path of
%% {`foo/bar/baz/bash`, `baz`} and a Target of `faz/foo/foos`, the symlink
%% would be `faz/foo/foos/baz`.
-spec link_app({string(), string()}, string()) -> ok.
link_app({Path, TargetFile}, TargetDir) ->
Target = filename:join(TargetDir, TargetFile),
ok = make_symlink(Path, Target).
-spec make_symlink(string(), string()) -> ok.
make_symlink(Path, TargetFile) ->
file:delete(TargetFile),
ok = filelib:ensure_dir(TargetFile),
io:format("Making symlink from ~s to ~s~n", [Path, TargetFile]),
ok = file:make_symlink(Path, TargetFile).
%% @doc
%% Write the result of the format string out to stderr.
-spec stderr(string(), [term()]) -> ok.
stderr(FormatStr, Args) ->
io:put_chars(standard_error, io_lib:format(FormatStr, Args)).

View file

@ -0,0 +1,34 @@
{stdenv, fetchFromGitHub, buildRebar3 }:
let
shell = drv: stdenv.mkDerivation {
name = "interactive-shell-${drv.name}";
buildInputs = [ drv ];
};
pkg = self: buildRebar3 rec {
name = "pgsql";
version = "25+beta.2";
src = fetchFromGitHub {
owner = "semiocast";
repo = "pgsql";
rev = "14f632bc89e464d82ce3ef12a67ed8c2adb5b60c";
sha256 = "17dcahiwlw61zhy8aq9rn46lwb35fb9q3372s4wmz01czm8c348w";
};
dontStrip = true;
meta = {
description = "Erlang PostgreSQL Driver";
license = stdenv.lib.licenses.mit;
homepage = "https://github.com/semiocast/pgsql";
maintainers = with stdenv.lib.maintainers; [ ericbmerritt ];
};
passthru = {
env = shell self;
};
};
in stdenv.lib.fix pkg

View file

@ -42,7 +42,7 @@ let
virtualenvVersion = "1.11.6";
virtualenv = fetchurl {
url = "https://pypi.python.org/packages/source/v/virtualenv/virtualenv-${virtualenvVersion}.tar.gz";
url = "mirror://pypi/v/virtualenv/virtualenv-${virtualenvVersion}.tar.gz";
sha256 = "1xq4prmg25n9cz5zcvbqx68lmc3kl39by582vd8pzs9f3qalqyiy";
};
in

View file

@ -1,26 +0,0 @@
source $stdenv/setup
mkdir -p $out
cabextract $src
mkdir tmp
cd tmp
cabextract ../vcsetup1.cab
rm ../vc* # reduce temporary disk usage a bit
while read target; do
read source
echo "$source -> $target"
mkdir -p $out/$(dirname $target)
cp -p "$source" $out/"$target"
done < $filemap
# Make DLLs and executables executable.
find $out \( -iname "*.dll" -o -iname "*.exe" -o -iname "*.config" \) -print0 | xargs -0 chmod +x
cat > $out/setup <<EOF
export PATH="$out/VC/bin:$out/Common7/IDE:\$PATH"
export LIB="$(cygpath -w -p "$out/VC/lib")"
export INCLUDE="$(cygpath -w -p "$out/VC/include")"
EOF

View file

@ -1,27 +0,0 @@
{stdenv, fetchurl, cabextract}:
assert stdenv.system == "i686-cygwin";
stdenv.mkDerivation {
# Derived from Visual C++ 2005 (= VC 8), followed by cl.exe's
# internal version number.
name = "visual-c++-8-14.00.50727.42";
builder = ./builder.sh;
src = fetchurl {
url = http://download.microsoft.com/download/0/5/A/05AA45B9-A4BE-4872-8D57-733DF5297284/Ixpvc.exe;
md5 = "5b3b07cb048798822582a752f586bab9";
};
# The `filemap' maps the pretty much useless paths in the CAB file
# to their intended destinations in the file system, as determined
# from a normal Visual C++ Express installation.
#
# Recipe for reproducing:
# $ find -type f /path/to/unpacked-cab -print0 | xargs -0 md5sum > m1
# $ find -type f /path/to/visual-c++ -print0 | xargs -0 md5sum > m2
# $ nixpkgs/maintainers/scripts/map-files.pl m1 m2 > filemap
filemap = ./filemap;
buildInputs = [cabextract];
}

View file

@ -1,622 +0,0 @@
./Common7/IDE/msobj80.dll
./FL_msobj71_dll_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/mspdb80.dll
./FL_mspdb71_dll_2_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/mspdbcore.dll
./FL_mspdbcore_dll_92167_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/mspdbsrv.exe
./FL_mspdbsrv_exe_92168_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PEVerify.exe
./FL_PEVerify_exe_142183_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PEVerify.exe.config
./FL_PEVerify_exe_config_142184________.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PublicAssemblies/CppCodeProvider.dll
./FL_CppCodeProvider_dll_72654_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PublicAssemblies/Microsoft.VisualC.VSCodeProvider.dll
./FL_Microsoft_VisualC_VSCodeProvider_dll_72653_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PublicAssemblies/Microsoft.VisualStudio.VCCodeModel.dll
./Microsoft_VisualStudio_VCCodeModel_dll_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PublicAssemblies/Microsoft.VisualStudio.VCCodeModel.xml
./FL_Microsoft_VisualStudio_VCCodeModel_xml_141601_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PublicAssemblies/Microsoft.VisualStudio.VCProject.dll
./Microsoft_VisualStudio_VCProject_dll_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PublicAssemblies/Microsoft.VisualStudio.VCProject.xml
./FL_Microsoft_VisualStudio_VCProject_xml_141602_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PublicAssemblies/Microsoft.VisualStudio.VCProjectEngine.dll
./FL_Microsoft_VisualStudio_VCProjectEngine__72652_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/IDE/PublicAssemblies/Microsoft.VisualStudio.VCProjectEngine.xml
./FL_Microsoft_VisualStudio_VCProjectEngine__141603_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/Tools/errlook.exe
./FL_errlook_exe_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/Tools/errlook.hlp
./FL_errlook_hlp_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/Tools/makehm.exe
./FL_makehm_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./Common7/Tools/vcvars.txt
./FL_vcvars32_bat_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/AxImp.exe
./FL_AxImp_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/gacutil.exe
./FL_gacutil_exe_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/gacutil.exe.config
./FL_PEVerify_exe_config_142184________.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/lc.exe
./FL_lc_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/PEVerify.exe
./FL_PEVerify_exe_142183_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/PEVerify.exe.config
./FL_PEVerify_exe_config_142184________.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/ResGen.exe
./FL_ResGen_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/sgen.exe
./FL_sgen_exe_94980_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/signtool.exe
./FL_signtool_exe_102951_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/sn.exe
./FL_sn_exe_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/TlbExp.exe
./FL_TlbExp_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/TlbImp.exe
./TlbImp_exe_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/TlbRef.dll
./FL_TlbRef_dll_91955_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/wsdl.exe
./FL_wsdl_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/wsdl.exe.config
./FL_PEVerify_exe_config_142184________.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Bin/xsd.exe
./FL_xsd_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./SDK/v2.0/Lib/mscoree.lib
./mscoree_lib_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/1033/atlprovui.dll
./FL_atlprovui_dll_122786_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/1033/bscmakeui.dll
./FL_bscmakeui_dll_103043_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/1033/clui.dll
./FL_clui_dll_95594_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/1033/cvtresui.dll
./FL_cvtresui_dll_103020_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/1033/linkui.dll
./FL_linkui_dll_102968_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/1033/nmakeui.dll
./FL_nmakeui_dll_103025_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/atlprov.dll
./FL_atlprov_dll_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/bscmake.exe
./FL_bscmake_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/c1.dll
./FL_c1_dll_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/c1xx.dll
./FL_c1xx_dll_67102_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/c2.dll
./FL_c2_dll_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/cl.exe
./FL_cl_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/cl.exe.config
./FL_xdcmake_exe_config_76491_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/cvtres.exe
./cvtres_exe_4_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/dumpbin.exe
./FL_dumpbin_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/editbin.exe
./FL_editbin_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/lib.exe
./FL_lib_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/link.exe
./FL_link_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/link.exe.config
./FL_xdcmake_exe_config_76491_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/nmake.exe
./FL_nmake_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/rc.exe
./rc_exe_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/rcdll.dll
./FL_rcdll_dll_66416_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/undname.exe
./FL_undname_exe_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/VCExpCmdPromptShortcut.txt
./FL_blank_txt_120872________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/vcvars32.bat
./vcvars32_bat_1________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/xdcmake.exe
./FL_xdcmake_exe_76490_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/bin/xdcmake.exe.config
./FL_xdcmake_exe_config_76491_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/delayhlp.cpp
./FL_delayhlp_cpp________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/intrin.h
./FL_intrin_h_106236_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/memory.h
./FL_memory_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/time.h
./FL_time_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/algorithm
./FL_algrithm________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/assert.h
./FL_assert_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/bitset
./FL_bitset________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cassert
./FL_cassert________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cctype
./FL_cctype________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cerrno
./FL_cerrno________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cfloat
./FL_cfloat________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/ciso646
./FL_ciso646________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/climits
./FL_climits________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/clocale
./FL_clocale________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cmath
./FL_cmath________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/CodeAnalysis/sourceannotations.h
./FL_sourceannotations_h_126529________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/comdef.h
./FL_comdef_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/comdefsp.h
./FL_comdefsp_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/comip.h
./FL_comip_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/complex
./FL_complex________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/comutil.h
./FL_comutil_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/conio.h
./FL_conio_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/crtassem.h
./FL_crtassem_h_115581_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/crtdbg.h
./FL_crtdbg_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/crtdefs.h
./FL_crtdefs_h_92449_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/crtwrn.h
./FL_crtwrn_h_110314_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/csetjmp
./FL_csetjmp________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/csignal
./FL_csignal________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cstdarg
./FL_cstdarg________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cstddef
./FL_cstddef________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cstdio
./FL_cstdio________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cstdlib
./FL_cstdlib________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cstring
./FL_cstring________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/ctime
./FL_ctime________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/ctype.h
./FL_ctype_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cwchar
./FL_cwchar________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/cwctype
./FL_cwctype________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/dbgautoattach.h
./dbgautoattach_h_2________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/minmax.h
./FL_minmax_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/mm3dnow.h
./FL_mm3dnow_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/mmintrin.h
./FL_mmintrin_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/all.h
./FL_all_h_120615________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/appdomain.h
./FL_appdomain_h_120616________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/auto_gcroot.h
./FL_auto_gcroot_h_120617________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/auto_handle.h
./FL_auto_handle_h_120618________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/com/ptr.h
./FL_ptr_h_120621________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/event.h
./FL_event_h_122275________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/gcroot.h
./FL_gcroot_h_134688________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/lock.h
./FL_lock_h_120619________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/msclr/safebool.h
./FL_safebool_h_120620________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/new
./FL_new________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/new.h
./FL_new_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/numeric
./FL_numeric________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/ostream
./FL_ostream________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/penwin.h
./FL_penwin_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/process.h
./FL_process_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/queue
./FL_queue________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/rtcapi.h
./rtcapi_h_1________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sal.h
./FL_sal_h_122276_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/search.h
./FL_search_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/set
./FL_set________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/setjmp.h
./FL_setjmp_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/setjmpex.h
./FL_setjmpex_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/share.h
./FL_share_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/signal.h
./FL_signal_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sstream
./FL_sstream________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/stack
./FL_stack________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/stdarg.h
./FL_stdarg_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/stddef.h
./FL_stddef_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/stdexcept
./FL_stdxcept________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/stdexcpt.h
./FL_stdexcpt_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/stdio.h
./FL_stdio_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/stdlib.h
./FL_stdlib_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/streambuf
./FL_streambf________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/string
./FL_string________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/string.h
./FL_string_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/strstream
./FL_strstrem________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/swprintf.inl
./FL_swprintf_inl_114606_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/locking.h
./locking_h_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/stat.h
./stat_h_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/stat.inl
./FL_stat_inl_73772_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/timeb.h
./timeb_h_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/timeb.inl
./FL_timeb_inl_73773_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/types.h
./types_h_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/utime.h
./utime_h_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/utime.inl
./FL_utime_inl_73774_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/sys/wstat.inl
./FL_wstat_inl_73775_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/tchar.h
./FL_tchar_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/delayimp.h
./FL_delayimp_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/deque
./FL_deque________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/direct.h
./FL_direct_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/dos.h
./FL_dos_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/dvec.h
./FL_dvec_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/eh.h
./FL_eh_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/emmintrin.h
./FL_emmintrin_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/errno.h
./FL_errno_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/exception
./FL_xception________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/excpt.h
./FL_excpt_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/fcntl.h
./FL_fcntl_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/float.h
./FL_float_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/fpieee.h
./FL_fpieee_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/fstream
./FL_fstream________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/functional
./FL_fctional________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/fvec.h
./FL_fvec_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/gcroot.h
./FL_gcroot_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/hash_map
./FL_hash_map________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/hash_set
./FL_hash_set________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/time.inl
./FL_time_inl_73769_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/typeinfo
./FL_typeinfo________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/typeinfo.h
./FL_typeinfo_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/use_ansi.h
./FL_use_ansi_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/utility
./FL_utility________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/vadefs.h
./FL_vadefs_h_76352_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/valarray
./FL_valarray________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/varargs.h
./FL_varargs_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/vcclr.h
./FL_vcclr_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/vector
./FL_vector________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/wchar.h
./FL_wchar_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/wctype.h
./FL_wctype_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/wtime.inl
./FL_wtime_inl_73771_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xcomplex
./FL_xcomplex________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xdebug
./FL_xdebug________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xhash
./FL_xhash________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xiosbase
./FL_xiosbase________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xlocale
./FL_xlocale________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xlocinfo
./FL_xlocinfo________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xlocinfo.h
./FL_xlocinfo_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xlocmes
./FL_xlocmes________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xlocmon
./FL_xlocmon________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xlocnum
./FL_xlocnum________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xloctime
./FL_xloctime________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xmath.h
./FL_xmath_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xmemory
./FL_xmemory________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xmmintrin.h
./FL_xmmintrin_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xstddef
./FL_xstddef________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xstring
./FL_xstring________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xtree
./FL_xtree________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/xutility
./FL_xutility________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/ymath.h
./FL_ymath_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/yvals.h
./FL_yvals_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/_vcclrit.h
./FL__vcclrit_h_103662_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/invkprxy.h
./FL_invkprxy_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/io.h
./FL_io_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/iomanip
./FL_iomanip________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/ios
./FL_ios________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/iosfwd
./FL_iosfwd________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/iostream
./FL_iostream________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/iso646.h
./FL_iso646_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/istream
./FL_istream________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/iterator
./FL_iterator________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/ivec.h
./FL_ivec_h________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/limits
./FL_limits________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/limits.h
./FL_limits_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/list
./FL_list________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/listing.inc
./listing_inc_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/locale
./FL_locale________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/locale.h
./FL_locale_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/malloc.h
./FL_malloc_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/map
./FL_map________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/math.h
./FL_math_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/mbctype.h
./FL_mbctype_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/mbstring.h
./FL_mbstring_h_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/include/memory
./FL_memory________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/msvcprtd.lib
./FL_msvcprtd_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/binmode.obj
./FL_binmode_obj_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/chkstk.obj
./chkstk_obj_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/commode.obj
./FL_commode_obj_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/comsupp.lib
./FL_comsupp_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/comsuppd.lib
./comsuppd_lib_1_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/comsuppw.lib
./FL_comsuppw_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/comsuppwd.lib
./FL_comsuppwd_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/delayimp.lib
./FL_delayimp_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/fp10.obj
./FL_fp10_obj_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/invalidcontinue.obj
./FL_invalidcontinue_obj_117316_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/kernel32.lib
./FL_kernel32_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libcmt.lib
./FL_libcmt_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libcmt.pdb
./FL_libcmt_pdb_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libcmtd.lib
./FL_libcmtd_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libcmtd.pdb
./FL_libcmtd_pdb_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libcpmt.lib
./FL_libcpmt_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libcpmt.pdb
./FL_libcpmt_pdb_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libcpmtd.lib
./FL_libcpmtd_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libcpmtd.pdb
./FL_libcpmtd_pdb_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/libsmanifest.res
./FL_libsmanifest_res_111130________.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/loosefpmath.obj
./FL_loosefpmath_obj_106228_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/msvcmrt.lib
./FL_msvcmrt_lib_92271_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/msvcmrtd.lib
./FL_msvcmrtd_lib_92272_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/msvcprt.lib
./FL_msvcprt_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/msvcrt.lib
./FL_msvcrt_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/msvcrtd.lib
./FL_msvcrtd_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/msvcurt.lib
./FL_msvcurt_lib_102954_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/msvcurtd.lib
./FL_msvcurtd_lib_102955_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/newmode.obj
./FL_newmode_obj_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/noarg.obj
./FL_noarg_obj_126544_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/nochkclr.obj
./FL_nochkclr_obj_110315_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/noenv.obj
./FL_noenv_obj_126545_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/nothrownew.obj
./FL_nothrownew_obj_97867_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/oldnames.lib
./FL_oldnames_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/opends60.lib
./FL_opends60_lib_127616_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pbinmode.obj
./FL_pbinmode_obj_125244_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pcommode.obj
./FL_pcommode_obj_125245_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pinvalidcontinue.obj
./FL_pinvalidcontinue_obj_125246_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pnewmode.obj
./FL_pnewmode_obj_125247_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pnoarg.obj
./FL_pnoarg_obj_125248_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pnoenv.obj
./FL_pnoenv_obj_125249_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pnothrownew.obj
./FL_pnothrownew_obj_125250_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/psetargv.obj
./FL_psetargv_obj_125251_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pthreadlocale.obj
./FL_pthreadlocale_obj_125252_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/ptrustm.lib
./FL_ptrustm_lib_136980_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/ptrustmd.lib
./FL_ptrustmd_lib_136981_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/ptrustu.lib
./FL_ptrustu_lib_136982_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/ptrustud.lib
./FL_ptrustud_lib_136983_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/pwsetargv.obj
./FL_pwsetargv_obj_125253_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/RunTmChk.lib
./FL_RunTmChk_lib_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/setargv.obj
./FL_setargv_obj_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/smalheap.obj
./FL_smalheap_obj_126541_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/threadlocale.obj
./FL_threadlocale_obj_126542_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/lib/wsetargv.obj
./FL_wsetargv_obj_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/vcpackages/1033/vcbuildui.dll
./FL_vcbuildui_dll_113019_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/vcpackages/1033/VCProjectUI.dll
./FL_prjbldui_dll_ENU_X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/vcpackages/vcbuild.exe
./FL_vsbuild_exe_75031_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/vcpackages/VCProjectEngine.dll.config
./FL_VCProjectEngine_dll_config_93244_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/vcpackages/VCProjectEngine.Dll.Express.Config
./FL_VCProjectEngine_Dll_Express_Config_109708_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/ATLDynamic.vsprops
./FL_ATLDynamic_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/ATLNoCRT.vsprops
./FL_ATLNoCRT_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/ATLStatic.vsprops
./FL_ATLStatic_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/ATLWithCRT.vsprops
./FL_ATLWithCRT_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/BuildBsc.vsprops
./FL_BuildBsc_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/CoreWin.vsprops
./FL_CoreWin_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/corewin_express.vsprops
./FL_corewin_express_vsprops_104010_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/ManagedExtensions.vsprops
./FL_ManagedExtensions_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/ManagedExtensionsOldSyntax.vsprops
./FL_ManagedExtensionsOldSyntax_vsprops_103909_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/ManagedExtensionsPure.vsprops
./FL_ManagedExtensionsPure_vsprops_103907_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/ManagedExtensionsSafe.vsprops
./FL_ManagedExtensionsSafe_vsprops_103908_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/MfcDynamic.vsprops
./FL_MfcDynamic_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/MfcStatic.vsprops
./FL_MfcStatic_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/MultiByteCharSupport.vsprops
./FL_MultiByteCharSupport_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/pgoinstrument.vsprops
./FL_pgoinstrument_vsprops_92166_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/pgooptimize.vsprops
./FL_pgooptimize_vsprops_92165_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/pgoupdate.vsprops
./FL_pgoupdate_vsprops_92935_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/StaticAnalysis.vsprops
./FL_StaticAnalysis_vsprops_122128_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/UnicodeSupport.vsprops
./FL_UnicodeSupport_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/UpgradeFromVC60.vsprops
./FL_UpgradeFromVC60_vsprops_123105_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/UpgradeFromVC70.vsprops
./FL_UpgradeFromVC70_vsprops_123106_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/UpgradeFromVC71.vsprops
./FL_UpgradeFromVC71_vsprops_123107_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/VCMergeModules.xml
./FL_VCMergeModules_xml_120801_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/WholeProgOptimize.vsprops
./FL_WholeProgOptimize_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/VCProjectDefaults/WinDLL.vsprops
./FL_WinDLL_vcstyle_____X86.3643236F_FC70_11D3_A536_0090278A1BB8
./VC/vcvarsall.bat
./FL_vcvarsall_bat_103803________.3643236F_FC70_11D3_A536_0090278A1BB8

View file

@ -1,6 +0,0 @@
source $stdenv/setup
source $visualcpp/setup
source $windowssdk/setup
mkdir -p $out/bin
cl "$(cygpath -w $src)" /Fe"$(cygpath -w $out/bin/hello.exe)" user32.lib

View file

@ -1,10 +0,0 @@
{stdenv, fetchurl, visualcpp, windowssdk}:
assert stdenv.system == "i686-cygwin";
stdenv.mkDerivation {
name = "win32-hello";
builder = ./builder.sh;
src = ./hello.c;
inherit visualcpp windowssdk;
}

View file

@ -1,7 +0,0 @@
#include <windows.h>
int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInstance, LPSTR lpCmdLine,
int nCmdShow)
{
MessageBox(NULL, "Hello World!", "Nix", MB_OK);
return 0;
}

View file

@ -1,14 +0,0 @@
{ stdenv, pkgs }: #? import <nixpkgs> {} }:
let
self = rec {
hex = import ./hex-packages.nix { stdenv = stdenv; callPackage = self.callPackage; };
callPackage = pkgs.lib.callPackageWith (pkgs // self // hex);
buildRebar3 = callPackage ./build-rebar3.nix {};
buildHex = callPackage ./build-hex.nix {};
## Non hex packages
webdriver = callPackage ./webdriver {};
};
in self // self.hex

File diff suppressed because it is too large Load diff

View file

@ -1,4 +1,5 @@
{ stdenv, fetchurl, erlang, rebar, makeWrapper, coreutils, curl, bash }:
{ stdenv, fetchurl, erlang, rebar, makeWrapper, coreutils, curl, bash,
debugInfo ? false }:
stdenv.mkDerivation rec {
name = "elixir-${version}";
@ -16,6 +17,12 @@ stdenv.mkDerivation rec {
LANG = "en_US.UTF-8";
LC_TYPE = "en_US.UTF-8";
setupHook = ./setup-hook.sh;
buildFlags = if debugInfo
then "ERL_COMPILER_OPTIONS=debug_info"
else "";
preBuild = ''
# The build process uses ./rebar. Link it to the nixpkgs rebar
rm -v rebar

View file

@ -0,0 +1,5 @@
addErlLibPath() {
addToSearchPath ERL_LIBS $1/lib/elixir/lib
}
envHooks+=(addErlLibPath)

View file

@ -3,10 +3,10 @@
stdenv.mkDerivation rec {
name = "bobcat-${version}";
version = "4.01.04";
version = "4.02.00";
src = fetchFromGitHub {
sha256 = "1qnyssvjvwc7ann5rw8spcfrfkxyh1lv3k12bq19d8db67znk4ms";
sha256 = "1hl5b2g4cmxcafkcpr4vs0c705cy254g0h410zi5wxnygjam8adn";
rev = version;
repo = "bobcat";
owner = "fbb-git";

View file

@ -3,20 +3,20 @@
stdenv.mkDerivation rec {
name = "catch-${version}";
version = "1.2.1";
version = "1.5.0";
src = fetchFromGitHub {
owner = "philsquared";
repo = "Catch";
rev = "v" + version;
sha256 = "0rz2nmvvh66x6w2nb7l08vc5x9aqg1qfz2qfiykaz1ybc19fwck2";
sha256 = "1ag8siafg7fmb50qdqznryrg3lvv56f09nvqwqqn2rlk83zjnaw0";
};
buildInputs = [ cmake ];
dontUseCmakeConfigure = true;
buildPhase = ''
cmake -Hprojects/CMake -BBuild -DCMAKE_BUILD_TYPE=Release
cmake -Hprojects/CMake -BBuild -DCMAKE_BUILD_TYPE=Release -DUSE_CPP11=ON
cd Build
make
cd ..

View file

@ -1,11 +1,11 @@
{ stdenv, fetchurl, makeWrapper }:
stdenv.mkDerivation rec {
name = "libeatmydata-82";
name = "libeatmydata-105";
src = fetchurl {
url = "http://www.flamingspork.com/projects/libeatmydata/${name}.tar.gz";
sha256 = "0aavq71bf0yxdgyf8gvyzq086shszzwpbsz5rqkjg4cz0rc5yrqb";
sha256 = "1pd8sc73cgc41ldsvq6g8ics1m5k8gdcb91as9yg8z5jnrld1lmx";
};
buildInputs = [ makeWrapper ];

View file

@ -1,4 +1,5 @@
{ stdenv, fetchurl }:
stdenv.mkDerivation rec {
name = "tsocks-${version}";
version = "1.8beta5";
@ -16,11 +17,19 @@ stdenv.mkDerivation rec {
export configureFlags="$configureFlags --libdir=$out/lib"
'';
preBuild = ''
# We don't need the saveme binary, it is in fact never stored and we're
# never injecting stuff into ld.so.preload anyway
sed -i \
-e "s,TARGETS=\(.*\)..SAVE.\(.*\),TARGETS=\1\2," \
-e "/SAVE/d" Makefile
'';
meta = with stdenv.lib; {
description = "Transparent SOCKS v4 proxying library";
homepage = http://tsocks.sourceforge.net/;
license = stdenv.lib.licenses.gpl2;
maintainers = with maintainers; [ edwtjo phreedom ];
platforms = platforms.linux;
platforms = platforms.unix;
};
}
}

View file

@ -1,35 +0,0 @@
source $stdenv/setup
mkdir -p $out
n=1
for p in $srcs; do
ln -s $p PSDK-FULL.$n.cab
n=$((n + 1))
done
mkdir tmp
cd tmp
cabextract ../PSDK-FULL.1.cab
mkdir tmp
cd tmp
for i in ../Setup/*.cab; do
cabextract $i
done
while read target; do
read source
echo "$source -> $target"
mkdir -p "$out/$(dirname "$target")"
cp "$source" "$out/$target"
done < $filemap
# Make DLLs and executables executable.
find $out \( -iname "*.dll" -o -iname "*.exe" -o -iname "*.config" \) -print0 | xargs -0 chmod +x
cat > $out/setup <<EOF
export PATH="$out/bin:\$PATH"
export LIB="$(cygpath -w -p "$out/lib");\$LIB"
export INCLUDE="$(cygpath -w -p "$out/include");\$INCLUDE"
EOF

View file

@ -1,92 +0,0 @@
{stdenv, fetchurl, cabextract}:
#assert stdenv.system == "i686-cygwin";
stdenv.mkDerivation {
# Windows Server 2003 R2 Platform SDK - March 2006 Edition.
name = "windows-sdk-2003-r2";
builder = ./builder.sh;
srcs = [
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.1.cab;
md5 = "9b07b16ff1ae4982a5d4bfbe550d383e";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.2.cab;
md5 = "b8ace0bdda22b267d88149ac3d49f889";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.3.cab;
md5 = "b7a0109df5a28a5489e84df7d7a61668";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.4.cab;
md5 = "f3aded09c1ea845785247c45574f27fd";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.5.cab;
md5 = "978b7124550895358196e3f7de303cf5";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.6.cab;
md5 = "cf390a0479860e1e74f8e8fcddaf307f";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.7.cab;
md5 = "c9d1c8790fc5becaff4619d778d192a9";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.8.cab;
md5 = "d94d61c444ba73702c54d93084b756e1";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.9.cab;
md5 = "1990b7598960d503b9cd9aa9b7eb9174";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.10.cab;
md5 = "6437fd9dc2c65017c7bb4e759b13f678";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.11.cab;
md5 = "98f46cb52a01fae4e56e62f5bfef0fde";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.12.cab;
md5 = "b5f21fde5965b0f1079fd9c9a3434da6";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.13.cab;
md5 = "708574a95c51307e40e6da48e909f288";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.14.cab;
md5 = "19e90769d3500f6448e5ce2e1290fdd5";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.15.cab;
md5 = "0ccb3484253b3578e60ff1abb89f2f68";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.16.cab;
md5 = "e94106bb4e217b3c86c529afbb8489eb";
})
(fetchurl {
url = http://download.microsoft.com/download/1/e/a/1ea37493-825f-464e-a874-403c75facd5b/PSDK-FULL.17.cab;
md5 = "87eaa56fbd625ec696f16dbf136a3904";
})
];
# The `filemap' maps the pretty much useless paths in the CAB file
# to their intended destinations in the file system, as determined
# from a normal SDK installation.
#
# Recipe for reproducing:
# $ find -type f /path/to/unpacked-cabs -print0 | xargs -0 md5sum > m1
# $ find -type f /path/to/visual-c++ -print0 | xargs -0 md5sum > m2
# $ nixpkgs/maintainers/scripts/map-files.pl m1 m2 > filemap
filemap = ./filemap;
buildInputs = [cabextract];
}

File diff suppressed because it is too large Load diff

View file

@ -4,7 +4,7 @@ buildPythonPackage {
name = "zc.buildout-nix-2.5.0";
src = fetchurl {
url = "https://pypi.python.org/packages/source/z/zc.buildout/zc.buildout-2.5.0.tar.gz";
url = "mirror://pypi/z/zc.buildout/zc.buildout-2.5.0.tar.gz";
sha256 = "721bd2231a9f01f2d5c14f3adccb3385f85b093ee05b18d15d0ff2b9f1f1bd02";
};

View file

@ -16,7 +16,7 @@ buildPythonPackage rec {
version = "2.5.0";
src = fetchurl {
url = "https://pypi.python.org/packages/source/h/h5py/${name}.tar.gz";
url = "mirror://pypi/h/h5py/${name}.tar.gz";
sha256 = "9833df8a679e108b561670b245bcf9f3a827b10ccb3a5fa1341523852cfac2f6";
};

View file

@ -15,7 +15,7 @@ buildPythonPackage rec {
version = "1.5.1";
src = fetchurl {
url = "https://pypi.python.org/packages/source/m/matplotlib/${name}.tar.gz";
url = "mirror://pypi/m/matplotlib/${name}.tar.gz";
sha256 = "3ab8d968eac602145642d0db63dd8d67c85e9a5444ce0e2ecb2a8fedc7224d40";
};

View file

@ -5,7 +5,7 @@ buildPythonPackage rec {
namePrefix = "";
src = fetchurl {
url = "http://pypi.python.org/packages/source/p/pycrypto/${name}.tar.gz";
url = "mirror://pypi/p/pycrypto/${name}.tar.gz";
sha256 = "0g0ayql5b9mkjam8hym6zyg6bv77lbh66rv1fyvgqb17kfc1xkpj";
};

View file

@ -7,7 +7,7 @@ stdenv.mkDerivation rec {
version = "19.4"; # 18.4 and up breaks python34Packages.characteristic and many others
src = fetchurl {
url = "https://pypi.python.org/packages/source/s/setuptools/${shortName}.tar.gz";
url = "mirror://pypi/s/setuptools/${shortName}.tar.gz";
sha256 = "214bf29933f47cf25e6faa569f710731728a07a19cae91ea64f826051f68a8cf";
};

View file

@ -6,7 +6,7 @@ buildPythonPackage rec {
name = "tables-${version}";
src = fetchurl {
url = "https://pypi.python.org/packages/source/t/tables/${name}.tar.gz";
url = "mirror://pypi/t/tables/${name}.tar.gz";
sha256 = "3564b351a71ec1737b503b001eb7ceae1f65d5d6e3ffe1ea75aafba10f37fa84";
};

View file

@ -7,7 +7,7 @@ buildPythonApplication rec {
version = "0.4.3";
src = fetchurl {
url = "https://pypi.python.org/packages/source/y/yolk/yolk-${version}.tar.gz";
url = "mirror://pypi/y/yolk/yolk-${version}.tar.gz";
sha256 = "1f6xwx210jnl5nq0m3agh2p1cxmaizawaf3fwq43q4yw050fn1qw";
};

View file

@ -5,7 +5,7 @@ buildPythonApplication (rec {
namePrefix = "";
src = fetchurl {
url = "https://pypi.python.org/packages/source/b/buildbot-slave/${name}.tar.gz";
url = "mirror://pypi/b/buildbot-slave/${name}.tar.gz";
sha256 = "09pncw44c7vqrl7zyn1nvfismiqi9s51axk9cqxn9gq7jhj38mpg";
};

View file

@ -13,7 +13,7 @@ buildPythonApplication (rec {
namePrefix = "";
src = fetchurl {
url = "https://pypi.python.org/packages/source/b/buildbot/${name}.tar.gz";
url = "mirror://pypi/b/buildbot/${name}.tar.gz";
sha256 = "1mn4h04sp6smr3ahqfflys15cpn13q9mfkapcs2jc4ppvxv6kdn6";
};

View file

@ -1,73 +1,62 @@
{ stdenv, writeText, callPackage, fetchurl,
fetchHex, erlang, hermeticRebar3 ? true, rebar3-nix-bootstrap, tree, fetchFromGitHub }:
fetchHex, erlang, hermeticRebar3 ? true,
tree, fetchFromGitHub, hexRegistrySnapshot }:
let
version = "3.0.0-beta.4";
registrySnapshot = callPackage ./registrySnapshot.nix { };
version = "3.1.0";
bootstrapper = ./rebar3-nix-bootstrap;
# TODO: all these below probably should go into nixpkgs.erlangModules.sources.*
# {erlware_commons, "0.16.0"},
erlware_commons = fetchHex {
pkg = "erlware_commons";
version = "0.16.0";
sha256 = "0kh24d0001390wfx28d0xa874vrsfvjgj41g315vg4hac632krxx";
version = "0.19.0";
sha256 = "1gfsy9bbhjb94c5ghff2niamn93x2x08lnklh6pp7sfr5i0gkgsv";
};
# {ssl_verify_hostname, "1.0.5"},
ssl_verify_hostname = fetchHex {
pkg = "ssl_verify_hostname";
version = "1.0.5";
sha256 = "1gzavzqzljywx4l59gvhkjbr1dip4kxzjjz1s4wsn42f2kk13jzj";
};
# {certifi, "0.1.1"},
certifi = fetchHex {
pkg = "certifi";
version = "0.1.1";
sha256 = "0afylwqg74gprbg116asz0my2nipmki0512c8mdiq6xdiyjdvlg6";
version = "0.4.0";
sha256 = "04bnvsbssdcf6b9h9bfglflds7j0gx6q5igl1xxhx6fnwaz37hhw";
};
# {providers, "1.5.0"},
providers = fetchHex {
pkg = "providers";
version = "1.5.0";
sha256 = "1hc8sp2l1mmx9dfpmh1f8j9hayfg7541rmx05wb9cmvxvih7zyvf";
version = "1.6.0";
sha256 = "0byfa1h57n46jilz4q132j0vk3iqc0v1vip89li38gb1k997cs0g";
};
# {getopt, "0.8.2"},
getopt = fetchHex {
pkg = "getopt";
version = "0.8.2";
sha256 = "1xw30h59zbw957cyjd8n50hf9y09jnv9dyry6x3avfwzcyrnsvkk";
};
# {bbmustache, "1.0.4"},
bbmustache = fetchHex {
pkg = "bbmustache";
version = "1.0.4";
sha256 = "04lvwm7f78x8bys0js33higswjkyimbygp4n72cxz1kfnryx9c03";
};
# {relx, "3.8.0"},
relx = fetchHex {
pkg = "relx";
version = "3.8.0";
sha256 = "0y89iirjz3kc1rzkdvc6p3ssmwcm2hqgkklhgm4pkbc14fcz57hq";
version = "3.17.0";
sha256 = "1xjybi93m8gj9f9z3lkc7xbg3k5cw56yl78rcz5qfirr0223sby2";
};
# {cf, "0.2.1"},
cf = fetchHex {
pkg = "cf";
version = "0.2.1";
sha256 = "19d0yvg8wwa57cqhn3vqfvw978nafw8j2rvb92s3ryidxjkrmvms";
};
# {cth_readable, "1.1.0"},
cth_readable = fetchHex {
pkg = "cth_readable";
version = "1.0.1";
sha256 = "1cnc4fbypckqllfi5h73rdb24dz576k3177gzvp1kbymwkp1xcz1";
version = "1.2.2";
sha256 = "0kb9v4998liwyidpjkhcg1nin6djjzxcx6b313pbjicbp4r58n3p";
};
# {eunit_formatters, "0.2.0"}
eunit_formatters = fetchHex {
pkg = "eunit_formatters";
version = "0.2.0";
sha256 = "03kiszlbgzscfd2ns7na6bzbfzmcqdb5cx3p6qy3657jk2fai332";
version = "0.3.1";
sha256 = "0cg9dasv60v09q3q4wja76pld0546mhmlpb0khagyylv890hg934";
};
# {eunit_formatters, "0.2.0"}
rebar3_hex = fetchHex {
pkg = "rebar3_hex";
version = "1.12.0";
@ -81,19 +70,21 @@ stdenv.mkDerivation {
src = fetchurl {
url = "https://github.com/rebar/rebar3/archive/${version}.tar.gz";
sha256 = "0px66scjdia9aaa5z36qzxb848r56m0k98g0bxw065a2narsh4xy";
sha256 = "0r4wpnpi81ha4iirv9hcif3vrgc82qd51kah7rnhvpym55wcy9ml";
};
inherit bootstrapper;
patches = if hermeticRebar3 == true
then [ ./hermetic-bootstrap.patch ./hermetic-rebar3.patch ]
else [];
buildInputs = [ erlang tree ];
propagatedBuildInputs = [ registrySnapshot rebar3-nix-bootstrap ];
propagatedBuildInputs = [ hexRegistrySnapshot ];
postPatch = ''
echo postPatch
rebar3-nix-bootstrap registry-only
${erlang}/bin/escript ${bootstrapper} registry-only
echo "$ERL_LIBS"
mkdir -p _build/default/lib/
mkdir -p _build/default/plugins

View file

@ -1,39 +1,61 @@
diff --git a/bootstrap b/bootstrap
index 25bd658..b2a986b 100755
index 35759b0..939c838 100755
--- a/bootstrap
+++ b/bootstrap
@@ -8,9 +8,6 @@ main(_Args) ->
@@ -7,9 +7,11 @@ main(_) ->
application:start(asn1),
application:start(public_key),
application:start(ssl),
- inets:start(),
- inets:start(httpc, [{profile, rebar}]),
- set_httpc_options(),
+ %% Removed for hermeticity on Nix
+ %%
+ %% inets:start(),
+ %% inets:start(httpc, [{profile, rebar}]),
+ %% set_httpc_options(),
%% Fetch and build deps required to build rebar3
BaseDeps = [{providers, []}
@@ -33,7 +30,6 @@ main(_Args) ->
setup_env(),
os:putenv("REBAR_PROFILE", "bootstrap"),
- rebar3:run(["update"]),
{ok, State} = rebar3:run(["compile"]),
reset_env(),
os:putenv("REBAR_PROFILE", ""),
@@ -71,33 +67,7 @@ fetch_and_compile({Name, ErlFirstFiles}, Deps) ->
@@ -74,12 +76,12 @@ default_registry_file() ->
filename:join([CacheDir, "hex", "default", "registry"]).
fetch_and_compile({Name, ErlFirstFiles}, Deps) ->
- case lists:keyfind(Name, 1, Deps) of
- {Name, Vsn} ->
- ok = fetch({pkg, atom_to_binary(Name, utf8), list_to_binary(Vsn)}, Name);
- {Name, _, Source} ->
- ok = fetch(Source, Name)
- end,
+ %% case lists:keyfind(Name, 1, Deps) of
+ %% {Name, Vsn} ->
+ %% ok = fetch({pkg, atom_to_binary(Name, utf8), list_to_binary(Vsn)}, Name);
+ %% {Name, _, Source} ->
+ %% ok = fetch(Source, Name)
+ %% end,
%% Hack: erlware_commons depends on a .script file to check if it is being built with
%% rebar2 or rebar3. But since rebar3 isn't built yet it can't get the vsn with get_key.
@@ -88,63 +90,63 @@ fetch_and_compile({Name, ErlFirstFiles}, Deps) ->
compile(Name, ErlFirstFiles).
fetch({pkg, Name, Vsn}, App) ->
-fetch({pkg, Name, Vsn}, App) ->
- Dir = filename:join([filename:absname("_build/default/lib/"), App]),
- CDN = "https://s3.amazonaws.com/s3.hex.pm/tarballs",
- Package = binary_to_list(<<Name/binary, "-", Vsn/binary, ".tar">>),
- Url = string:join([CDN, Package], "/"),
- case request(Url) of
- {ok, Binary} ->
- {ok, Contents} = extract(Binary),
- ok = erl_tar:extract({binary, Contents}, [{cwd, Dir}, compressed]);
- _ ->
- io:format("Error: Unable to fetch package ~p ~p~n", [Name, Vsn])
- case filelib:is_dir(Dir) of
- false ->
- CDN = "https://s3.amazonaws.com/s3.hex.pm/tarballs",
- Package = binary_to_list(<<Name/binary, "-", Vsn/binary, ".tar">>),
- Url = string:join([CDN, Package], "/"),
- case request(Url) of
- {ok, Binary} ->
- {ok, Contents} = extract(Binary),
- ok = erl_tar:extract({binary, Contents}, [{cwd, Dir}, compressed]);
- _ ->
- io:format("Error: Unable to fetch package ~p ~p~n", [Name, Vsn])
- end;
- true ->
- io:format("Dependency ~s already exists~n", [Name])
- end.
-
-extract(Binary) ->
@ -51,14 +73,17 @@ index 25bd658..b2a986b 100755
- Error ->
- Error
- end.
+ ok.
get_rebar_config() ->
{ok, [[Home]]} = init:get_argument(home),
@@ -109,20 +79,6 @@ get_rebar_config() ->
[]
end.
-
-get_rebar_config() ->
- {ok, [[Home]]} = init:get_argument(home),
- ConfDir = filename:join(Home, ".config/rebar3"),
- case file:consult(filename:join(ConfDir, "rebar.config")) of
- {ok, Config} ->
- Config;
- _ ->
- []
- end.
-
-get_http_vars(Scheme) ->
- proplists:get_value(Scheme, get_rebar_config(), []).
-
@ -72,7 +97,63 @@ index 25bd658..b2a986b 100755
-set_httpc_options(Scheme, Proxy) ->
- {ok, {_, _, Host, Port, _, _}} = http_uri:parse(Proxy),
- httpc:set_options([{Scheme, {{Host, Port}, []}}], rebar).
-
+%% fetch({pkg, Name, Vsn}, App) ->
+%% Dir = filename:join([filename:absname("_build/default/lib/"), App]),
+%% case filelib:is_dir(Dir) of
+%% false ->
+%% CDN = "https://s3.amazonaws.com/s3.hex.pm/tarballs",
+%% Package = binary_to_list(<<Name/binary, "-", Vsn/binary, ".tar">>),
+%% Url = string:join([CDN, Package], "/"),
+%% case request(Url) of
+%% {ok, Binary} ->
+%% {ok, Contents} = extract(Binary),
+%% ok = erl_tar:extract({binary, Contents}, [{cwd, Dir}, compressed]);
+%% _ ->
+%% io:format("Error: Unable to fetch package ~p ~p~n", [Name, Vsn])
+%% end;
+%% true ->
+%% io:format("Dependency ~s already exists~n", [Name])
+%% end.
+
+%% extract(Binary) ->
+%% {ok, Files} = erl_tar:extract({binary, Binary}, [memory]),
+%% {"contents.tar.gz", Contents} = lists:keyfind("contents.tar.gz", 1, Files),
+%% {ok, Contents}.
+
+%% request(Url) ->
+%% case httpc:request(get, {Url, []},
+%% [{relaxed, true}],
+%% [{body_format, binary}],
+%% rebar) of
+%% {ok, {{_Version, 200, _Reason}, _Headers, Body}} ->
+%% {ok, Body};
+%% Error ->
+%% Error
+%% end.
+
+%% get_rebar_config() ->
+%% {ok, [[Home]]} = init:get_argument(home),
+%% ConfDir = filename:join(Home, ".config/rebar3"),
+%% case file:consult(filename:join(ConfDir, "rebar.config")) of
+%% {ok, Config} ->
+%% Config;
+%% _ ->
+%% []
+%% end.
+
+%% get_http_vars(Scheme) ->
+%% proplists:get_value(Scheme, get_rebar_config(), []).
+
+%% set_httpc_options() ->
+%% set_httpc_options(https_proxy, get_http_vars(https_proxy)),
+%% set_httpc_options(proxy, get_http_vars(http_proxy)).
+
+%% set_httpc_options(_, []) ->
+%% ok;
+
+%% set_httpc_options(Scheme, Proxy) ->
+%% {ok, {_, _, Host, Port, _, _}} = http_uri:parse(Proxy),
+%% httpc:set_options([{Scheme, {{Host, Port}, []}}], rebar).
compile(App, FirstFiles) ->
Dir = filename:join(filename:absname("_build/default/lib/"), App),
filelib:ensure_dir(filename:join([Dir, "ebin", "dummy.beam"])),

View file

@ -1,8 +1,8 @@
diff --git a/src/rebar3.erl b/src/rebar3.erl
index 2b73844..af1d871 100644
diff a/src/rebar3.erl b/src/rebar3.erl
index c1a1ae4..1bf1ea0 100644
--- a/src/rebar3.erl
+++ b/src/rebar3.erl
@@ -282,9 +282,11 @@ start_and_load_apps(Caller) ->
@@ -294,9 +294,11 @@ start_and_load_apps(Caller) ->
ensure_running(crypto, Caller),
ensure_running(asn1, Caller),
ensure_running(public_key, Caller),
@ -10,21 +10,14 @@ index 2b73844..af1d871 100644
- inets:start(),
- inets:start(httpc, [{profile, rebar}]).
+ ensure_running(ssl, Caller).
+%% Removed due to the hermicity requirements of Nix
+%% Removed due to the hermicity requirements of Nix
+%%
+%% inets:start(),
+%% inets:start(httpc, [{profile, rebar}]).
ensure_running(App, Caller) ->
case application:start(App) of
@@ -339,4 +341,4 @@ safe_define_test_macro(Opts) ->
test_defined([{d, 'TEST'}|_]) -> true;
test_defined([{d, 'TEST', true}|_]) -> true;
test_defined([_|Rest]) -> test_defined(Rest);
-test_defined([]) -> false.
\ No newline at end of file
+test_defined([]) -> false.
diff --git a/src/rebar_hermicity.erl b/src/rebar_hermicity.erl
diff a/src/rebar_hermicity.erl b/src/rebar_hermicity.erl
new file mode 100644
index 0000000..d814e2a
--- /dev/null
@ -72,37 +65,29 @@ index 0000000..d814e2a
+ "are as follows:", []),
+ ?ERROR("Requesnt: ~p ~s", [Method, Url]),
+ erlang:halt(1).
diff --git a/src/rebar_pkg_resource.erl b/src/rebar_pkg_resource.erl
index 4f55ad1..f76fd5d 100644
diff a/src/rebar_pkg_resource.erl b/src/rebar_pkg_resource.erl
index ec7e09d..03be343 100644
--- a/src/rebar_pkg_resource.erl
+++ b/src/rebar_pkg_resource.erl
@@ -100,10 +100,10 @@ make_vsn(_) ->
@@ -104,7 +104,7 @@ make_vsn(_) ->
{error, "Replacing version of type pkg not supported."}.
request(Url, ETag) ->
- case httpc:request(get, {Url, [{"if-none-match", ETag} || ETag =/= false]},
- [{ssl, ssl_opts(Url)}, {relaxed, true}],
- [{body_format, binary}],
- rebar) of
+ case rebar_hermicity:request(get, {Url, [{"if-none-match", ETag} || ETag =/= false]},
+ [{ssl, ssl_opts(Url)}, {relaxed, true}],
+ [{body_format, binary}],
+ rebar) of
{ok, {{_Version, 200, _Reason}, Headers, Body}} ->
?DEBUG("Successfully downloaded ~s", [Url]),
{"etag", ETag1} = lists:keyfind("etag", 1, Headers),
diff --git a/src/rebar_prv_update.erl b/src/rebar_prv_update.erl
index 6637ebe..d82c1d8 100644
- case httpc:request(get, {Url, [{"if-none-match", ETag} || ETag =/= false]++[{"User-Agent", rebar_utils:user_agent()}]},
+ case rebar_hermicity:request(get, {Url, [{"if-none-match", ETag} || ETag =/= false]++[{"User-Agent", rebar_utils:user_agent()}]},
[{ssl, ssl_opts(Url)}, {relaxed, true}],
[{body_format, binary}],
rebar) of
diff a/src/rebar_prv_update.erl b/src/rebar_prv_update.erl
index 5e1e253..ea25b9e 100644
--- a/src/rebar_prv_update.erl
+++ b/src/rebar_prv_update.erl
@@ -44,8 +44,8 @@ do(State) ->
TmpFile = filename:join(TmpDir, "packages.gz"),
Url = rebar_state:get(State, rebar_packages_cdn, ?DEFAULT_HEX_REGISTRY),
- case httpc:request(get, {Url, []},
- [], [{stream, TmpFile}, {sync, true}],
+ case rebar_hermicity:request(get, {Url, []},
+ [], [{stream, TmpFile}, {sync, true}],
rebar) of
{ok, saved_to_file} ->
{ok, Data} = file:read_file(TmpFile),
@@ -52,7 +52,7 @@ do(State) ->
case rebar_utils:url_append_path(CDN, ?REMOTE_REGISTRY_FILE) of
{ok, Url} ->
?DEBUG("Fetching registry from ~p", [Url]),
- case httpc:request(get, {Url, [{"User-Agent", rebar_utils:user_agent()}]},
+ case rebar_hermicity:request(get, {Url, [{"User-Agent", rebar_utils:user_agent()}]},
[], [{stream, TmpFile}, {sync, true}],
rebar) of
{ok, saved_to_file} ->

View file

@ -0,0 +1,255 @@
#!/usr/bin/env escript
%% -*- erlang-indent-level: 4;indent-tabs-mode: nil -*-
%%! -smp enable
%%% ---------------------------------------------------------------------------
%%% @doc
%%% The purpose of this command is to prepare a rebar3 project so that
%%% rebar3 understands that the dependencies are all already
%%% installed. If you want a hygienic build on nix then you must run
%%% this command before running rebar3. I suggest that you add a
%%% `Makefile` to your project and have the bootstrap command be a
%%% dependency of the build commands. See the nix documentation for
%%% more information.
%%%
%%% This command designed to have as few dependencies as possible so
%%% that it can be a dependency of root level packages like rebar3. To
%%% that end it does many things in a fairly simplistic way. That is
%%% by design.
%%%
%%% ### Assumptions
%%%
%%% This command makes the following assumptions:
%%%
%%% * It is run in a nix-shell or nix-build environment
%%% * that all dependencies have been added to the ERL_LIBS
%%% Environment Variable
-record(data, {version
, registry_only = false
, compile_ports
, erl_libs
, plugins
, root
, name
, registry_snapshot}).
-define(HEX_REGISTRY_PATH, ".cache/rebar3/hex/default/registry").
main(Args) ->
{ok, ArgData} = parse_args(Args),
{ok, RequiredData} = gather_required_data_from_the_environment(ArgData),
do_the_bootstrap(RequiredData).
%% @doc There are two modes 'registery_only' where the register is
%% created from hex and everything else.
-spec do_the_bootstrap(#data{}) -> ok.
do_the_bootstrap(RequiredData = #data{registry_only = true}) ->
ok = bootstrap_registry(RequiredData);
do_the_bootstrap(RequiredData) ->
ok = bootstrap_registry(RequiredData),
ok = bootstrap_configs(RequiredData),
ok = bootstrap_plugins(RequiredData),
ok = bootstrap_libs(RequiredData).
%% @doc
%% Argument parsing is super simple only because we want to keep the
%% dependencies minimal. For now there can be two entries on the
%% command line, "registery-only"
-spec parse_args([string()]) -> #data{}.
parse_args(["registry-only"]) ->
{ok, #data{registry_only = true}};
parse_args([]) ->
{ok, #data{registry_only = false}};
parse_args(Args) ->
io:format("Unexpected command line arguments passed in: ~p~n", [Args]),
erlang:halt(120).
-spec bootstrap_configs(#data{}) -> ok.
bootstrap_configs(RequiredData)->
io:format("Boostrapping app and rebar configurations~n"),
ok = if_single_app_project_update_app_src_version(RequiredData),
ok = if_compile_ports_add_pc_plugin(RequiredData).
-spec bootstrap_plugins(#data{}) -> ok.
bootstrap_plugins(#data{plugins = Plugins}) ->
io:format("Bootstrapping rebar3 plugins~n"),
Target = "_build/default/plugins/",
Paths = string:tokens(Plugins, " "),
CopiableFiles =
lists:foldl(fun(Path, Acc) ->
gather_dependency(Path) ++ Acc
end, [], Paths),
lists:foreach(fun (Path) ->
ok = link_app(Path, Target)
end, CopiableFiles).
-spec bootstrap_libs(#data{}) -> ok.
bootstrap_libs(#data{erl_libs = ErlLibs}) ->
io:format("Bootstrapping dependent librariesXXXX~n"),
Target = "_build/default/lib/",
Paths = string:tokens(ErlLibs, ":"),
CopiableFiles =
lists:foldl(fun(Path, Acc) ->
gather_directory_contents(Path) ++ Acc
end, [], Paths),
lists:foreach(fun (Path) ->
ok = link_app(Path, Target)
end, CopiableFiles).
-spec gather_dependency(string()) -> [{string(), string()}].
gather_dependency(Path) ->
FullLibrary = filename:join(Path, "lib/erlang/lib/"),
case filelib:is_dir(FullLibrary) of
true ->
gather_directory_contents(FullLibrary);
false ->
[raw_hex(Path)]
end.
-spec raw_hex(string()) -> {string(), string()}.
raw_hex(Path) ->
[_, Name] = re:split(Path, "-hex-source-"),
{Path, erlang:binary_to_list(Name)}.
-spec gather_directory_contents(string()) -> [{string(), string()}].
gather_directory_contents(Path) ->
{ok, Names} = file:list_dir(Path),
lists:map(fun(AppName) ->
{filename:join(Path, AppName), fixup_app_name(AppName)}
end, Names).
%% @doc
%% Makes a symlink from the directory pointed at by Path to a
%% directory of the same name in Target. So if we had a Path of
%% {`foo/bar/baz/bash`, `baz`} and a Target of `faz/foo/foos`, the symlink
%% would be `faz/foo/foos/baz`.
-spec link_app({string(), string()}, string()) -> ok.
link_app({Path, TargetFile}, TargetDir) ->
Target = filename:join(TargetDir, TargetFile),
make_symlink(Path, Target).
-spec make_symlink(string(), string()) -> ok.
make_symlink(Path, TargetFile) ->
file:delete(TargetFile),
ok = filelib:ensure_dir(TargetFile),
io:format("Making symlink from ~s to ~s~n", [Path, TargetFile]),
ok = file:make_symlink(Path, TargetFile).
%% @doc
%% This takes an app name in the standard OTP <name>-<version> format
%% and returns just the app name. Why? because rebar is doesn't
%% respect OTP conventions in some cases.
-spec fixup_app_name(string()) -> string().
fixup_app_name(FileName) ->
case string:tokens(FileName, "-") of
[Name] -> Name;
[Name, _Version] -> Name
end.
-spec bootstrap_registry(#data{}) -> ok.
bootstrap_registry(#data{registry_snapshot = RegistrySnapshot}) ->
io:format("Bootstrapping Hex Registry for Rebar~n"),
make_sure_registry_snapshot_exists(RegistrySnapshot),
filelib:ensure_dir(?HEX_REGISTRY_PATH),
ok = case filelib:is_file(?HEX_REGISTRY_PATH) of
true ->
file:delete(?HEX_REGISTRY_PATH);
false ->
ok
end,
ok = file:make_symlink(RegistrySnapshot,
?HEX_REGISTRY_PATH).
-spec make_sure_registry_snapshot_exists(string()) -> ok.
make_sure_registry_snapshot_exists(RegistrySnapshot) ->
case filelib:is_file(RegistrySnapshot) of
true ->
ok;
false ->
stderr("Registry snapshot (~s) does not exist!", [RegistrySnapshot]),
erlang:halt(1)
end.
-spec gather_required_data_from_the_environment(#data{}) -> {ok, map()}.
gather_required_data_from_the_environment(ArgData) ->
{ok, ArgData#data{ version = guard_env("version")
, erl_libs = os:getenv("ERL_LIBS", [])
, plugins = os:getenv("buildPlugins", [])
, root = code:root_dir()
, name = guard_env("name")
, compile_ports = nix2bool(os:getenv("compilePorts", ""))
, registry_snapshot = guard_env("HEX_REGISTRY_SNAPSHOT")}}.
-spec nix2bool(any()) -> boolean().
nix2bool("1") ->
true;
nix2bool("") ->
false.
-spec guard_env(string()) -> string().
guard_env(Name) ->
case os:getenv(Name) of
false ->
stderr("Expected Environment variable ~s! Are you sure you are "
"running in a Nix environment? Either a nix-build, "
"nix-shell, etc?~n", [Name]),
erlang:halt(1);
Variable ->
Variable
end.
%% @doc
%% If the compile ports flag is set, rewrite the rebar config to
%% include the 'pc' plugin.
-spec if_compile_ports_add_pc_plugin(#data{}) -> ok.
if_compile_ports_add_pc_plugin(#data{compile_ports = true}) ->
ConfigTerms = add_pc_to_plugins(read_rebar_config()),
Text = lists:map(fun(Term) -> io_lib:format("~tp.~n", [Term]) end,
ConfigTerms),
file:write_file("rebar.config", Text);
if_compile_ports_add_pc_plugin(_) ->
ok.
-spec add_pc_to_plugins([term()]) -> [term()].
add_pc_to_plugins(Config) ->
PluginList = case lists:keysearch(plugins, 1, Config) of
{ok, {plugins, ExistingPluginList}} -> ExistingPluginList;
_ -> []
end,
lists:keystore(plugins, 1, Config, {plugins, [pc | PluginList]}).
-spec read_rebar_config() -> [term()].
read_rebar_config() ->
case file:consult("rebar.config") of
{ok, Terms} ->
Terms;
_ ->
stderr("Unable to read rebar config!", []),
erlang:halt(1)
end.
-spec if_single_app_project_update_app_src_version(#data{}) -> ok.
if_single_app_project_update_app_src_version(#data{name = Name,
version = Version}) ->
SrcFile = filename:join("src",
lists:concat([Name, ".app.src"])),
case filelib:is_file(SrcFile) of
true ->
update_app_src_with_version(SrcFile, Version);
false ->
ok
end.
-spec update_app_src_with_version(string(), string()) -> ok.
update_app_src_with_version(SrcFile, Version) ->
{ok, [{application, Name, Details}]} = file:consult(SrcFile),
NewDetails = lists:keyreplace(vsn, 1, Details, {vsn, Version}),
ok = file:write_file(SrcFile, io_lib:fwrite("~p.\n", [{application, Name, NewDetails}])).
%% @doc
%% Write the result of the format string out to stderr.
-spec stderr(string(), [term()]) -> ok.
stderr(FormatStr, Args) ->
io:put_chars(standard_error, io_lib:format(FormatStr, Args)).

View file

@ -5,7 +5,7 @@ pythonPackages.buildPythonApplication rec {
version = "2.3.2";
src = fetchurl {
url = "https://pypi.python.org/packages/source/d/devpi-client/devpi-client-${version}.tar.gz";
url = "mirror://pypi/d/devpi-client/devpi-client-${version}.tar.gz";
md5= "bfc8cd768f983fd0585c347bca00c8bb";
};

View file

@ -1,5 +1,5 @@
{stdenv, autoconf, which, writeText, makeWrapper, fetchFromGitHub, erlang,
erlangPackages, z3, python27 }:
beamPackages, z3, python27 }:
stdenv.mkDerivation rec {
name = "cuter";
@ -13,9 +13,9 @@ stdenv.mkDerivation rec {
};
setupHook = writeText "setupHook.sh" ''
addToSearchPath ERL_LIBS "$1/lib/erlang/lib/"
addToSearchPath ERL_LIBS "$1/lib/erlang/lib/"
'';
buildInputs = with erlangPackages; [ autoconf erlang z3 python27 makeWrapper which ];
buildInputs = with beamPackages; [ autoconf erlang z3 python27 makeWrapper which ];
buildFlags = "PWD=$(out)/lib/erlang/lib/cuter-${version} cuter_target";
configurePhase = ''

Some files were not shown because too many files have changed in this diff Show more