Compare commits

..

898 Commits

Author SHA1 Message Date
Georges Dubus
770822493e gusb: fixed build, updated to 0.2.4
(cherry picked from commit 0ca664e996)
2016-03-01 14:10:57 +01:00
Eelco Dolstra
c191689afb vim: Fix download location
http://hydra.nixos.org/build/32085889
2016-02-17 09:44:19 +01:00
Eelco Dolstra
8c1bb397c4 Use updated bootstrap binaries
Fixes #5335.

(cherry picked from commit a5aa8f3efa)
2016-02-16 22:28:31 +01:00
Shea Levy
c210b69584 CVE-2015-7547: Adapt patch for glibc 2.20 2016-02-16 11:35:22 -05:00
Nathan Zadoks
9ad4159eae glibc: fix cve-2015-7547.patch so it applies cleanly
(cherry picked from commit fc48bf5a2c)
2016-02-16 11:28:32 -05:00
Nathan Zadoks
5a9202823e glibc: patch CVE-2015-7547
The glibc DNS client side resolver is vulnerable to a stack-based buffer
overflow when the getaddrinfo() library function is used. Software using
this function may be exploited with attacker-controlled domain names,
attacker-controlled DNS servers, or through a man-in-the-middle attack.
https://googleonlinesecurity.blogspot.co.uk/2016/02/cve-2015-7547-glibc-getaddrinfo-stack.html

(cherry picked from commit b5aa8a4e64)
2016-02-16 10:25:43 -05:00
Robert Helgesson
9d6ba7d831 keepassx: 0.4.3 -> 0.4.4
Fixes CVE-2015-8359 and CVE-2015-8378. Also switch URL to new download
location.
2015-12-21 08:09:16 +01:00
Pascal Wittmann
f2bdf674b7 audiofile: fix CVE-2015-7747
closes #10678

(cherry picked from commit 6aea1c55c0669540cffd5472fdf7c4b607d4c324 by
falsifian)
2015-11-04 18:53:48 -08:00
aszlig
a85150b2fa python-hetzner: Update to bugfix version 0.7.4.
Fixes pinned CA root certificate and probing for system CA bundle.

Closes NixOS/nixops#354.

I'm using fetchFromGitHub now because it's use of fetchzip is more
stable for autogenerated tarballs from GitHub.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 1d1cf4845f)
2015-11-04 14:08:14 +01:00
Domen Kožar
aafebd27ea unzip: CVE-2015-7696, CVE-2015-7697
(cherry picked from commit aff3a23d67)
2015-11-01 20:12:46 -08:00
aszlig
a8faa9d01a thttpd: Fix SHA256 of the upstream tarball.
It's a bit unfortunate to see this, but while looking online to download
the old version of the file I found that MacPorts and FreeBSD had the
same issue:

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=199562

I've checked the diff as well and found no big functional changes,
except a function rename, copyright updates and changed syslog
priorities:

https://bz-attachments.freebsd.org/attachment.cgi?id=155775

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit f15420b0fe)
2015-10-21 17:17:49 +02:00
aszlig
166fdcec80 nixpart0: Don't search for libudev using SO major.
The SO major is going to change in the upcoming update of the Hetzner
rescue system, which will cause NixOps to break because it's statically
using the SO major 0 while the new rescue system will have the major
number 1.

I'm still keeping the udevSoMajor attribute to retain backwards-
compatibility with older NixOps versions.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 3bf3d19759)
2015-10-21 17:17:49 +02:00
RoboNickBot
885ca28fa9 texlive-moderntimeline: 0.8 (broken) -> 0.9
Close #9612, close #10235.

The v0.8 build was broken because the CTAN package updated to v0.9 and
CTAN doesn't keep old versions of packages.

Besides bumping the version, this commit changes the src url from the
unversioned CTAN link (which would break the derivation every time a new
version of the package released, as it did yesterday) to the versioned
Github release link.

(cherry picked from commit 126d8dba96)
2015-10-05 09:25:25 +02:00
Vincent Laporte
b373bf9c7d couchdb: fix build (fixes #10084)
(cherry picked from commit 4361a7a597)
2015-09-27 08:40:43 +02:00
Vladimír Čunát
41377038a7 vorbis-tools: security patches and fix meta
Patches: CVE-2014-9638, CVE-2014-9639, CVE-2015-6749, and some non-security.
Also drop glibc from buildInputs.

(cherry picked from commit 000a2108ba)
2015-09-25 11:52:32 +02:00
Lluís Batlle i Rossell
263c13481c Fix my-env so it includes gcc, as it used to do.
This is a reaction to 1014620bce, that
moved some paths from nix source to the builder.sh of stdenv.
2015-09-24 14:57:01 +02:00
Ricardo M. Correia
7e5c1e8395 flashplayer: 11.2.202.491 -> 11.2.202.508
(cherry picked from commit 4c8b2beb55)
2015-09-23 19:43:03 +02:00
Rob Vermaas
a968b70b71 Update libcloud to 0.18.0. Needed for newer nixops. 2015-09-17 19:31:56 +00:00
Pascal Wittmann
e3596798c5 Merge pull request #9868 from shen390s/working
add perl-Tk
2015-09-17 09:18:11 +02:00
Rongsong Shen
fbb8fa5e22 Tk: init at 804.033 2015-09-17 12:52:03 +08:00
Eelco Dolstra
42847f5d95 Fix broken use of <nixpkgs>
Nixpkgs should never use <nixpkgs>, because there is no guarantee that
<nixpkgs> refers to the same tree (e.g. when doing "nix-env -f . -qa").
2015-09-14 18:49:41 +02:00
Bjørn Forsman
0341382f15 meshlab: add missing patch (doh!)
Should have been included in af7d5f27d0 ("meshlab: 1.3.2 -> 1.3.3").

(cherry picked from commit c9c3a3cb72)
2015-08-27 11:19:29 +02:00
Bjørn Forsman
e9651c0769 meshlab: 1.3.2 -> 1.3.3
Remove patches that no longer apply (integrated upstream I guess), but
forward port the part that adds the missing "include <unistd.h>"[1].

Build and run tested.

[1]: http://sourceforge.net/p/meshlab/bugs/342/

(cherry picked from commit af7d5f27d0)
2015-08-27 11:19:12 +02:00
Bjørn Forsman
bb79e195c4 pcl: 1.6.0 -> 1.7.2 (unbreaks build)
New deps added: libXt (required), libpcap (optional).

Releases are now at github.

(cherry picked from commit ac8f2391f3)
2015-08-27 09:34:25 +02:00
Eelco Dolstra
4471b1eab2 nixUnstable: Update 2015-08-26 15:07:54 +02:00
Lluís Batlle i Rossell
d71e083563 mbsync: update to 1.2.0
it requires some config file updates. It requires SASL now, for some auth
methods like PLAIN on IMAP.
2015-08-25 15:35:53 +02:00
Lluís Batlle i Rossell
8f11a84c91 Make hydra build proxychains. 2015-08-25 14:21:56 +02:00
Eelco Dolstra
f2ec401001 Revert "Merge pull request #9428 from deepfire/maintain"
This reverts commit 090f523498. It
breaks evaluation: http://hydra.nixos.org/build/24984169
2015-08-25 11:14:29 +02:00
Vladimír Čunát
090f523498 Merge pull request #9428 from deepfire/maintain
maintain introduced packages
(cherry picked from commit ce6daa507a)
2015-08-24 22:59:19 +02:00
Anders Papitto
25317137a1 fix updmap invocation in texLive
Close #9430, fixes #9318.

(cherry picked from commit 6b892be9a8)
2015-08-24 22:48:00 +02:00
Eelco Dolstra
4e8d015878 Revert "openssh: Apply some Fedora security backports"
This reverts commit eace57c983. Oops.
2015-08-24 19:06:10 +02:00
Eelco Dolstra
eace57c983 openssh: Apply some Fedora security backports
(cherry picked from commit 2d4b6405b3)
2015-08-24 19:05:33 +02:00
Bob van der Linden
d02e9314a6 can-utils: updated homepage url (close #9425)
(cherry picked from commit 5cdf3d4f8e)
2015-08-24 18:56:32 +02:00
Eelco Dolstra
5e631b21d7 subversion: Update to 1.8.14
CVE-2015-3184, CVE-2015-3187.

(cherry picked from commit 24f1a7a5cb)
2015-08-24 12:53:01 +02:00
Vladimír Čunát
ad6e048b4f micropolis: fix patch hash, probably updated
Fixes #9414. Seems to run OK, as far as I can tell in a minute.

(cherry picked from commit d36e4f3063)
2015-08-24 08:25:09 +02:00
Thomas Tuegel
8faad6e163 Merge pull request #9373 from bendlas/dropbox-stable-revert
dropbox: 3.8.5 -> 3.6.9 [nixos-stable]
2015-08-20 16:13:50 -05:00
Herwig Hochleitner
190af0b5ce dropbox: 3.8.5 -> 3.6.9
dropbox as of 3.8.4 depends on qt 5.4, while nixos-14.12 is on qt 5.3
https://www.dropboxforum.com/hc/en-us/community/posts/204541685-Release-Candidate-3-8-4

This reverts commit f961f3d793.
fixes #9338
2015-08-20 20:27:15 +02:00
Eelco Dolstra
e6c54b5af2 Revert "cbc: Enable on Darwin"
This reverts commit 7d902b92b7. It
doesn't build on 14.12.
2015-08-19 13:10:44 +02:00
Eelco Dolstra
7d902b92b7 cbc: Enable on Darwin
(cherry picked from commit f423ba3863)
2015-08-19 11:56:52 +02:00
Eelco Dolstra
176139701c Add cbc, a mixed ILP solver
(cherry picked from commit 80c137c7a2)
2015-08-18 16:24:03 +02:00
William A. Kennington III
e809a2868f bundler-head: Correct hash
(cherry picked from commit 0f21f3e00b)
/cc #9005. The needed hash is different than on master,
perhaps due to fetchgit differences.
2015-08-17 11:34:58 +02:00
Bob van der Linden
eb325dd80b memtest86+: fixed reboot issues
(cherry picked from commit 3b40ec5012)
2015-08-14 14:48:54 +02:00
Rob Vermaas
57d290f34f Keep lib/strings.nix isStorePath compatible with nix 1.8. If builtin does not exist, fallback to hardcoded /nix/store. 2015-08-14 08:55:16 +00:00
Eelco Dolstra
d8f6a3a250 Revert "Add option system.stateVersion"
This reverts commit ab415725ed.
2015-08-13 16:28:44 +02:00
Eelco Dolstra
1c13abaeea Fix installer failure
http://hydra.nixos.org/build/24716029
2015-08-13 15:09:19 +02:00
Eelco Dolstra
43b640fa56 Fix Nix 1.7 compat 2015-08-13 14:56:37 +02:00
Eelco Dolstra
ab415725ed Add option system.stateVersion
This option requests compatibility with older NixOS releases with
respect to stateful data, in cases where new releases have defaults
that might be incompatible with system state of existing NixOS
deployments. For instance, if we change the default version of
PostgreSQL, existing deployments will break if the new version can't
read databases created by the old version.

So for example, setting

  system.stateVersion = "15.07";

requests that options like services.postgresql.package use defaults
corresponding to the 15.07 release branch. Note that
nixos-generate-config emits this option. (In the future, NixOps may
set system.stateVersion to the NixOS release in use when the machine
was created.)

See also #7939 for another motivating example.

(cherry picked from commit d166c854b6)
2015-08-13 11:58:39 +02:00
Eelco Dolstra
9a44fa3d5b Allow options with type "package" to be store paths
For example, this allows writing

  nix.package = /nix/store/786mlvhd17xvcp2r4jmmay6jj4wj6b7f-nix-1.10pre4206_896428c;

Also, document types.package in the manual.

(cherry picked from commit 214d4fb73c)

Conflicts:
	lib/strings.nix
2015-08-13 11:58:32 +02:00
Eelco Dolstra
f60e48ce81 Revert "blender: Update to 2.73"
This reverts commit 6dc172d9c7.
2015-08-12 13:32:53 +02:00
Eelco Dolstra
b5fc462b76 Revert "blender: fix build after update to 2.73"
This reverts commit 9e710a6cce.
2015-08-12 13:32:44 +02:00
Eelco Dolstra
b694058dd4 Revert "blender: Update to 2.73a"
This reverts commit 6ae70c86a1.
2015-08-12 13:32:39 +02:00
Eelco Dolstra
8c7931a363 Revert "Blender: enable blenderplayer"
This reverts commit 557ef9e1de.
2015-08-12 13:32:31 +02:00
Eelco Dolstra
3d60824a38 Revert "blender: Update to 2.74"
This reverts commit 1e3c112a23.
2015-08-12 13:32:25 +02:00
Eelco Dolstra
7a44642200 Revert "blender: Update to 2.75"
This reverts commit 709f95f8c5.
2015-08-12 13:32:18 +02:00
Eelco Dolstra
bb6327730c Revert "blender: Update to 2.75a"
This reverts commit 6375e18e31.
2015-08-12 13:32:16 +02:00
Eelco Dolstra
ae36c07210 Revert "openexr: 1.7.1 -> 2.2.0"
This reverts commit a0ca6f00b3.
2015-08-12 13:32:13 +02:00
Eelco Dolstra
525927c9fa Revert "ilmbase: Update to openexr version"
This reverts commit e5fd500733.
2015-08-12 13:32:09 +02:00
Eelco Dolstra
e9ca7bfa67 Revert "Making openimageio use parallel building."
This reverts commit ff31b14cc5.
2015-08-12 13:32:06 +02:00
Lluís Batlle i Rossell
ff31b14cc5 Making openimageio use parallel building. 2015-08-12 10:59:46 +02:00
William A. Kennington III
e5fd500733 ilmbase: Update to openexr version
(cherry picked from commit e9c1a56f97)
2015-08-12 10:59:46 +02:00
William A. Kennington III
a0ca6f00b3 openexr: 1.7.1 -> 2.2.0
(cherry picked from commit 51cc9612b7)
2015-08-12 10:59:46 +02:00
Eelco Dolstra
6375e18e31 blender: Update to 2.75a
(cherry picked from commit aca6eb1fdb)
2015-08-12 10:59:46 +02:00
Eelco Dolstra
709f95f8c5 blender: Update to 2.75
(cherry picked from commit 36779d90e2b7e93ec5387cc5b5d106a037eb3d11)
(cherry picked from commit f3e2b31297)
2015-08-12 10:59:45 +02:00
Eelco Dolstra
1e3c112a23 blender: Update to 2.74
(cherry picked from commit b8ccb390b3)
2015-08-12 10:59:45 +02:00
Cillian de Róiste
557ef9e1de Blender: enable blenderplayer
(cherry picked from commit 79f3689289)
2015-08-12 10:59:45 +02:00
Eelco Dolstra
6ae70c86a1 blender: Update to 2.73a
(cherry picked from commit 480602bea1)
2015-08-12 10:59:45 +02:00
Luca Bruno
9e710a6cce blender: fix build after update to 2.73
(cherry picked from commit 5f12045f34)
2015-08-12 10:59:45 +02:00
Eelco Dolstra
6dc172d9c7 blender: Update to 2.73
(cherry picked from commit b0321dadcb)
2015-08-12 10:59:45 +02:00
Eelco Dolstra
54ddd7a3b6 Revert "nixos/ISO profile: fix defaultLocales :-)"
This reverts commit e2ef5cc163. It broke
the installer tests:

http://hydra.nixos.org/build/24626135
2015-08-11 20:38:25 +02:00
Eelco Dolstra
f3ea802f85 php: Update to 5.4.44 2015-08-11 13:17:15 +02:00
William A. Kennington III
8da2cf4b11 kernel: 3.14.49 -> 3.14.50
(cherry picked from commit 52e55d85cb)

Conflicts:
	pkgs/os-specific/linux/kernel/linux-3.14.nix
	pkgs/os-specific/linux/kernel/patches.nix
2015-08-11 12:03:40 +02:00
Eelco Dolstra
56b84dc3c2 mysql: Update to 5.4.45
(cherry picked from commit a6f466065c)

Conflicts:
	pkgs/servers/sql/mysql/5.5.x.nix

http://hydra.nixos.org/build/24146564
2015-08-11 12:01:36 +02:00
Vladimír Čunát
e960991f51 lyx: maintenance update
(cherry picked from commit cf1b771b2e)
2015-08-10 15:59:56 +02:00
Rob Vermaas
55d9786289 Add initial Brightbox expression. 2015-08-08 19:49:38 +00:00
James Cook
892c4ffb8a firefox: 39.0 -> 39.0.3
(cherry picked from commit 9f79830345)
2015-08-07 11:27:28 +02:00
Vladimír Čunát
22e10f13e6 ikiwiki: maintenance update, and use a stable URL
CC maintainer @peti.

(cherry picked from commit f484050a81)
2015-08-06 17:52:56 +02:00
Vladimír Čunát
2efe8b6828 Revert "glibc-locales: check that all we build is supported"
This reverts commit 0ec3901383.

The checks work fine on master, but here they don't.
I don't see why and I'm not digging deeper. It might be
just some bad character in the checked file in this glibc version.

Now the locales for ISOs build again.
2015-08-06 13:14:40 +02:00
Vladimír Čunát
e2ef5cc163 nixos/ISO profile: fix defaultLocales :-)
https://github.com/NixOS/nixpkgs/commit/eb4a88d8fd2#commitcomment-12527102
(cherry picked from commit 7dc9450ed2)
2015-08-06 13:14:39 +02:00
Joachim Fasting
95ed62bd91 attic: 0.15 -> 0.16
(cherry picked from commit 0d6ef780c7)
2015-08-06 12:27:55 +02:00
Bjørn Forsman
e1407a3a1c attic: update source hash (unbreaks build)
Diff of old/new source trees:

  $ diff -uNr /nix/store/h600g290a0h8szjhdfvfn4x7janrhd8n-attic-0.15-src/ attic-0.15-today/
  diff -uNr /nix/store/h600g290a0h8szjhdfvfn4x7janrhd8n-attic-0.15-src/attic/_version.py attic-0.15-today/attic/_version.py
  --- /nix/store/h600g290a0h8szjhdfvfn4x7janrhd8n-attic-0.15-src/attic/_version.py	1970-01-01 01:00:01.000000000 +0100
  +++ attic-0.15-today/attic/_version.py	2015-04-15 21:49:03.000000000 +0200
  @@ -10,7 +10,7 @@
   # versioneer-0.7+ (https://github.com/warner/python-versioneer)

   # these strings will be replaced by git during git-archive
  -git_refnames = " (HEAD, tag: 0.15, master)"
  +git_refnames = " (tag: 0.15)"
   git_full = "e815d6da8e15be8ccd09b7a183bb22bad25cf3e6"

So it looks like dynamic git archives can still bite us. Hopefully this
can be fixed upstream (attic) in the future.
2015-08-06 12:25:00 +02:00
Arseniy Seroka
1e45c69d1c Merge pull request #9136 from bendlas/dropbox-stable-update
dropbox: 3.6.9 -> 3.8.5 [stable branch]
2015-08-06 03:08:12 +03:00
Herwig Hochleitner
f961f3d793 dropbox: 3.6.9 -> 3.8.5 2015-08-05 23:58:30 +02:00
Eelco Dolstra
09db60c5ef php: Update to 5.4.43 2015-08-04 17:49:05 +02:00
Eelco Dolstra
5cb71d3e11 subversion: Update to 1.8.13
(cherry picked from commit c98b8f4c11)
2015-08-04 17:48:45 +02:00
Rob Vermaas
8f493eb3ea Update awscli from 1.5.5 to 1.7.41 2015-08-04 14:16:56 +00:00
Eelco Dolstra
5bcff3d016 releaseTools.coverageAnalysis: Emit hydra-metrics
(cherry picked from commit 068f8abaa5)
2015-08-04 11:06:51 +02:00
Bjørn Forsman
ab550c85fe ntopng: update geoip hashes
These files are updated (in place) every month or so.
2015-08-03 13:00:48 +02:00
Bjørn Forsman
d65a8c81b5 ntopng: add extra download URL
It seems upstream have moved the ntopng-1.2.1.tgz into an "old/"
subdirectory.

(cherry picked from commit c2aadb38a7)
2015-08-03 12:45:02 +02:00
Robert Scott
f24eb7cb4f ghostscript: add patch fixing CVE-2015-3228 (from debian)
(cherry picked from commit 179cdbc62c)
2015-08-02 09:43:22 +02:00
Robert Scott
31a6c3c72b elfutils: upgrade to 0.163 due to security
... vaguely mentioned by upstream, see e.g. FEDORA-2015-11380.
Close #9084.

(cherry picked from commit aefc8b3ddf)
2015-08-02 09:37:58 +02:00
Vladimír Čunát
0ec3901383 glibc-locales: check that all we build is supported
Until now, if e.g. the user passed "en_US.UTF-8" instead of "en_US.UTF-8/UTF-8",
the locales would be generated without failing but wouldn't work well.
Now we guard against such mistakes. Real life examples:
https://github.com/fish-shell/fish-shell/issues/1927

(cherry picked from commit eb4a88d8fd)
2015-07-31 15:40:13 +02:00
aszlig
01cb65d269 chromium: Add another mirror for Chrome deb.
The only mirror left which still has the .deb for 44.0.2403.89 is
http://mirror.pcbeta.com/, but that one doesn't seem to be reachable
from certain contries.

And according to @CestDiego, it doesn't seem to be reachable from within
the US.

Closes #9021, thanks to @CestDiego for reporting.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Reported-by: Diego Berrocal <cestdiego@gmail.com>
Tested-by: Diego Berrocal <cestdiego@gmail.com>
(cherry picked from commit 8d34b4a46a)
2015-07-30 20:04:47 +02:00
Susan Potter
18bb8220cb jwhois: fix path to lynx in $lynx/etc/jwhois.conf
Close #8696.
Fixes issues found when jwhois attempts to launch terminal browser
(lynx) for HTTP whois queries, for example:

    $ whois blah.io
    [Querying http://www.io.io/cgi-bin/whois]
    [HTTP: Unable to run web browser: /usr/bin/lynx: No such file or directory]

Tested via:

    grep lynx \
      /nix/store/bymgmn2vvw1n7nbb1isy87xg94s8f2ml-jwhois-4.0/etc/jwhois.conf \
      | cut -f2 -d'"' \
      | xargs stat -t

(cherry picked from commit a9e2cf0af3)
2015-07-30 15:53:27 +02:00
Eelco Dolstra
602b80af82 nixUnstable: Update to 1.10pre4200_76cc8e9 2015-07-30 12:16:12 +02:00
Vladimír Čunát
87d170230c lsof: use a pair of URLs to work when upstream updates
Fixes #9043.

(cherry picked from commit af3261f7a2)
2015-07-29 17:48:09 +02:00
Spencer Janssen
be9732d2ed nvidia-x11: add a symlink for libGLESv2.so.2 (close #9024)
nvidia's EGL stack looks for libGLESv2.so.2 at runtime (confirmed by
watching strace), however builder.sh only provides a libGLESv2.so.1
symlink.

@vcunat ported to legacy_340; older ones don't produce GLES.

(cherry picked from commit ebe67d3c85)
2015-07-28 12:53:39 +02:00
James Cook
494a2b7d01 expat: patch for CVE-2015-1283 from Mozilla
(Cherry-picked from fba4a950685023bc792422665b2dbe9934ebc9c6.)
2015-07-27 22:40:49 -07:00
Robert Scott
221101a571 apache-httpd: update minor versions of both 2.2 and 2.4 for security-related fixes
(cherry picked from commit 1dca2fba7f)
2015-07-28 00:13:56 +02:00
Vladimír Čunát
e08192cd4a cups-filters: update, including security fixes
- NEWS claims to fix CVE-2015-{3258,3279}
- shell path is now directly configurable

(Cherry-picked from 9147dee57f, with slight adjustments.)
2015-07-21 21:09:49 +02:00
Thomas Tuegel
e21dff1c9c Merge pull request #8922 from bendlas/dropbox-stable-update
dropbox: 3.6.7 -> 3.6.9 [stable backport]
2015-07-21 09:45:12 -05:00
Robert Helgesson
bae15904ad vsftpd: fix CVE-2015-1419
Adds patch from Debian.

(cherry picked from commit 66bc50a968)
2015-07-21 16:36:42 +02:00
taku0
b7545835aa flashplayer: 11.2.202.481 -> 11.2.202.491
(cherry picked from commit 6e5308df3f)
2015-07-21 16:35:52 +02:00
Herwig Hochleitner
e71c0cce44 dropbox: 3.6.7 -> 3.6.9 2015-07-21 16:24:08 +02:00
Tobias Geerinckx-Rice
3b8e2f7e7a jmtpfs: fix changed sha256 hash
...by switching to fetchFromGitHub. Also clean up (some
dependencies are no longer needed).

(cherry picked from commit dda255f938)
2015-07-18 11:17:47 +02:00
Lluís Batlle i Rossell
55072502d2 Updating retroshare 0.6.0 from some svn to rc2 2015-07-18 00:15:44 +02:00
Lluís Batlle i Rossell
67317b47d5 updating the old tor to 0.2.6.10
I fix the build, which was not using compiler optimisations since 2013, commit
9a5ca5aced.

I add seccomp. I guess it is good to have.
2015-07-17 18:13:26 +02:00
Lluís Batlle i Rossell
db04589f48 Updating gtkwave 3.3.64 to 3.3.66
(cherry picked from commit a9c4f2db351d8e968cf29989f17c00169a5b4bbc)
2015-07-17 18:13:26 +02:00
Rob Vermaas
4c35598ad0 Make fetchBower a bit more like a normal mkDerivation, which is easier to test.
Also, in some cases, the result of fetchBower is different depending on the
value of $out. For now, it seems that it works best if using a local output
directory before copying to $out.
2015-07-16 14:42:44 +00:00
William A. Kennington III
a2b95b9059 Merge pull request #8842 from Beauhurst/djangoupdates-14.12
update django minor versions (including security fixes) - 14.12 backport
2015-07-15 17:42:22 -07:00
Robert Scott
6e59ff838d update django minor versions (including security fixes) 2015-07-15 15:21:19 +00:00
Eelco Dolstra
9172c7d530 Make OpenJDK release-critical
Currently there are no tests that depend on the JDK. Since we don't
want a release with a broken JDK, make it an explicit dependency of
the "tested" jobs.

(cherry picked from commit 4c0e44c34c)

Conflicts:
	nixos/release-small.nix
2015-07-14 16:07:02 +02:00
Vladimír Čunát
c2755c1d10 /etc/ssh/ssh_known_hosts: refactor and fix #5612
Generating the file was refactored to be completely in nix.
Functionally it should create the same content as before,
only adding the newlines.

CC recent updaters: @aszlig, @rickynils.

(cherry picked from commit 72d2d59cd4)
2015-07-13 16:13:11 +02:00
Eelco Dolstra
f398845d68 Add options nix.{trustedUsers,allowedUsers}
These are just trusted-users and allowed-users in nix.conf. It's
useful to have options for them so that different modules can specify
trusted/allowed users.

(cherry picked from commit 1f3f31b2a8)

Conflicts:
	nixos/modules/services/misc/nix-daemon.nix
2015-07-13 15:04:08 +02:00
Bjørn Forsman
35bfea0566 nixos/minidlna: rename minidlna -> minidlnad (unbreak service)
Upstream renamed their binary. This fix is needed since commit
27e0536fb4 ("Updating minidlna to 1.1.4 (2009→2014)").

On master branch there was a different commit (42a5ad5c5e) that
updated both minidlna package and the NixOS service at the same time, so
this commit is just for the release-14.12 branch.
2015-07-13 11:02:37 +02:00
Domen Kožar
89185887ff flashplayer: 11.2.202.468 -> 11.2.202.481
(cherry picked from commit 59cc99990e)
2015-07-12 13:11:19 +02:00
Karn Kallio
1b0caeaf1e openjdk : Patch to extend valid currency change dates to 20 years.
(cherry picked from commit 9b81769950)

Conflicts:
	pkgs/development/compilers/openjdk/default.nix
2015-07-10 11:28:28 +02:00
Eelco Dolstra
8615d193ba Revert "Ugly hack until we can update openjdk. Without this openjdk fails with:"
This reverts commit 3279579bc4.
2015-07-10 11:10:55 +02:00
Eelco Dolstra
a39ce56266 openssl: Update to 1.0.1p 2015-07-10 01:20:30 +02:00
Eelco Dolstra
5390f11ffa Revert "apache-httpd: Don't set default content encodings"
This reverts commit 6f88c6c210 since it
breaks existing installations, so it shouldn't be applied to the
stable branch.
2015-07-09 15:20:43 +02:00
Eelco Dolstra
ff7520eb34 linux: 3.14.46 -> 3.14.47
CVE-2014-7822

(cherry picked from commit 5c9f437d2f)

Conflicts:
	pkgs/os-specific/linux/kernel/linux-3.14.nix
	pkgs/os-specific/linux/kernel/patches.nix
2015-07-09 15:20:30 +02:00
Eelco Dolstra
6f88c6c210 apache-httpd: Don't set default content encodings
In general, you don't want a .tar.gz file to be served with
"Content-Encoding: x-gzip", because this causes browsers (like Chrome
or "curl --compressed") to decompress the file on the fly. So you end
up with a .tar rather than .tar.gz file, which is unexpected.

If people want such encodings, they should set them in their own NixOS
configuration.

(cherry picked from commit 9fa19cfcea)
2015-07-09 13:03:27 +00:00
aszlig
b3fcde49a8 python-hetzner: Update to bugfix version 0.7.3.
Fixes creating of admin accounts, which is used by NixOps to deploy new
servers. Props to @rbvermaa for reporting the issue and testing it with
NixOps.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 9b8f66180f)
2015-07-09 12:45:15 +02:00
Vladimír Čunát
d24705ebb2 symbola font: update to fix download (fixes #8717)
(cherry picked from commit bf86c228b9)
2015-07-09 12:30:20 +02:00
Michael Raskin
8e8b964fad Firefox: update 38.0.6 -> 39.0
(cherry picked from commit 62da31931c)
2015-07-07 14:26:26 +02:00
William A. Kennington III
6cae037316 firefox: 38.0.5 -> 38.0.6
(cherry picked from commit c5b17670e1)
2015-07-07 14:26:23 +02:00
William A. Kennington III
1b1244e2e7 nss: 3.19.1 -> 3.19.2
(cherry picked from commit f80dc98ca9)
2015-07-07 14:24:06 +02:00
Alexander Foremny
4397fc255f Update flashplayer-11
(cherry picked from commit ba7e7e1c9a)

Conflicts:
	pkgs/applications/networking/browsers/mozilla-plugins/flashplayer-11/default.nix
2015-07-06 12:51:16 +02:00
Lluís Batlle i Rossell
27e0536fb4 Updating minidlna to 1.1.4 (2009→2014) 2015-07-04 18:31:26 +02:00
Eelco Dolstra
a08167ca47 Revert "Adding internetarchive 0.8.3"
This reverts commit 3cf96ffa6b. It
breaks Nixpkgs evaluation due to the "bsd" attribute.
2015-07-02 08:36:49 +02:00
Eelco Dolstra
8a771535b2 Revert "Fix python-json-pointer meta."
This reverts commit f1f5441b50.
2015-07-02 08:36:37 +02:00
Lluís Batlle i Rossell
bdcb09bedb Updating syncthing to 0.11.11. 2015-07-01 15:10:40 +02:00
William A. Kennington III
00bcaf93b9 nbd: 3.8 -> 3.10 2015-07-01 15:10:26 +02:00
Sou Bunnbu
1cad147969 Merge pull request #8525 from phunehehe/yak
Yakuake: hardcode path to konsole
2015-06-29 22:53:54 +08:00
Kirill Elagin
ae9ff0e142 Yakuake: hardcode path to konsole 2015-06-27 18:51:03 +08:00
Lluís Batlle i Rossell
f1f5441b50 Fix python-json-pointer meta. 2015-06-25 15:43:08 +02:00
Lluís Batlle i Rossell
50afa41efb Updating podofo to 0.9.3.
(cherry picked from commit e7d10c4190)
2015-06-25 15:41:14 +02:00
Lluís Batlle i Rossell
3cf96ffa6b Adding internetarchive 0.8.3
I updated requests2 to a newer version, because of an important bug in uploads.
https://github.com/jjjake/internetarchive/issues/80

This is more or less equivalent to
master commit 66bd251a7c .
2015-06-25 12:11:40 +02:00
Rickard Nilsson
891701ed25 google-cloud-sdk: Update from 0.9.58 to 0.9.65
(cherry picked from commit af5472a739)
2015-06-23 11:24:52 +02:00
Stephen Weinberg
a8343207f7 Add the google-cloud-sdk package
(cherry picked from commit da2aef3685)
2015-06-23 11:24:44 +02:00
William A. Kennington III
2b834940c3 kernel: 3.14.43 -> 3.14.44
(cherry picked from commit 24042f3803)
2015-06-22 12:50:59 +02:00
Michael Raskin
7ce1e5ab74 Update PostgreSQL to latest point-releases
(cherry picked from commit 5d5bb71567)
2015-06-22 12:48:23 +02:00
Eelco Dolstra
076c0a2219 postgresql: Latest versions
(cherry picked from commit f08c8bc752)
2015-06-22 12:48:12 +02:00
Tobias Geerinckx-Rice
8e13f6ad04 eagle 6.5.0 -> 6.6.0
CC @bjornfor:

Version 6.5.0 has disappeared from Cadsoft's FTP site. This is the
closest version that's still available. Not extensively tested, but
works fine here.

Current version is 7.3.0. I leave that to someone more interested.

(cherry picked from commit 655cda730d)
2015-06-22 07:19:57 +02:00
Domen Kožar
48b41f0e95 update flash player 2015-06-21 09:22:39 +02:00
Thomas Tuegel
99783b8e8b Merge pull request #8409 from bendlas/update-dropbox-stable
dropbox: 3.4.6 -> 3.6.7 (stable backport)
2015-06-19 07:24:18 -05:00
Herwig Hochleitner
1366bcb61b dropbox: 3.4.6 -> 3.6.7 (stable backport) 2015-06-19 13:55:09 +02:00
Bjørn Forsman
6c3286c122 nixos: move environment.{variables => sessionVariables}.MODULE_DIR
This solves the problem that modprobe does not know about $MODULE_DIR
when run via sudo, and instead wrongly tries to read /lib/modules/:

  $ sudo strace -efile modprobe foo |& grep modules
  open("/lib/modules/3.14.37/modules.softdep", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
  open("/lib/modules/3.14.37/modules.dep.bin", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
  open("/lib/modules/3.14.37/modules.dep.bin", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
  open("/lib/modules/3.14.37/modules.alias.bin", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

Without this patch, one would have to use sudo -E (preserves environment
vars). But that option is reserved for sudo users with extra rights
(SETENV), so it's not a solution.

environment.sessionVariables are set by PAM, so they are included in the
environment used by sudo.

(cherry picked from commit 74d5adcb4d)
2015-06-17 21:05:28 +02:00
Shea Levy
51c11574fd Disable failing DBIxClass tests
Seems to be random

(cherry picked from commit 5273166f53)
2015-06-17 16:46:33 +02:00
Peter Simons
4fde9fdfca fetchgit: add 'deepClone' argument to disable shallow fetching
This patch resolves https://github.com/NixOS/nixpkgs/issues/6395. Deep
cloning is useful in combination with 'leaveDotGit' for builds that want
to run "git describe" to obtain a proper version string, etc., like the
'haskellngPackages.cabal2nix' package does.

(cherry picked from commit 5d02f0e854)

Conflicts:
	pkgs/build-support/fetchgit/default.nix
2015-06-17 09:36:38 +02:00
Vladimír Čunát
d954a695e7 libarchive: fix CVE-2015-1197 by upstream patch
Fixes #6799.

(cherry picked from commit f2c84ffeb2)
2015-06-16 18:35:26 +02:00
Vladimír Čunát
76a54e8458 libtasn1: pick updates from master, including security
Fixes #7333. Changelog indicates compatible ABI.
2015-06-16 17:58:36 +02:00
Casey Ransom
84ea837896 Allow custom tags to be set for datadog monitoring
(cherry picked from commit d3212beff9)
2015-06-16 08:30:44 +00:00
Vladimír Čunát
a1e250c248 imagemagick: remove mirrors that don't work
/cc #8302.

(cherry picked from commit 6c382151fb)
2015-06-15 11:30:59 +02:00
Bjørn Forsman
cfa1c0b80f gtkglextmm: unbreak build
* Add missing build inputs: pangox_compat, libXmu
* Add patch from debian to fix build with newer gtk

(cherry picked from commit 903183d9e4)

Conflicts (fetchurl -> fetchurlGnome):
	pkgs/desktops/gnome-2/platform/gtkglextmm/default.nix
2015-06-14 19:59:44 +02:00
Eelco Dolstra
d863066283 sqlite: Update to 3.8.10.2
(cherry picked from commit cb6daa036b)
2015-06-13 11:58:33 +02:00
Michael Raskin
07ff139232 Update SQLite
(cherry picked from commit 1a407e9311)
2015-06-13 11:58:33 +02:00
koral
adf70a3e29 sqlite: 3.8.8.3 -> 3.8.9
(cherry picked from commit 3fe9fae62c)
2015-06-13 11:58:33 +02:00
Nicolas Pouillard
0667cd2dca Update sqlite to 3.8.8.3
(cherry picked from commit eee31a2c97)

[Bjørn: add maintainer alias for Nicolas Pouillard from master branch,
to not break eval.]
2015-06-13 11:57:39 +02:00
Eelco Dolstra
04efac258b php: Update to 5.4.42
CVE-2015-3414, CVE-2015-3415, CVE-2015-3416
2015-06-12 15:28:51 +02:00
Eelco Dolstra
5c544486a1 Debian: Update to 8.1
(cherry picked from commit 69829dd4ff)
2015-06-12 11:25:25 +02:00
Vladimír Čunát
a5444111bc mesa: fix download - moved due to version being old 2015-06-11 21:56:14 +02:00
Arseniy Seroka
e738fb152e Merge pull request #8196 from taku0/flashplayer_2.2.202.460
flashplayer: Update from 11.2.202.457 -> 11.2.202.460
(cherry picked from commit 5395128a36)
2015-06-11 21:43:45 +02:00
Rickard Nilsson
961ee1bca6 scollector: Change type of collectors to allow proper merging
(cherry picked from commit 7a0ca52267)
2015-06-11 16:50:26 +02:00
Rickard Nilsson
89d691d819 jetty: Update from 9.2.5 to 9.2.11
(cherry picked from commit 8a7c23456d)
2015-06-11 13:34:06 +02:00
Domen Kožar
310427c49f Merge pull request #8218 from bjornfor/python-bump-stable
python: 2.7.9 -> 2.7.10
2015-06-11 10:24:06 +02:00
Domen Kožar
bc4f18506c greenlet: delete problematic test
(cherry picked from commit 3efefb5baa)
2015-06-08 10:55:34 +02:00
Domen Kožar
43439620e5 pythonPackages.greenlet: 0.4.5 -> 0.4.7
(cherry picked from commit 4c67102a59)

[Bjørn: this unbreaks gevent]
2015-06-08 10:55:17 +02:00
Domen Kožar
a0724b0644 python: 2.7.9 -> 2.7.10
(cherry picked from commit c918903381)
2015-06-08 10:47:10 +02:00
Lengyel Balázs
7b38ae2617 Updated apcupsd to version 3.14.13
(cherry picked from commit c3d9e90f0e)
2015-06-08 09:04:34 +02:00
Bjørn Forsman
fb4d491302 nixos/postfix: make symlink /var/mail -> /var/spool/mail
This solves the problem of e.g. mutt not finding mail unless the user
sets MAIL=/var/spool/mail/$USER.

The default MAIL variable seems come from bash. Reasons for adding
symlink instead of changing MAIL default in bash:

- No need to rebuild world
- FHS recommends /var/mail over /var/spool/mail anyway[1]. Better fix
  NixOS mail location than change MAIL in bash to something that doesn't
  work on non-NixOS (however unlikely that users run nixpkgs bash on a
  non-NixOS distro...).

[1] http://www.pathname.com/fhs/pub/fhs-2.3.html#VARMAILUSERMAILBOXFILES

(cherry picked from commit 12e84c6378)
2015-06-07 19:10:44 +02:00
Eelco Dolstra
c06f066f22 Remove installer.grub1 from the release-critical builds
It randomly crashes

  Kernel panic - not syncing: assertion "i && sym_get_cam_status(cp->cmd) == DID_SOFT_ERROR" failed: file "/tmp/nix-build-linux-3.14.43.drv-0/linux-3.14.43/drivers/scsi/sym53c8xx_2/sym_hipd.c", line 3399

Rumour has it this is fixed in newer versions of QEMU or the kernel,
so I'm only disabling it on the 14.12 branch.

http://hydra.nixos.org/build/22836392
2015-06-04 20:11:16 +02:00
William A. Kennington III
d3322c069b nss: 3.19 -> 3.19.1
(cherry picked from commit 5483697ab1)
2015-06-03 13:26:53 +02:00
Eelco Dolstra
e6d7f2aa49 firefox: Update to 38.0.5
(cherry picked from commit 4564a0e5e2)
2015-06-03 13:26:18 +02:00
Eelco Dolstra
61fe3b6ecb VM tests: Don't produce output on failure
Producing output makes it hard to restart builds that failed for
intermittent reasons (like timeouts). So let's not do that.

(cherry picked from commit 13dcb35233)
2015-06-03 13:25:33 +02:00
Vladimír Čunát
582ee6ec34 cairo: maintenance update
The removed patch was included in the release.

(cherry picked from commit d3399ca45b)
2015-06-02 19:40:14 +02:00
Vladimír Čunát
3853528e84 libav(-11): maintenance update, including security
(cherry picked from commit c86c1b79af)
2015-06-02 11:03:11 +02:00
William A. Kennington III
2c9065ccdf nixUnstable: Bump
(cherry picked from commit f51d38214d)

Conflicts:
	pkgs/tools/package-management/nix/unstable.nix
2015-06-01 18:21:31 +02:00
Henry Till
84ee754a7f dunst: allow user configuration (fixes #5222)
This commit eliminates a patch which hard-coded an example configuration file as the program's default settings and prevented the program from reading a user's configuration file.

(cherry picked from commit 37fb8fb9ca)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-05-31 17:49:55 +02:00
Pascal Wittmann
bdc24fc5ed wireshark: update from 1.12.4 to 1.12.5, fixes CVE-2015-3808
(cherry picked from commit c0a5ffc438)
2015-05-30 13:17:22 +02:00
Eelco Dolstra
b400189493 Add libpqxx
(cherry picked from commit faff3a44a7)
2015-05-29 12:15:05 +02:00
Benjamin Staffin
eaf67fe0a1 Typo fix! s/wheezy/jessie/
(cherry picked from commit 1db5bafc94)
2015-05-29 11:53:57 +02:00
Benjamin Staffin
073131e443 Add Debian 8.0
Had to add file type logic in debClosureGenerator because Packages.bz2
is not available for Jessie - only Packages.xz is.

(cherry picked from commit c7ac0ed3eb)
2015-05-29 11:53:56 +02:00
Sami BOUHLEL
eeaad09fe4 added support for boto 2.38.0 2015-05-29 07:17:22 +00:00
Bjørn Forsman
7b6fd7682b python-pyev: new package
Python bindings for the libev library.

https://code.google.com/p/pyev/
(cherry picked from commit 201059f728)

Conflicts:
	pkgs/top-level/python-packages.nix
2015-05-27 23:07:25 +02:00
Peter Simons
79effb88a0 irssi: add second download mirror because irrsi.org is offline 2015-05-25 00:12:16 +02:00
skityl
d7e38ef19f Bumped version of irssi-0.8.16 to irssi-0.8.17
Signed-off-by: skityl <mopofhair@gmail.com>
(cherry picked from commit 400adb7ec4)
2015-05-24 23:58:36 +02:00
Bjørn Forsman
cbeee4db43 fail2ban: fix broken download/hash
The (dynamically generated) compressed archive has changed. Switch from
fetchurl to fetchzip to not get bitten by that again.

(cherry picked from commit b217d9a4dd)
2015-05-24 23:03:44 +02:00
Peter Simons
92c52c3297 Merge pull request #7975 from samueldr/release-14.12
Fix midori; was building but not working.
2015-05-24 22:26:30 +02:00
Samuel Dionne-Riel
5c9d55280b midori: Fixed wrong desktop schemas path wrapped.
A buildInput was missing to get the right schemas path.

The symptoms of the issue this fixes are:

  ** (WebKitWebProcess:): WARNING **: Error retrieving accessibility bus address: org.freedesktop.DBus.Error.ServiceUnknown: The name org.a11y.Bus was not provided by any .service files
  (process:): GLib-GIO-ERROR **: Settings schema 'org.gnome.system.proxy' is not installed
  (WebKitWebProcess:): GLib-GIO-ERROR **: Settings schema 'org.gnome.system.proxy' is not installed
2015-05-24 16:02:00 -04:00
Samuel Dionne-Riel
f1de592fc4 Add a mirror for midori 2015-05-24 15:09:18 -04:00
Peter Simons
8115e8cff5 nixos: add config.services.openssh.moduliFile option so that users can replace the default file from OpenSSH
The man page for ssh-keygen(1) has a section "MODULI GENERATION" that describes
how to generate your own moduli file. The following script might also be helpful:

 | #! /usr/bin/env bash
 |
 | moduliFiles=()
 |
 | generateModuli()
 | {
 |   ssh-keygen -G "moduli-$1.candidates" -b "$1"
 |   ssh-keygen -T "moduli-$1" -f "moduli-$1.candidates"
 |   rm "moduli-$1.candidates"
 | }
 |
 | for (( i=0 ; i <= 16 ; ++i )); do
 |   let bitSize="2048 + i * 128"
 |   generateModuli "$bitSize" &
 |   moduliFiles+=( "moduli-$bitSize" )
 | done
 | wait
 |
 | echo >moduli "# Time Type Tests Tries Size Generator Modulus"
 | cat >>moduli "${moduliFiles[@]}"
 | rm "${moduliFiles[@]}"

Note that generating moduli takes a long time, i.e. several hours on a fast
machine!

This patch resolves https://github.com/NixOS/nixpkgs/pull/5870.

(cherry picked from commit 86d299bc6e)
2015-05-23 15:01:54 +02:00
Domen Kožar
ada9ca773d gevent: 1.0.1 -> 1.0.2
(cherry picked from commit 42d9fe8b09)
Signed-off-by: Domen Kožar <domen@dev.si>

Conflicts:
	pkgs/top-level/python-packages.nix
2015-05-23 14:32:08 +02:00
Peter Simons
ec2ca3183d jailbreak-cabal: update to latest version 1.3-r2
This patch fixes https://github.com/NixOS/nixpkgs/issues/7940.
2015-05-22 15:06:20 +02:00
Eelco Dolstra
10c9cee08f Add Ubuntu 15.04
(cherry picked from commit 178c52e7ad)
2015-05-22 13:24:02 +02:00
Eelco Dolstra
f0c1308875 firefox: Use internal SQLite
The version of SQLite in Nixpkgs is too old.
2015-05-22 11:47:17 +02:00
Eelco Dolstra
d5732b01f5 thunderbird: Update to 31.7.0
Also enable parallel building, as it seems to work reliably for
Firefox.

(cherry picked from commit 99e9710348)
2015-05-22 11:47:10 +02:00
Eelco Dolstra
0986d3dae1 thunderbird: Update to 31.6.0
Fixes various critical vulnerabilities.

(cherry picked from commit 748be0b5d0)
2015-05-22 11:47:04 +02:00
Eelco Dolstra
b5c8e09414 php: Update to 5.4.41
CVE-2006-7243
2015-05-22 11:46:45 +02:00
Bjørn Forsman
38ae836bee nixos/libvirtd: remove --verbose flag
Because it spams the log:

  .libvirtd-wrapp[1950]: OBJECT_UNREF: obj=0x7f5d900b4200
  .libvirtd-wrapp[1950]: EVENT_POLL_UPDATE_HANDLE: watch=874 events=13
  .libvirtd-wrapp[1950]: OBJECT_UNREF: obj=0x7f5d900b4200
  .libvirtd-wrapp[1950]: EVENT_POLL_RUN: nhandles=24 timeout=-1
  .libvirtd-wrapp[1950]: EVENT_POLL_DISPATCH_HANDLE: watch=874 events=1
  .libvirtd-wrapp[1950]: OBJECT_REF: obj=0x7f5d900b4200
  .libvirtd-wrapp[1950]: [137B blob data]

(cherry picked from commit db991a4024)
2015-05-20 12:25:17 +02:00
Bjørn Forsman
31796c5d94 nixos/libvirtd: add 'extraOptions' option
And move the '--verbose' flag to extraOptions, so that users can easily
disable it.

(cherry picked from commit 3d2d78cb39)
2015-05-20 12:25:17 +02:00
Evgeny Egorochkin
08e829cabb azure-image: common: add sg3_utils 2015-05-20 13:23:12 +03:00
William A. Kennington III
802e783237 kernel: 3.14.41 -> 3.14.43 2015-05-19 22:26:31 -07:00
William A. Kennington III
7a928b39b6 kernel: 4.0.2 -> 4.0.4 2015-05-19 22:25:18 -07:00
William A. Kennington III
66e1731369 kernel: 3.2.68 -> 3.2.69 2015-05-19 22:25:17 -07:00
William A. Kennington III
91b395c871 kernel: 3.19.7 -> 3.19.8 2015-05-19 22:25:16 -07:00
William A. Kennington III
2adeabb6fe kernel: 3.10.77 -> 3.10.79 2015-05-19 22:23:00 -07:00
William A. Kennington III
1f41d1c9ac nss: 3.18.1 -> 3.19
(cherry picked from commit 9f337e8cc7)

Conflicts:
	pkgs/development/libraries/nss/default.nix
2015-05-19 18:16:56 +02:00
William A. Kennington III
de0a7421f6 firefox: 38.0 -> 38.0.1
(cherry picked from commit 0700e844e2)
2015-05-19 18:14:20 +02:00
William A. Kennington III
97ac345791 firefox: 37.0.2 -> 38.0
(cherry picked from commit 8ffc461f91)
2015-05-19 18:14:08 +02:00
Tobias Geerinckx-Rice
4cce8c6747 tzdata 2015c -> 2015d
(cherry picked from commit 7931799a0f)
2015-05-19 16:36:36 +02:00
Tobias Geerinckx-Rice
669a8a4c90 tzdata 2015a -> 2015c
(cherry picked from commit 4679104133)
2015-05-19 12:47:27 +02:00
Thomas Tuegel
3756017dee dropbox: install icons 2015-05-18 15:49:02 -05:00
Thomas Tuegel
eabf79bba1 dropbox: move updateable attributes to the top 2015-05-18 15:49:01 -05:00
Herwig Hochleitner
624049d786 dropbox: 3.4.4 -> 3.4.6 2015-05-18 15:48:26 -05:00
Ricardo M. Correia
1c0a126655 flashplayer: Update from 11.2.202.451 -> 11.2.202.457
(cherry picked from commit 7dddf8a68c)
2015-05-18 11:30:49 +02:00
taku0
ce2a1718d9 firefox-bin: update to version 38.0.1
(cherry picked from commit fa2102b463)
2015-05-18 11:30:42 +02:00
taku0
4ba9a8746e firefox-bin: update to version 38.0
(cherry picked from commit c22b03db0c)
2015-05-18 11:30:36 +02:00
taku0
1948ea862b firefox-bin: update to version 37.0.2
(cherry picked from commit cc3d0913d3)
2015-05-18 11:30:31 +02:00
taku0
bcaa9fd0ce firefox-bin: update to version 37.0.1
(cherry picked from commit dcb61624e7)
2015-05-18 11:30:25 +02:00
taku0
1bad77ee6a firefox-bin: update to version 37.0; thunderbird-bin: update to version 31.6.0
(cherry picked from commit ce7481e129)
2015-05-18 11:30:18 +02:00
taku0
680b74d545 firefox-bin: update to version 36.0.4
(cherry picked from commit f4f340e833)
2015-05-18 11:30:11 +02:00
taku0
5ae3970e20 firefox-bin: update to version 36.0.1 (close #6691)
(cherry picked from commit 08e41f7a58)
2015-05-18 11:30:05 +02:00
taku0
bfc6d272c3 firefox-bin: update to version 36.0; thunderbird-bin: update to version 31.5.0
(cherry picked from commit 2e8f2d6477)
2015-05-18 11:30:00 +02:00
taku0
c756236293 Update firefox-bin to 35.0.1
(cherry picked from commit c5079ee886)
2015-05-18 11:29:53 +02:00
taku0
4350ae2b83 firefox-bin: update to version 35.0; thunderbird-bin: update to version 31.4.0
(cherry picked from commit 9d2cf54c6a)
2015-05-18 11:29:48 +02:00
Evgeny Egorochkin
0672315759 azure sdk for python: update from 0.9.0 to 0.11.0 2015-05-17 19:27:39 +03:00
Joachim Schiele
a6dd603b69 tig-2.1.1: version bump
(cherry picked from commit 50fb7b312b)
2015-05-16 16:09:42 +02:00
William A. Kennington III
0ad951419d tig: 2.0.3 -> 2.1
(cherry picked from commit cd3b460200)
2015-05-16 16:09:27 +02:00
William A. Kennington III
836dc68872 cgit: 0.10.2 -> 0.11.2
(cherry picked from commit 06ea226495)
2015-05-16 15:50:36 +02:00
Lluís Batlle i Rossell
815c8d6e30 Fix for the build of the xorg openchrome driver 2015-05-15 13:57:11 +02:00
aszlig
7963a45b99 linux/kernel: Remove EXT2_FS_XIP for version 4.0.
The option has been removed in torvalds/linux@6cd176a and thus we
shouldn't try to set it for kernel version 4.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 791b970c6e)
2015-05-14 23:51:48 +02:00
Franz Pletz
46db4d8ad3 Check if /proc/sys/kernel/hotplug exists before writing
If a kernel without CONFIG_UEVENT_HELPER set is used with NixOS, the file
/proc/sys/kernel/hotplug does not exist. Before writing to it to disable
this deprecated mechanism, we have to ensure it actually exists because
otherwise the activation script will fail.

(cherry picked from commit 16d25f4fa6)
2015-05-12 11:18:36 +02:00
William A. Kennington III
a9280e086d btrfs: Remove btrfs deadlock patch 2015-05-08 05:28:35 -07:00
William A. Kennington III
b4cf0bb944 kernel: Add 4.0 and fix grsecurity message 2015-05-07 20:42:49 -07:00
William A. Kennington III
8123467a38 kernel: 3.14.40 -> 3.14.41 2015-05-07 20:42:49 -07:00
William A. Kennington III
a341d8e146 kernel: 4.0.1 -> 4.0.2 2015-05-07 20:42:49 -07:00
William A. Kennington III
048aa3e54d kernel: 3.19.6 -> 3.19.7 2015-05-07 20:42:49 -07:00
William A. Kennington III
a18e23f914 kernel: 3.18.12 -> 3.18.13 2015-05-07 20:42:49 -07:00
William A. Kennington III
1998c49674 kernel: 3.12.40 -> 3.12.42 2015-05-07 20:42:49 -07:00
William A. Kennington III
b73134f6bf kernel: 3.10.76 -> 3.10.77 2015-05-07 20:42:49 -07:00
Rob Vermaas
ccf672ca6b Revert restartIfChanged on fetch-ec2-data, as it breaks deployments that set ec2.metadata = true, as the existing (default) blackhole will not be cleared. 2015-05-07 08:50:47 +00:00
Rob Vermaas
ce83865800 le: add psutil to dependencies
(cherry picked from commit b114eab794)
2015-05-05 13:27:15 +00:00
Eelco Dolstra
e79a47b007 fetch-ec2-data: Don't restart
This service only needs to run once on system startup, so it doesn't
need to be restarted by switch-to-configuration.

(cherry picked from commit 4239e276ea)
2015-05-05 12:40:57 +00:00
Rob Vermaas
63def04891 Update nixUnstable to a build that is there. 2015-05-04 19:40:29 +00:00
Rob Vermaas
34326bcbcc D'ohhh 2015-05-04 19:19:32 +00:00
Rob Vermaas
bb1081abbd Disable httpretty tests as some tests fail because tests do not complete within 2 microseconds. 2015-05-04 19:05:18 +00:00
Vladimír Čunát
62b4419294 texLiveModerntimeline: fix download by updating
Unfortunately I only see them providing an unversioned tarball :-/
CC #6747.

(cherry picked from commit 263ac41c18)
2015-05-04 10:44:15 +00:00
Evgeny Egorochkin
30c812d026 azure-image: fix, split into bootstrap and regular configurations 2015-05-03 20:18:18 +03:00
William A. Kennington III
a690f3f585 curl: 7.42.0 -> 7.42.1 2015-05-01 15:09:56 -07:00
William A. Kennington III
863728b9c3 kernel: 3.12.40 -> 3.12.41 2015-05-01 15:09:29 -07:00
Rob Vermaas
c7f7f12f2b Add logentries agent 1.4.13
(cherry picked from commit 33984cfeee)
2015-04-30 16:45:43 +00:00
William A. Kennington III
e942188876 kernel: 3.14.39 -> 3.14.40 2015-04-29 15:46:08 -07:00
William A. Kennington III
62c22cebb4 kernel: 3.19.5 -> 3.19.6 2015-04-29 15:45:55 -07:00
William A. Kennington III
d94c3efa93 kernel: 3.10.75 -> 3.10.76 2015-04-29 15:41:54 -07:00
Eelco Dolstra
4c29879b20 php: Update to 5.4.40
(cherry picked from commit 552ea209d0)

Conflicts:
	pkgs/development/interpreters/php/5.4.nix
2015-04-29 16:13:37 +02:00
Domen Kožar
3a8ddee143 boto: 2.34.0 -> 2.36.0
(cherry picked from commit 5da0d18a0a)
2015-04-28 13:50:57 +00:00
Eelco Dolstra
b514f66400 Don't require sslServerChain to be set
(cherry picked from commit 534b84a9ac)
2015-04-27 18:24:45 +02:00
Eelco Dolstra
78ca36b2fc firefox: Update to 37.0.2
(cherry picked from commit 9f3370a9c9)
2015-04-27 18:07:53 +02:00
Peter Simons
f86a148dad R: port version 3.2.0 update from master
Resolves https://github.com/NixOS/nixpkgs/issues/7581.
2015-04-27 12:53:51 +02:00
Bjørn Forsman
42c5cd8723 jquery: bump 1.11.1 -> 1.11.2
(cherry picked from commit 173da15f75)
2015-04-25 20:32:58 +02:00
Joachim Schiele
fc4c99db15 wpa-supplicant: CVE-2015-1863 (close #7526)
http://w1.fi/security/2015-1/
(cherry picked from commit e3e8aebdc1)
2015-04-23 20:25:15 +02:00
Vladimír Čunát
cf46c88a8d mariadb: remove ~250MB of superfluous files
Picked lines from master, discussion:
https://github.com/NixOS/nixpkgs/issues/7117#issuecomment-95657579

The output is still ~190 MB, but it's much better.
On master there's a splitting solution anyway.
2015-04-23 20:14:43 +02:00
William A. Kennington III
9ce9f85cec nss: 3.18 -> 3.18.1 2015-04-22 16:52:04 -07:00
William A. Kennington III
f96835cac1 gnutls: 3.2.20 -> 3.2.21 2015-04-22 16:27:16 -07:00
William A. Kennington III
6eaaaaa1d2 grsec_path: Update patch 2015-04-22 16:21:29 -07:00
William A. Kennington III
7a03dbce26 kernel: Add kernel 3.19 2015-04-22 16:19:13 -07:00
William A. Kennington III
94a95ff537 kernel: 3.18.10 -> 3.18.12 2015-04-22 16:11:53 -07:00
William A. Kennington III
c11a02e492 kernel: 3.14.37 -> 3.14.39 2015-04-22 15:52:52 -07:00
William A. Kennington III
d67fb4f007 kernel: 3.4.106 -> 3.4.107 2015-04-22 15:52:52 -07:00
William A. Kennington III
c1d57646a7 kernel: 3.12.38 -> 3.12.40 2015-04-22 15:42:03 -07:00
William A. Kennington III
6a4c334268 kernel: 3.10.71 -> 3.10.75 2015-04-22 15:42:01 -07:00
William A. Kennington III
471512b619 curl: 7.39.0 -> 7.42.0 2015-04-22 15:41:12 -07:00
Lluís Batlle i Rossell
b0d594ca9b Updating cjdns to 20150422.
(cherry picked from commit 5a21c015c7)
2015-04-22 17:13:26 +02:00
William A. Kennington III
f21c8c7a0e Merge pull request #6919 from ehmry/cjdns
cjdns: update pkg and fix nixos test
(cherry picked from commit 9d9a393a4b)
2015-04-22 17:13:06 +02:00
Peter Feigl
cb3bc913e4 apache-httpd: adding support for sslServerChain
(cherry picked from commit e5b3918f85)
2015-04-20 17:03:01 +02:00
Thomas Tuegel
55c55db0ab Merge pull request #7478 from bendlas/dropbox-stable
dropbox-[cli]: latest versions for stable branch
2015-04-20 09:33:35 -05:00
Eelco Dolstra
6a8c9ed59a Typo
(cherry picked from commit d5f187de03)
2015-04-20 16:12:42 +02:00
Eelco Dolstra
776e671e3a Use "mkdir -p" when creating ~/.nix-defexpr
Otherwise, simultaneous invocations of /etc/profile can fail, e.g.

  mkdir: cannot create directory ‘/.nix-defexpr’: File exists

(cherry picked from commit 11a9774c75)
2015-04-20 13:06:52 +02:00
Eelco Dolstra
6277b1f58f nodejs: Update to 0.10.38 2015-04-20 13:06:08 +02:00
Herwig Hochleitner
84323e0639 dropbox-[cli]: latest versions for stable branch
dropbox: 3.4.4
    dropbox-cli: 2015.02.12

This contains the following commits from staging:

29398fd6b1 dropbox[-cli]: update to latest versions
7ed4beec55 Update dropbox[-cli] to latest
75c4f136ca dropbox-cli: make `dropbox start` work
f12536f151 dropbox: use bundled librsync (working)
bd6a15d6d3 dropbox: rm qt.conf
115e8110f7 dropbox: wrap for LD_LIBRARY_PATH (runtime loads)
d36af8e0ae dropbox: don't wrap with Mesa
32643c010e dropbox: update to 3.2.6 (fixed)
52cc26eb3e Revert "Revert "dropbox: update to version 3.2.6""
a9b2dee6e6 Revert "dropbox: update to version 3.2.6"
7c37b4d672 dropbox: update to version 3.2.6
2015-04-20 12:34:07 +02:00
Alexander Flatter
b6b8f025ef Compile postgresql with openssl
(cherry picked from commit e8df73e508)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-04-18 18:24:54 -04:00
j-keck
c86a1279bd postgresql: Update to 9.0.19, 9.1.15, 9.2.10, 9.3.6, 9.4.1
(cherry picked from commit 1c45287baf)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-04-18 18:24:54 -04:00
j-keck
08d8b51e83 postgresql: add version 9.4.0
(cherry picked from commit 356d05dbc0)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-04-18 18:24:54 -04:00
Lluís Batlle i Rossell
fec14fba4e Updating trigger rally to 0.6.1
A lot more tracks

(cherry picked from commit 7937bd7039)
2015-04-17 10:46:38 +02:00
Lluís Batlle i Rossell
e95d381e48 Adding alsa/pulseaudio to mikmod
I also write the sf urls with mirror://.

(cherry picked from commit 19a96c7c30)
2015-04-17 09:39:39 +02:00
Peter Simons
32ced25cb4 mikmod: update to version 3.2.6
(cherry picked from commit 31ecab7b7e)
2015-04-17 09:39:25 +02:00
Peter Simons
1efbf87ee0 libmikmod: update to version 3.3.7
(cherry picked from commit a98c79d6a1)
2015-04-17 09:39:18 +02:00
taku0
bd42bce8bd oraclejdk: bump to 8u45, 7u79, and 7u80
(cherry picked from commit 256cd8046c)
Signed-off-by: Domen Kožar <domen@dev.si>

Conflicts:
	pkgs/development/compilers/oraclejdk/jdk7-linux.nix
	pkgs/development/compilers/oraclejdk/jdk7psu-linux.nix
	pkgs/development/compilers/oraclejdk/jdk8-linux.nix
2015-04-16 19:11:10 -04:00
Eelco Dolstra
8bb0101333 dnsmasq: Add some types
(cherry picked from commit a0f69df10e)
2015-04-16 19:14:37 +02:00
Eelco Dolstra
ec0d153ed8 dbus: Reload if /etc/dbus-1 changes
Specifically, this fixes dnsmasq, which failed with

  Apr 16 19:00:30 mandark dnsmasq[23819]: dnsmasq: DBus error: Connection ":1.260" is not allowed to own the service "uk.org.thekelleys.dnsmasq" due to security policies in the configuration file
  Apr 16 19:00:30 mandark dnsmasq[23819]: DBus error: Connection ":1.260" is not allowed to own the service "uk.org.thekelleys.dnsmasq" due to security policies in the configuration file

after being enabled, due to dbus not being reloaded.

(cherry picked from commit 5a5a43ea25)
2015-04-16 19:14:36 +02:00
William A. Kennington III
4f2ab67bd9 nixos/dnsmasq: Fix service name typo
(cherry picked from commit f27fa79aa9)
2015-04-16 19:14:24 +02:00
aszlig
9d71536a72 virtualbox: Add an alias for the hardened version.
This is to ensure that Hydra will build the hardened version of
VirtualBox and it's also lowPrio to avoid being accidentally installed
into a user's environment.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 142b12c864)
2015-04-16 17:49:08 +02:00
Wayne Scott
ea6815a8b4 Upgrade backup/attic to 0.15
(cherry picked from commit 0520f7a938)
2015-04-16 08:27:35 +02:00
Ricardo M. Correia
dd0f98f1c0 flashplayer: Update from 11.2.202.442 -> 11.2.202.451
(cherry picked from commit c6c3016406)
2015-04-15 19:44:43 +02:00
Rickard Nilsson
49edb6d0a4 scollector module: Add extraOpts option
(cherry picked from commit bdbdaee3c0)
2015-04-15 13:16:23 +02:00
Rickard Nilsson
05a95dd84e nginx: Add fluentd module
(cherry picked from commit c61dff28ae)
2015-04-15 13:15:05 +02:00
Lluís Batlle i Rossell
0e214408a4 Updating gdb to 7.9.
I can remove the patch of edit-signals. It seems to work without it.

I tested the change over release-14.12.

(cherry picked from commit 745b1ce04a)
2015-04-14 17:26:34 +02:00
Thomas Strobel
60e515641c Fix/update Xpra
(cherry picked from commit c6ef0727c3)
2015-04-12 17:43:56 +02:00
Bjørn Forsman
6500243503 python-pelican: add missing 'markupsafe' dependency
Needed to be able to run 'make serve' in a pelican directory, else this
happens:

  $ make serve
  cd /home/bfo/pelican-test/output && python -m pelican.server
  /run/current-system/sw/bin/python: No module named markupsafe
  make: *** [serve] Error 1

(cherry picked from commit 48b5ad912f)
2015-04-12 17:19:52 +02:00
Pavan Rikhi
23b48bf2d2 python pelican: v3.4.0 -> v3.5.0
(cherry picked from commit c08310c62d)
2015-04-12 17:19:47 +02:00
Bjørn Forsman
8d46191ddc mutt: use "sendmail" instead of "/usr/bin/sendmail"
That way sending mail with mutt works on NixOS too, without having to
manually change mutt's config on your system. sendmail will be found in
$PATH at runtime, and thus the setuid wrapper will be used, if
available.

(cherry picked from commit 6e0d0636a1)
2015-04-12 10:49:04 +02:00
Bjørn Forsman
ecb7c34a83 hping: set platforms = all
From http://www.hping.org/:

  "Hping works on the following unix-like systems: Linux, FreeBSD,
   NetBSD, OpenBSD, Solaris, MacOs X, Windows."

(cherry picked from commit c1556f70d7)
2015-04-11 15:27:27 +02:00
Bjørn Forsman
67c9b3a78e lftp: update 4.6.0 -> 4.6.1
2014-12-29: lftp-4.6.1 released. Some bugs fixed, minor feature added.
(cherry picked from commit 965129cdac)
2015-04-11 15:07:42 +02:00
Bjørn Forsman
1fa37c4393 qmmp: update 0.8.2 -> 0.8.4
(cherry picked from commit 124bdd5114)
2015-04-11 14:56:39 +02:00
Bjørn Forsman
91c5b64d85 python-robotframework: update 2.8.6 -> 2.8.7
Release notes:
https://github.com/robotframework/robotframework/releases/tag/2.8.7

(cherry picked from commit 2c6f9b0c62)
2015-04-11 14:23:57 +02:00
Bjørn Forsman
f5e5001b31 wireshark: update from 1.12.3 to 1.12.4
Potentially fixes CVE-2015-2188, CVE-2015-2189, CVE-2015-2191

(cherry picked from commit 890534bedc)
2015-04-11 13:48:34 +02:00
Vladimír Čunát
5f22660e53 linux: remove 3.17 and disable depending grsecurity
Having gr*security* with an outdated kernel was probably useless.
2015-04-09 19:44:26 +02:00
Nikolay Amiantov
f01dd23aaf kernel: add patch to fix btrfs deadlocks to affected kernels
(cherry picked from commit 285d64d2f0)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-04-08 20:17:33 +02:00
Eelco Dolstra
fdce0a6a88 tests/misc.nix: Ensure that the Nix DB is initialised correctly
(cherry picked from commit facd53315b)
2015-04-07 15:52:41 +02:00
Eelco Dolstra
6015f6a01f Revert "Set stricter permissions on /nix/store"
This reverts commit 066758758e because
it breaks NixOS VM tests.

(cherry picked from commit a38f130126)
2015-04-07 15:52:41 +02:00
Michael Raskin
acfb8abcb6 Update Firefox to 37.0.1
(cherry picked from commit 4b0e70f89a)
2015-04-07 15:52:20 +02:00
Bjørn Forsman
2d6291cc41 perl-threads: new package
A dependency of newer Slic3r (at least v1.2.6 needs it).

(cherry picked from commit 884713bf09)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-04-07 12:22:27 +02:00
Bjørn Forsman
6c6768d5ec slic3r: update 1.2.1 -> 1.2.6
Release notes: http://slic3r.org/releases/1.2.6

Slic3r needs additional dependency, 'threads'. Add it.

In addition to bug fixes and some new features, this update stops Slic3r
from printing this on startup:

  Running Slic3r under Perl >= 5.16 is not supported nor recommended

We don't have perl < 5.16 anymore, so we better update slic3r.

(cherry picked from commit 962690cc18)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-04-07 12:22:22 +02:00
Vladimír Čunát
e0c06a0de4 xorg: pick supposedly safe changes and additions
/cc #5583 (hopefully fixes that problem).
2015-04-06 22:53:41 +02:00
Nikolay Amiantov
7e373750fb xorg-server: add Xephyr (close #6715)
(cherry picked from commit edaa3a7643)
2015-04-06 22:49:50 +02:00
aszlig
513170e980 xorg.mxfontscale: Fix segfault with some fonts.
The update to version 1.1.2 in 9c22c1b introduces a segfault when
mkfontscale is processing fonts where the family name is missing.

Applies a patch from Stefan Dirsch <sndirsch@suse.com> to be found at:

https://bugs.freedesktop.org/show_bug.cgi?id=89409

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 0ccf34039c)
2015-04-06 22:49:39 +02:00
Vladimír Čunát
9ce5be7367 xf86-video-vmware: drop patch included in update
(cherry picked from commit 6c20e1d0bd)
2015-04-06 22:49:02 +02:00
Vladimír Čunát
6f141f345c xf86-video-vmware: update
(cherry picked from commit a3e0ee10e5)
2015-04-06 22:49:02 +02:00
Vladimír Čunát
a576448a4d xorg: update various modules
(cherry picked from commit 9c22c1b3d7)
The sessreg update is omitted, as it doesn't seem to be a minor update.
2015-04-06 22:46:41 +02:00
Alexander V. Nikolaev
0d98e16a80 Proper default path for XKB config files
(cherry picked from commit 279d5af119)
2015-04-06 22:44:18 +02:00
Vladimír Čunát
df677ae5ce xorg.xf86-video-intel: maintenance update
(cherry picked from commit 0bc5228fd2)
2015-04-06 22:42:16 +02:00
David Virgilio
b69e4e47f2 new package: xwayland
(cherry picked from commit 9a2b2e7b34)
2015-04-06 22:39:58 +02:00
Bjørn Forsman
7efbe87ecd slic3r: remove unneeded dependency on BoostGeometryUtils
Slic3r dropped this dependency in v1.1.0 and we have v1.2.x.

And more importantly, BoostGeometryUtils is currently broken (fails on
newer Perl versions), so this patch unbreaks Slic3r.

(cherry picked from commit 7273ca19b3)
2015-04-06 16:04:07 +02:00
Bjørn Forsman
d3a2973fe8 perl-App-cpanminus: new package
cpanm is one of three(?) CPAN clients, see
http://stackoverflow.com/questions/5861292/which-cpan-installer-is-the-right-one-cpan-pm-cpanplus-cpanminus.

Generated with "nix-generate-from-cpan App::cpanminus", plus I added
platforms = all;

(cherry picked from commit 4cecfe9ab7)
2015-04-06 16:04:07 +02:00
Alexander V. Nikolaev
bd75ca4cd3 Fix build for perl-Alien-Wx and friends
This should fix at least one problem, preventing build master on
Travis-CI.

(cherry picked from commit a1ca3dbd08)
2015-04-06 16:04:06 +02:00
Bjørn Forsman
6c5dbb9a23 perl-Math-Clipper: update 1.22 -> 1.23 (fixes build)
Version 1.22 is broken on newer Perl ("Out of memory" test failures).

 Bug #121948 for perl5: Bleadperl breaks Math-Clipper-1.22.tar.gz ("Out of memory")
 https://rt.perl.org/Public/Bug/Display.html?id=121948

(cherry picked from commit 1ecd116c78)
2015-04-06 15:25:39 +02:00
Vladimír Čunát
073d70f2ae libzip: fix CVE-2015-2331 by Debian patch
Rebuild impact seems low, except for LibreOffice.

(cherry picked from commit 4041fc3e85)
2015-04-06 12:13:32 +02:00
Lluís Batlle i Rossell
ef475fb309 Updating syncthing to 0.10.30.
The builder in master is completely different, so this commit can't be
shared between master & release-14.12.
2015-04-05 15:51:33 +02:00
Lluís Batlle i Rossell
a3bd913d55 Updating get_iplayer to 2.92.
Version 2.86 wasn't compatible with the current web.
2015-04-05 15:51:33 +02:00
Moritz Ulrich
4e2669fb00 audacity: Fix nyquist support.
(cherry picked from commit 30e577cdfe)
2015-04-05 15:51:33 +02:00
William A. Kennington III
f22ab7058f kernel: 3.14.36 -> 3.14.37
(cherry picked from commit 304b3c077c)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-04-04 16:21:25 +02:00
William A. Kennington III
be3415f5da kernel: 3.18.9 -> 3.18.10
(cherry picked from commit a040e15a48)
Signed-off-by: Domen Kožar <domen@dev.si>

Conflicts:
	pkgs/os-specific/linux/kernel/linux-3.18.nix
2015-04-04 16:19:56 +02:00
Eelco Dolstra
8515a124d1 Reload, don't restart, dbus.service
Many bus clients get hopelessly confused when dbus-daemon is
restarted. So let's not do that.

Of course, this is not ideal either, because we end up stuck with a
possibly outdated dbus-daemon. But that issue will become irrelevant
in the glorious kdbus-based future.

Hopefully this also gets rid of systemd getting stuck after
dbus-daemon is restarted:

Apr 01 15:37:50 mandark systemd[1]: Failed to register match for Disconnected message: Connection timed out
Apr 01 15:37:50 mandark systemd[1]: Looping too fast. Throttling execution a little.
Apr 01 15:37:51 mandark systemd[1]: Looping too fast. Throttling execution a little.
...

(cherry picked from commit 1c39a47ac8)
2015-04-03 12:10:45 +02:00
Eelco Dolstra
c76f954247 nixUnstable: Update to 1.9pre4087
(cherry picked from commit f713e7033e)
2015-04-03 11:40:35 +02:00
Eelco Dolstra
b8838f2c00 php: Update to 5.4.39
CVE-2015-2787, CVE-2015-2348, CVE-2015-2305, CVE-2015-2331.

(cherry picked from commit 33dfdbd0df)
2015-04-03 11:34:30 +02:00
William A. Kennington III
e262c19ad2 nss: 3.17.4 -> 3.18
(cherry picked from commit 7215167342)
2015-04-03 11:34:30 +02:00
Eelco Dolstra
77f7c6afbb firefox: Update to 37.0
(cherry picked from commit 4c8f0e8d1c)
2015-04-03 11:34:30 +02:00
Eelco Dolstra
a494359d15 switch-to-configuration: Don't print already active target units
Since we restart all active target units (of which there are many),
it's hard to see the units that actually matter. So don't print that
we're starting target units that are already active.

(cherry picked from commit 475df1a350)
2015-04-03 11:34:29 +02:00
Eelco Dolstra
2715d81958 nixos-rebuild: Add ‘dry-activate’ command
‘nixos-rebuild dry-activate’ builds the new configuration and then
prints what systemd services would be stopped, restarted etc. if the
configuration were actually activated. This could be extended later to
show other activation actions (like uids being deleted).

To prevent confusion, ‘nixos-rebuild dry-run’ has been renamed to
‘nixos-rebuild dry-build’.

(cherry picked from commit a574065a81)
2015-04-03 11:34:29 +02:00
Eelco Dolstra
b32e72e2c2 Add perf-tools
(cherry picked from commit dfc6809215)
2015-04-03 11:34:29 +02:00
Eelco Dolstra
1f06c1d597 perf: Use libunwind and libbfd
This gives better stack traces.

(cherry picked from commit fa3bcc4f1c)
2015-04-03 11:34:29 +02:00
Bjørn Forsman
3c4b8c3888 attic: update source derivation name
0.14.tar.gz => attic-0.14-src.

(cherry picked from commit 16730fa87a)
2015-04-03 08:54:41 +02:00
Bjørn Forsman
8f22f78f74 attic: update source hash
I don't know what changed, but apparently something did. We're using
fetchzip and the 0.14 tag doesn't seem to have moved (AFAICS).

Build and run-tested.

For reference, the (current) annotated tag '0.14' is dated
"Wed Dec 17 23:32:11 2014 +0100" and points to commit
f342621dff8065b29aeda238ccce5ac92d04f5b6 ("Preparing release").

(cherry picked from commit 2c89d0b82d)
2015-04-03 08:54:40 +02:00
Eelco Dolstra
99bfc89a97 Merge pull request #7086 from retrry/spotify-backport
Backport new Spotify version to 14.12
2015-03-30 16:12:35 +02:00
Tadas Barzdzius
acbbb01627 Add udev to dependencies and remove workaround 2015-03-30 17:09:06 +03:00
Tadas Barzdzius
fbbd0df8b0 Remove obsolete part of comment 2015-03-30 16:33:33 +03:00
Siarhei Zirukin
02fd9e5d75 spotify: 0.9.11.27 -> 0.9.17.1 2015-03-30 15:47:43 +03:00
Rickard Nilsson
1b3dae4f54 dovecot: Update from 2.2.15 to 2.2.16
(cherry picked from commit 9fde4cc2f0)
2015-03-29 12:42:39 +02:00
William A. Kennington III
1f14275f51 kernel: 3.14.35 -> 3.14.36
(cherry picked from commit 36ada70250)

Conflicts:
	pkgs/os-specific/linux/kernel/patches.nix
2015-03-26 19:53:43 +01:00
Michael Raskin
10cc3bc885 Update Firefox. Second take.
(cherry picked from commit 166614ee41)
2015-03-26 19:49:38 +01:00
Ricardo M. Correia
a832bb2313 firefox: Update from 36.0.1 -> 36.0.3
(cherry picked from commit a246b849eb)
2015-03-26 19:49:30 +01:00
Domen Kožar
f26ca1fd64 fira: 3.x -> 4.004
(cherry picked from commit 636b25af67)
Signed-off-by: Domen Kožar <domen@dev.si>

Conflicts:
	pkgs/data/fonts/fira/default.nix
2015-03-26 11:56:57 +01:00
Thomas Tuegel
35c0e0a768 robomongo: fix build with openssl-1.0.1m 2015-03-25 07:45:53 -05:00
Bjørn Forsman
4e0e0cfbe2 lttng-modules: update to latest stable (fixes build)
Fixes build against linux 3.14.36+.

Also
* It works with linux 3.12 now, so remove that assert
* Remove unneeded patches (merged upstream)

(cherry picked from commit ff9bc81946)
2015-03-25 00:13:06 +01:00
Vladimír Čunát
dc8da14b8d octave: disable parallel building again
http://hydra.nixos.org/build/19917018
(cherry picked from commit 7abccbe81c)
2015-03-24 21:32:41 +01:00
Rob Vermaas
cc9e1930ae Do not build nodePackages. 2015-03-24 14:13:38 +00:00
Jaka Hudoklin
7094efc5da nodePackages: fix builder
- reuse unpack and patch phase
- patch shebangs of source code
- properly patch depdency versions (thanks @svanderburg)
- add patching for github version names
- add some inline docs
- fix recursive depdencies runtime handling by copying files instead of
  symlinking if package has recursive dependencies

(cherry picked from commit 86744fef91)
2015-03-24 14:05:39 +00:00
Eelco Dolstra
f9a8cc63c1 libguestfs: Don't build on Hydra
It produces a package over 4 GB large, and takes several hours to
build (probably because of the overhead of copying that 4 GB image).

(cherry picked from commit 433d30b877)
2015-03-24 15:01:40 +01:00
Eelco Dolstra
2178fd281f nixUnstable: Update to 1.9pre4083_5114a07
(cherry picked from commit 5cc05f6cf2)
2015-03-24 15:01:29 +01:00
Domen Kožar
6a64465c69 Merge pull request #6943 from goodwillcoding/release-14.12
fix the cmake 2.8.x detection of OpenSSL version broken in openssl 1.0.1m.
2015-03-23 10:34:20 +01:00
goodwillcoding
30dd174520 fix the cmake 2.8.x detection of OpenSSL version broken in openssl 1.0.1m
this is a follow up to security update for openssl: 1.0.1l -> 1.0.1m,
references:
 - http://public.kitware.com/Bug/bug_relationship_graph.php?bug_id=15386
 - http://www.cmake.org/gitweb?p=cmake.git;a=commitdiff;h=c5d9a8283cfac15b4a5a07f18d5eb10c1f388505#patch1
2015-03-22 20:00:04 -07:00
Brian McKenna
2dab7cf8d5 tigerVNC: fix by updating (close #6852)
The default xorgserver is now on 1.16 and so the patch needs to change.
The 116 patch is not in 1.3.1 so we also need to upgrade.

I don't know how to compute this filename since the xorgserver derivation
doesn't have a version attribute.

(cherry picked from commit dc1ea2e968)
2015-03-22 20:29:27 +01:00
Domen Kožar
356c70aea7 Merge pull request #6921 from goodwillcoding/release-14.12
security update for openssl: 1.0.1l -> 1.0.1m
2015-03-21 18:57:11 +01:00
goodwillcoding
2d130c000b Merge branch 'release-14.12' of github.com:goodwillcoding/nixpkgs into release-14.12 2015-03-21 10:48:49 -07:00
goodwillcoding
89522dc12d security update for openssl: 1.0.1l -> 1.0.1m
Errata: https://github.com/openssl/openssl/blob/OpenSSL_1_0_1-stable/NEWS

Major changes between OpenSSL 1.0.1l and OpenSSL 1.0.1m [19 Mar 2015]
o Segmentation fault in ASN1_TYPE_cmp fix (CVE-2015-0286)
o ASN.1 structure reuse memory corruption fix (CVE-2015-0287)
o PKCS7 NULL pointer dereferences fix (CVE-2015-0289)
o DoS via reachable assert in SSLv2 servers fix (CVE-2015-0293)
o Use After Free following d2i_ECPrivatekey error fix (CVE-2015-0209)
o X509_to_X509_REQ NULL pointer deref fix (CVE-2015-0288)
o Removed the export ciphers from the DEFAULT ciphers
2015-03-21 10:48:35 -07:00
goodwillcoding
eaa3934a6a security update for openssl: 1.0.1l -> 1.0.2m
Errata: https://github.com/openssl/openssl/blob/OpenSSL_1_0_1-stable/NEWS

Major changes between OpenSSL 1.0.1l and OpenSSL 1.0.1m [19 Mar 2015]
o Segmentation fault in ASN1_TYPE_cmp fix (CVE-2015-0286)
o ASN.1 structure reuse memory corruption fix (CVE-2015-0287)
o PKCS7 NULL pointer dereferences fix (CVE-2015-0289)
o DoS via reachable assert in SSLv2 servers fix (CVE-2015-0293)
o Use After Free following d2i_ECPrivatekey error fix (CVE-2015-0209)
o X509_to_X509_REQ NULL pointer deref fix (CVE-2015-0288)
o Removed the export ciphers from the DEFAULT ciphers
2015-03-21 10:45:28 -07:00
Eelco Dolstra
535018fab8 nvidia-x11: Update to 340.76
(cherry picked from commit fb72208bcf)
2015-03-18 20:26:38 +01:00
Vladimír Čunát
c6fb75b950 xorg.libXfont: security update
Fixes CVE-2015-{1802,1803,1804}.
http://lists.x.org/archives/xorg-announce/2015-March/002550.html
Almost nothing needs rebuilding.

(cherry picked from commit 6a230188c6)
2015-03-17 18:37:12 +01:00
Cillian de Róiste
545d06e136 xf86_input_wacom: update from 0.27.0 to 0.28.0
(cherry picked from commit c40a5a4322)
2015-03-17 10:16:02 +01:00
Nikita Karetnikov
abed7e7171 pcmcia-utils: update to 017
Cherry picked from commit d8ff010255. This
fixes https://github.com/NixOS/nixpkgs/issues/6809.
2015-03-14 18:00:39 +01:00
Sander van der Burg
297ec179ac disnix: use libiconvOrEmpty 2015-03-13 21:12:46 +00:00
Sander van der Burg
d3f5da5c61 disnix: bump to version 0.3 2015-03-13 21:10:24 +00:00
Vladimír Čunát
98b8eb66bd libav*: maintenance updates, including security
(cherry picked from commit 07e49e6952)
2015-03-12 20:17:07 +01:00
Nikolay Amiantov
b37188eddb stage-1: fix hibernation (close #6675)
Fixes #6617.

(cherry picked from commit b802018482)
2015-03-12 20:17:07 +01:00
Eelco Dolstra
28c0d0fe41 nixos: enhance squashfs handling during boot
Merge pull request #6477 from ts468/stage-1-2
(cherry picked from commit 24c10d0612)
2015-03-12 20:17:07 +01:00
Rickard Nilsson
ff0b2a3861 syslog-ng: Update from 3.6.1 to 3.6.2
(cherry picked from commit 2d00826ac9)
2015-03-11 02:08:36 +01:00
Lluís Batlle i Rossell
2db8293855 Updating gobby and libinfinity.
(cherry picked from commit 44c3256017)
2015-03-10 14:37:41 +01:00
William A. Kennington III
3a9de8f25a gnupg: 2.0.26 -> 2.0.27
(cherry picked from commit e1703a836e)
2015-03-10 11:56:53 +01:00
William A. Kennington III
4f00f1e1a2 gnupg: Fix default path to pcsclite
(cherry picked from commit 9631f5a718)

Conflicts:
	pkgs/tools/security/gnupg/20.nix
2015-03-10 11:56:52 +01:00
Domen Kožar
cb21db1c77 fix eval 2015-03-10 11:43:53 +01:00
koral
7c12c7830e opensmtpd: 5.4.2p1 -> 5.4.4p1
(cherry picked from commit 3bc7dfdf22)
2015-03-10 11:30:27 +01:00
Luca Bruno
fce401fa07 povray: fix build and add platforms
(cherry picked from commit ca2d7774e0)
2015-03-09 18:00:32 +01:00
Lluís Batlle i Rossell
f8ff105d7d Add pcsc-tools, to test ccid cards.
(cherry picked from commit a2f4b94dbe)
2015-03-09 15:38:50 +01:00
Lluís Batlle i Rossell
10b693dbee Fixing judy for gcc 4.8
gtkwave crashes often, without this fix.
http://sourceforge.net/p/judy/mailman/message/31995144/

(cherry picked from commit a22c19f56a)
2015-03-09 15:38:40 +01:00
Eelco Dolstra
5baf87bc72 subversion: Update to 1.8.11
(cherry picked from commit 49282dd1af)
2015-03-09 13:07:40 +01:00
Thomas Tuegel
537008118a clementine: wrap for GST_PLUGINS_PATH 2015-03-09 06:45:28 -05:00
William A. Kennington III
3fb7fab03f libu2f-host: 0.0.2 -> 0.0.4
(cherry picked from commit a1f6084fc8)
2015-03-09 11:43:50 +01:00
William A. Kennington III
c6e76335f9 libu2f-host: 0.0.1 -> 0.0.2
(cherry picked from commit 9a56a86f5e)
2015-03-09 11:43:42 +01:00
Eelco Dolstra
5a2099b254 php: Update to 5.4.38
(cherry picked from commit 7f90cc40b4)
2015-03-09 11:37:17 +01:00
Eelco Dolstra
6261d6c079 nixUnstable: Update to 1.9pre4074_e659978
(cherry picked from commit e02d926ca9)
2015-03-09 11:37:13 +01:00
William A. Kennington III
de393636ff kernel: 3.12.37 -> 3.12.38 2015-03-08 15:31:20 -07:00
William A. Kennington III
1ded7008c1 kernel: 3.10.70 -> 3.10.71 2015-03-08 15:28:35 -07:00
William A. Kennington III
34023141cf kernel: 3.2.67 -> 3.2.68 2015-03-08 15:28:11 -07:00
William A. Kennington III
d9ce51d8f7 kernel: 3.18.8 -> 3.18.9 2015-03-08 15:27:30 -07:00
William A. Kennington III
5e23a2fed8 kernel: 3.14.34 -> 3.14.35 2015-03-08 15:26:27 -07:00
Domen Kožar
9e72a07066 fix #6548
(cherry picked from commit 0fd3db4ba1)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-03-07 22:32:13 +01:00
Domen Kožar
04be36e000 gevent: update Python 2.7.9 compatibility patch
(cherry picked from commit 0e0bc3ac86)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-03-07 22:32:07 +01:00
Vladimír Čunát
2635bde9ee libav*.tools: remove overlapping paths, fixes #6682
(cherry picked from commit cdd00f47fa)
2015-03-06 12:55:46 +01:00
Ricardo M. Correia
aba9ff9a11 firefox: Update from 36.0 -> 36.0.1
(cherry picked from commit 02b91f93c4)
2015-03-06 12:12:31 +01:00
Ricardo M. Correia
4f557ea774 firefox: Fix hash
(cherry picked from commit 1e4287645c)
2015-03-06 12:12:27 +01:00
Eelco Dolstra
77d78cf029 Ensure that the home directory exists even if the user already exists
(cherry picked from commit 16cf3ee9da)
2015-03-05 15:40:21 +01:00
Tom
ef0b35e28d [SECURITY] Update git to 2.1.4
This fixes CVE-2014-9390

http://article.gmane.org/gmane.linux.kernel/1853266
(cherry picked from commit 7800270ae4)
2015-03-05 15:20:15 +01:00
aszlig
5f7d37480d virtualbox: Update to new upstream version 4.3.24.
New maintenance release, changes:

 * VMM: emulation fix for the ENTER instruction under certain
   conditions; fixes Solaris 10 guests (VT-x without unrestricted guest
   execution)
 * VMM: fix for handling NMIs on Linux hosts with X2APIC enabled
 * NAT/NAT Network: fix connection drops when the host's DHCP lease was
   renewed (4.3.22 regression; Windows hosts only)
 * NAT: don't crash on an empty domain list when switching the DNS host
   configuration (4.3.22 regression; Mac OS X hosts only)
 * PXE: re-enable it on Windows hosts (4.3.22 regression; Windows hosts
   only)
 * Shared Folders: fixed a problem with Windows guests (4.3.22
   regression)
 * Audio: improved record quality when using the DirectSound audio
   backend
 * VBoxManage: when executing the controlvm command take care that the
   corresponding VM runtime changes are saved permanently
 * Windows Installer: properly install the 32-bit version of VBoxRes.dll
   on 32-bit hosts
 * Linux hosts / guests: Linux 4.0 fixes
 * OS/2 Additions: fixed mouse integration (4.3.22 regression)
 * X11 Additions: fixed a sporadic failure to deactivate virtual screens

Full changelog with bug IDs can be found at:

https://www.virtualbox.org/wiki/Changelog

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 54a8e13f2a)
2015-03-04 16:20:28 +01:00
Tobias Geerinckx-Rice
064d391bdf virtualbox 4.3.20 -> 4.3.22
(cherry picked from commit 39ff896253)
2015-03-04 16:20:27 +01:00
Eelco Dolstra
f5e00fc080 Add "input" group
This is required by systemd >= 215.

(cherry picked from commit 1002fb6433)

Conflicts:
	nixos/modules/misc/ids.nix
2015-03-04 12:02:36 +01:00
Eelco Dolstra
3d70aa085e Create /dev/nvidia-uvm for CUDA support
(cherry picked from commit a4e0278fcd)
2015-03-04 12:01:54 +01:00
James Cook
e4971bb713 Merge pull request #6627 from falsifian/graphviz_cve-2014-9157_14.12
graphviz: Patch to fix CVE-2014-9157 (release-14.12)
2015-03-03 09:29:20 -08:00
Eelco Dolstra
095d4ea75a linux: Disable CONFIG_DEBUG_STACKOVERFLOW
This got enabled accidentally in
e64e3ad88a.

(cherry picked from commit 584ca36462)
2015-03-03 14:31:36 +01:00
William A. Kennington III
5ff06c63f3 kernel: 3.14.33 -> 3.14.34
(cherry picked from commit 103f9820f6)

Conflicts:
	pkgs/os-specific/linux/kernel/patches.nix
2015-03-03 14:30:48 +01:00
Peter Simons
3ce68399e3 Merge pull request #6643 from falsifian/procmail_cve_2014-3618_14.12
procmail: Patch to fix CVE-2014-3618 (cherry-pick to release-14.12)
2015-03-03 11:23:43 +01:00
James Cook
1db0fe1b9a procmail: Patch to fix CVE-2014-3618.
(Cherry-picked from f7066d4.)
2015-03-02 23:40:46 -08:00
Bjørn Forsman
9a4157580c microscheme: update to latest release (0.9.2)
* Don't "externalize url/rev/sha256 to permit easier override".
  Just override 'src' itself. Then you can get the source from anywhere,
  not just git. I needed to touch this anyway, because I want to use
  fetchzip instead of fetchgit for releases (no need to clone repo).
* Latest release has "make install" improvements, simplifying our
  install.

(cherry picked from commit c47a3b0663)
2015-03-02 21:56:49 +01:00
James Cook
168295e9fe graphviz: Patch to fix CVE-2014-9157.
Cherry-picked from 3688b85.
2015-03-02 00:15:11 -08:00
William A. Kennington III
d5d435fe99 kernel: 3.14.32 -> 3.14.33
(cherry picked from commit 58a04a9359)

Conflicts:
	pkgs/top-level/all-packages.nix
2015-02-28 19:29:49 +01:00
Eelco Dolstra
e9901bcc11 firefox: Update to 36.0
(cherry picked from commit 8196962097)
2015-02-28 19:28:03 +01:00
Eelco Dolstra
3b5941cbfa nss: Update to 3.17.4
(cherry picked from commit 843f21fd6a)
2015-02-28 19:28:00 +01:00
Eelco Dolstra
ec085dc5c0 sqlite: Update to 3.8.7.4
(cherry picked from commit 3facd6b66d)
2015-02-28 19:27:56 +01:00
Eelco Dolstra
40a65c6812 sudo: Fix incorrect runtime path
(cherry picked from commit 9e9e446880)
2015-02-28 19:27:49 +01:00
Eelco Dolstra
9c9da0505f tzdata: Update to 2015a
(cherry picked from commit 586b9d9525)
2015-02-28 19:27:38 +01:00
Eelco Dolstra
842cac1412 Fix "systemctl reload container@"
Fixes #5179.

(cherry picked from commit 22d2fc3657)
2015-02-28 19:27:17 +01:00
Eelco Dolstra
aa6babf188 Disable the cjdns test
The cjdns module uses "import from derivation", which is a bad thing
(it causes building at evaluation time).

(cherry picked from commit 568df3f4a9)
2015-02-28 19:27:07 +01:00
Eelco Dolstra
290d31d3a2 Don't use machinectl to shut down containers
If the host is shutting down, machinectl may fail because it's
bus-activated and D-Bus will be shutting down. So just send a signal
to the leader process directly.

Fixes #6212.

(cherry picked from commit 307064ceb5)
2015-02-28 19:26:54 +01:00
Eelco Dolstra
62d5fad26b fillDiskWithRPMs: Pass --extract-over-symlinks to cpio
http://hydra.nixos.org/build/20003320
(cherry picked from commit 3a31043b43)
2015-02-27 14:00:38 +01:00
Domen Kožar
d961f80ec6 dbus-glib: 0.102 -> 0.104 (fixes nm-applet empty menu)
(cherry picked from commit 83b9a19390)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-02-27 13:01:11 +01:00
Domen Kožar
f5406e6715 openssl: 1.0.1k -> 1.0.1l
(cherry picked from commit 1fb78f8994)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-02-27 13:01:11 +01:00
Bjørn Forsman
45c5af4594 gradle: don't hardcode gradle-launcher-VERSION.jar
Instead, figure out VERSION at build-time. This simplifies using
overrideDerivation (no need to copy and modify installPhase).

Also add a check that the file exists (catch potential failure early).

(cherry picked from commit fc966aead0)

Conflicts:
	pkgs/development/tools/build-managers/gradle/default.nix
2015-02-27 12:10:06 +01:00
Rob Vermaas
2639faa896 Only start fetch-keys for GCE image after ip-up.
(cherry picked from commit 24e0565407)
2015-02-27 10:48:38 +00:00
Vladimír Čunát
1f09b77634 cpio: fix CVE-2015-1197 by Suse patch
(cherry picked from commit f3bf4505a9)
2015-02-26 21:26:04 +01:00
Rob Vermaas
8e54447ccf Backport GCE image from master. 2015-02-26 19:27:24 +00:00
lethalman
39b85c9db0 Merge pull request #6542 from nathanielbaxter/release-14.12
Libvirt security updates
2015-02-26 13:34:29 +01:00
Lluís Batlle i Rossell
b799804d05 Updating gtkwave to 3.3.64
(cherry picked from commit aa188a27a2)
2015-02-26 10:36:28 +01:00
Pascal Wittmann
5555a158e3 cv: update to 0.6
(cherry picked from commit 19a979d9a2)
2015-02-26 10:03:53 +01:00
Bjørn Forsman
e580cb5602 nix-prefetch-git: print commit date (close #6522)
The commit date can be used as a version number in packages that don't
have proper releases.

(cherry picked from commit 06f5651ef5)
2015-02-24 23:03:47 +01:00
Bjørn Forsman
4b67cdf99e xclip: set meta.platforms
(cherry picked from commit 6667e964e9)
2015-02-24 19:37:47 +01:00
lethalman
0902cfe5e9 Merge pull request #6552 from nslqqq/master
Correct NetworkManager documentation
(cherry picked from commit 2fdad12a8d)
2015-02-24 18:43:20 +01:00
Lluís Batlle i Rossell
b8f7da25c7 fix pam (OATH related)
the pam config was wrong.

Issue #6551

(cherry picked from commit b26e939111)
2015-02-24 17:53:38 +01:00
Eelco Dolstra
d5b7382e16 apache-httpd: Update to 2.4.12
CVE-2014-3583, CVE-2014-3581, CVE-2014-8109, CVE-2013-5704.

(cherry picked from commit b1ec8e6c64)
2015-02-24 16:31:07 +01:00
Lluís Batlle i Rossell
d93c6ffa10 Adding ddar, unix de-duplicating archiver. 2015-02-24 12:53:18 +01:00
Nathaniel Baxter
37c5a816d5 pythonPackages.libvirt: fix python executable path 2015-02-24 08:37:09 +11:00
Nathaniel Baxter
8b784ee5cc libvirt: update from 1.2.9 to 1.2.12
libvirt-glib: update from 0.1.9 to 0.2.0
pythonPackages.libvirt: update from 1.2.9 to 1.2.12

Potentially fixes CVE-2014-7823 CVE-2015-0236
2015-02-24 08:34:15 +11:00
Eelco Dolstra
c64c2ff254 samba: Update to 3.6.25, 4.1.17
CVE-2015-0240, CVE-2014-0178

(cherry picked from commit 1dd423e651)
2015-02-23 17:04:52 +01:00
Lluís Batlle i Rossell
a6f1024b1f octave: generate the documentation
I find octave quite unusable, without its help pages. Recently it started to
require gnuplot to generate them (even the text-only).

I also enabled parallel building. A comment from 2012 said about spurious
failures if it were enabled, but I don't know if these happen again. Let's
enable it to see.
2015-02-23 10:21:28 +01:00
Lluís Batlle i Rossell
58a004999b Update xclip to a more recent version (svn)
This can do -target, so it can work with images.
2015-02-22 15:24:57 +01:00
aszlig
5b3383b288 Revert "chromium: remove preferLocalBuild"
This reverts commit 84bd62da0a.

The reason I'm reverting this is that the implications this had on the
IO load of Hydra are fixed by ba0f957d7b.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-02-22 08:38:46 +01:00
aszlig
8a13fb2482 nixos/tests/chromium: Check new userns sandbox.
Since Chromium version 42, we have a new user namespaces sandbox in the
upstream project. It's more integrated so the chrome://sandbox page
reports it as "Namespace Sandbox" instead of SUID sandbox, which we were
re-using (or abusing?) in our patch.

So if either "SUID Sandbox" or "Namespace Sandbox" reports with "Yes",
it's fine on our side.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 9de4caddc1)
2015-02-22 08:03:06 +01:00
aszlig
ba0f957d7b chromium: Split up the source tarball on the fly.
So far we've done the source code split up by using the generic
unpackPhase and copying it all over into the different outputs.

However, this had the problem of generating the I/O load of about three
times the size of the source tree: First at fetchurl of the tarball
(although it's not as much because it's compressed), second at
unpackPhase and third at installPhase.

Now we don't use installPhase anymore and directly unpack into the
output paths, which unfortunately becomes quite a bit more complex
because we need to transform the paths of the tar file on the fly.

I've also tried using GNU Tar's --to-command option to even untar *and*
patch it at the same time, but forking for every single file in the
tarball gets REALLY slow and also gets even more complex than this two
stage approach because you need to make sure that the patch file is
applied correctly, for example for files that don't yet exist but are to
be created by the patch file.

We're using --anchored and --no-wildcards-match-slash here to prevent
accidentally excluding files we don't want to exclude. One example is
something like v8/tools/gyp/v8.gyp.

So the current approach is some compromise between complexity and speed
and should hopefully get rid of the Hydra build timeouts by lowering I/O
load.

See here for examples of builds having this issue:

http://hydra.nixos.org/build/19045023
http://hydra.nixos.org/build/19044973
http://hydra.nixos.org/build/19044968
http://hydra.nixos.org/build/19045019

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit c92dbffeac)
2015-02-22 08:03:06 +01:00
aszlig
02110707f6 chromium: Update all channels to latest versions.
Overview of the updated versions:

stable: 40.0.2214.91 -> 40.0.2214.115
beta:   41.0.2272.16 -> 41.0.2272.64
dev:    41.0.2272.16 -> 42.0.2305.3

Introduces 42.0.2305.3 as the new dev version, which no longer requires
our user namespaces sandbox patch. Thanks to everyone participating in
https://crbug.com/312380 for finally having this upstream.

In the course of supporting the official namespace sandbox (that's what
the user namespace sandbox is called), a few things needed to be fixed
for version 42:

 * Add an updated nix_plugin_paths.patch, because the old
   one tries to patch the path for libpdf, which is now natively included
   in Chromium.

 * Don't copy libpdf.so to libexec path for version 42, it's no longer
   needed as it's completely built-in now.

 * Disable SUID sandbox directly in the source instead of going the easy
   route of passing --disable-setuid-sandbox. The reason is that with
   the command line flag a nasty nagbar will appear.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 0aad4b7ee4)
2015-02-22 08:02:26 +01:00
Vladimír Čunát
949adbbb22 nixos/nvidia: use correct 32-bit legacy libs; refactor
Fixes #6127.
Now we avoid multiple switches among the version possibilities.

(cherry picked from commit a3a467ce77)
2015-02-21 16:36:38 +01:00
Rickard Nilsson
fd4d6c2937 elasticsearch: Update from 1.4.3 to 1.4.4
(cherry picked from commit 0fbe589331)
2015-02-20 23:56:32 +01:00
Rob Vermaas
5ef99d845a elasticsearch: update from 1.4.2 to 1.4.3, potentially fixes CVE-2015-1427
(cherry picked from commit e1f08578aa)
2015-02-20 11:04:21 +00:00
Rickard Nilsson
24c2f95285 elasticsearch: Update from 1.3.4 to 1.4.2
(cherry picked from commit 0dedcdf29d)
2015-02-20 11:04:16 +00:00
Vladimír Čunát
3d2552657c uthash: new package
It's headers only. Newer fontforge needs it.

(cherry picked from commit 9274093a34)
2015-02-19 21:40:33 +01:00
Vladimír Čunát
a21057f8b6 fontforge: large update with large changes implied
- Things didn't work very well before, as libs were only dlopened and
  not found. Fixes #5716.
- Newer releases need autotools to build (and git), leading to some bloat.
- Also, more things are installed by default, increasing the output size.

(cherry picked from commit f9c59ca168)
2015-02-19 20:54:33 +01:00
Eelco Dolstra
efba0f9bc7 nixUnstable: Update
(cherry picked from commit cbab474cea)
2015-02-19 11:20:18 +01:00
Vladimír Čunát
073a4a0a44 poppler-qt4: fix rendering, fixes #6366
The subpixel patches seem to cause trouble in recent versions.

(cherry picked from commit a9e4fc1079)
2015-02-18 21:39:47 +01:00
Eelco Dolstra
72ba458362 nixUnstable: Update to 1.9pre4028_0d1dafa
(cherry picked from commit 038a837f02)
2015-02-18 10:51:02 +01:00
Daniel Peebles
5c125ccbbf Bump nixUnstable build
(cherry picked from commit ea5594679c)
2015-02-18 10:50:59 +01:00
Daniel Peebles
c86cc84a64 Turn nixUnstable back on
(cherry picked from commit 65522d05d4)
2015-02-18 10:50:54 +01:00
Eelco Dolstra
1316755bac Apply upstream fix for Nix on XFS
Fixes #6424.

(cherry picked from commit d6c88eaeb8)
2015-02-18 10:42:47 +01:00
Bjørn Forsman
e5c8bd8f48 speedtest-cli: drop the "python2.7-" name prefix
(cherry picked from commit 9b79a35371)
2015-02-17 20:24:26 +01:00
Bjørn Forsman
cca35eddc8 speedtest-cli: align attrname with pkgname
(cherry picked from commit ea6a9a2281)
2015-02-17 20:24:24 +01:00
Rob Vermaas
2b0b92f8f3 Fixes #6374. Now for real, dohhh.
(cherry picked from commit 8495c101dc)
2015-02-17 13:10:44 +00:00
Rob Vermaas
00bb9cfd5b Fixes #6374.
(cherry picked from commit 1a0e6f0039)
2015-02-17 13:08:43 +00:00
Antoine R. Dumont
8840240db3 Add microscheme derivation
(A Scheme subset for Atmel microcontrollers.)

Use of the actual git HEAD because the actual tarball compiles but
segfault at runtime.

Upload the BLINK.ms sample on arduino board (/dev/ttyACM0):

```sh
$ sudo ./result/bin/microscheme -m UNO -d /dev/ttyACM0 -auc ~/repo/perso/microscheme/examples/BLINK.ms
Microscheme 0.8, (C) Ryan Suchocki
>> Treeshaker: After 4 rounds: 84 globals purged! 22 bytes will be
reserved.
>> 18 lines compiled OK
>> Assembling...
>> Uploading...

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100%
0.00s

avrdude: Device signature = 0x1e950f
avrdude: reading input file
"/home/tony/repo/perso/microscheme/examples/BLINK.hex"
avrdude: writing flash (2080 bytes):

Writing | ################################################## | 100%
0.35s

avrdude: 2080 bytes of flash written

avrdude: safemode: Fuses OK (E:00, H:00, L:00)

avrdude done.  Thank you.

>> Cleaning Up...
>> Finished.
```

(cherry picked from commit 172d78923b)
2015-02-16 23:19:27 +01:00
Antoine R. Dumont
79df9d1dd4 Fix avr-gcc url
New releases have been made and the current one is now an old one.

(cherry picked from commit 9b81fa284f)
2015-02-16 23:19:26 +01:00
James Cook
eea0364f3f Merge pull request #6353 from falsifian/sox_CVE-2014-8145-14.12
sox: cherry-pick for release-14.12: Patches for CVE-2014-8145
2015-02-16 13:39:13 -08:00
Eelco Dolstra
d00116f609 Fix bad licenses on CUDA packages
They were marked as "nonfree" rather than "unfree", causing them to be
allowed with allowUnfree = false.

(cherry picked from commit 2ba9ae0129)
2015-02-16 11:25:42 +01:00
Rob Vermaas
213fe8427c Move amazon option out of amazon-image.nix, needed to make ec2.hvm usable from nixops, without breaking evaluation for other backends. 2015-02-16 09:56:08 +00:00
Eelco Dolstra
3e6cedab0d Provide symlinks to ca-bundle.crt for compat with other distros
There is no "standard" location for the certificate bundle, so many
programs/libraries have various hard-coded default locations that
don't exist on NixOS. To make these more likely to work, provide
some symlinks.

(cherry picked from commit d180a67b4223b35a39defff115723719190e6362)
2015-02-15 19:08:07 +01:00
James Cook
c719e10876 sox: Patches for CVE-2014-8145
Found via RedHat bug 1174792.  It was not clear whether these address a
NULL dereference and a division by zero.

(Cherry-picked from cf11e285997d7c06e546987212a7a2c69f9e08d7.)
2015-02-15 00:18:45 -08:00
James Cook
acfbdf7f91 Merge pull request #6240 from falsifian/ppp_2.4.7_squash-14.12
PPP: Update to 2.4.7.
2015-02-14 21:18:59 -08:00
Lluís Batlle i Rossell
cb3cba54a1 nixos: Adding OATH in pam. 2015-02-15 00:34:00 +01:00
Florian Friesdorf
6ef25caf8a mirrors: move more reliable postgresql mirror up
Picked from #6101.

(cherry picked from commit e82e14ef60)
2015-02-14 10:33:46 +01:00
Lluís Batlle i Rossell
cd417206f9 Updating weka to 3.6.12. 2015-02-13 16:20:22 +01:00
Peter Simons
4043e6b2d6 cabal-install-1.18.0.3: fix build with GHC 7.8.4
Fixes https://github.com/NixOS/nixpkgs/issues/6081.
2015-02-13 15:32:31 +01:00
Rickard Nilsson
b515dada09 vimb: Update from 2.8 to 2.9
(cherry picked from commit da6abad31a)
2015-02-13 15:13:13 +01:00
Ivan Sorokin
0354fe2888 bash-completion: fix bad array subscript error. Closes #6117
(cherry picked from commit 20ab4027da)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-02-12 21:19:47 +01:00
Vladimír Čunát
abfa2b27af p7zip: small update to fix CVE-2015-1038
(cherry picked from commit d3b25752f1)
2015-02-12 20:53:11 +01:00
Vladimír Čunát
f5319bac0c vala-0.26: minor update to fix CVE-2014-8154
@lethalman: it seems strange to me to have the 0.23.* version as
the default, as it's even an unstable release.

(cherry picked from commit 8afa77cb07)
2015-02-12 20:44:12 +01:00
Vladimír Čunát
6aae54021b fix eval (typo)
Notified thanks to Travis.
2015-02-12 20:31:58 +01:00
Vladimír Čunát
30ad3a7306 lyx: maintenance update
(cherry picked from commit 4dfafb8ff7)
2015-02-12 20:23:42 +01:00
Vladimír Čunát
ef0ceb0a88 xorg-server: security+bugfix, including CVE-2015-0255
Tested briefly against 14.12.

(cherry picked from commit cf1550cbbf)
2015-02-12 20:15:52 +01:00
Eelco Dolstra
ff916010ac Fix conflict between fedora-release and generic-release
http://hydra.nixos.org/build/19594340
(cherry picked from commit fa47d347a4)
2015-02-12 17:56:09 +01:00
Eelco Dolstra
1d4319286d Remove tabs
(cherry picked from commit ff37dc6fb6)
2015-02-12 17:56:09 +01:00
Eelco Dolstra
ee1b046a39 fillDiskWithRPMs: Shut up some warnings
(cherry picked from commit da73688e3d)
2015-02-12 17:56:09 +01:00
Eelco Dolstra
d313d5202b Drop tests.installer.grub1 as release critical
This test sometimes fails with

  Kernel panic - not syncing: assertion "i && sym_get_cam_status(cp->cmd) == DID_SOFT_ERROR" failed: file "/tmp/nix-build-linux-3.14.32.drv-0/linux-3.14.32/drivers/scsi/sym53c8xx_2/sym_hipd.c", line 3399

after "sd 2:0:0:0: ABORT operation timed-out."

Since we don't care all that much about GRUB 1 anymore, don't make the
release depend on it.

http://hydra.nixos.org/build/19563197
(cherry picked from commit 1907ca8a2a)
2015-02-12 16:22:33 +01:00
Shea Levy
b14e51d78a Backport pleasant ruby 2015-02-11 12:03:55 -05:00
Bjørn Forsman
baa9878eee nixos/tests/jenkins: increase timeout to 6 minutes
Fixes the test failure, at least on my system.

(cherry picked from commit 7a6af47cca)
2015-02-10 16:52:37 +01:00
Vladimír Čunát
aaddf52c43 linux_3_{10,12,14}: fix upstream regression, fixes #6231
Some modules wouldn't load crc32c dependency due to module renaming.

(cherry picked from commit 57f2d329ac)

Conflicts (simple):
	pkgs/top-level/all-packages.nix
2015-02-10 13:50:05 +01:00
William A. Kennington III
b9d607f4aa kernel: 3.14.31 -> 3.14.32
(cherry picked from commit c4d21cf1c4)
2015-02-10 12:54:11 +01:00
Eelco Dolstra
9e472b6dc6 Add Fedora 21
(cherry picked from commit 3786f08d25)
2015-02-10 11:55:07 +01:00
Vladimír Čunát
65300abfc1 thunderbird: update, and refactor the expression
- use mach for building (the way Mozilla devs use),
- use --disable-debug-symbols to reduce build-time resource consumption

(cherry picked from commit 07966befee)
2015-02-09 12:32:24 +01:00
Eelco Dolstra
98afc992d1 Add options for installing additional root certificates
(cherry picked from commit d2bfb5ceb0)
2015-02-09 11:24:48 +01:00
Domen Kožar
cdfb1e0b58 Merge pull request #6248 from nathanielbaxter/release-14.12
flashplayer: Minor security update to 11.2.202.442
2015-02-09 05:45:34 +01:00
Nathaniel Baxter
9551e74e2c flashplayer: Minor security update to 11.2.202.442 2015-02-09 10:06:13 +11:00
James Cook
58c9dc1e25 PPP: Update to 2.4.7.
Fixes CVE-2014-3158.

Also remove postPatch and postInstall that don't seem to be needed (any
more?).
2015-02-08 12:51:02 -08:00
Lluís Batlle i Rossell
0e860da001 Updating cjdns to 20150207.
Version without memory leaks.
2015-02-08 18:05:45 +01:00
Bjørn Forsman
af261a263c arduino: set meta.platforms and add myself as maintainer
(cherry picked from commit daec5d6f25)
2015-02-07 12:25:54 +01:00
Bjørn Forsman
edac9203f0 arduino: new package (2nd attempt). Close #6159.
[Now without the "stdenv.glibc" reference, which is unavailable on
darwin. It seems the dynamic linker finds libc/libm without it being
explicitly in RPATH, so we can just drop it.]

This commit adds the graphical Arduino IDE, built from the arduino-core
expression.

Also:
  - Add libusb to RPATH for avrdude. Without this, avrdude is broken.
    Possible TODO: replace bundled avrdude with the one from nixpkgs.
  - Use "cp -r ./build/linux/work/*", so example sketeches, the HTML
    reference documentation and the 'arduino' shell script that starts the
    IDE gets included.
  - Make meta.description slightly more generic, to cover both GUI/core
    variants.

(cherry picked from commit e10704335a)
2015-02-07 10:00:26 +01:00
Bjørn Forsman
8e96a53b81 Remove mistakenly committed file 'tags'
The file was added in 8bae32afb5 (update jack2 to version 1.9.10).
2015-02-07 09:58:27 +01:00
Vladimír Čunát
489532cd48 xdg-utils: update from git to fix CVE-2014-9622
Fixes #6193.
Disabling docs generation might be another alternative
to the build-time dependency blowup.

(cherry picked from commit 346c8d7a98)

Conflicts (simple):
	pkgs/tools/X11/xdg-utils/default.nix
2015-02-07 07:38:45 +01:00
cillianderoiste
7cdb8dfd83 Merge pull request #6205 from magnetophon/14.12-jack2v1.9.10
update jack2 to version 1.9.10
2015-02-06 18:38:59 +01:00
Bart Brouns
8bae32afb5 update jack2 to version 1.9.10 2015-02-06 18:16:13 +01:00
Domen Kožar
84bd62da0a chromium: remove preferLocalBuild due to intense IO in VM tests 2015-02-06 12:07:49 +01:00
Domen Kožar
d562614d52 Revert "Disable the chromium tests"
This reverts commit 95101a8876.

See
95101a8876
for discussion
2015-02-06 11:48:14 +01:00
Vladimír Čunát
596cf1b731 ffmpeg-2.2: update (still used by vlc)
(cherry picked from commit 474aeb0b3d)
2015-02-05 11:30:58 +01:00
Thomas Tuegel
e911b1864e fontconfig: stringify dpi correctly
(cherry picked from commit 0fee7a2b21)
2015-02-05 10:13:22 +01:00
Vladimír Čunát
99df1f3e98 kernel-*: updates from master 2015-02-04 21:14:13 +01:00
Domen Kožar
bc73086149 Revert "arduino: new package"
This reverts commit ec0ff0dee4.

Breaks eval. cc @bjornfor
2015-02-04 13:49:53 +01:00
Domen Kožar
bf7ef8a1dd varnish: 3.0.5 -> 3.0.6
(cherry picked from commit 98a480363c)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-02-04 11:54:27 +01:00
Domen Kožar
ff8452d766 Remove Varnish 2.1.5
Last release was in 2010, has vulns CVE-2013-4484, cc @garbas

(cherry picked from commit cb6706c22f)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-02-04 11:54:24 +01:00
Domen Kožar
4fa25ee93a solr: 4.10.2 -> 4.10.3, CVE-2014-3628 2015-02-04 11:48:13 +01:00
Domen Kožar
fe7d32d904 jasper: CVE-2014-8157, CVE-2014-8158, fixes #6114
(cherry picked from commit eaeef0377f)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-02-04 11:38:05 +01:00
Domen Kožar
d5faa39847 unzip: CVE-2014-9636, fixes #6128
(cherry picked from commit d50bfd7515)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-02-04 11:17:44 +01:00
Brendan Long
a7fc60c382 go: Update to version 1.4.1.
Also had to fix the code that was trying to make sure the go-* folders get renamed to just "go".

Resolves #5797

(cherry picked from commit 51902ba32d)
2015-02-04 11:05:32 +01:00
Brendan Long
92374ba137 go: Update to 1.4
(cherry picked from commit 8c3399f4d8)

I leave the main go to 1.3 though, so I could skip many changes from 8c3399.
2015-02-04 11:05:32 +01:00
Bjørn Forsman
ec0ff0dee4 arduino: new package
This commit adds the graphical Arduino IDE, built from the arduino-core
expression.

Also:
  - Add libusb to RPATH for avrdude. Without this, avrdude is broken.
    Possible TODO: replace bundled avrdude with the one from nixpkgs.
  - Use "cp -r ./build/linux/work/*", so example sketeches, the HTML
    reference documentation and the 'arduino' shell script that starts the
    IDE gets included.
  - Make meta.description slightly more generic, to cover both GUI/core
    variants.

(cherry picked from commit ca982158bf)
2015-02-04 07:34:21 +01:00
Bjørn Forsman
cfb2030e63 arduino-core: align attrname with package name
arduino_core => arduino-core. Retain copy of old attrname for backward
compatibility.

(cherry picked from commit 83e3f38593)
2015-02-04 07:34:19 +01:00
Eelco Dolstra
12846214f2 valgrind: Update to 3.10.1
(cherry picked from commit fcd4aa44d5)
2015-02-03 18:11:35 +01:00
Eelco Dolstra
cdb450f94d ntpd: Fork into the background
With -n, ntpd will write log messages to both syslog and stderr, which
is ugly.

(cherry picked from commit b61d4ac6a5)
2015-02-03 10:40:41 +01:00
Eelco Dolstra
16bf47df11 nspr: Update to 4.10.8
(cherry picked from commit 32183b2ea4)
2015-02-03 10:40:31 +01:00
Eelco Dolstra
262d7a4a78 Restrict the length of container names
(cherry picked from commit 378006f0f2)
2015-02-03 10:40:23 +01:00
Edward O'Callaghan
4cd7b0fce5 php: update from 5.4.35 to 5.4.37
Potentially fixes CVE-2014-8142, CVE-2014-9427, CVE-2015-0231, CVE-2015-0232

Signed-off-by: Edward O'Callaghan <eocallaghan@alterapraxis.com>
(cherry picked from commit ed232ef5f8)
2015-02-03 10:40:05 +01:00
Vladimír Čunát
0021ffab7a fix 404 URLs (CC #6105)
Cherry-picked from b9cc04329b and 740c6ae240
2015-02-03 10:12:30 +01:00
Rob Vermaas
61adf9e27f Update node-packages, re-added fetch-bower, to make fetchbower function eval succeed 2015-02-02 14:55:55 +00:00
Bjørn Forsman
65383e531a nixos/tftpd: add option types and fixup descriptions
The first description is a (incorrect) copy/paste from the 'vsftpd'
module, and the second option lacks a 'dot' at the end.

(cherry picked from commit ee52a61e3a)
2015-02-01 16:03:57 +01:00
Bjørn Forsman
c64fd2b1cb spek: new package
spek is an accoustic spectrum analyzer. It helps analyse your audio
files by showing their spectrogram.

http://spek.cc/
(cherry picked from commit b26a6e8a23)
2015-02-01 15:22:15 +01:00
Lluís Batlle i Rossell
cd80d050cb cjdns: updating with bugfix, and readd nodejs tools 2015-01-30 09:25:21 +01:00
Eelco Dolstra
95101a8876 Disable the chromium tests
These are timing out a lot.

http://hydra.nixos.org/build/19179868
2015-01-30 00:57:34 +01:00
Lluís Batlle i Rossell
bdc630e7e9 gpa: using mirror url. 2015-01-29 22:38:06 +01:00
Lluís Batlle i Rossell
24a89c028a Adding GPA, The GNU Privacy Assistant. 2015-01-29 20:28:18 +01:00
Lluís Batlle i Rossell
b99fb2383e Updating gpgme to 1.5.3 2015-01-29 20:27:25 +01:00
Lluís Batlle i Rossell
aeefbe552a Update cjdns to v15 2015-01-29 19:47:40 +01:00
Lluís Batlle i Rossell
56e0562cdb Install more rkflashtools. 2015-01-29 19:47:40 +01:00
Ricardo M. Correia
4a0fa82731 flashplayer: Update from 11.2.202.438 -> 11.2.202.440
(cherry picked from commit f46a6c92c0)
2015-01-29 17:36:13 +01:00
Ricardo M. Correia
e7bfc04769 flashplayer: Update from 11.2.202.429 -> 11.2.202.438
(cherry picked from commit f315b7d74a)
2015-01-29 17:36:07 +01:00
Ricardo M. Correia
2461992fc9 flashplayer: Update from 11.2.202.425 -> 11.2.202.429
(cherry picked from commit 7d1d89e532)
2015-01-29 17:35:58 +01:00
Ricardo M. Correia
51cc523a2a firefox: Update from 35.0 -> 35.0.1
(cherry picked from commit 934ea63e8f)
2015-01-28 13:22:51 +01:00
Eelco Dolstra
1fbf6e4bd9 spotify: Drop more unused dependencies
(cherry picked from commit 6c4d79191c)

Conflicts:
	pkgs/applications/audio/spotify/default.nix
2015-01-27 19:01:07 +01:00
Eelco Dolstra
1a936bebf5 spotify: Drop unused qt4webkit dependency
(cherry picked from commit 836cc2f64d)
2015-01-27 19:00:38 +01:00
Eelco Dolstra
3d5134962d spotify: Install in $out/lib/spotify instead of $out/lib
This prevents nix-env collisions with other packages like Hipchat due
to private copies of libQtWebKit.so.4 and other libraries.

(cherry picked from commit 3ea88fec96)

Conflicts:
	pkgs/applications/audio/spotify/default.nix
2015-01-27 19:00:26 +01:00
Eelco Dolstra
63ced498e4 gdb: Update to 7.8.2
(cherry picked from commit f3ee32559d)
2015-01-27 18:59:32 +01:00
Eelco Dolstra
33152356da nixos-rebuild: Update fallback code to update Nix
(cherry picked from commit 53710c752a)
2015-01-27 18:59:10 +01:00
Eelco Dolstra
a54b75fc45 Remove executable bits from non-executable files
(cherry picked from commit 6f8fad2253)
2015-01-27 18:59:06 +01:00
Domen Kožar
10792c5035 if we abort with too old Nix, hint docs
(cherry picked from commit 1defdb972e)
Signed-off-by: Domen Kožar <domen@dev.si>

Conflicts:
	default.nix
2015-01-27 18:46:16 +01:00
Cillian de Róiste
8cf5faeba6 DISTRHO: remove from 14.12, upstream repo has moved and the build fails
I will debug and fix this in unstable, but probably won't backport the changes
2015-01-27 13:04:06 +01:00
aszlig
b880176921 chromium: Ensure runtime deps for enabled plugins.
We're propagating the plugin flags by importing from another Nix
expression file, which in turn exports the Nix path to the wrapper. This
causes that the store path isn't referenced in the wrapper and the path
isn't recognized by scanning the wrapper script (only those already
referenced at build time are).

So let's add the activated plugins to the buildInputs of the wrapper.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 9343f6f461)
2015-01-26 09:40:10 +01:00
aszlig
5d02f3c1e5 nixos/tests/chromium: Increase VM memory size.
Chromium is quite memory hungry and we frequently get random crashes in
the tests, so let's set it to 1024 MB because new releases of Chromium
most probably won't consume *less* memory.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit eae32fb798)
2015-01-26 09:39:59 +01:00
aszlig
d6916eedf0 chromium: Update all channels to latest versions.
This brings a new stable version 40.0.2214.91 along with a beta update
to version 41.0.2272.16, the dev channel is still stuck at version
41.0.2272.12 and within the next days will jump to version 42.

For this reason, I've done some cheating here and brought the beta
channel in par with the dev channel, because dev is older than beta on
OmahaProxy.

Here's an overview of the channel upgrades:

stable: 39.0.2171.65 -> 40.0.2214.91 [1]
beta:   40.0.2214.10 -> 41.0.2272.16 [1] [2] [3]
dev:    41.0.2224.3  -> 41.0.2272.16 [1] [2] [3]

[1]: We needed to patch in locations of lib{pci,udev}.so, because
     Chromium tries to load them at runtime. For version 41 startup will
     fail if it is unable to load libudev, but it also has the advantage
     that this fixes GPU detection using libpci in the stable version,
     which in turn could fix a few bugs on NixOS.

[2]: The upstream Debian package for the binary plugins now uses XZ
     compression for the enclosed data tarball.

[3]: Chromium 41 needs {shapshot,natives}_blob.bin in order to start up,
     so let's cp it among with the .pak files to avoid adding a
     conditional for version 40.

The release annoucement of the stable channel update can be found here:

http://googlechromereleases.blogspot.de/2015/01/stable-update.html

Note that this release contains 62 security fixes(!) and I'm hereby
apologizing for the delay of this update.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit ced5afc38c even
 though it's a major version upgrade, it simply has too many security
 updates to even *think* about trying to backport them)
2015-01-26 09:37:17 +01:00
aszlig
d566f3009e nixos/manual: Re-add development section.
I think this has been accidentally dropped by a099ca4, at least there is
no reason stated, why it shouldn't be included, so I'm bringing it back.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 6308cba3fa)
2015-01-25 20:18:49 +01:00
Lluís Batlle i Rossell
442148e20a Adding a pgf command line tool. 2015-01-23 16:08:21 +01:00
Lluís Batlle i Rossell
f6856be9ee Making freeimage build and install freeimageplus too.
I need it for the pgf command line tool (next commit)
2015-01-23 16:08:05 +01:00
Lluís Batlle i Rossell
91b63783e1 Updating digikam to 4.6.0 and adding libpgf.
4.6.0 fixes the build with current gcc/glibc, and libpgf was a new requirement.
2015-01-23 10:26:35 +01:00
aszlig
e04d02e404 nixos/rename: Fix merging multiple destinations.
The renaming of options define the original value for the new attribute
path. This works well if there is only *one* target, but if there are
more, we end up recursing into the attribute set of the option
definition itself.

We now check for that within the parent recursion node (we can't check
that from the subnode, because we lack that information about whether
it's defined multiple times) and if the subnode consist entirely of a
list of definitions, we use mkMerge on it.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 127c928c23)
2015-01-23 09:37:35 +01:00
Lluís Batlle i Rossell
c9449172f4 Updating cjdns to protocol version 14
(cherry picked from commit 8dd230aa09)
2015-01-23 09:35:45 +01:00
aszlig
47c741fa60 chromium: Fix userns patch for kernel 3.18.2.
Writing the gid_map is already non-fatal, but the actual sandbox process
still tries to setresgid() to nogroup (usually 65534). This however
fails, because if user namespace sandboxing is present, the namespace
doesn't have CAP_SETGID at this point.

Fortunately, the effective GID is already 65534, so we just need to
check whether the target gid matches and only(!) setresgid() if it
doesn't.

So if someone would run a SUID version of the sandbox, it would still
work nonetheless without a negative impact on security.

Fixes #5730, thanks to @wizeman for reporting and initial debugging.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 536feffc68)
2015-01-23 00:46:51 +01:00
Longrin Wischnewski
545d71a9bb php: make curl wrappers optional
cURL wrappers are experimental and break any application/library
that rely on $http_response_header

(cherry picked from commit 96f4758d09)
2015-01-22 13:04:32 +01:00
Cillian de Róiste
cc6b4f7094 simplescreenrecorder: update from 0.3.2 to 0.3.3
(cherry picked from commit 523644e48903dd488d2fc15003d7a688f6174972)
2015-01-22 12:14:25 +01:00
Cillian de Róiste
f15c535319 SimpleScreenRecorder: 0.3.1 -> 0.3.2
(cherry picked from commit 9a5da8168d)
2015-01-22 12:14:08 +01:00
Eelco Dolstra
dc18915ce8 Fix release notes
(cherry picked from commit f637e27138)
2015-01-21 16:28:08 +01:00
Rickard Nilsson
b018853bdb nginx: Add set-misc-nginx-module
(cherry picked from commit c7c917dfff)
2015-01-21 12:39:32 +01:00
Domen Kožar
f7b68679a5 gevent: fix ssl patch
(cherry picked from commit 5cd76cd85e)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-01-20 22:41:16 +01:00
Kosyrev Serge
d4a7019892 debootstrap: 1.0.64.tar.xz -> 1.0.66.tar.gz (close #5548)
It was 404.
@vcunat: convert URLs to mirror://debian.

(cherry picked from commit bd3f891c1c)
2015-01-20 16:52:03 +01:00
Domen Kožar
676e8d7aa4 eventlet: disable tests, too much of a burden 2015-01-20 13:47:26 +01:00
Lluís Batlle i Rossell
87c637ae15 Updating megatools to 1.9.94.
Fixing the glib network part splice, which wasn't working.

(cherry picked from commit 8aaac406bf)
2015-01-20 12:50:57 +01:00
William A. Kennington III
b7393c939d kernel: 3.14.28 -> 3.14.29
(cherry picked from commit 2c02b7caff)
2015-01-20 12:31:08 +01:00
Rickard Nilsson
337058ce25 new package: httping 2.3.4
(cherry picked from commit b64eeaf727)
2015-01-19 03:54:16 +01:00
Domen Kožar
23a202519c python2.6: add a patch to fix parallel make failure 2015-01-18 19:19:40 +01:00
Domen Kožar
1c489ee2a8 eventlet: increase TEST_TIMEOUT 2015-01-18 19:19:40 +01:00
Michael Raskin
4a056a27b7 Make stumpwm-contrib separately available: StumpWM currently recommends installing it separately and adding to ASDF search path 2015-01-18 20:59:36 +03:00
Bjørn Forsman
3cb749f796 ardour: report correct version number
Even though we build from git tag 3.5.403, `ardour --version` reports
3.5-380-g2f6065b. Fix it.

(Another way to fix this is to clone the whole git repo, preserve the
.git/ directory and add git as buildInput so that Ardour can figure out
all this version info stuff by itself.)

(cherry picked from commit 0e3007ec88)
2015-01-18 15:25:34 +01:00
Bjørn Forsman
ce41de13a6 munin: remove /usr/{bin,sbin}/ references from plugins
Instead, run things out of $PATH.

Fixes errors like these (on NixOS):
  munin-available-plugins/.mysql_slowqueries-wrapped: line 67: /usr/bin/printf: No such file or directory

(Basically, this unbreaks some plugins.)

(cherry picked from commit 412cb5a3a2)
2015-01-18 14:41:15 +01:00
Bjørn Forsman
7ad4af120a taskwarrior: enable bash completion
By adding the missing link between the (already installed) completion
script and $out/etc/bash_completion.d/.

(cherry picked from commit 02458a939a)
2015-01-18 14:15:56 +01:00
Evgeny Egorochkin
5836ed0ea6 kde4: fix silent missing kde-workspace dependencies needed for kfontinst and kfontview 2015-01-18 09:37:55 +02:00
Domen Kožar
a769e87199 fix gevent/eventlet on python 2.7.9, fixes #5782
(cherry picked from commit c611f5837c)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-01-17 14:15:32 +01:00
Eelco Dolstra
916430748c Fix a warning in initrd generation
${pkgs.busybox}/bin and ${pkgs.busybox}/sbin are now the same
directory, so don't copy both.

(cherry picked from commit 7358b8dfda)
2015-01-15 21:08:45 +01:00
Eelco Dolstra
4599bfcc3b nixos-install: Create /root with 700 permission
(cherry picked from commit b9c4569b6b)
2015-01-15 21:08:08 +01:00
Eelco Dolstra
d693d4432f NixOS containers: Create /root with 700 permission
Systemd-nspawn creates /root with 755 permission if it doesn't exist,
which is bad. So we have to create it ourselves before calling
systemd-nspawn.

(cherry picked from commit 3ca275d7ba)
2015-01-15 21:08:07 +01:00
Eelco Dolstra
bc195e2feb Paranoia
(cherry picked from commit efa8fc2b0a)

Conflicts:
	nixos/modules/virtualisation/google-compute-image.nix
2015-01-15 21:06:28 +01:00
Eelco Dolstra
a71ce6abb5 Update Debian to 7.8
(cherry picked from commit 1b1e015e6e)
2015-01-15 14:52:22 +01:00
Eelco Dolstra
68378336a6 test-instrumentation.nix: Prevent calling a pager
(cherry picked from commit 24ce7ff3ea)
2015-01-15 14:52:22 +01:00
Vladimír Čunát
674d33a516 firefox: major bump 34.0.5 -> 35.0
(cherry picked from commit 1072635cf0)
2015-01-14 22:51:20 +01:00
Luca Bruno
314c5e9ac6 nixos-rebuild: use reload-or-restart for dbus. Closes #5767
Now that dbus reload has been moved before restarting units,
the reload may fail if dbus has been stopped before.
The reload-or-restart will reload dbus if it's active,
otherwise start it.
2015-01-14 17:09:29 +01:00
aszlig
d9de59a46b lighttpd: Fix building with magnet support.
Doesn't build with LUA 5.2, so lets explicitly set LUA 5.1 as a
dependency.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit c5354fafce)
2015-01-13 08:38:37 +01:00
Eelco Dolstra
89807d4221 Fix CentOS 6.5 URLs
(cherry picked from commit 02df7cdaa0)
2015-01-12 15:14:55 +01:00
Emery Hemingway
96a481b1d0 cjdns: bump to protocol version 13
(cherry picked from commit 5b8e1be7ba)
2015-01-12 11:33:19 +01:00
Lluís Batlle i Rossell
5da890f725 Porting the jdk hack about the 10-year timezones to icedtea
(Based on 3279579bc4)
2015-01-12 11:04:55 +01:00
Rob Vermaas
65a89fcce7 Use callPackage for nodePackages, to allow easier overriding of node-packages set. 2015-01-12 10:04:38 +01:00
Evgeny Egorochkin
48288fcc34 kde4.calligra: update from 2.8.6 to 2.8.7 2015-01-11 18:21:57 +02:00
Evgeny Egorochkin
0f301bcb1c calligra: fix dependencies, and add several new ones 2015-01-11 17:04:36 +02:00
cillianderoiste
56f0fb3ffb Merge pull request #5691 from magnetophon/faustbugfix
Faust: bugfix for 14.12
2015-01-10 17:24:05 +01:00
Bart Brouns
9c5856496d Faust: bugfix for 14.12
use patchshebangs instead of manual patching
patch .faust2* as well as faust2*
2015-01-10 16:04:51 +01:00
Domen Kožar
70a7d4bd16 openssl: 1.0.1j -> 1.0.1k 2015-01-09 20:21:41 +01:00
Evgeny Egorochkin
d8cda00a10 KDE4: update 4.14.1 to 4.14.3 2015-01-09 18:51:39 +02:00
Bjørn Forsman
82578aec9c graphviz: patch vimdot to lookup 'vim' in $PATH
Without this it tries to run /usr/bin/vim. Patch is already accepted
upstream.

(cherry picked from commit e90d316f19)
2015-01-09 07:12:44 +01:00
Rob Vermaas
3279579bc4 Ugly hack until we can update openjdk. Without this openjdk fails with:
Error: time is more than 10 years from present: 1104530400000

See also:
   http://permalink.gmane.org/gmane.os.netbsd.devel.pkgsrc.user/20888
2015-01-08 22:31:15 +01:00
James Cook
db24035952 unzip: Patch for CVE-2014-81{39,40,41}.
(Cherry-picked from 173f41cf0bc618f0b2c313b1915fee8d8a6d0ee2.)
2015-01-08 11:34:00 -08:00
Bjørn Forsman
a431e3ad3b wireshark: update 1.12.2 -> 1.12.3 (security update)
The following vulnerabilities have been fixed.

- wnpa-sec-2015-01
  The WCCP dissector could crash. (Bug 10720, Bug 10806) CVE-2015-0559,
  CVE-2015-0560

- wnpa-sec-2015-02
  The LPP dissector could crash. (Bug 10773) CVE-2015-0561

- wnpa-sec-2015-03
  The DEC DNA Routing Protocol dissector could crash. (Bug 10724) CVE-2015-0562

- wnpa-sec-2015-04
  The SMTP dissector could crash. (Bug 10823) CVE-2015-0563

- wnpa-sec-2015-05
  Wireshark could crash while decypting TLS/SSL sessions. Discovered by Noam
  Rathaus. CVE-2015-0564

See more at https://www.wireshark.org/docs/relnotes/wireshark-1.12.3.html

(cherry picked from commit 7a1e652130)
2015-01-08 19:46:11 +01:00
Michael Raskin
1e60d1f8ba LibreOffice: install icons
(cherry picked from commit f329eb0137)
2015-01-08 18:20:29 +01:00
Michael Raskin
df3d687a81 LibreOffice: 4.3.3.2->4.3.5.2
(cherry picked from commit d7bc5835c8)
2015-01-08 18:20:28 +01:00
Eelco Dolstra
066758758e Set stricter permissions on /nix/store
The nixbld group doesn't need read permission, it only needs write and
execute permission.
2015-01-08 16:57:34 +01:00
Shea Levy
037af9ffcc Revert "Add amazonka, amazonka-core, amazonka-cloudwatch haskell packages"
Unnecessary change to the haskell packages infrastructure, will move
this to haskellng packages.

This reverts commit a9d8413737.
2015-01-08 09:40:36 -05:00
Peter Simons
8ab68f8f91 Add GHC 7.8.4 and create haskellPackages_ghc784 package set.
(cherry picked from commit 8311973759)
2015-01-08 09:29:44 -05:00
Peter Simons
7e43433012 haskell-configuration-ghc-7.9.x: improve configuration to fix some builds
(cherry picked from commit 197e7672e6)
2015-01-08 09:10:08 -05:00
Peter Simons
805870f1e6 haskell-configuration-common: cosmetic
(cherry picked from commit 0811375a69)
2015-01-08 09:09:39 -05:00
Peter Simons
e500e7c5c8 Say hello to our brand-new Haskell infrastructure.
(cherry picked from commit 54baa53df1)

Trivial conflict

Conflicts:
	pkgs/top-level/all-packages.nix
2015-01-08 09:09:02 -05:00
Domen Kožar
6d99bcdd89 pypy: trivial change to trigger rebuild 2015-01-08 10:52:30 +01:00
Domen Kožar
7a5db26b8a Merge pull request #5617 from flosse/prosody-097
nixpkgs: prosody 0.9.6 -> 0.9.7
2015-01-08 01:52:43 +01:00
Eelco Dolstra
92272d48eb Doh^2 2015-01-07 19:20:10 +01:00
Eelco Dolstra
09ab06f79a Doh 2015-01-07 12:55:07 +01:00
Eelco Dolstra
c839a6beab Revert "php: Update to 5.4.36"
This reverts commit e7d4d39c6e. The
build fails in a chroot because it tries to download a PEAR from the
network:

http://hydra.nixos.org/build/18517333
(cherry picked from commit 37ac9deb3d)
2015-01-07 12:54:06 +01:00
Eelco Dolstra
fc9c486f7b php: Update to 5.4.36
CVE-2014-8142

(cherry picked from commit e7d4d39c6e)
2015-01-07 11:36:47 +01:00
Eelco Dolstra
d39bae9c3e Disable the macvlan test
This test currently fails and blocks NixOS releases.

http://hydra.nixos.org/build/18394742
2015-01-07 11:20:46 +01:00
Markus Kohlhase
6ff4d51ab1 nixpkgs: prosody 0.9.6 -> 0.9.7 2015-01-07 09:47:19 +00:00
Shea Levy
a9d8413737 Add amazonka, amazonka-core, amazonka-cloudwatch haskell packages
Required adding a deep override mechanism to haskell packages

(cherry picked from commit 0f04707953)
2015-01-06 14:45:44 -05:00
Domen Kožar
8be9ba0dbd Merge pull request #5611 from vlstill/14.12-perl-IdleTime
perlPackages: Add X11-IdleTime.
2015-01-06 20:08:42 +01:00
Vladimir Still
708b71cdd5 perlPackages: Add X11-IdleTime. 2015-01-06 19:32:36 +01:00
Domen Kožar
acb34ebdfb document options to nixos-install script
(cherry picked from commit c876f7a25d)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-01-06 14:49:40 +01:00
Eelco Dolstra
86fc464dbd mercurial: Update to 3.2.4
(cherry picked from commit 0b8ac6b791)
2015-01-06 14:29:44 +01:00
Eelco Dolstra
e71b376b49 mercurial: Update to 3.2.2
(cherry picked from commit cb5433b8de)
2015-01-06 14:29:44 +01:00
Karn Kallio
0cc38ae2ed pakcs: advance version 1.11.3 to 1.11.4, also fixing the build.
(cherry picked from commit 19cd862a6d)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-01-06 11:16:26 +01:00
aszlig
5e08d9aa98 chromium: Precompile pycs instead of deleting.
This is more of an attempt rather than a real fix (or maybe it is? let's
see) for the corrupted .pyc files during build. I believe the reason we
get these are likely due to several instances of the Python interpreter
that run in parallel and one of these processes might still be writing
the .pyc file.

So, rather than deleting all .pyc files, we now precompile then in order
to avoid any build process trying to generate any .pyc file.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 597373bbd5)
2015-01-06 10:58:41 +01:00
Eelco Dolstra
af8d8673b1 gdb: Fix manpages
(cherry picked from commit 8af48d9428)
2015-01-06 10:56:59 +01:00
Eelco Dolstra
14f1b057e8 geeqie: Revert to 1.1
Version 1.2 has some relatively critical issues:

  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=762257
  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=765437

Until these are fixed, it's better to stick to 1.1.

(cherry picked from commit fee59b1235)
2015-01-06 10:54:58 +01:00
Peter Simons
fa97e9a861 nixos/modules/services/misc/nix-daemon.nix: document meaning of '0' for the buildCores attribute
(cherry picked from commit ea94a6d653)
2015-01-05 20:05:18 +01:00
Jaka Hudoklin
afbef4ff4d nginx: syslog extension, fix git revision 2015-01-05 14:35:11 +01:00
Rob Vermaas
7f02b1f350 Update dd-agent to 5.1.1 2015-01-05 12:58:04 +01:00
Rob Vermaas
c67204dec2 dd-agent: set SSL_CERT_FILE for dogstatsd. 2015-01-05 12:57:49 +01:00
Rob Vermaas
3e73b5888e Add pythonPackages.ntplib, needed for dd-agent update. 2015-01-05 11:05:22 +01:00
Rob Vermaas
96904915d9 Minor fixes to EC2 image generation script. Set autoresponder, so no interaction is necessary. Write output in a format that can be easily included in ec2-amis.nix of nixops. 2015-01-05 09:34:34 +01:00
Rob Vermaas
bdd3a3bac8 Use nixos-images bucket for GCE images. 2015-01-05 09:32:49 +01:00
Rob Vermaas
42c0bc4b8f Fixes for script that builds and uploads EC2 s3 backed images. Mostly credential related. 2015-01-05 09:32:21 +01:00
Rob Vermaas
98af87cd4a Fix GCE image build. 2015-01-05 09:31:22 +01:00
Domen Kožar
49c0ce1dbf Add Type information into manual and manpages, fixes #4600
(cherry picked from commit d1019c3c54d8c788c91df16cba8b13d4a1c91583)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-01-04 15:41:17 +01:00
Franz Pletz
a2b7bc2841 t1lib: Use metalab mirrors (close #5552)
(cherry picked from commit 261e31c186)
2015-01-03 22:19:02 +01:00
Domen Kožar
65157bfe9d fix manual
(cherry picked from commit 3d7ff07258)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-01-03 16:32:33 +01:00
Peter Simons
5cda741c9f youtube-dl: enable the documentation build
(cherry picked from commit 64cef6eaa7)
2015-01-03 12:30:39 +01:00
Peter Simons
76ecfff019 Switch users of 'pandoc' to the lean version.
(cherry picked from commit 8235e8c544)

Conflicts:
	pkgs/servers/nosql/hyperdex/default.nix
2015-01-03 12:30:39 +01:00
Peter Simons
085bdf876a Add a 'pandoc' variant to the top-level that has no run-time dependencies on GHC or any other Haskell package.
(cherry picked from commit c2b1ff33fe)
2015-01-03 12:30:39 +01:00
Domen Kožar
35d4d87625 clarify things about hashed passwords and mutableUsers
(cherry picked from commit 1f523bb23d)
Signed-off-by: Domen Kožar <domen@dev.si>
2015-01-03 11:54:57 +01:00
Domen Kožar
cb58784fb9 k3b: 2.0.2 -> 2.0.3 2015-01-03 11:54:57 +01:00
Bjørn Forsman
6bce6bb452 attic: add missing dependency on 'llfuse'
Without this one cannot mount the backup repository:

 $ attic mount /backups/backup.attic mnt
 attic: the "llfuse" module is required to use this feature
 attic: Exiting with failure status due to previous errors

(cherry picked from commit ca9d370f56)
2015-01-02 15:19:48 +01:00
Bjørn Forsman
967867d6d7 python-llfuse: new package
Python bindings for the low-level FUSE API. (Needed by attic, the backup
program.)

(cherry picked from commit b8e860682b)
2015-01-02 15:19:46 +01:00
Bjørn Forsman
739bf38b49 attic: new package
attic is a deduplication backup program.

This commit is a cherry-pick + squash of the following commits from the
master branch:

1a79e7ffdc attic: fetchurl -> fetchzip
bee4a4e5dc attic: fix sha256
ec5e916f6f attic: add maintainer and platforms
1fde0738ca attic: fix missing modules at runtime
4a0aff5f3b attic: upgrade to 0.14
a8af7f16ce attic: expression cleanup
110333abd3 attic: fix path to OPENSSL headers.
6dc9ea2a2c Package attic-backup.org
2015-01-02 14:09:21 +01:00
Bjørn Forsman
ab138b4d2e libsigrok: install missing firmware files
Without this, hardware that requires firmware (e.g. Saleae Logic) is
unuseable.

Example error that this fixes:

  sr: ezusb: Unable to open firmware file /nix/store/rqgppsz3gwy8jailflf3049fzyzrgkdb-libsigrok-0.3.0/share/sigrok-firmware/fx2lafw-saleae-logic.fw for reading: No such file or directory
  sr: fx2lafw: Firmware upload failed for device 0.

(cherry picked from commit e4dd2dcad4)
2015-01-01 20:06:39 +01:00
Bjørn Forsman
7196511abc eclipse: add webkit as dependency
This makes the Eclipse internal web browser work.

The internal web browser is the default browser, and Eclipse requires
manual configuration for any other (external) web browser. To me this
means the internal browser should be working by default, unless users
will get an error popup if they click any links.

This change increases the closure size from 714 to 880 MiB
(attribute eclipses.eclipse_cpp_43).

(cherry picked from commit f364e3f8e8)
2015-01-01 13:41:19 +01:00
Vladimír Čunát
d6d7876cfb handbrake: fix download URL
(cherry picked from commit 04d410cc4d)
2015-01-01 10:15:33 +01:00
Eelco Dolstra
8a998cac50 Tweak
(cherry picked from commit c2af4f3ea8)
2015-01-01 00:55:56 +01:00
Lluís Batlle i Rossell
013705113b Fix gltron. Sinterklaas present for iElectric. 2014-12-31 10:51:39 +01:00
aszlig
814dcbea10 nixos/release-notes: Fix typo in VirtualBox notes.
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit d137ff33e2)
2014-12-30 23:43:24 +01:00
Eelco Dolstra
d940c7b4a8 pstack: Remove
It doesn't work anymore. And anyway, this probably shouldn't have been
a package in the first place (it's just some gdb options).

(cherry picked from commit 4a63787b78)
2014-12-30 22:41:46 +01:00
Eelco Dolstra
35c15d6e96 blender: Add OpenCOLLADA support
(cherry picked from commit 49f53f63f5)
2014-12-30 22:41:38 +01:00
Eelco Dolstra
a750cf4e02 Document small channels
(cherry picked from commit 3370ee6a13)
2014-12-30 22:41:23 +01:00
Eelco Dolstra
e137ebd5bd Release notes tweak
(cherry picked from commit cf1d9ed317)
2014-12-30 22:41:19 +01:00
Eelco Dolstra
9bc67924f0 Sort stuff
(cherry picked from commit 4df1ca0875)
2014-12-30 22:41:15 +01:00
Eelco Dolstra
9a27eac6a2 Disambiguate util-linux package names
(cherry picked from commit 035e502b5b)
2014-12-30 22:41:09 +01:00
Eelco Dolstra
8775f104f5 Create AMIs in the lb-nixos account
(cherry picked from commit 512d788a68)
2014-12-30 22:41:06 +01:00
Eelco Dolstra
6126aadbe9 Drop reference to obsolete ControlGroupAttribute option
(cherry picked from commit adf62ba9c1)
2014-12-30 22:41:02 +01:00
Eelco Dolstra
a5a7f5afb7 Release notes
(cherry picked from commit c502369a23)
2014-12-30 22:40:56 +01:00
Eelco Dolstra
c1e6f45dd5 Release date
(cherry picked from commit 5f2d5fcc12)
2014-12-30 22:40:52 +01:00
Damien Cassou
25828fa5bb Add systemd.user.timers
(cherry picked from commit dcc93abe74)
2014-12-30 22:40:01 +01:00
Igor Pashev
25e22678d2 Strongswan: preserve PATH
(cherry picked from commit 17d8029150)
2014-12-30 13:16:13 -05:00
Igor Pashev
9868631cb4 Strongswan: updown script uses ip and iptables utilities
(cherry picked from commit 2b91b9b594)
2014-12-30 13:16:13 -05:00
Igor Pashev
5776334cae Strongswan: use full path to ipsec
This fixes issue:

... charon[6135]: 11[CHD] updown: /bin/sh: ipsec: command not found

(cherry picked from commit 9bbe674927)
2014-12-30 13:16:12 -05:00
Igor Pashev
54aee1152c autoreconf may need gettext
E. g. for AC_LIB_PREFIX

(cherry picked from commit d57927748a)
2014-12-30 13:16:12 -05:00
Bjørn Forsman
a55eb1a8b9 xidel: new package
Command line tool to download and extract data from html/xml page.

http://videlibri.sourceforge.net/xidel.html

(cherry picked from commit 7f06428544)
2014-12-30 14:04:37 +01:00
Domen Kožar
b3f9ef07df Merge pull request #5504 from nckx/cleanups
Fix user-facing typos (mainly in descriptions)
(cherry picked from commit c76fb4c6ba)

Conflicts (skipped fixing missing files):
	nixos/modules/services/monitoring/cadvisor.nix
	nixos/modules/services/networking/tox-bootstrapd.nix
2014-12-30 11:09:02 +01:00
Shea Levy
139ead2b42 Add rubyLibs.redis
(cherry picked from commit 3cf0677087)
2014-12-29 16:27:35 -05:00
Shea Levy
1ac98038cc Add rubyLibs.rabbitmq_manager
(cherry picked from commit 487325a68c)
2014-12-29 16:27:35 -05:00
Shea Levy
6a6a42a2eb Add rubyLibs.newrelic_plugin
(cherry picked from commit a1e0944263)
2014-12-29 16:27:35 -05:00
Shea Levy
09ebd5331f gummiboot-builder.py: run nix with no build-users-group
During install, the bootloader script gets run inside a chroot after the
/etc/group bind-mount is unmounted. Since we're not doing any building,
this should be safe, but really nix should just not care if the group
does not exist when no build is needed.

Fixes #5494

(cherry picked from commit 9245516b46)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-29 13:16:54 +01:00
Lluís Batlle i Rossell
7eda68709e Adding scantailor. 2014-12-29 10:23:00 +01:00
Vladimír Čunát
18270196ce libpng: security update (no CVE yet)
http://www.securitytracker.com/id/1031444
(cherry picked from commit 5d903d850a)
2014-12-28 20:33:22 +01:00
Eelco Dolstra
8f8604d8d4 Fix ntpd
Since the 4.2.8 upgrade, ntpd is broken on NixOS:

  Dec 28 19:06:54 hagbard ntpd[27723]: giving up resolving host 1.nixos.pool.ntp.org: Servname not supported for ai_socktype (-8)

This appears to be because DNS resolution doesn't work in chroots
anymore (due to /etc being missing). So disable chroots for now. It's
probably better to use systemd's containment facilities anyway.

(cherry picked from commit ea9d391bb5)
2014-12-28 20:24:23 +01:00
Eelco Dolstra
f51342c6cf ntp: Don't depend on openssl, don't install docs
(cherry picked from commit 782440310d)
2014-12-28 20:24:23 +01:00
Vladimír Čunát
2b1213cd38 ntp: security update, and use libcrypto
http://support.ntp.org/bin/view/Main/SecurityNotice#Recent_Vulnerabilities

The package would no longer build without libcrypto,
and it wouldn't find it without pkgconfig.
I checked that Debian and Arch do use openssl as a dependency,
so it's probably not so bad a thing to have.

CC maintainer @edolstra.

(cherry picked from commit 0fbc5ddadb)
2014-12-28 20:24:23 +01:00
Marco Maggesi
ed2f05c04d Bumb BLCR 2014-12-28 19:48:32 +01:00
Benno Fünfstück
1d3215304c firefox-wrapper: more gstreamer plugins
The previous commit effaa51 broke some of soundcloud in firefox.
2014-12-28 12:45:06 +01:00
Eduard Bachmakov
bdfa31b4e4 Add photoqt-1.1.0.1
Also, add myself to maintainers.

(cherry picked from commit 5e4a8d9fd8)
2014-12-27 22:15:48 +01:00
Domen Kožar
af8f76c256 network-manager: specify full path to sytemctl binary 2014-12-27 11:52:42 +01:00
Domen Kožar
ea540f8fc6 udiskie: specify correct dependencies for the version bump 2014-12-27 11:52:42 +01:00
tv
4e10afdfc4 journal-mailer: camelCasify attribute name
(cherry picked from commit ce100a5d58)
2014-12-26 10:51:56 -05:00
tv
515d136af5 journal-mailer: add version 0.1.1.0
(cherry picked from commit 7015c61686)
2014-12-26 10:51:55 -05:00
muflax
5e323b44b5 bup: update to 0.26 and adopt it
[Bjørn: use patchShebangs to unbreak chroot build (fixes up references
to /usr/bin/env {python,bash}]

(cherry picked from commit e5480cab83)
2014-12-26 14:11:41 +01:00
muflax
ceb090dd2c par2cmdline: update to 0.6.11 and adopt it
[Bjørn: break overlong longDescription line]

(cherry picked from commit 001f2110bd)
2014-12-26 14:11:39 +01:00
Bjørn Forsman
b7ee71ed19 nixos/munin: add /var/setuid-wrappers to PATH
/var/setuid-wrappers is an extension of the system profile, so it
belongs in PATH for the munin service.

(cherry picked from commit 0a8623d6a9)
2014-12-25 15:44:33 +01:00
Brandon Dimcheff
cd3f849717 squish cups patches all into one statement
(cherry picked from commit 139d7f6e1a)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-24 11:01:47 +01:00
Brandon Dimcheff
ea2977d520 Fix compiled-in /bin/bash in foomatic filters
Foomatic filters contained a 64-char c string hardcoded to /bin/bash.
This caused some filters (at least pdftops) to fail.

I also had to increase the size of the string because nix paths are too
long.

(cherry picked from commit 6a2195c3a5)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-24 11:01:43 +01:00
Vladimír Čunát
116e19f0e9 nvidia_x11: maintenance+security updates
It's supposed to fix GLX problems CVE-2014-8298, see:
http://nvidia.custhelp.com/app/answers/detail/a_id/3610

Tested building all atop 14.12, and running 340.* there.

(cherry picked from commit 5a4feadd58)
2014-12-23 23:38:27 +01:00
Nikolay Amiantov
c67ab57e78 nixos-install: fix -I flag
(cherry picked from commit 22eb0e22d3)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-23 20:41:03 +01:00
Thomas Strobel
5b448a02d4 Update: Enlightenment: 0.19.1 -> 0.19.2
(cherry picked from commit 5c620a998d)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-23 20:41:03 +01:00
Matthias C. M. Troffaes
8e79570fa4 easytag: Fix "Using the 'memory' GSettings backend" (see issue #4415).
(cherry picked from commit 6c9eb020ab)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-23 20:41:02 +01:00
Matthias C. M. Troffaes
64b84d2ac0 shotwell: Fix "Using the 'memory' GSettings backend" (fix suggested by lethalman, see issue #5433).
(cherry picked from commit 1aacda5490)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-23 20:41:02 +01:00
Domen Kožar
c92cd80c4f fix selenium python bindings
(cherry picked from commit 667b97b5c2)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-23 20:41:02 +01:00
Siarhei Zirukin
9487dc19b6 gqrx: update 2.3.0 -> 2.3.2
[Bjørn: use 'gqrx:' commit message prefix]

(cherry picked from commit 3bd2c4dabf)
2014-12-23 10:26:38 +01:00
Luca Bruno
e3986e3a7a nixos: Add -verbose to xserverArgs example 2014-12-22 22:13:51 +01:00
lethalman
cdbc7b82c5 Merge pull request #5346 from svenkeidel/disable-xserver-verbose-logging
disable verbose logging for XServer, fixes #4333
2014-12-22 22:13:39 +01:00
Shea Levy
a2c14143e9 Add newrelic-sysmond
(cherry picked from commit 4e558732e7)
2014-12-22 15:13:18 -05:00
James Cook
163ccb886c jasper: Patch for CVE-2014-8138 via RedHat.
(Cherry-picked from commit 1b5c9c24dea9d5241f4a46a471d77d185b31b524.)
2014-12-22 08:21:11 -08:00
James Cook
c3902e944e jasper: Patch for CVE-2014-8137 via RedHat.
(Cherry-picked from commit 951ac10ae15bf53ea919802a8c3570518f34d86b.)
2014-12-22 08:20:51 -08:00
James Cook
95dae8ecbc jasper: Patch for CVE-2014-9029 via RedHat.
Also update homepage.

(Cherry-picked from commit 90162e7dbd5b96f04e277e6d208c9a9940d818a9.)
2014-12-22 08:20:37 -08:00
Emery Hemingway
986dfe1545 transmission-remote-gtk: meta fixup (close #5420)
(cherry picked from commit 86213a1f23)
2014-12-21 10:35:59 +01:00
Vladimír Čunát
80dbe035f3 libssh: security+maintenance to fix CVE-2014-8132
Also switched to openssl instead of libgcrypt (wouldn't compile otherwise),
and fixed meta.license.

(cherry picked from commit 7357f0ae24)
2014-12-20 14:51:23 +01:00
Vladimír Čunát
dabd851726 kde4.kmplayer: use gentoo mirror (fixes #5407)
The upstream server is down.

(cherry picked from commit ca850deb9e)
2014-12-20 10:34:54 +01:00
Domen Kožar
42b2c1f3cf crashplan: install desktop file 2014-12-19 23:25:27 +01:00
Eelco Dolstra
479d937e8a systemd: Apply upstream fixes
In particular, upstream commit 3072eecf3c714e3ed88c882623c40aca15445f64
fixes 15-character network interface names (as generated by ID_NET_NAME_MAC).

(cherry picked from commit e47ed98f9b)
2014-12-19 16:08:50 +01:00
Shea Levy
36202621ea systemd: read units from /etc/systemd-mutable
This allows for persistent units managed outside of configuration.nix

(cherry picked from commit e3825b47ec)
2014-12-19 16:08:50 +01:00
Matej Cotman
e626576c2e vlc: change url
(cherry picked from commit eebc60d7f9)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-19 15:49:49 +01:00
Mathijs Kwik
47e863666a virtualisation.qemuNetworkingOptions -> virtualisation.qemu.networkingOptions
(cherry picked from commit 6e728a42ec)
2014-12-19 13:49:46 +01:00
Mathijs Kwik
787f5a16dd nixos/qemu-vm: make networking options configurable
(cherry picked from commit 6cdacdd4a2)
2014-12-19 13:49:46 +01:00
Eelco Dolstra
2f11c9a189 Shut up a warning from udev
Issue #5260.

(cherry picked from commit 3d834a464ad63c8a4a4aa869fb1869fef1734702)
2014-12-19 13:07:56 +01:00
Eelco Dolstra
28c95385dd ssh-agent: Don't have a timeout by default
IMHO, having a short timeout (1h) defeats the point of using
ssh-agent, which is not to have to retype passphrases all the time. Of
course, users who want timeouts can set programs.ssh.agentTimeout.

This restores the 14.04 behaviour.

(cherry picked from commit 63c14e259d)
2014-12-19 13:03:24 +01:00
Bjørn Forsman
e4ecddcf3b gdmap: set meta attributes (license, platforms, maintainers)
(cherry picked from commit 4b65f53652)
2014-12-19 08:01:45 +01:00
Evgeny Egorochkin
6dc110ff00 resurrect torsocks-faster 2014-12-19 08:09:48 +02:00
Evgeny Egorochkin
44fd836210 rename torify to tsocks, to avoid name clashes and make it clear which wrapper library is used 2014-12-19 08:09:35 +02:00
Evgeny Egorochkin
c37a9adc09 torsocks: enable by default if tor client functionality is enabled 2014-12-19 08:09:26 +02:00
Evgeny Egorochkin
5dcfeeceef tor: restore the Privoxy setup, but configure the system Privoxy instead of running a separate instance. 2014-12-19 08:09:16 +02:00
Evgeny Egorochkin
d946826b25 tor: restore strong circuit isolation 2014-12-19 08:08:57 +02:00
Evgeny Egorochkin
5cd8ecd8ba Revert "nixos: Remove torify module"
tsocks is still useful because it's less strict

This reverts commit 1b26faeb69.
2014-12-19 08:08:43 +02:00
aszlig
336d6a6dca picard: Fix derivation name.
Name has been changed in c9282c65f4.

Users would probably expect "nix-env -i picard" to work, and as picard
isn't a library it doesn't make sense to set a prefix.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 718666204a)
2014-12-18 23:21:20 +01:00
aszlig
b414d9df79 nixos: Add VBox hardening to 14.12 release notes.
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit efb2b27a8f)
2014-12-18 23:00:58 +01:00
aszlig
54c826c980 nixos/virtualbox: Revert disable hardening.
This reverts commit 5d67b17901.

The issues have been resolved by ac603e208c.

Tested this with hostonlyifs and USB support with extension pack.

Conflicts:
	nixos/modules/programs/virtualbox-host.nix

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Tested-by: Mateusz Kowalczyk <fuuzetsu@fuuzetsu.co.uk>
Tested-by: tv <tv@shackspace.de>
Tested-by: Domen Kožar <domen@dev.si>
(cherry picked from commit f7384b8c75)
2014-12-18 22:43:59 +01:00
aszlig
11925d64aa nixos/tests/virtualbox: Disable debug logging.
Especially if the user isn't in the vboxusers group anymore, this gets
VERY noisy, because the VBoxSVC process emits warnings for every single
USB device noting that it's only possible to access it when the user is
in the vboxusers group.

So, we now have a debug attribute, where we can enable it when
necessary.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit d45649b415)
2014-12-18 22:43:35 +01:00
aszlig
7697962a28 nixos/tests/virtualbox: Don't use vboxusers group.
At least when we're running in hardening mode, because it's needed there
only for USB support.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit ef691d5c30)
2014-12-18 22:43:35 +01:00
aszlig
e91cd4e5c2 virtualbox: Fix runtime paths in hardening mode.
Because we have to rely on setuid wrappers on NixOS, we can't easily
hardcode the executable paths and set it 4755. So for all calls, we need
to change the runtime path executable directory to /var/setuid-wrappers/
and for verification we need to retain the executable directory.

Also note, that usually VBoxNetAdpCtl, VBoxNetDHCP, VBoxNetNAT, VBoxSDL
and VBoxVolInfo don't reside in directories that are commonly in PATH,
but in /usr/lib/virtualbox in most mainstream distros. But because the
names of these executables are distinctive enough to not cause
collisions with other setuid programs, I'll leave it like that and not
patch up setuid-wrappers.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit ac603e208c)
2014-12-18 22:43:34 +01:00
aszlig
20d02244ce virtualbox: Allow to easily change the build type.
Not really changes anything in functionality, but makes it easier to
change the build type to "debug", for example.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit b69ac6c159)
2014-12-18 22:43:34 +01:00
aszlig
6c4d5f7e4d virtualbox: Fix hardcoded /sbin/ifconfig path.
Just accidentally found this while debugging and it's needed for
fetching a few interface details, not sure however whether because of
this anything has been broken so far.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 14ef3446e1)
2014-12-18 22:43:33 +01:00
aszlig
90c6ae5e43 virtualbox: Explicitly excempt src during install.
Instead of coping it to $out and later deleting it, we now exclude the
src directory during copy. Also, we no longer cd into the release
directory during installPhase, which should make sure that we are
constantly in $sourceRoot.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 5a8c5d2768)
2014-12-18 22:43:16 +01:00
Vladimír Čunát
3865ab9e69 nixos/doc release notes: mention intel GPU driver 2014-12-18 19:03:05 +01:00
Sebastián Bernardo Galkin
9ec8d3e0ac xorg-server: enable DRI3 (close #5381)
TEST needed. I tested on my NixOS Thinkpad with Optimus nvidia and intel
cards.  Testing in other architectures is needed.

This patch also improves the regular expressions that scan the build
configuration files to enable the building of a binary utility in
xf86-video-intel: intel-virtual-output. This utility is useful for some
Optimus laptops

DRI3 was added to xorg-server propagatedBuildInputs so now it's inherited
by several projects that can use it.

(cherry picked from commit 06e6d7def2)
2014-12-18 19:03:05 +01:00
Eelco Dolstra
b57ea539c6 Fix container test
http://hydra.nixos.org/build/17989795
(cherry picked from commit bf0f2adbeb)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-18 15:57:38 +01:00
Rob Vermaas
597007f8b7 Fix sysstat build. 2014-12-18 14:47:00 +01:00
aszlig
876b0828fc nixos/tests/blivet: Fix by avoiding "nix-store".
The "nix-store" command within the VM test is running without
NIX_REMOTE=daemon and since Nix 1.8 tries to open the store database in
read-write mode even for nix-store -qR.

Now, we're doing this properly and rely on setup hooks, which is the
same method that's used when you're building a library which depends on
blivet.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 2af435b5cd)
2014-12-18 14:12:41 +01:00
William A. Kennington III
a287614ecb kernel: 3.14.26 -> 3.14.27
(cherry picked from commit 7e8c5b578a)
2014-12-18 14:07:02 +01:00
Eelco Dolstra
142e9a9d06 sudo: Update to 1.8.11p2
(cherry picked from commit 6866712a39)
2014-12-18 12:58:42 +01:00
Eelco Dolstra
e928eeb1fd Improve /etc/sudoers message
(cherry picked from commit 89697b0fc1)
2014-12-18 12:58:34 +01:00
Domen Kožar
8566f66ea4 release notes: reindent, remove renames (redudant) 2014-12-18 12:21:45 +01:00
Domen Kožar
9bc8bcbbdc fix users.mutableUsers = false; install in iso 2014-12-18 12:18:24 +01:00
Domen Kožar
0d4acad489 crashplan: fix CrashPlanDesktop binary 2014-12-18 10:12:37 +01:00
Domen Kožar
827a9bbd44 ulex: set platforms 2014-12-18 10:01:32 +01:00
宋文武
66087ead07 jenkins: update to 1.594
(cherry picked from commit f40a613577)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-18 09:59:23 +01:00
Domen Kožar
b0a0fb60df dropbox: 2.0.0 -> 2.2.0, disable tests 2014-12-18 09:22:29 +01:00
Domen Kožar
33e9a0503a update release notes 2014-12-18 02:00:49 +01:00
Eelco Dolstra
9e06a26471 switch-to-configuration: Ignore slice units
(cherry picked from commit c812e45292)
2014-12-18 01:47:54 +01:00
William A. Kennington III
8f71e04e9f btrfs-progs: 3.17.2 -> 3.17.3
(cherry picked from commit 0cfd61bdea)
2014-12-18 00:40:38 +01:00
William A. Kennington III
990b5a1b3e xfsprogs: 3.2.1 -> 3.2.2
(cherry picked from commit 02f75f91f1)
2014-12-18 00:40:29 +01:00
Domen Kožar
692f5958e3 remove btrfsProgs-3_16, not needed anymore
(cherry picked from commit 9de5eb6ade)
2014-12-18 00:40:20 +01:00
William A. Kennington III
ffb104750d kernel: Remove 3.16
(cherry picked from commit 4b73212241)
2014-12-18 00:38:52 +01:00
William A. Kennington III
30e74be80f kernel: 3.14.26 -> 3.14.27
(cherry picked from commit 4eaecca7b1)
2014-12-18 00:38:37 +01:00
Eelco Dolstra
ec539dc8ff Revert "enable bash autocomplete by default"
This reverts commit ee8e15fe76. See
discussion at ee8e15fe76.

(cherry picked from commit bde9ae18cf)
2014-12-18 00:37:45 +01:00
Eelco Dolstra
6038215e9c Remove udev from /run/opengl-drivers
/run/opengl-drivers should contain only libGL-related libraries, not
stuff like udev. Injecting anything into LD_LIBRARY_PATH is dangerous
because it can break applications that expect a different version of
the library.

Caused by eef9a8ac2a. Fixes #5371.

(cherry picked from commit d34c600414)
2014-12-18 00:26:25 +01:00
Domen Kožar
44ed738567 skrooge: add boost dependency
(cherry picked from commit 179c7344cc)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-17 20:14:08 +01:00
vi
dc23b0ee8f Added mirrors for MySQL.
(cherry picked from commit 0c49b2942e)
2014-12-17 11:13:30 -05:00
Domen Kožar
5bafb9cf0f nixos/tests/gitlab.nix: set TimeoutStartSec to 10min 2014-12-17 16:40:26 +01:00
Rob Vermaas
b2d5e79e6d icecast: update from 2.4.0 to 2.4.1, potentially fixes CVE-2014-9018
(cherry picked from commit f72c7e93ce)
2014-12-17 15:51:19 +01:00
Rob Vermaas
8e527b5ef8 nodejs: update from 0.10.32 to 0.10.33, potentially fixes CVE-2014-7192
(cherry picked from commit 81f6af4a54)
2014-12-17 15:51:14 +01:00
Rob Vermaas
f41c34529f docker: update from 1.3.1 to 1.3.3, potentially fixes CVE-2014-6407, CVE-2014-6408
(cherry picked from commit 90c3dc79c5)
2014-12-17 15:51:10 +01:00
Mathijs Kwik
40b9186d58 nixos: allow adding extra modules through environment
This is useful for adding extra functionality or defaults to _every_
nixos evaluation.

My use case is overriding behaviour for all nixos tests, for example
setting packageOverrides to newer versions and changing some default
dependencies/settings.

By making this accessible through an environment variable, this can now
be fully accomplished externally. No more need to fork
nixos/nixpkgs (which becomes a maintenance burden), just use the channel
instead and plug in via this envvar.

(cherry picked from commit 73f18fd42f)
2014-12-17 09:52:59 +01:00
Vladimír Čunát
0dbc415e9d ffmpeg_2_3: use 2.2 instead of 2.3
2.3 branch is unmaintained and was critically vulnerable (I thank to monitor).

(cherry picked from commit 304484a753)
2014-12-16 21:34:06 +01:00
Eelco Dolstra
087e6895c9 cups: Build with SERVERROOT set to /etc/cups
(cherry picked from commit be0e73b938)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-16 21:04:48 +01:00
Eelco Dolstra
ca042d2c18 cups: Get rid of obsolete banners
These use bannertops, which no longer exists. And they conflicted with
the working banners in cups-filters.

(cherry picked from commit ffdabf02b9)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-16 21:04:48 +01:00
Eelco Dolstra
eb375fdec3 cupsd.nix: Clean up environment.etc
(cherry picked from commit dc6c8b9714)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-16 21:04:48 +01:00
Eelco Dolstra
e6fe8a3fd0 cups-filters: Fix gstoraster
It was trying to find "gs" via execve, so use execvpe instead. It's
probably better to use gs's absolute path, but maybe not every
cups-filters user needs it.

(cherry picked from commit fb079432b0)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-16 21:04:48 +01:00
Eelco Dolstra
2928e8d8f2 cups-filters: Fix finding GS in several filters
(cherry picked from commit 6c00d9f7e4)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-16 21:04:47 +01:00
Eelco Dolstra
c981a89bce cups-filters: Fix banners
It was looking in cups' prefix for the PDF templates. So for instance
printing a CUPS test page wouldn't work.

(cherry picked from commit 0aa452e179)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-16 21:04:47 +01:00
tv@shackspace.de
b0a2c6281a nixos/cupsd: use cups-files.conf
(cherry picked from commit b71f3c4315)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-16 21:04:47 +01:00
Vladimír Čunát
4a261914e6 xorg-server: security update to RC1 of 1.16.3
Close #5292. There are almost no other changes since 1.16.2
than fixing that CVE-2014-8092. See also:
http://www.x.org/wiki/Development/Security/Advisory-2014-12-09/

(cherry picked from commit 84d6debf46)
2014-12-16 19:29:06 +01:00
Domen Kožar
118fd6f526 pypy: disable whole ssl test suit instead of a single test 2014-12-16 17:11:34 +01:00
Bjørn Forsman
5a3b1a4d40 virt-viewer: fix missing schema error
Fixes this error, as seen when trying to open a guest VM when
virt-viewer is accessed over ssh with X forwarding:

  GLib-GIO-ERROR **: Settings schema 'org.gnome.system.proxy' is not installed

A similar issue was fixed for virt-manager in commit
fb8a2b3be7 ("virt-manager: fix missing
schema error")

(cherry picked from commit a2bb84a936)
2014-12-16 14:09:15 +01:00
Eelco Dolstra
9ad2b0988b Document screen incompatibility
(cherry picked from commit 997531d172)
2014-12-16 11:28:34 +01:00
Peter Simons
839bf37647 nixos/doc/manual/release-notes/rl-1412.xml: document change of default time zone
https://github.com/NixOS/nixpkgs/pull/5332
(cherry picked from commit 60f21f983f)
2014-12-16 11:28:29 +01:00
Eelco Dolstra
0bbe723191 php-5.3: Remove
PHP 5.3 is EOL (see http://php.net/supported-versions.php). NixOS
14.12 is a good opportunity to drop it.

(cherry picked from commit 4d918cb6c7)
2014-12-16 11:28:22 +01:00
Eelco Dolstra
df6daae1f8 Rename release notes
(cherry picked from commit df1f751f03)
2014-12-16 11:28:14 +01:00
Eelco Dolstra
aafb7aee1b virtualbox: Get tid of runtime dependency on linux.dev
(cherry picked from commit d9ce3ae57f)
2014-12-16 11:27:11 +01:00
Eelco Dolstra
237f9fc866 kdepimlibs: Get rid of a dependency on boost.dev
(cherry picked from commit 0e8373143e)
2014-12-16 11:27:11 +01:00
aszlig
d3c277710e virtualbox: Fix extension pack without hardening.
We divert to the $out/share/virtualbox directory only if we have
hardening enabled, so let's put the extension pack into
$out/libexec/virtualbox instead if we're compiling without hardening.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit eb561f0798)
2014-12-16 11:25:39 +01:00
aszlig
40e3672258 nixos/virtualbox: Fix warning on enableHardening.
The warning was displayed whenever services.virtualboxHost.enable was
true, but if people were to enable hardening, they'd still get that
annoying message.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit e36bec661c)
2014-12-16 11:25:38 +01:00
Bjørn Forsman
b43e2c752b virt-viewer: fix SPICE support
* Add missing dependency on 'spice_protocol'

* Fix new build error which came now that ./configure enables SPICE support:

  building virt-viewer
    CCLD     virt-viewer
  /nix/store/b8qhjrwf8sf9ggkjxqqav7f1m6w83bh0-binutils-2.23.1/bin/ld: cannot find -lgdbm
  /nix/store/b8qhjrwf8sf9ggkjxqqav7f1m6w83bh0-binutils-2.23.1/bin/ld: cannot find -lcap
  collect2: error: ld returned 1 exit status

  Fix by adding gddbm and libcap as inputs. Yes, libcap is needed
  _in addition_ to libcap_ng (I tested removing libcap_ng, it failed).

Without this change, virt-viewer cannot be used with guests machines
that uses SPICE.

(cherry picked from commit 477bc03568)
2014-12-16 10:51:39 +01:00
Bjørn Forsman
9e678dde06 avr8-burn-omat: update to version 2.1.2
* Update homepage / download url
* Set meta.platforms (= all)

(cherry picked from commit 39dc905310)
2014-12-15 22:32:48 +01:00
aszlig
000c24a43f nixos/tests/virtualbox: Improve logging.
This also makes showvminfo obsolete, as we get the same information from
the hosts log.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 8bbf1dc80e)
2014-12-15 19:19:45 +01:00
aszlig
0a5535ffd6 nixos/virtualbox/hostonlyif: Fix writing to /root.
Creates unnecessary cruft in the root users home directory, which we
really don't need. Except the log, but therefore we now cat the log to
stderr and the private temporary directory is cleaned up afterwards.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit d85fabd68c)
2014-12-15 19:19:44 +01:00
aszlig
c141582aaf nixos/virtualbox: Disable hardening for now.
This should display a big fat warning that people can hardly miss until
we have fixed the issues with the host-only-interfaces that persist when
hardining is enabled.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 5d67b17901)
2014-12-15 18:54:56 +01:00
aszlig
8fbe48804f nixos/tests/virtualbox: Add test for hostonlyif.
Essentially adds two more VirtualBox VMs to the test and also increases
the memory size of the qemu VM to 768 MB to make sure we don't run out
of memory too soon.

We're testing whether those two VMs can talk to either each other
(currently via ICMP only) or to/from the host via TCP/IP.

Also, this restructures the VM test a bit, so that we now pass in a
custom stage2Init script that has access to the store via a private
mount over the /nix/store that's already in the initrd. The reason why
this is a private mount is that we don't want to shadow the Nix store of
the initrd, essentially breaking cleanup functionality after the custom
stage 2 script (currently this is only "poweroff -f").

Note that setting the hostname inside the VirtualBox VM is *not* for
additional fanciness but to produce a different store path for the VM
image, so that VirtualBox doesn't bail out when trying to use an image
which is already attached to another VM.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 9bf16a9c33)
2014-12-15 17:56:45 +01:00
aszlig
d50a7cc5bb nixos/virtualbox: Note about "vboxusers" group.
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 245baeb2f6)
2014-12-15 17:56:45 +01:00
aszlig
6fe6960d19 virtualbox package: Disable hardening by default.
Yes, this is only on the package level, so it's possible to use
VirtualBox for example installed by nix-env -i, which of course doesn't
have access to the functionality provided by the various VirtualBox
kernel modules.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit a199eedfce)
2014-12-15 17:56:45 +01:00
aszlig
23c40d21b9 nixos/virtualbox: Allow to disable hardening.
Hardening mode in VirtualBox is quite restrictive and on some systems it
could make sense to disable hardening mode, especially while we still
have issues with hostonly networking and other issues[TM] we don't know
or haven't tested yet.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit e03e0ff42a)
2014-12-15 17:56:44 +01:00
aszlig
6242e62cd6 nixos/tests/virtualbox: Generalize expression.
We're going to create more than one VirtualBox VM, so let's dynamically
generate subs specific to a particular VirtualBox VM, merging everything
into the testScript and machine expressions.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 77831e8467)
2014-12-15 17:56:44 +01:00
aszlig
9cf63120e8 nixos: Add VM test for VirtualBox.
Currently it pretty much tests starting up virtual machines and just
shutting down afterwards, but for both VBoxManage and the VirtualBox
GUI.

This helps catching errors in hardened mode, however we still need to
test whether networking works the way intended (and I fear that this is
broken at the moment).

The VirtualBox VM is _not_ using hardware virtualization support (thus
we use system = "i686-linux", because x86_64 has no emulation support),
because we're already within a qemu VM, which means it's going to be
slow as hell (that's why I've written own subs just for testing
startup/shutdown/whatnot with respective timeouts).

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 69858d7743)
2014-12-15 17:56:44 +01:00
Thomas Tuegel
87d8deef6c nixos: fix config.fonts.fontconfig.ultimate.allowBitmaps
The option was incorrectly negated, so that 'allowBitmaps = true'
actually disabled bitmap fonts.
2014-12-15 09:18:11 -06:00
Thomas Tuegel
ccce6171e9 fontconfig-ultimate: do not replace terminus or proggy fonts 2014-12-15 09:18:02 -06:00
Rob Vermaas
2b143522c9 cron: make into systemd.service and make it depend on /etc/localtime
so that changes in timezone will trigger a restart of cron service.

(cherry picked from commit b48e41b8d7)
2014-12-15 14:52:27 +01:00
Eelco Dolstra
58bc726d76 strace: Update to 4.9
(cherry picked from commit 1a504e3fb7)
2014-12-15 14:50:15 +01:00
Eelco Dolstra
84cc6a14a9 Fix using Apache httpd 2.2
(cherry picked from commit cfe26e4438)
2014-12-15 14:50:15 +01:00
Domen Kožar
59fa67e5a0 pypy: disable cpickle test..
(cherry picked from commit 5819f29875)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-15 14:18:17 +01:00
Eelco Dolstra
f82ab5981c Fix ANSI escape in warning messages
Seems to have been broken by accident in 7d1ddae58e.
2014-12-15 12:08:31 +01:00
Jaka Hudoklin
ec2a51519d nixos/gitlab: enable tests in release 2014-12-15 00:39:04 +01:00
Vladimír Čunát
8938e6a224 gcc-4.6: bump to 4.6.4
The dropped patch was applied upstream within the update.

(cherry picked from commit 9cdd231ad3)
2014-12-14 22:48:18 +01:00
Thomas Tuegel
e32a0ad78c zotero: use firefox instead of xulrunner to fix i686 build 2014-12-14 13:50:12 -06:00
Shea Levy
44da04f80d nix-exec: use nix stable
(cherry picked from commit e82aed56f9)
2014-12-14 13:11:49 -05:00
Domen Kožar
24cba87e7f libsepol: fix download url 2014-12-14 19:05:26 +01:00
Domen Kožar
1f059cd5a9 python: 2.7.8 -> 2.7.9 2014-12-14 19:05:26 +01:00
Bjørn Forsman
a05c5d6762 libreoffice: fix Exec= in .desktop files
Before we do substitutions, the Exec= line is (currently)
"Exec=libreofficedev4.3 --some-arg". Our substitution logic doesn't handle
that, resulting in broken "Exec=$out/bin/sofficedev4.3 --some-arg"
($out/bin/sofficedev4.3 doesn't exist).

Looking at libreoffice source, the .desktop files refer to a UNIXBASISROOTNAME
variable which come from instsetoo_native/util/openoffice.lst.in. Currently, it
can have one of two values, presumably depending on whether the build is
"normal" or "development":

  libreoffice${major}.${minor}

  libreofficedev${major}.${minor}

Handle both these cases, and also leave the old non-versioned substitution
around, just in case.

Fixes issue #3463.

(cherry picked from commit 64661f0597)
2014-12-14 18:10:54 +01:00
Vladimír Čunát
743157a95f gnat: make it build again (close #5307)
Problems are worked around by using older gcc wrapper for gnat bootstrap.
(from ca441636f1^)

I tried nicer solutions first, but I was unable to fix all problems for hours.

(cherry picked from commit 1a0a161920)
2014-12-14 17:12:41 +01:00
Domen Kožar
fa4e45f20c add chromium test to the tested job 2014-12-14 13:46:48 +01:00
Domen Kožar
fde7e1286e fix quake3 test 2014-12-14 13:34:04 +01:00
Sebastián Bernardo Galkin
a8510482d9 Fix networkmanager resumeCommands
Small typo prevented the post resume script to restart network manager

(cherry picked from commit aba0d8a73d)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-14 13:09:59 +01:00
Domen Kožar
ad4e371acf typo 2014-12-14 11:28:58 +01:00
Domen Kožar
0e37a9fa41 http://nixos.org -> https://nixos.org 2014-12-14 11:26:21 +01:00
Vladimír Čunát
2d600bd184 broadcom_sta: fix build with kernel 3.18 (close #5315)
I couldn't find any source that looked reliable, but I guess it's better
than nothing: it's fairly simple patch that fixes the build.

(cherry picked from commit 274a9419c1)
2014-12-14 10:53:31 +01:00
Eelco Dolstra
b1f8f90e52 nix-repl: Update
(cherry picked from commit bd0d1e836c)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-14 09:51:58 +01:00
Eelco Dolstra
d6373f2ac4 nix: Update to 1.8
(cherry picked from commit e115bdecd8)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-14 09:51:54 +01:00
Eelco Dolstra
cef8e2df7d Add nix-serve
(cherry picked from commit 188c038897)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-14 09:51:48 +01:00
Jaka Hudoklin
97ec11c43b nixos/gitlab: imporove tests 2014-12-14 09:49:50 +01:00
Jaka Hudoklin
5e41ab79f7 gitlab: fix i686-linux build and module
It turns out that installing therubytracer, with dependency on old v8, even
when using source libv8 version is problematic.
(see
http://stackoverflow.com/questions/21666379/problems-installing-gitlab-on-odroid-v8-lib-not-available).

But wait, rails does not even need therubytracer, just any kind of javascript
server side execution framework like nodejs. Well just use that, as also
suggested from different internet sources (look link above), it works just
fine.
2014-12-14 09:49:50 +01:00
Jaka Hudoklin
e048d38d4e nixos/kubernetes: fix test, make more deterministic by having more ram 2014-12-14 02:44:10 +01:00
Mathijs Kwik
a1b77e0f9a ghc-head: upgrade to 2014-12-10
(cherry picked from commit 04f73ed2e4)
2014-12-13 21:18:54 +01:00
Mathijs Kwik
a266855d15 dvdauthor: fix building against glibc 2.20
and 2 other patches from redhat

(cherry picked from commit 9a7d425edd)
2014-12-13 21:18:41 +01:00
Mathijs Kwik
27df8a588f mkvtoolnix: fix to find boost lib
(cherry picked from commit 752554cdcb)
2014-12-13 21:18:34 +01:00
Domen Kožar
94c1406951 fix perl build failures 2014-12-13 16:32:09 +01:00
Domen Kožar
6425765553 lzma-conduit: broken on 32bit linux, see #5313
(cherry picked from commit 4709c950f0)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-13 15:28:35 +01:00
Domen Kožar
b7894032b4 hhvm: use upstream patches to fix the build 2014-12-13 15:22:38 +01:00
aszlig
2460b40331 nixos/virtualbox: Fix setuid wrappers.
We only need to have setuid-root wrappers for VBox{Headless,SDL} and
VirtualBox, otherwise VBoxManage will run as root and NOT drop
privileges!

Fixes #5283.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit 0d71ec8a6e)
2014-12-13 07:52:59 +01:00
Domen Kožar
b1140ab80c Merge pull request #5314 from offlinehacker/teh-gitlab-release-14.12
[14.12] nixos: Add gitlab and gitlab-shell
2014-12-12 19:56:46 +01:00
Domen Kožar
896036d8e5 whitespace change to fix k2pdfopt build 2014-12-12 18:37:50 +01:00
Domen Kožar
23d01bb90c gltron: mark as broken 2014-12-12 18:36:15 +01:00
Jaka Hudoklin
b82803983b nixos/gitlab: fixes
- fix timezone data not found
- fix module, add simple test
- allow to set port
2014-12-12 18:09:08 +01:00
Thomas Hunger
0c95c87758 nixos: Add gitlab and gitlab-shell
I had to make several adjustments to make it work with nixos:

* Replace relative config file lookups with ENV variable.
* Modify gitlab-shell to not clear then environment when running
  pre-receive.
* Modify gitlab-shell to write some environment variables into
  the .authorized_keys file to make sure gitlab-shell reads the
  correct config file.
* Log unicorn output to syslog.
  I tried various ways of adding a syslog package but the bundler would
  not pick them up. Please fix in a better way if possible.
* Gitlab-runner program wrapper.
  This is useful to run e.g. backups etc. with the correct
  environment set up.
2014-12-12 18:09:06 +01:00
Domen Kožar
9d0d9ae9f7 hhvm: 3.2.0 -> 3.3.0, fix build 2014-12-12 17:08:28 +01:00
Domen Kožar
6c406b9425 Merge pull request #5310 from offlinehacker/kubernetes_fleet_rename
[14.12] nixos: move kubernetes & fleet to services/cluster
2014-12-12 15:37:16 +01:00
Jaka Hudoklin
d88567ed08 nixos: move kubernetes & fleet to services/cluster 2014-12-12 14:39:51 +01:00
Michael Raskin
5a104cdcd9 Fix fetchzip for actuall zip files
(cherry picked from commit 9ed097ab50)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-12 13:58:29 +01:00
Michael Raskin
3461855316 Improve eudev paths in the same way as they are set in the original package 2014-12-12 13:58:17 +01:00
Domen Kožar
a9590e474d Merge pull request #5280 from vcunat/p/hibernation
nixos: check resumeDevice is absolute path and document
2014-12-12 11:11:15 +01:00
Massimo Zaniboni
a3ed55b99a redmine: use libc libciconv implementation on Linux.
(cherry picked from commit 32f9644943)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-12 10:48:11 +01:00
ambrop7@gmail.com
c19ca69ac8 virtualbox: Unbreak the nixos module.
(cherry picked from commit 65393ca8d3)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-12 10:47:35 +01:00
ambrop7@gmail.com
268f3f4cc7 virtualbox: Allow disabling the network interface.
The current nixos module for VirtualBox unconditionally configures a vboxnet0
network interface at boot. This may be undesired, especially when the user wants
to manage network interfaces in a centralized manner.

(cherry picked from commit 9fa2c35ec8)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-12 10:46:46 +01:00
aszlig
4504b12bc1 nixos-install: Pass CA cert bundle to chroot.
Since we're using HTTPS for the binary cache (introduced in faf0797) by
default, the binary cache should also be available during installation.

The file that is defined in SSL_CERT_FILE outside of the chroot is
copied over to /tmp/ca-cert.crt inside the chroot, so we have an
absolute path we can reference during nixos-install. However, this might
end up with the file not being cleaned up properly from outside of the
store, but neither would be /tmp/root so the cleanup issue needs to be
solved in another place (or commit to be more exact).

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
(cherry picked from commit cf7f15c92c)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-12 10:46:11 +01:00
Bjørn Forsman
d410622cdf nixos/gnome: enable MTP support in gvfs
To support browsing files on Android phones in Nautilus (and other GVFS
based file browsers).

(cherry picked from commit f3a46c3858)
2014-12-12 07:58:37 +01:00
Vladimír Čunát
a1c1589b52 Merge #5286: ati-driver: Update to 4.12
(cherry picked from commit 80e3018bc0)
2014-12-11 22:13:46 +01:00
Domen Kožar
9629a59a4c deluge: 1.3.10 -> 1.3.11 2014-12-11 15:40:35 +01:00
Domen Kožar
c8d9073c0e pythonPackages.pyptlib: disable tests 2014-12-11 11:22:55 +01:00
Domen Kožar
6ce4ea5482 remove libvlc, unused package
cc @ttuegel

(cherry picked from commit aaf998f604)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-11 10:39:42 +01:00
Domen Kožar
d58fd144ac folly: disable on 32bit (unsupported)
(cherry picked from commit 776d796221)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-11 10:39:34 +01:00
Domen Kožar
20fdf0fab1 classpath: fix build
(cherry picked from commit 3c9828fd77)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-11 10:39:26 +01:00
Domen Kožar
322607e6ce opentsdb: patch shebangs in correct directory 2014-12-11 09:17:23 +01:00
Michael Raskin
8b55030957 Update/Fix OVMF
(cherry picked from commit a199693cab)
2014-12-11 08:53:23 +03:00
Domen Kožar
d92b7b7a67 fix builds for rest of kernel modules on 3.18
(cherry picked from commit 27281f660c)
2014-12-11 02:04:15 +01:00
Vladimír Čunát
a4afaf15e8 kde: fix CVE-2014-8600 by upstream patches
https://www.kde.org/info/security/advisory-20141113-1.txt
I couldn't find kio-extras, so I hope we don't have it disguised somewhere.

(cherry picked from commit 15b9626a3d)
2014-12-10 21:53:54 +01:00
Vladimír Čunát
55d793f2fb libyaml: fix CVE-2014-9130 by upstream patch
(cherry picked from commit c8a53923fc)
2014-12-10 21:53:54 +01:00
Vladimír Čunát
3fb1e7ed7c cpio: fix CVE-2014-9112 by Fedora patch
(cherry picked from commit 225ddcda9a)
2014-12-10 21:53:54 +01:00
Domen Kožar
6efba89335 Revert "xulrunner: use gold linker"
This reverts commit fc31d6dbc7.

Error occurs randomly: http://hydra.nixos.org/eval/1165369
2014-12-10 21:14:27 +01:00
Domen Kožar
79387f419d python3Packages.dateutil_2_1: fix build 2014-12-10 21:10:40 +01:00
Peter Simons
1bfa102c9b vimus: disable Linux 32 bit builds
https://ghc.haskell.org/trac/ghc/ticket/9825
(cherry picked from commit 57c5b8f5e1)
2014-12-10 19:31:57 +01:00
Emery Hemingway
7a0036d129 glibc_multi: fix package name (close #5284)
"multi" should be between the "glibc" and the version

(cherry picked from commit be2060f1e7)
2014-12-10 18:33:54 +01:00
Eelco Dolstra
3a491aaacb php: Really update to 5.4.34
75738437a4 only updated the version string...

(cherry picked from commit 55d59eefb3)
2014-12-10 17:19:56 +01:00
Vladimír Čunát
d7b053a44c apparmor: fix build by using older perl
This is work around #5270.
Also bogus path in wrapper got fixed.

CC: maintainers @phreedom, @thoughtpolice.
It would be better to test this as well by someone who actually uses it.

(cherry picked from commit 62e5e2a880)
2014-12-10 16:14:49 +01:00
Eelco Dolstra
6b63c46167 Update version delta for 14.12 2014-12-10 15:50:19 +01:00
Eelco Dolstra
f7410b4119 Shorten the version string
As suggested by Bjørn Forsman, use the number of commits in the
release branch.

(cherry picked from commit 21e8cfac80)
2014-12-10 15:50:19 +01:00
Eelco Dolstra
4497f1e7f0 Set the channel for this release 2014-12-10 15:50:18 +01:00
Vladimír Čunát
bdf161ed8d dolphin-emu-master: disable unsupported i686 platform
(cherry picked from commit e815624b67)
CC maintainer @MP2E.
2014-12-10 15:44:02 +01:00
Vladimír Čunát
9530bb2174 shotcut: mark as broken for now
(cherry picked from commit b65c8ffc37)
2014-12-10 15:36:26 +01:00
Mathijs Kwik
fc31d6dbc7 xulrunner: use gold linker 2014-12-10 13:56:40 +01:00
Vladimír Čunát
9532b0b1f4 luminance-hdr: fix build by Debian patch
(cherry picked from commit 8ca78f0376)
2014-12-10 13:37:35 +01:00
Vladimír Čunát
d5428a8ea9 qt5SDK: fix build by not building docs
Feel free to find a proper fix.

(cherry picked from commit d7a7b72353)
2014-12-10 13:21:45 +01:00
Vladimír Čunát
f7ad0d2e19 root: fix build by upstream patch
Also refactor the expression a little.

(cherry picked from commit 7ce485ff0f)
2014-12-10 13:11:42 +01:00
Domen Kožar
fbc784c22c flexget: fix runtime dependencies 2014-12-10 12:53:53 +01:00
Domen Kožar
671efd23de lttng-modules: fix build on kernel 3.18 2014-12-10 12:53:53 +01:00
Domen Kožar
cab4205ad7 v4l2loopback: fix build in kernel 3.18 2014-12-10 12:53:53 +01:00
Vladimír Čunát
0681d61c37 nixos: check resumeDevice is absolute path and document
Fixes #5219 after merging #4995.
2014-12-10 11:49:25 +01:00
aszlig
6757f0c7fc tomahawk: Fix resolver signature verification.
Requires the OpenSSL QCA plugin, otherwise QCA is unable to load the
Tomahawk public key.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-10 10:29:16 +01:00
Domen Kožar
5b8544337f tcpcrypt: 2011.07.22 -> 0.3rc1, fix nixos service 2014-12-10 10:23:28 +01:00
Domen Kožar
d3df56dfa1 gmpc: fix build 2014-12-10 09:55:22 +01:00
Domen Kožar
3703e4d00a fix a bunch of perl modules 2014-12-10 01:37:37 +01:00
Bjørn Forsman
f8047b48a1 lttng-modules: fix build on linux 3.14.x
By applying patch from upstream mailing list[1] (should be in the next
release).

[1]: http://lists.lttng.org/pipermail/lttng-dev/2014-December/023914.html

(cherry picked from commit 507e78fb94)
2014-12-09 19:35:43 +01:00
Bjørn Forsman
2f430a1ac4 buildbot-slave: align attrname with pkgname
Keep old attrname (buildbotSlave) around for backward compatibility.

(cherry picked from commit 1b396c7ae9)
2014-12-09 19:16:10 +01:00
Bjørn Forsman
0e9216f653 buildbot{,-slave}: update 0.8.8 -> 0.8.10
Build tested. Source distribution is now on pypi instead of googlecode.

(cherry picked from commit 99eab9f1e2)
2014-12-09 19:16:08 +01:00
Ricardo M. Correia
61fa393169 flashplayer: Update from 11.2.202.424 -> 11.2.202.425 2014-12-09 19:08:58 +01:00
Eelco Dolstra
eb7e458d2a Use https://cache.nixos.org
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-09 15:18:57 +01:00
Domen Kožar
1049988db4 14.11 -> 14.12 2014-12-09 15:03:41 +01:00
Domen Kožar
9ffe20cbff pyptlib: disable py3k and pypy 2014-12-09 13:22:20 +01:00
Domen Kožar
c92f24a815 PyQt: fix build 2014-12-09 13:20:25 +01:00
Domen Kožar
87cdd944da gosmore: fix build 2014-12-09 12:40:21 +01:00
Domen Kožar
c219abb81a ccp-netlib: fix build by downgrading boost 2014-12-09 12:36:23 +01:00
Domen Kožar
1b10d224c8 boringssl: fix build 2014-12-09 12:32:08 +01:00
Domen Kožar
ef0eac28e5 remove cppnetlib, we already have cpp-netlib 2014-12-09 12:24:42 +01:00
Domen Kožar
7a396ad522 nixos.tests.bittorrent: mark torrent as private
Hopefully that resolves transient errors with DHT
such as http://hydra.nixos.org/build/17784957
2014-12-09 12:08:13 +01:00
Domen Kožar
b8d5958ccc mariadb: 10.0.14 -> 10.0.15 2014-12-09 11:27:37 +01:00
Domen Kožar
1937962e79 xfdesktop: 4.10.2 -> 4.10.3 2014-12-09 11:27:18 +01:00
Domen Kožar
a327bb6f17 xfce4.xfce4-power-manager: 1.3.0 -> 1.3.2 2014-12-09 11:12:24 +01:00
aszlig
fca406ca8e tomahawk: Fix finding Phonon VLC backend.
Using propagatedBuildInputs only works for environment.systemPackages
but not for using nix-env, because on NixOS we already have a default
QT_PLUGIN_PATH set there.

The main reason why I'm using the VLC backend and not providing options
for other Phonon backends is because it's recommended upstream and also
will be directly used (via libvlc) in the upcoming 0.9 release.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-09 10:19:28 +01:00
aszlig
dea4ef3497 tomahawk: Update to bugfix release 0.8.2.
Fixes a few annoying bugs (in my case it's the painting issue that's
most annoying):

 * Show error message if saving tags failed.
 * Fixed painting issue on search page.
 * (OS X & Windows) Fixed crash during collection scan.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-09 10:19:23 +01:00
William A. Kennington III
74d1336c67 kernel: 3.14.25 -> 3.14.26 2014-12-09 10:18:48 +01:00
William A. Kennington III
6469098f1c kernel: 3.17.4 -> 3.17.6 2014-12-09 10:18:42 +01:00
William A. Kennington III
c73f4aba55 kernel: 3.4.104 -> 3.4.105 2014-12-09 10:18:35 +01:00
William A. Kennington III
8b4ae0d8f1 kernel: 3.12.33 -> 3.12.34 2014-12-09 10:18:25 +01:00
William A. Kennington III
8ea79ac189 kernel: 3.10.61 -> 3.10.62 2014-12-09 10:18:19 +01:00
William A. Kennington III
611419beba kernel: Add 3.18 2014-12-09 10:18:12 +01:00
Bjørn Forsman
bfaf5e0652 thrift: update 0.9.1 -> 0.9.2
* Drop unneeded patch to fix build error; now included upstream
* Fetch tarball instead of using git
* Drop unneeded autotools deps since we're building from tarball

TODO: Package boost-test library, so that we can run the test suite.
(cherry picked from commit 3871539d3b)
2014-12-08 22:54:44 +01:00
35771 changed files with 445281 additions and 2978874 deletions

View File

@@ -1,87 +0,0 @@
# EditorConfig configuration for nixpkgs
# https://EditorConfig.org
# Top-most EditorConfig file
root = true
# Unix-style newlines with a newline ending every file, utf-8 charset
[*]
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
charset = utf-8
# Ignore diffs/patches
[*.{diff,patch}]
end_of_line = unset
insert_final_newline = unset
trim_trailing_whitespace = unset
# see https://nixos.org/nixpkgs/manual/#chap-conventions
# Match json/lockfiles/markdown/nix/perl/python/ruby/shell/docbook files, set indent to spaces
[*.{json,lock,md,nix,pl,pm,py,rb,sh,xml}]
indent_style = space
# Match docbook files, set indent width of one
[*.xml]
indent_size = 1
# Match json/lockfiles/markdown/nix/ruby files, set indent width of two
[*.{json,lock,md,nix,rb}]
indent_size = 2
# Match perl/python/shell scripts, set indent width of four
[*.{pl,pm,py,sh}]
indent_size = 4
# Match gemfiles, set indent to spaces with width of two
[Gemfile]
indent_size = 2
indent_style = space
# Disable file types or individual files
# some of these files may be auto-generated and/or require significant changes
[*.{c,h}]
insert_final_newline = unset
trim_trailing_whitespace = unset
[*.{asc,key,ovpn}]
insert_final_newline = unset
end_of_line = unset
trim_trailing_whitespace = unset
[*.lock]
indent_size = unset
# trailing whitespace is an actual syntax element of classic Markdown/
# CommonMark to enforce a line break
[*.md]
trim_trailing_whitespace = unset
[eggs.nix]
trim_trailing_whitespace = unset
[nixos/modules/services/networking/ircd-hybrid/*.{conf,in}]
trim_trailing_whitespace = unset
[pkgs/build-support/dotnetenv/Wrapper/**]
end_of_line = unset
indent_style = unset
insert_final_newline = unset
trim_trailing_whitespace = unset
[pkgs/development/compilers/elm/registry.dat]
end_of_line = unset
insert_final_newline = unset
[pkgs/development/haskell-modules/hackage-packages.nix]
indent_style = unset
trim_trailing_whitespace = unset
[pkgs/servers/dict/wordnet_structures.py]
trim_trailing_whitespace = unset
[pkgs/tools/misc/timidity/timidity.cfg]
trim_trailing_whitespace = unset

View File

@@ -1,38 +0,0 @@
# This file contains a list of commits that are not likely what you
# are looking for in a blame, such as mass reformatting or renaming.
# You can set this file as a default ignore file for blame by running
# the following command.
#
# $ git config blame.ignoreRevsFile .git-blame-ignore-revs
#
# To temporarily not use this file add
# --ignore-revs-file=""
# to your blame command.
#
# The ignoreRevsFile can't be set globally due to blame failing if the file isn't present.
# To not have to set the option in every repository it is needed in,
# save the following script in your path with the name "git-bblame"
# now you can run
# $ git bblame $FILE
# to use the .git-blame-ignore-revs file if it is present.
#
# #!/usr/bin/env bash
# repo_root=$(git rev-parse --show-toplevel)
# if [[ -e $repo_root/.git-blame-ignore-revs ]]; then
# git blame --ignore-revs-file="$repo_root/.git-blame-ignore-revs" $@
# else
# git blame $@
# fi
# nixos/modules/rename: Sort alphabetically
1f71224fe86605ef4cd23ed327b3da7882dad382
# manual: fix typos
feddd5e7f8c6f8167b48a077fa2a5394dc008999
# nixos: fix module paths in rename.nix
d08ede042b74b8199dc748323768227b88efcf7c
# fix indentation in mk-python-derivation.nix
d1c1a0c656ccd8bd3b25d3c4287f2d075faf3cf3

16
.gitattributes vendored
View File

@@ -1,16 +0,0 @@
**/deps.nix linguist-generated
**/node-packages.nix linguist-generated
pkgs/applications/editors/emacs-modes/*-generated.nix linguist-generated
pkgs/development/r-modules/*-packages.nix linguist-generated
pkgs/development/haskell-modules/hackage-packages.nix linguist-generated
pkgs/development/beam-modules/hex-packages.nix linguist-generated
doc/** linguist-documentation
doc/default.nix linguist-documentation=false
nixos/doc/** linguist-documentation
nixos/doc/default.nix linguist-documentation=false
nixos/modules/module-list.nix merge=union
# pkgs/top-level/all-packages.nix merge=union

291
.github/CODEOWNERS vendored
View File

@@ -1,291 +0,0 @@
# CODEOWNERS file
#
# This file is used to describe who owns what in this repository. This file does not
# replace `meta.maintainers` but is instead used for other things than derivations
# and modules, like documentation, package sets, and other assets.
#
# For documentation on this file, see https://help.github.com/articles/about-codeowners/
# Mentioned users will get code review requests.
#
# IMPORTANT NOTE: in order to actually get pinged, commit access is required.
# This also holds true for GitHub teams. Since almost none of our teams have write
# permissions, you need to list all members of the team with commit access individually.
# This file
/.github/CODEOWNERS @edolstra
# GitHub actions
/.github/workflows @NixOS/Security @Mic92 @zowoq
/.github/workflows/merge-staging @FRidh
# EditorConfig
/.editorconfig @Mic92 @zowoq
# Libraries
/lib @edolstra @nbp @infinisil
/lib/systems @alyssais @nbp @ericson2314 @matthewbauer
/lib/generators.nix @edolstra @nbp @Profpatsch
/lib/cli.nix @edolstra @nbp @Profpatsch
/lib/debug.nix @edolstra @nbp @Profpatsch
/lib/asserts.nix @edolstra @nbp @Profpatsch
# Nixpkgs Internals
/default.nix @nbp
/pkgs/top-level/default.nix @nbp @Ericson2314
/pkgs/top-level/impure.nix @nbp @Ericson2314
/pkgs/top-level/stage.nix @nbp @Ericson2314 @matthewbauer
/pkgs/top-level/splice.nix @Ericson2314 @matthewbauer
/pkgs/top-level/release-cross.nix @Ericson2314 @matthewbauer
/pkgs/stdenv/generic @Ericson2314 @matthewbauer
/pkgs/stdenv/cross @Ericson2314 @matthewbauer
/pkgs/build-support/cc-wrapper @Ericson2314
/pkgs/build-support/bintools-wrapper @Ericson2314
/pkgs/build-support/setup-hooks @Ericson2314
/pkgs/build-support/setup-hooks/auto-patchelf.sh @layus
/pkgs/build-support/setup-hooks/auto-patchelf.py @layus
# Nixpkgs build-support
/pkgs/build-support/writers @lassulus @Profpatsch
# Nixpkgs documentation
/doc @fricklerhandwerk
/maintainers/scripts/db-to-md.sh @jtojnar @ryantm
/maintainers/scripts/doc @jtojnar @ryantm
/doc/build-aux/pandoc-filters @jtojnar
/doc/contributing/contributing-to-documentation.chapter.md @jtojnar
# NixOS Internals
/nixos/default.nix @nbp @infinisil
/nixos/lib/from-env.nix @nbp @infinisil
/nixos/lib/eval-config.nix @nbp @infinisil
/nixos/doc/manual/configuration/abstractions.xml @nbp
/nixos/doc/manual/configuration/config-file.xml @nbp
/nixos/doc/manual/configuration/config-syntax.xml @nbp
/nixos/doc/manual/configuration/modularity.xml @nbp
/nixos/doc/manual/development/assertions.xml @nbp
/nixos/doc/manual/development/meta-attributes.xml @nbp
/nixos/doc/manual/development/option-declarations.xml @nbp
/nixos/doc/manual/development/option-def.xml @nbp
/nixos/doc/manual/development/option-types.xml @nbp
/nixos/doc/manual/development/replace-modules.xml @nbp
/nixos/doc/manual/development/writing-modules.xml @nbp
/nixos/doc/manual/man-nixos-option.xml @nbp
/nixos/modules/installer/tools/nixos-option.sh @nbp
/nixos/modules/system @dasJ
# NixOS integration test driver
/nixos/lib/test-driver @tfc
# Systemd
/nixos/modules/system/boot/systemd.nix @NixOS/systemd
/nixos/modules/system/boot/systemd @NixOS/systemd
/nixos/lib/systemd-*.nix @NixOS/systemd
/pkgs/os-specific/linux/systemd @NixOS/systemd
# Updaters
## update.nix
/maintainers/scripts/update.nix @jtojnar
/maintainers/scripts/update.py @jtojnar
## common-updater-scripts
/pkgs/common-updater/scripts/update-source-version @jtojnar
# Python-related code and docs
/maintainers/scripts/update-python-libraries @FRidh
/pkgs/top-level/python-packages.nix @FRidh @jonringer
/pkgs/development/interpreters/python @FRidh
/pkgs/development/python-modules @FRidh @jonringer
/doc/languages-frameworks/python.section.md @FRidh
/pkgs/development/tools/poetry2nix @adisbladis
/pkgs/development/interpreters/python/hooks @FRidh @jonringer
# Haskell
/doc/languages-frameworks/haskell.section.md @cdepillabout @sternenseemann @maralorn
/maintainers/scripts/haskell @cdepillabout @sternenseemann @maralorn
/pkgs/development/compilers/ghc @cdepillabout @sternenseemann @maralorn
/pkgs/development/haskell-modules @cdepillabout @sternenseemann @maralorn
/pkgs/test/haskell @cdepillabout @sternenseemann @maralorn
/pkgs/top-level/release-haskell.nix @cdepillabout @sternenseemann @maralorn
/pkgs/top-level/haskell-packages.nix @cdepillabout @sternenseemann @maralorn
# Perl
/pkgs/development/interpreters/perl @stigtsp @zakame
/pkgs/top-level/perl-packages.nix @stigtsp @zakame
/pkgs/development/perl-modules @stigtsp @zakame
# R
/pkgs/applications/science/math/R @jbedo
/pkgs/development/r-modules @jbedo
# Ruby
/pkgs/development/interpreters/ruby @marsam
/pkgs/development/ruby-modules @marsam
# Rust
/pkgs/development/compilers/rust @Mic92 @LnL7 @zowoq
/pkgs/build-support/rust @zowoq
/doc/languages-frameworks/rust.section.md @zowoq
# C compilers
/pkgs/development/compilers/gcc @matthewbauer
/pkgs/development/compilers/llvm @matthewbauer
# Compatibility stuff
/pkgs/top-level/unix-tools.nix @matthewbauer
/pkgs/development/tools/xcbuild @matthewbauer
# Audio
/nixos/modules/services/audio/botamusique.nix @mweinelt
/nixos/modules/services/audio/snapserver.nix @mweinelt
/nixos/tests/modules/services/audio/botamusique.nix @mweinelt
/nixos/tests/snapcast.nix @mweinelt
# Browsers
/pkgs/applications/networking/browsers/firefox @mweinelt
# Jetbrains
/pkgs/applications/editors/jetbrains @edwtjo
# Licenses
/lib/licenses.nix @alyssais
# Qt / KDE
/pkgs/applications/kde @ttuegel
/pkgs/desktops/plasma-5 @ttuegel
/pkgs/development/libraries/kde-frameworks @ttuegel
/pkgs/development/libraries/qt-5 @ttuegel
# PostgreSQL and related stuff
/pkgs/servers/sql/postgresql @thoughtpolice @marsam
/nixos/modules/services/databases/postgresql.xml @thoughtpolice
/nixos/modules/services/databases/postgresql.nix @thoughtpolice
/nixos/tests/postgresql.nix @thoughtpolice
# Hardened profile & related modules
/nixos/modules/profiles/hardened.nix @joachifm
/nixos/modules/security/hidepid.nix @joachifm
/nixos/modules/security/lock-kernel-modules.nix @joachifm
/nixos/modules/security/misc.nix @joachifm
/nixos/tests/hardened.nix @joachifm
/pkgs/os-specific/linux/kernel/hardened-config.nix @joachifm
# Home Automation
/nixos/modules/services/misc/home-assistant.nix @mweinelt
/nixos/modules/services/misc/zigbee2mqtt.nix @mweinelt
/nixos/tests/home-assistant.nix @mweinelt
/nixos/tests/zigbee2mqtt.nix @mweinelt
/pkgs/servers/home-assistant @mweinelt
/pkgs/tools/misc/esphome @mweinelt
# Network Time Daemons
/pkgs/tools/networking/chrony @thoughtpolice
/pkgs/tools/networking/ntp @thoughtpolice
/pkgs/tools/networking/openntpd @thoughtpolice
/nixos/modules/services/networking/ntp @thoughtpolice
# Network
/pkgs/tools/networking/kea/default.nix @mweinelt
/pkgs/tools/networking/babeld/default.nix @mweinelt
/nixos/modules/services/networking/babeld.nix @mweinelt
/nixos/modules/services/networking/kea.nix @mweinelt
/nixos/modules/services/networking/knot.nix @mweinelt
/nixos/tests/babeld.nix @mweinelt
/nixos/tests/kea.nix @mweinelt
/nixos/tests/knot.nix @mweinelt
# Dhall
/pkgs/development/dhall-modules @Gabriella439 @Profpatsch @ehmry
/pkgs/development/interpreters/dhall @Gabriella439 @Profpatsch @ehmry
# Idris
/pkgs/development/idris-modules @Infinisil
# Bazel
/pkgs/development/tools/build-managers/bazel @Profpatsch
# NixOS modules for e-mail and dns services
/nixos/modules/services/mail/mailman.nix @peti
/nixos/modules/services/mail/postfix.nix @peti
/nixos/modules/services/networking/bind.nix @peti
/nixos/modules/services/mail/rspamd.nix @peti
# Emacs
/pkgs/applications/editors/emacs/elisp-packages @adisbladis
/pkgs/applications/editors/emacs @adisbladis
/pkgs/top-level/emacs-packages.nix @adisbladis
# Neovim
/pkgs/applications/editors/neovim @jonringer @teto
# VimPlugins
/pkgs/applications/editors/vim/plugins @jonringer
# VsCode Extensions
/pkgs/applications/editors/vscode/extensions @jonringer
# Prometheus exporter modules and tests
/nixos/modules/services/monitoring/prometheus/exporters.nix @WilliButz
/nixos/modules/services/monitoring/prometheus/exporters.xml @WilliButz
/nixos/tests/prometheus-exporters.nix @WilliButz
# PHP interpreter, packages, extensions, tests and documentation
/doc/languages-frameworks/php.section.md @aanderse @etu @globin @ma27 @talyz
/nixos/tests/php @aanderse @etu @globin @ma27 @talyz
/pkgs/build-support/build-pecl.nix @aanderse @etu @globin @ma27 @talyz
/pkgs/development/interpreters/php @jtojnar @aanderse @etu @globin @ma27 @talyz
/pkgs/development/php-packages @aanderse @etu @globin @ma27 @talyz
/pkgs/top-level/php-packages.nix @jtojnar @aanderse @etu @globin @ma27 @talyz
# Podman, CRI-O modules and related
/nixos/modules/virtualisation/containers.nix @zowoq @adisbladis
/nixos/modules/virtualisation/cri-o.nix @zowoq @adisbladis
/nixos/modules/virtualisation/podman @zowoq @adisbladis
/nixos/tests/cri-o.nix @zowoq @adisbladis
/nixos/tests/podman @zowoq @adisbladis
# Docker tools
/pkgs/build-support/docker @roberth
/nixos/tests/docker-tools* @roberth
/doc/builders/images/dockertools.section.md @roberth
# Blockchains
/pkgs/applications/blockchains @mmahut @RaghavSood
# Go
/doc/languages-frameworks/go.section.md @kalbasit @Mic92 @zowoq
/pkgs/build-support/go @kalbasit @Mic92 @zowoq
/pkgs/development/compilers/go @kalbasit @Mic92 @zowoq
# GNOME
/pkgs/desktops/gnome @jtojnar
/pkgs/desktops/gnome/extensions @piegamesde @jtojnar
# Cinnamon
/pkgs/desktops/cinnamon @mkg20001
# nim
/pkgs/development/compilers/nim @ehmry
/pkgs/development/nim-packages @ehmry
/pkgs/top-level/nim-packages.nix @ehmry
# terraform providers
/pkgs/applications/networking/cluster/terraform-providers @zowoq
# kubernetes
/nixos/doc/manual/configuration/kubernetes.chapter.md @zowoq
/nixos/modules/services/cluster/kubernetes @zowoq
/nixos/tests/kubernetes @zowoq
/pkgs/applications/networking/cluster/kubernetes @zowoq
# Matrix
/pkgs/servers/heisenbridge @piegamesde
/pkgs/servers/matrix-conduit @piegamesde
/pkgs/servers/matrix-synapse/matrix-appservice-irc @piegamesde
/nixos/modules/services/misc/heisenbridge.nix @piegamesde
/nixos/modules/services/misc/matrix-appservice-irc.nix @piegamesde
/nixos/modules/services/misc/matrix-conduit.nix @piegamesde
/nixos/tests/matrix-appservice-irc.nix @piegamesde
/nixos/tests/matrix-conduit.nix @piegamesde
# Dotnet
/pkgs/build-support/dotnet @IvarWithoutBones
/pkgs/development/compilers/dotnet @IvarWithoutBones

View File

@@ -1,11 +0,0 @@
## Issue description
### Steps to reproduce
## Technical details
Please run `nix-shell -p nix-info --run "nix-info -m"` and paste the result.

View File

@@ -1,40 +0,0 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: '0.kind: bug'
assignees: ''
---
### Describe the bug
A clear and concise description of what the bug is.
### Steps To Reproduce
Steps to reproduce the behavior:
1. ...
2. ...
3. ...
### Expected behavior
A clear and concise description of what you expected to happen.
### Screenshots
If applicable, add screenshots to help explain your problem.
### Additional context
Add any other context about the problem here.
### Notify maintainers
<!--
Please @ people who are in the `meta.maintainers` list of the offending package or module.
If in doubt, check `git blame` for whoever last touched something.
-->
### Metadata
Please run `nix-shell -p nix-info --run "nix-info -m"` and paste the result.
```console
[user@system:~]$ nix-shell -p nix-info --run "nix-info -m"
output here
```

View File

@@ -1,34 +0,0 @@
---
name: Build failure
about: Create a report to help us improve
title: ''
labels: '0.kind: build failure'
assignees: ''
---
### Steps To Reproduce
Steps to reproduce the behavior:
1. build *X*
### Build log
```
log here if short otherwise a link to a gist
```
### Additional context
Add any other context about the problem here.
### Notify maintainers
<!--
Please @ people who are in the `meta.maintainers` list of the offending package or module.
If in doubt, check `git blame` for whoever last touched something.
-->
### Metadata
Please run `nix-shell -p nix-info --run "nix-info -m"` and paste the result.
```console
[user@system:~]$ nix-shell -p nix-info --run "nix-info -m"
output here
```

View File

@@ -1,48 +0,0 @@
---
name: Out-of-date package reports
about: For packages that are out-of-date
title: ''
labels: '9.needs: package (update)'
assignees: ''
---
###### Checklist
<!-- Note that these are hard requirements -->
<!--
You can use the "Go to file" functionality on GitHub to find the package
Then you can go to the history for this package
Find the latest "package_name: old_version -> new_version" commit
The "new_version" is the current version of the package
-->
- [ ] Checked the [nixpkgs master branch](https://github.com/NixOS/nixpkgs)
<!--
Type the name of your package and try to find an open pull request for the package
If you find an open pull request, you can review it!
There's a high chance that you'll have the new version right away while helping the community!
-->
- [ ] Checked the [nixpkgs pull requests](https://github.com/NixOS/nixpkgs/pulls)
###### Project name
`nix search` name:
<!--
The current version can be found easily with the same process as above for checking the master branch
If an open PR is present for the package, take this version as the current one and link to the PR
-->
current version:
desired version:
###### Notify maintainers
<!--
Search your package here: https://search.nixos.org/packages?channel=unstable
If no maintainer is listed for your package, tag the person that last updated the package
-->
maintainers:
###### Note for maintainers
Please tag this issue in your PR.

View File

@@ -1,18 +0,0 @@
---
name: Packaging requests
about: For packages that are missing
title: ''
labels: '0.kind: packaging request'
assignees: ''
---
**Project description**
_describe the project a little_
**Metadata**
* homepage URL:
* source URL:
* license: mit, bsd, gpl2+ , ...
* platforms: unix, linux, darwin, ...

View File

@@ -1,41 +0,0 @@
###### Description of changes
<!--
For package updates please link to a changelog or describe changes, this helps your fellow maintainers discover breaking updates.
For new packages please briefly describe the package or provide a link to its homepage.
-->
###### Things done
<!-- Please check what applies. Note that these are not hard requirements but merely serve as information for reviewers. -->
- Built on platform(s)
- [ ] x86_64-linux
- [ ] aarch64-linux
- [ ] x86_64-darwin
- [ ] aarch64-darwin
- [ ] For non-Linux: Is `sandbox = true` set in `nix.conf`? (See [Nix manual](https://nixos.org/manual/nix/stable/command-ref/conf-file.html))
- [ ] Tested, as applicable:
- [NixOS test(s)](https://nixos.org/manual/nixos/unstable/index.html#sec-nixos-tests) (look inside [nixos/tests](https://github.com/NixOS/nixpkgs/blob/master/nixos/tests))
- and/or [package tests](https://nixos.org/manual/nixpkgs/unstable/#sec-package-tests)
- or, for functions and "core" functionality, tests in [lib/tests](https://github.com/NixOS/nixpkgs/blob/master/lib/tests) or [pkgs/test](https://github.com/NixOS/nixpkgs/blob/master/pkgs/test)
- made sure NixOS tests are [linked](https://nixos.org/manual/nixpkgs/unstable/#ssec-nixos-tests-linking) to the relevant packages
- [ ] Tested compilation of all packages that depend on this change using `nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"`. Note: all changes have to be committed, also see [nixpkgs-review usage](https://github.com/Mic92/nixpkgs-review#usage)
- [ ] Tested basic functionality of all binary files (usually in `./result/bin/`)
- [22.11 Release Notes (or backporting 22.05 Release notes)](https://github.com/NixOS/nixpkgs/blob/master/CONTRIBUTING.md#generating-2211-release-notes)
- [ ] (Package updates) Added a release notes entry if the change is major or breaking
- [ ] (Module updates) Added a release notes entry if the change is significant
- [ ] (Module addition) Added a release notes entry if adding a new NixOS module
- [ ] (Release notes changes) Ran `nixos/doc/manual/md-to-db.sh` to update generated release notes
- [ ] Fits [CONTRIBUTING.md](https://github.com/NixOS/nixpkgs/blob/master/CONTRIBUTING.md).
<!--
To help with the large amounts of pull requests, we would appreciate your
reviews of other pull requests, especially simple package updates. Just leave a
comment describing what you have tested in the relevant package/service.
Reviewing helps to reduce the average time-to-merge for everyone.
Thanks a lot if you do!
List of open PRs: https://github.com/NixOS/nixpkgs/pulls
Reviewing guidelines: https://nixos.org/manual/nixpkgs/unstable/#chap-reviewing-contributions
-->

36
.github/STALE-BOT.md vendored
View File

@@ -1,36 +0,0 @@
# Stale bot information
- Thanks for your contribution!
- Our stale bot will never close an issue or PR.
- To remove the stale label, just leave a new comment.
- _How to find the right people to ping?_ &rarr; [`git blame`](https://git-scm.com/docs/git-blame) to the rescue! (or GitHub's history and blame buttons.)
- You can always ask for help on [our Discourse Forum](https://discourse.nixos.org/), [our Matrix room](https://matrix.to/#/#nix:nixos.org), or on the [#nixos IRC channel](https://web.libera.chat/#nixos).
## Suggestions for PRs
1. GitHub sometimes doesn't notify people who commented / reviewed a PR previously, when you (force) push commits. If you have addressed the reviews you can [officially ask for a review](https://docs.github.com/en/free-pro-team@latest/github/collaborating-with-issues-and-pull-requests/requesting-a-pull-request-review) from those who commented to you or anyone else.
2. If it is unfinished but you plan to finish it, please mark it as a draft.
3. If you don't expect to work on it any time soon, closing it with a short comment may encourage someone else to pick up your work.
4. To get things rolling again, rebase the PR against the target branch and address valid comments.
5. If you need a review to move forward, ask in [the Discourse thread for PRs that need help](https://discourse.nixos.org/t/prs-in-distress/3604).
6. If all you need is a merge, check the git history to find and [request reviews](https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/requesting-a-pull-request-review) from people who usually merge related contributions.
## Suggestions for issues
1. If it is resolved (either for you personally, or in general), please consider closing it.
2. If this might still be an issue, but you are not interested in promoting its resolution, please consider closing it while encouraging others to take over and reopen an issue if they care enough.
3. If you still have interest in resolving it, try to ping somebody who you believe might have an interest in the topic. Consider discussing the problem in [our Discourse Forum](https://discourse.nixos.org/).
4. As with all open source projects, your best option is to submit a Pull Request that addresses this issue. We :heart: this attitude!
**Memorandum on closing issues**
Don't be afraid to close an issue that holds valuable information. Closed issues stay in the system for people to search, read, cross-reference, or even reopen--nothing is lost! Closing obsolete issues is an important way to help maintainers focus their time and effort.
## Useful GitHub search queries
- [Open PRs with any stale-bot interaction](https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+commenter%3Aapp%2Fstale+)
- [Open PRs with any stale-bot interaction and `2.status: stale`](https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+commenter%3Aapp%2Fstale+label%3A%222.status%3A+stale%22)
- [Open PRs with any stale-bot interaction and NOT `2.status: stale`](https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+commenter%3Aapp%2Fstale+-label%3A%222.status%3A+stale%22+)
- [Open Issues with any stale-bot interaction](https://github.com/NixOS/nixpkgs/issues?q=is%3Aissue+is%3Aopen+commenter%3Aapp%2Fstale+)
- [Open Issues with any stale-bot interaction and `2.status: stale`](https://github.com/NixOS/nixpkgs/issues?q=is%3Aissue+is%3Aopen+commenter%3Aapp%2Fstale+label%3A%222.status%3A+stale%22+)
- [Open Issues with any stale-bot interaction and NOT `2.status: stale`](https://github.com/NixOS/nixpkgs/issues?q=is%3Aissue+is%3Aopen+commenter%3Aapp%2Fstale+-label%3A%222.status%3A+stale%22+)

158
.github/labeler.yml vendored
View File

@@ -1,158 +0,0 @@
"6.topic: agda":
- doc/languages-frameworks/agda.section.md
- nixos/tests/agda.nix
- pkgs/build-support/agda/**/*
- pkgs/development/libraries/agda/**/*
- pkgs/top-level/agda-packages.nix
"6.topic: cinnamon":
- pkgs/desktops/cinnamon/**/*
"6.topic: emacs":
- nixos/modules/services/editors/emacs.nix
- nixos/modules/services/editors/emacs.xml
- nixos/tests/emacs-daemon.nix
- pkgs/applications/editors/emacs/elisp-packages/**/*
- pkgs/applications/editors/emacs/**/*
- pkgs/build-support/emacs/**/*
- pkgs/top-level/emacs-packages.nix
"6.topic: erlang":
- doc/languages-frameworks/beam.section.md
- pkgs/development/beam-modules/**/*
- pkgs/development/interpreters/elixir/**/*
- pkgs/development/interpreters/erlang/**/*
- pkgs/development/tools/build-managers/rebar/**/*
- pkgs/development/tools/build-managers/rebar3/**/*
- pkgs/development/tools/erlang/**/*
- pkgs/top-level/beam-packages.nix
"6.topic: fetch":
- pkgs/build-support/fetch*/**/*
"6.topic: GNOME":
- doc/languages-frameworks/gnome.section.md
- nixos/modules/services/desktops/gnome/**/*
- nixos/modules/services/x11/desktop-managers/gnome.nix
- nixos/tests/gnome-xorg.nix
- nixos/tests/gnome.nix
- pkgs/desktops/gnome/**/*
"6.topic: golang":
- doc/languages-frameworks/go.section.md
- pkgs/build-support/go/**/*
- pkgs/development/compilers/go/**/*
"6.topic: haskell":
- doc/languages-frameworks/haskell.section.md
- maintainers/scripts/haskell/**/*
- pkgs/development/compilers/ghc/**/*
- pkgs/development/haskell-modules/**/*
- pkgs/development/tools/haskell/**/*
- pkgs/test/haskell/**/*
- pkgs/top-level/haskell-packages.nix
- pkgs/top-level/release-haskell.nix
"6.topic: kernel":
- pkgs/build-support/kernel/**/*
- pkgs/os-specific/linux/kernel/**/*
"6.topic: lua":
- pkgs/development/interpreters/lua-5/**/*
- pkgs/development/interpreters/luajit/**/*
- pkgs/development/lua-modules/**/*
- pkgs/top-level/lua-packages.nix
"6.topic: nixos":
- nixos/**/*
- pkgs/os-specific/linux/nixos-rebuild/**/*
"6.topic: nim":
- doc/languages-frameworks/nim.section.md
- pkgs/development/compilers/nim/*
- pkgs/development/nim-packages/**/*
- pkgs/top-level/nim-packages.nix
"6.topic: ocaml":
- doc/languages-frameworks/ocaml.section.md
- pkgs/development/compilers/ocaml/**/*
- pkgs/development/compilers/reason/**/*
- pkgs/development/ocaml-modules/**/*
- pkgs/development/tools/ocaml/**/*
- pkgs/top-level/ocaml-packages.nix
"6.topic: pantheon":
- nixos/modules/services/desktops/pantheon/**/*
- nixos/modules/services/x11/desktop-managers/pantheon.nix
- nixos/modules/services/x11/display-managers/lightdm-greeters/pantheon.nix
- nixos/tests/pantheon.nix
- pkgs/desktops/pantheon/**/*
"6.topic: policy discussion":
- .github/**/*
"6.topic: printing":
- nixos/modules/services/printing/cupsd.nix
- pkgs/misc/cups/**/*
"6.topic: python":
- doc/languages-frameworks/python.section.md
- pkgs/development/interpreters/python/**/*
- pkgs/development/python-modules/**/*
- pkgs/top-level/python-packages.nix
"6.topic: qt/kde":
- doc/languages-frameworks/qt.section.md
- nixos/modules/services/x11/desktop-managers/plasma5.nix
- nixos/tests/plasma5.nix
- pkgs/applications/kde/**/*
- pkgs/desktops/plasma-5/**/*
- pkgs/development/libraries/kde-frameworks/**/*
- pkgs/development/libraries/qt-5/**/*
"6.topic: ruby":
- doc/languages-frameworks/ruby.section.md
- pkgs/development/interpreters/ruby/**/*
- pkgs/development/ruby-modules/**/*
"6.topic: rust":
- doc/languages-frameworks/rust.section.md
- pkgs/build-support/rust/**/*
- pkgs/development/compilers/rust/**/*
"6.topic: stdenv":
- pkgs/stdenv/**/*
"6.topic: steam":
- pkgs/games/steam/**/*
"6.topic: systemd":
- pkgs/os-specific/linux/systemd/**/*
- nixos/modules/system/boot/systemd*/**/*
"6.topic: TeX":
- doc/languages-frameworks/texlive.section.md
- pkgs/tools/typesetting/tex/**/*
"6.topic: vim":
- doc/languages-frameworks/vim.section.md
- pkgs/applications/editors/vim/**/*
- pkgs/applications/editors/vim/plugins/**/*
- nixos/modules/programs/neovim.nix
- pkgs/applications/editors/neovim/**/*
"6.topic: xfce":
- nixos/doc/manual/configuration/xfce.xml
- nixos/modules/services/x11/desktop-managers/xfce.nix
- nixos/tests/xfce.nix
- pkgs/desktops/xfce/**/*
"8.has: changelog":
- nixos/doc/manual/release-notes/**/*
"8.has: documentation":
- doc/**/*
- nixos/doc/**/*
"8.has: module (update)":
- nixos/modules/**/*

9
.github/stale.yml vendored
View File

@@ -1,9 +0,0 @@
# Configuration for probot-stale - https://github.com/probot/stale
daysUntilStale: 180
daysUntilClose: false
exemptLabels:
- "1.severity: security"
- "2.status: never-stale"
staleLabel: "2.status: stale"
markComment: false
closeComment: false

View File

@@ -1,41 +0,0 @@
name: Backport
on:
pull_request_target:
types: [closed, labeled]
# WARNING:
# When extending this action, be aware that $GITHUB_TOKEN allows write access to
# the GitHub repository. This means that it should not evaluate user input in a
# way that allows code injection.
permissions:
contents: read
jobs:
backport:
permissions:
contents: write # for zeebe-io/backport-action to create branch
pull-requests: write # for zeebe-io/backport-action to create PR to backport
name: Backport Pull Request
if: github.repository_owner == 'NixOS' && github.event.pull_request.merged == true && (github.event_name != 'labeled' || startsWith('backport', github.event.label.name))
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
# required to find all branches
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Create backport PRs
# should be kept in sync with `version`
uses: zeebe-io/backport-action@v0.0.5
with:
# Config README: https://github.com/zeebe-io/backport-action#backport-action
github_token: ${{ secrets.GITHUB_TOKEN }}
github_workspace: ${{ github.workspace }}
# should be kept in sync with `uses`
version: v0.0.5
pull_description: |-
Bot-based backport to `${target_branch}`, triggered by a label in #${pull_number}.
* [ ] Before merging, ensure that this backport complies with the [Criteria for Backporting](https://github.com/NixOS/nixpkgs/blob/master/CONTRIBUTING.md#criteria-for-backporting-changes).
* Even as a non-commiter, if you find that it does not comply, leave a comment.

View File

@@ -1,29 +0,0 @@
name: Basic evaluation checks
on:
workflow_dispatch
# pull_request:
# branches:
# - master
# - release-**
# push:
# branches:
# - master
# - release-**
permissions:
contents: read
jobs:
tests:
runs-on: ubuntu-latest
# we don't limit this action to only NixOS repo since the checks are cheap and useful developer feedback
steps:
- uses: actions/checkout@v3
- uses: cachix/install-nix-action@v17
- uses: cachix/cachix-action@v10
with:
# This cache is for the nixpkgs repo checks and should not be trusted or used elsewhere.
name: nixpkgs-ci
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
# explicit list of supportedSystems is needed until aarch64-darwin becomes part of the trunk jobset
- run: nix-build pkgs/top-level/release.nix -A tarball.nixpkgs-basic-release-checks --arg supportedSystems '[ "aarch64-darwin" "aarch64-linux" "x86_64-linux" "x86_64-darwin" ]'

View File

@@ -1,37 +0,0 @@
name: "Direct Push Warning"
on:
push:
branches:
- master
- release-**
permissions:
contents: read
jobs:
build:
permissions:
contents: write # for peter-evans/commit-comment to comment on commit
runs-on: ubuntu-latest
if: github.repository_owner == 'NixOS'
env:
GITHUB_SHA: ${{ github.sha }}
GITHUB_REPOSITORY: ${{ github.repository }}
steps:
- name: Check if commit is a merge commit
id: ismerge
run: |
ISMERGE=$(curl -H 'Accept: application/vnd.github.groot-preview+json' -H "authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" https://api.github.com/repos/${{ env.GITHUB_REPOSITORY }}/commits/${{ env.GITHUB_SHA }}/pulls | jq -r '.[] | select(.merge_commit_sha == "${{ env.GITHUB_SHA }}") | any')
echo "::set-output name=ismerge::$ISMERGE"
# github events are eventually consistent, so wait until changes propagate to thier DB
- run: sleep 60
if: steps.ismerge.outputs.ismerge != 'true'
- name: Warn if the commit was a direct push
if: steps.ismerge.outputs.ismerge != 'true'
uses: peter-evans/commit-comment@v2
with:
body: |
@${{ github.actor }}, you pushed a commit directly to master/release branch
instead of going through a Pull Request.
That's highly discouraged beyond the few exceptions listed
on https://github.com/NixOS/nixpkgs/issues/118661

View File

@@ -1,43 +0,0 @@
name: "Checking EditorConfig"
permissions: read-all
on:
# avoids approving first time contributors
pull_request_target:
branches-ignore:
- 'release-**'
jobs:
tests:
runs-on: ubuntu-latest
if: "github.repository_owner == 'NixOS' && !contains(github.event.pull_request.title, '[skip editorconfig]')"
steps:
- name: Get list of changed files from PR
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh api \
repos/NixOS/nixpkgs/pulls/${{github.event.number}}/files --paginate \
| jq '.[] | select(.status != "removed") | .filename' \
> "$HOME/changed_files"
- name: print list of changed files
run: |
cat "$HOME/changed_files"
- uses: actions/checkout@v3
with:
# pull_request_target checks out the base branch by default
ref: refs/pull/${{ github.event.pull_request.number }}/merge
- uses: cachix/install-nix-action@v17
with:
# nixpkgs commit is pinned so that it doesn't break
# editorconfig-checker 2.4.0
nix_path: nixpkgs=https://github.com/NixOS/nixpkgs/archive/c473cc8714710179df205b153f4e9fa007107ff9.tar.gz
- name: install editorconfig-checker
run: nix-env -iA editorconfig-checker -f '<nixpkgs>'
- name: Checking EditorConfig
run: |
cat "$HOME/changed_files" | xargs -r editorconfig-checker -disable-indent-size
- if: ${{ failure() }}
run: |
echo "::error :: Hey! It looks like your changes don't follow our editorconfig settings. Read https://editorconfig.org/#download to configure your editor so you never see this error again."

View File

@@ -1,24 +0,0 @@
name: "Label PR"
on:
pull_request_target:
types: [edited, opened, synchronize, reopened]
# WARNING:
# When extending this action, be aware that $GITHUB_TOKEN allows some write
# access to the GitHub API. This means that it should not evaluate user input in
# a way that allows code injection.
permissions:
contents: read
pull-requests: write
jobs:
labels:
runs-on: ubuntu-latest
if: github.repository_owner == 'NixOS'
steps:
- uses: actions/labeler@v4
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
sync-labels: true

View File

@@ -1,31 +0,0 @@
name: "Build NixOS manual"
permissions: read-all
on:
pull_request_target:
branches:
- master
paths:
- 'nixos/**'
jobs:
nixos:
runs-on: ubuntu-latest
if: github.repository_owner == 'NixOS'
steps:
- uses: actions/checkout@v3
with:
# pull_request_target checks out the base branch by default
ref: refs/pull/${{ github.event.pull_request.number }}/merge
- uses: cachix/install-nix-action@v17
with:
# explicitly enable sandbox
extra_nix_config: sandbox = true
- uses: cachix/cachix-action@v10
with:
# This cache is for the nixpkgs repo checks and should not be trusted or used elsewhere.
name: nixpkgs-ci
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
- name: Building NixOS manual
run: NIX_PATH=nixpkgs=$(pwd) nix-build --option restrict-eval true nixos/release.nix -A manual.x86_64-linux

View File

@@ -1,31 +0,0 @@
name: "Build Nixpkgs manual"
permissions: read-all
on:
pull_request_target:
branches:
- master
paths:
- 'doc/**'
jobs:
nixpkgs:
runs-on: ubuntu-latest
if: github.repository_owner == 'NixOS'
steps:
- uses: actions/checkout@v3
with:
# pull_request_target checks out the base branch by default
ref: refs/pull/${{ github.event.pull_request.number }}/merge
- uses: cachix/install-nix-action@v17
with:
# explicitly enable sandbox
extra_nix_config: sandbox = true
- uses: cachix/cachix-action@v10
with:
# This cache is for the nixpkgs repo checks and should not be trusted or used elsewhere.
name: nixpkgs-ci
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
- name: Building Nixpkgs manual
run: NIX_PATH=nixpkgs=$(pwd) nix-build --option restrict-eval true pkgs/top-level/release.nix -A manual

View File

@@ -1,34 +0,0 @@
name: NixOS manual checks
permissions: read-all
on:
pull_request_target:
branches-ignore:
- 'release-**'
paths:
- 'nixos/**/*.xml'
- 'nixos/**/*.md'
jobs:
tests:
runs-on: ubuntu-latest
if: github.repository_owner == 'NixOS'
steps:
- uses: actions/checkout@v3
with:
# pull_request_target checks out the base branch by default
ref: refs/pull/${{ github.event.pull_request.number }}/merge
- uses: cachix/install-nix-action@v17
- name: Check DocBook files generated from Markdown are consistent
run: |
nixos/doc/manual/md-to-db.sh
git diff --exit-code || {
echo
echo 'Generated manual files are out of date.'
echo 'Please run'
echo
echo ' nixos/doc/manual/md-to-db.sh'
echo
exit 1
}

View File

@@ -1,26 +0,0 @@
name: "No channel PR"
on:
pull_request:
branches:
- 'nixos-**'
- 'nixpkgs-**'
permissions:
contents: read
jobs:
fail:
permissions:
contents: none
name: "This PR is is targeting a channel branch"
runs-on: ubuntu-latest
steps:
- run: |
cat <<EOF
The nixos-* and nixpkgs-* branches are pushed to by the channel
release script and should not be merged into directly.
Please target the equivalent release-* branch or master instead.
EOF
exit 1

View File

@@ -1,26 +0,0 @@
name: "clear pending status"
on:
check_suite:
types: [ completed ]
permissions:
contents: read
jobs:
action:
permissions:
statuses: write
runs-on: ubuntu-latest
steps:
- name: clear pending status
if: github.repository_owner == 'NixOS' && github.event.check_suite.app.name == 'OfBorg'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
curl \
-X POST \
-H "Accept: application/vnd.github.v3+json" \
-H "Authorization: token $GITHUB_TOKEN" \
-d '{"state": "success", "target_url": " ", "description": " ", "context": "Wait for ofborg"}' \
"https://api.github.com/repos/NixOS/nixpkgs/statuses/${{ github.event.check_suite.head_sha }}"

View File

@@ -1,30 +0,0 @@
name: "set pending status"
on:
pull_request_target:
# WARNING:
# When extending this action, be aware that $GITHUB_TOKEN allows write access to
# the GitHub repository. This means that it should not evaluate user input in a
# way that allows code injection.
permissions:
contents: read
jobs:
action:
permissions:
statuses: write
runs-on: ubuntu-latest
steps:
- name: set pending status
if: github.repository_owner == 'NixOS'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
curl \
-X POST \
-H "Accept: application/vnd.github.v3+json" \
-H "Authorization: token $GITHUB_TOKEN" \
-d '{"state": "pending", "target_url": " ", "description": "This pending status will be cleared when ofborg starts eval.", "context": "Wait for ofborg"}' \
"https://api.github.com/repos/NixOS/nixpkgs/statuses/${{ github.event.pull_request.head.sha }}"

View File

@@ -1,59 +0,0 @@
# This action periodically merges base branches into staging branches.
# This is done to
# * prevent conflicts or rather resolve them early
# * make all potential breakage happen on the staging branch
# * and make sure that all major rebuilds happen before the staging
# branch gets merged back into its base branch.
name: "Periodic Merges (24h)"
on:
schedule:
# * is a special character in YAML so you have to quote this string
# Merge every 24 hours
- cron: '0 0 * * *'
permissions:
contents: read
jobs:
periodic-merge:
permissions:
contents: write # for devmasx/merge-branch to merge branches
issues: write # for peter-evans/create-or-update-comment to create or update comment
if: github.repository_owner == 'NixOS'
runs-on: ubuntu-latest
strategy:
# don't fail fast, so that all pairs are tried
fail-fast: false
# certain branches need to be merged in order, like master->staging-next->staging
# and disabling parallelism ensures the order of the pairs below.
max-parallel: 1
matrix:
pairs:
- from: master
into: haskell-updates
- from: release-22.05
into: staging-next-22.05
- from: staging-next-22.05
into: staging-22.05
name: ${{ matrix.pairs.from }} → ${{ matrix.pairs.into }}
steps:
- uses: actions/checkout@v3
- name: ${{ matrix.pairs.from }} → ${{ matrix.pairs.into }}
uses: devmasx/merge-branch@1.4.0
with:
type: now
from_branch: ${{ matrix.pairs.from }}
target_branch: ${{ matrix.pairs.into }}
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: Comment on failure
uses: peter-evans/create-or-update-comment@v2
if: ${{ failure() }}
with:
issue-number: 105153
body: |
Periodic merge from `${{ matrix.pairs.from }}` into `${{ matrix.pairs.into }}` has [failed](https://github.com/NixOS/nixpkgs/actions/runs/${{ github.run_id }}).

View File

@@ -1,57 +0,0 @@
# This action periodically merges base branches into staging branches.
# This is done to
# * prevent conflicts or rather resolve them early
# * make all potential breakage happen on the staging branch
# * and make sure that all major rebuilds happen before the staging
# branch gets merged back into its base branch.
name: "Periodic Merges (6h)"
on:
schedule:
# * is a special character in YAML so you have to quote this string
# Merge every 6 hours
- cron: '0 */6 * * *'
permissions:
contents: read
jobs:
periodic-merge:
permissions:
contents: write # for devmasx/merge-branch to merge branches
issues: write # for peter-evans/create-or-update-comment to create or update comment
if: github.repository_owner == 'NixOS'
runs-on: ubuntu-latest
strategy:
# don't fail fast, so that all pairs are tried
fail-fast: false
# certain branches need to be merged in order, like master->staging-next->staging
# and disabling parallelism ensures the order of the pairs below.
max-parallel: 1
matrix:
pairs:
- from: master
into: staging-next
- from: staging-next
into: staging
name: ${{ matrix.pairs.from }} → ${{ matrix.pairs.into }}
steps:
- uses: actions/checkout@v3
- name: ${{ matrix.pairs.from }} → ${{ matrix.pairs.into }}
uses: devmasx/merge-branch@1.4.0
with:
type: now
from_branch: ${{ matrix.pairs.from }}
target_branch: ${{ matrix.pairs.into }}
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: Comment on failure
uses: peter-evans/create-or-update-comment@v2
if: ${{ failure() }}
with:
issue-number: 105153
body: |
Periodic merge from `${{ matrix.pairs.from }}` into `${{ matrix.pairs.into }}` has [failed](https://github.com/NixOS/nixpkgs/actions/runs/${{ github.run_id }}).

View File

@@ -1,55 +0,0 @@
name: "Update terraform-providers"
on:
schedule:
- cron: "14 3 * * 0"
workflow_dispatch:
permissions:
contents: read
jobs:
tf-providers:
permissions:
contents: write # for peter-evans/create-pull-request to create branch
issues: write # for peter-evans/create-or-update-comment to create or update comment
pull-requests: write # for peter-evans/create-pull-request to create a PR
if: github.repository_owner == 'NixOS' && github.ref == 'refs/heads/master' # ensure workflow_dispatch only runs on master
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: cachix/install-nix-action@v17
- name: setup
id: setup
run: |
echo ::set-output name=title::"terraform-providers: update $(date -u +"%Y-%m-%d")"
- name: update terraform-providers
run: |
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config user.name "github-actions[bot]"
pushd pkgs/applications/networking/cluster/terraform-providers
./update-all-providers --no-build
git commit -m "${{ steps.setup.outputs.title }}" providers.json
popd
- name: create PR
uses: peter-evans/create-pull-request@v4
with:
body: |
Automatic update by [update-terraform-providers](https://github.com/NixOS/nixpkgs/blob/master/.github/workflows/update-terraform-providers.yml) action.
Check that all providers build with:
```
@ofborg build terraform.full
```
branch: terraform-providers-update
delete-branch: false
labels: "2.status: work-in-progress"
title: ${{ steps.setup.outputs.title }}
token: ${{ secrets.GITHUB_TOKEN }}
- name: comment on failure
uses: peter-evans/create-or-update-comment@v2
if: ${{ failure() }}
with:
issue-number: 153416
body: |
Automatic update of terraform providers [failed](https://github.com/NixOS/nixpkgs/actions/runs/${{ github.run_id }}).

20
.gitignore vendored
View File

@@ -2,28 +2,12 @@
,*
.*.swp
.*.swo
.idea/
.vscode/
outputs/
result
result-*
/doc/NEWS.html
/doc/NEWS.txt
/doc/manual.html
/doc/manual.pdf
/result
/source/
.version-suffix
.DS_Store
.mypy_cache
__pycache__
/pkgs/development/libraries/qt-5/*/tmp/
/pkgs/desktops/kde-5/*/tmp/
/pkgs/development/mobile/androidenv/xml/*
# generated by pkgs/common-updater/update-script.nix
update-git-commits.txt
# JetBrains IDEA module declaration file
/nixpkgs.iml
.DS_Store

5
.travis.yml Normal file
View File

@@ -0,0 +1,5 @@
language: python
python: "3.4"
before_install: ./maintainers/scripts/travis-nox-review-pr.sh nix
install: ./maintainers/scripts/travis-nox-review-pr.sh nox
script: ./maintainers/scripts/travis-nox-review-pr.sh build

View File

@@ -1 +1 @@
22.11
14.12

View File

@@ -1,134 +0,0 @@
# How to contribute
Note: contributing implies licensing those contributions
under the terms of [COPYING](COPYING), which is an MIT-like license.
## Opening issues
* Make sure you have a [GitHub account](https://github.com/signup/free)
* Make sure there is no open issue on the topic
* [Submit a new issue](https://github.com/NixOS/nixpkgs/issues/new/choose) by choosing the kind of topic and fill out the template
## Submitting changes
Read the ["Submitting changes"](https://nixos.org/nixpkgs/manual/#chap-submitting-changes) section of the nixpkgs manual. It explains how to write, test, and iterate on your change, and which branch to base your pull request against.
Below is a short excerpt of some points in there:
* Format the commit messages in the following way:
```
(pkg-name | nixos/<module>): (from -> to | init at version | refactor | etc)
(Motivation for change. Link to release notes. Additional information.)
```
For consistency, there should not be a period at the end of the commit message's summary line (the first line of the commit message).
Examples:
* nginx: init at 2.0.1
* firefox: 54.0.1 -> 55.0
https://www.mozilla.org/en-US/firefox/55.0/releasenotes/
* nixos/hydra: add bazBaz option
Dual baz behavior is needed to do foo.
* nixos/nginx: refactor config generation
The old config generation system used impure shell scripts and could break in specific circumstances (see #1234).
* `meta.description` should:
* Be capitalized.
* Not start with the package name.
* Not have a period at the end.
* `meta.license` must be set and fit the upstream license.
* If there is no upstream license, `meta.license` should default to `lib.licenses.unfree`.
* `meta.maintainers` must be set.
See the nixpkgs manual for more details on [standard meta-attributes](https://nixos.org/nixpkgs/manual/#sec-standard-meta-attributes).
## Writing good commit messages
In addition to writing properly formatted commit messages, it's important to include relevant information so other developers can later understand *why* a change was made. While this information usually can be found by digging code, mailing list/Discourse archives, pull request discussions or upstream changes, it may require a lot of work.
For package version upgrades and such a one-line commit message is usually sufficient.
## Rebasing between branches (i.e. from master to staging)
From time to time, changes between branches must be rebased, for example, if the
number of new rebuilds they would cause is too large for the target branch. When
rebasing, care must be taken to include only the intended changes, otherwise
many CODEOWNERS will be inadvertently requested for review. To achieve this,
rebasing should not be performed directly on the target branch, but on the merge
base between the current and target branch.
In the following example, we see a rebase from `master` onto the merge base
between `master` and `staging`, so that a change can eventually be retargeted to
`staging`. The example uses `upstream` as the remote for `NixOS/nixpkgs.git`
while the `origin` remote is used for the remote you are pushing to.
```console
# Find the common base between two branches
common=$(git merge-base upstream/master upstream/staging)
# Find the common base between your feature branch and master
commits=$(git merge-base $(git branch --show-current) upstream/master)
# Rebase all commits onto the common base
git rebase --onto=$common $commits
# Force push your changes
git push origin $(git branch --show-current) --force-with-lease
```
Then change the base branch in the GitHub PR using the *Edit* button in the upper
right corner, and switch from `master` to `staging`. After the PR has been
retargeted it might be necessary to do a final rebase onto the target branch, to
resolve any outstanding merge conflicts.
```console
# Rebase onto target branch
git rebase upstream/staging
# Review and fixup possible conflicts
git status
# Force push your changes
git push origin $(git branch --show-current) --force-with-lease
```
## Backporting changes
Follow these steps to backport a change into a release branch in compliance with the [commit policy](https://nixos.org/nixpkgs/manual/#submitting-changes-stable-release-branches).
You can add a label such as `backport release-22.05` to a PR, so that merging it will
automatically create a backport (via [a GitHub Action](.github/workflows/backport.yml)).
This also works for PR's that have already been merged, and might take a couple of minutes to trigger.
You can also create the backport manually:
1. Take note of the commits in which the change was introduced into `master` branch.
2. Check out the target _release branch_, e.g. `release-22.05`. Do not use a _channel branch_ like `nixos-22.05` or `nixpkgs-22.05-darwin`.
3. Create a branch for your change, e.g. `git checkout -b backport`.
4. When the reason to backport is not obvious from the original commit message, use `git cherry-pick -xe <original commit>` and add a reason. Otherwise use `git cherry-pick -x <original commit>`. That's fine for minor version updates that only include security and bug fixes, commits that fixes an otherwise broken package or similar. Please also ensure the commits exists on the master branch; in the case of squashed or rebased merges, the commit hash will change and the new commits can be found in the merge message at the bottom of the master pull request.
5. Push to GitHub and open a backport pull request. Make sure to select the release branch (e.g. `release-22.05`) as the target branch of the pull request, and link to the pull request in which the original change was comitted to `master`. The pull request title should be the commit title with the release version as prefix, e.g. `[22.05]`.
6. When the backport pull request is merged and you have the necessary privileges you can also replace the label `9.needs: port to stable` with `8.has: port to stable` on the original pull request. This way maintainers can keep track of missing backports easier.
## Criteria for Backporting changes
Anything that does not cause user or downstream dependency regressions can be backported. This includes:
- New Packages / Modules
- Security / Patch updates
- Version updates which include new functionality (but no breaking changes)
- Services which require a client to be up-to-date regardless. (E.g. `spotify`, `steam`, or `discord`)
- Security critical applications (E.g. `firefox`)
## Generating 22.11 Release Notes
Documentation in nixpkgs is transitioning to a markdown-centric workflow. Release notes now require a translation step to convert from markdown to a compatible docbook document.
Steps for updating 22.11 Release notes:
1. Edit `nixos/doc/manual/release-notes/rl-2211.section.md` with the desired changes
2. Run `./nixos/doc/manual/md-to-db.sh` to render `nixos/doc/manual/from_md/release-notes/rl-2211.section.xml`
3. Include changes to `rl-2211.section.md` and `rl-2211.section.xml` in the same commit.
## Reviewing contributions
See the nixpkgs manual for more details on how to [Review contributions](https://nixos.org/nixpkgs/manual/#chap-reviewing-contributions).

13
COPYING
View File

@@ -1,4 +1,4 @@
Copyright (c) 2003-2022 Eelco Dolstra and the Nixpkgs/NixOS contributors
Copyright (c) 2003-2006 Eelco Dolstra
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
@@ -18,3 +18,14 @@ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
======================================================================
Note: the license above does not apply to the packages built by the
Nix Packages collection, merely to the package descriptions (i.e., Nix
expressions, build scripts, etc.). Also, the license does not apply
to some of the binaries used for bootstrapping Nixpkgs (e.g.,
pkgs/stdenv/linux/tools/bash). It also might not apply to patches
included in Nixpkgs, which may be derivative works of the packages to
which they apply. The aforementioned artifacts are all covered by the
licenses of the respective packages.

127
README.md
View File

@@ -1,119 +1,10 @@
<p align="center">
<a href="https://nixos.org#gh-light-mode-only">
<img src="https://raw.githubusercontent.com/NixOS/nixos-homepage/master/logo/nixos-hires.png" width="500px" alt="NixOS logo"/>
</a>
<a href="https://nixos.org#gh-dark-mode-only">
<img src="https://raw.githubusercontent.com/NixOS/nixos-artwork/master/logo/nixos-white.png" width="500px" alt="NixOS logo"/>
</a>
</p>
Nixpkgs is a collection of packages for [Nix](https://nixos.org/nix/) package
manager. Nixpkgs also includes [NixOS](https://nixos.org/nixos/) linux distribution source code.
<p align="center">
<a href="https://github.com/NixOS/nixpkgs/blob/master/CONTRIBUTING.md"><img src="https://img.shields.io/github/contributors-anon/NixOS/nixpkgs" alt="Contributors badge" /></a>
<a href="https://opencollective.com/nixos"><img src="https://opencollective.com/nixos/tiers/supporter/badge.svg?label=supporters&color=brightgreen" alt="Open Collective supporters" /></a>
</p>
[Nixpkgs](https://github.com/nixos/nixpkgs) is a collection of over
80,000 software packages that can be installed with the
[Nix](https://nixos.org/nix/) package manager. It also implements
[NixOS](https://nixos.org/nixos/), a purely-functional Linux distribution.
# Manuals
* [NixOS Manual](https://nixos.org/nixos/manual) - how to install, configure, and maintain a purely-functional Linux distribution
* [Nixpkgs Manual](https://nixos.org/nixpkgs/manual/) - contributing to Nixpkgs and using programming-language-specific Nix expressions
* [Nix Package Manager Manual](https://nixos.org/nix/manual) - how to write Nix expressions (programs), and how to use Nix command line tools
# Community
* [Discourse Forum](https://discourse.nixos.org/)
* [Matrix Chat](https://matrix.to/#/#community:nixos.org)
* [NixOS Weekly](https://weekly.nixos.org/)
* [Community-maintained wiki](https://nixos.wiki/)
* [Community-maintained list of ways to get in touch](https://nixos.wiki/wiki/Get_In_Touch#Chat) (Discord, Telegram, IRC, etc.)
# Other Project Repositories
The sources of all official Nix-related projects are in the [NixOS
organization on GitHub](https://github.com/NixOS/). Here are some of
the main ones:
* [Nix](https://github.com/NixOS/nix) - the purely functional package manager
* [NixOps](https://github.com/NixOS/nixops) - the tool to remotely deploy NixOS machines
* [nixos-hardware](https://github.com/NixOS/nixos-hardware) - NixOS profiles to optimize settings for different hardware
* [Nix RFCs](https://github.com/NixOS/rfcs) - the formal process for making substantial changes to the community
* [NixOS homepage](https://github.com/NixOS/nixos-homepage) - the [NixOS.org](https://nixos.org) website
* [hydra](https://github.com/NixOS/hydra) - our continuous integration system
* [NixOS Artwork](https://github.com/NixOS/nixos-artwork) - NixOS artwork
# Continuous Integration and Distribution
Nixpkgs and NixOS are built and tested by our continuous integration
system, [Hydra](https://hydra.nixos.org/).
* [Continuous package builds for unstable/master](https://hydra.nixos.org/jobset/nixos/trunk-combined)
* [Continuous package builds for the NixOS 22.05 release](https://hydra.nixos.org/jobset/nixos/release-22.05)
* [Tests for unstable/master](https://hydra.nixos.org/job/nixos/trunk-combined/tested#tabs-constituents)
* [Tests for the NixOS 22.05 release](https://hydra.nixos.org/job/nixos/release-22.05/tested#tabs-constituents)
Artifacts successfully built with Hydra are published to cache at
https://cache.nixos.org/. When successful build and test criteria are
met, the Nixpkgs expressions are distributed via [Nix
channels](https://nixos.org/manual/nix/stable/package-management/channels.html).
# Contributing
Nixpkgs is among the most active projects on GitHub. While thousands
of open issues and pull requests might seem a lot at first, it helps
consider it in the context of the scope of the project. Nixpkgs
describes how to build tens of thousands of pieces of software and implements a
Linux distribution. The [GitHub Insights](https://github.com/NixOS/nixpkgs/pulse)
page gives a sense of the project activity.
Community contributions are always welcome through GitHub Issues and
Pull Requests. When pull requests are made, our tooling automation bot,
[OfBorg](https://github.com/NixOS/ofborg) will perform various checks
to help ensure expression quality.
The *Nixpkgs maintainers* are people who have assigned themselves to
maintain specific individual packages. We encourage people who care
about a package to assign themselves as a maintainer. When a pull
request is made against a package, OfBorg will notify the appropriate
maintainer(s). The *Nixpkgs committers* are people who have been given
permission to merge.
Most contributions are based on and merged into these branches:
* `master` is the main branch where all small contributions go
* `staging` is branched from master, changes that have a big impact on
Hydra builds go to this branch
* `staging-next` is branched from staging and only fixes to stabilize
and security fixes with a big impact on Hydra builds should be
contributed to this branch. This branch is merged into master when
deemed of sufficiently high quality
For more information about contributing to the project, please visit
the [contributing page](https://github.com/NixOS/nixpkgs/blob/master/CONTRIBUTING.md).
# Donations
The infrastructure for NixOS and related projects is maintained by a
nonprofit organization, the [NixOS
Foundation](https://nixos.org/nixos/foundation.html). To ensure the
continuity and expansion of the NixOS infrastructure, we are looking
for donations to our organization.
You can donate to the NixOS foundation through [SEPA bank
transfers](https://nixos.org/donate.html) or by using Open Collective:
<a href="https://opencollective.com/nixos#support"><img src="https://opencollective.com/nixos/tiers/supporter.svg?width=890" /></a>
# License
Nixpkgs is licensed under the [MIT License](COPYING).
Note: MIT license does not apply to the packages built by Nixpkgs,
merely to the files in this repository (the Nix expressions, build
scripts, NixOS modules, etc.). It also might not apply to patches
included in Nixpkgs, which may be derivative works of the packages to
which they apply. The aforementioned artifacts are all covered by the
licenses of the respective packages.
* [NixOS installation instructions](https://nixos.org/nixos/manual/#ch-installation)
* [Manual (How to write packages for Nix)](https://nixos.org/nixpkgs/manual/)
* [Manual (NixOS)](https://nixos.org/nixos/manual/)
* [Continuous build](https://hydra.nixos.org/jobset/nixos/trunk-combined)
* [Tests](https://hydra.nixos.org/job/nixos/trunk-combined/tested#tabs-constituents)
* [Mailing list](https://lists.science.uu.nl/mailman/listinfo/nix-dev)
* [IRC - #nixos on freenode.net](irc://irc.freenode.net/#nixos)

View File

@@ -1,28 +1,7 @@
let requiredVersion = import ./lib/minver.nix; in
if ! builtins ? nixVersion || builtins.compareVersions "1.7" builtins.nixVersion == 1 then
if ! builtins ? nixVersion || builtins.compareVersions requiredVersion builtins.nixVersion == 1 then
abort ''
This version of Nixpkgs requires Nix >= ${requiredVersion}, please upgrade:
- If you are running NixOS, `nixos-rebuild' can be used to upgrade your system.
- Alternatively, with Nix > 2.0 `nix upgrade-nix' can be used to imperatively
upgrade Nix. You may use `nix-env --version' to check which version you have.
- If you installed Nix using the install script (https://nixos.org/nix/install),
it is safe to upgrade by running it again:
curl -L https://nixos.org/nix/install | sh
For more information, please see the NixOS release notes at
https://nixos.org/nixos/manual or locally at
${toString ./nixos/doc/manual/release-notes}.
If you need further help, see https://nixos.org/nixos/support.html
''
abort "This version of Nixpkgs requires Nix >= 1.7, please upgrade! See https://nixos.org/wiki/How_to_update_when_nix_is_too_old_to_evaluate_nixpkgs"
else
import ./pkgs/top-level/impure.nix
import ./pkgs/top-level/all-packages.nix

8
doc/.gitignore vendored
View File

@@ -1,8 +0,0 @@
*.chapter.xml
*.section.xml
.version
functions/library/generated
functions/library/locations.xml
highlightjs
manual-full.xml
out

View File

@@ -1,116 +0,0 @@
MD_TARGETS=$(addsuffix .xml, $(basename $(shell find . -type f -regex '.*\.md$$' -not -name README.md)))
PANDOC ?= pandoc
pandoc_media_dir = media
# NOTE: Keep in sync with NixOS manual (/nixos/doc/manual/md-to-db.sh) and conversion script (/maintainers/scripts/db-to-md.sh).
# TODO: Remove raw-attribute when we can get rid of DocBook altogether.
pandoc_commonmark_enabled_extensions = +attributes+fenced_divs+footnotes+bracketed_spans+definition_lists+pipe_tables+raw_attribute
# Not needed:
# - docbook-reader/citerefentry-to-rst-role.lua (only relevant for DocBook → MarkDown/rST/MyST)
pandoc_flags = --extract-media=$(pandoc_media_dir) \
--lua-filter=$(PANDOC_LUA_FILTERS_DIR)/diagram-generator.lua \
--lua-filter=build-aux/pandoc-filters/myst-reader/roles.lua \
--lua-filter=build-aux/pandoc-filters/link-unix-man-references.lua \
--lua-filter=build-aux/pandoc-filters/docbook-writer/rst-roles.lua \
--lua-filter=build-aux/pandoc-filters/docbook-writer/labelless-link-is-xref.lua \
-f commonmark$(pandoc_commonmark_enabled_extensions)+smart
.PHONY: all
all: validate format out/html/index.html out/epub/manual.epub
.PHONY: debug
debug:
nix-shell --run "xmloscopy --docbook5 ./manual.xml ./manual-full.xml"
.PHONY: format
format: doc-support/result
find . -iname '*.xml' -type f | while read f; do \
echo $$f ;\
xmlformat --config-file "doc-support/result/xmlformat.conf" -i $$f ;\
done
.PHONY: fix-misc-xml
fix-misc-xml:
find . -iname '*.xml' -type f \
-exec ../nixos/doc/varlistentry-fixer.rb {} ';'
.PHONY: clean
clean:
rm -f ${MD_TARGETS} doc-support/result .version manual-full.xml functions/library/locations.xml functions/library/generated
rm -rf ./out/ ./highlightjs ./media
.PHONY: validate
validate: manual-full.xml doc-support/result
jing doc-support/result/docbook.rng manual-full.xml
out/html/index.html: doc-support/result manual-full.xml style.css highlightjs
mkdir -p out/html
xsltproc \
--nonet --xinclude \
--output $@ \
doc-support/result/xhtml.xsl \
./manual-full.xml
mkdir -p out/html/highlightjs/
cp -r highlightjs out/html/
cp -r $(pandoc_media_dir) out/html/
cp ./overrides.css out/html/
cp ./style.css out/html/style.css
mkdir -p out/html/images/callouts
cp doc-support/result/xsl/docbook/images/callouts/*.svg out/html/images/callouts/
chmod u+w -R out/html/
out/epub/manual.epub: manual-full.xml
mkdir -p out/epub/scratch
xsltproc --nonet \
--output out/epub/scratch/ \
doc-support/result/epub.xsl \
./manual-full.xml
cp -r $(pandoc_media_dir) out/epub/scratch/OEBPS
cp ./overrides.css out/epub/scratch/OEBPS
cp ./style.css out/epub/scratch/OEBPS
mkdir -p out/epub/scratch/OEBPS/images/callouts/
cp doc-support/result/xsl/docbook/images/callouts/*.svg out/epub/scratch/OEBPS/images/callouts/
echo "application/epub+zip" > mimetype
zip -0Xq "out/epub/manual.epub" mimetype
rm mimetype
cd "out/epub/scratch/" && zip -Xr9D "../manual.epub" *
rm -rf "out/epub/scratch/"
highlightjs: doc-support/result
mkdir -p highlightjs
cp -r doc-support/result/highlightjs/highlight.pack.js highlightjs/
cp -r doc-support/result/highlightjs/LICENSE highlightjs/
cp -r doc-support/result/highlightjs/mono-blue.css highlightjs/
cp -r doc-support/result/highlightjs/loader.js highlightjs/
manual-full.xml: ${MD_TARGETS} .version functions/library/locations.xml functions/library/generated *.xml **/*.xml **/**/*.xml
xmllint --nonet --xinclude --noxincludenode manual.xml --output manual-full.xml
.version: doc-support/result
ln -rfs ./doc-support/result/version .version
doc-support/result: doc-support/default.nix
(cd doc-support; nix-build)
functions/library/locations.xml: doc-support/result
ln -rfs ./doc-support/result/function-locations.xml functions/library/locations.xml
functions/library/generated: doc-support/result
ln -rfs ./doc-support/result/function-docs functions/library/generated
%.section.xml: %.section.md
$(PANDOC) $^ -t docbook \
$(pandoc_flags) \
-o $@
%.chapter.xml: %.chapter.md
$(PANDOC) $^ -t docbook \
--top-level-division=chapter \
$(pandoc_flags) \
-o $@

View File

@@ -1,12 +0,0 @@
# Nixpkgs/doc
This directory houses the sources files for the Nixpkgs manual.
You can find the [rendered documentation for Nixpkgs `unstable` on nixos.org](https://nixos.org/manual/nixpkgs/unstable/).
[Docs for Nixpkgs stable](https://nixos.org/manual/nixpkgs/stable/) are also available.
If you want to contribute to the documentation, [here's how to do it](https://nixos.org/manual/nixpkgs/unstable/#chap-contributing).
If you're only getting started with Nix, go to [nixos.org/learn](https://nixos.org/learn).

View File

@@ -1,23 +0,0 @@
--[[
Converts Code AST nodes produced by pandocs DocBook reader
from citerefentry elements into AST for corresponding role
for reStructuredText.
We use subset of MyST syntax (CommonMark with features from rST)
so lets use the rST AST for rST features.
Reference: https://www.sphinx-doc.org/en/master/usage/restructuredtext/roles.html#role-manpage
]]
function Code(elem)
elem.classes = elem.classes:map(function (x)
if x == 'citerefentry' then
elem.attributes['role'] = 'manpage'
return 'interpreted-text'
else
return x
end
end)
return elem
end

View File

@@ -1,34 +0,0 @@
--[[
Converts Link AST nodes with empty label to DocBook xref elements.
This is a temporary script to be able use cross-references conveniently
using syntax taken from MyST, while we still use docbook-xsl
for generating the documentation.
Reference: https://myst-parser.readthedocs.io/en/latest/using/syntax.html#targets-and-cross-referencing
]]
local function starts_with(start, str)
return str:sub(1, #start) == start
end
local function escape_xml_arg(arg)
amps = arg:gsub('&', '&amp;')
amps_quotes = amps:gsub('"', '&quot;')
amps_quotes_lt = amps_quotes:gsub('<', '&lt;')
return amps_quotes_lt
end
function Link(elem)
has_no_content = #elem.content == 0
targets_anchor = starts_with('#', elem.target)
has_no_attributes = elem.title == '' and elem.identifier == '' and #elem.classes == 0 and #elem.attributes == 0
if has_no_content and targets_anchor and has_no_attributes then
-- xref expects idref without the pound-sign
target_without_hash = elem.target:sub(2, #elem.target)
return pandoc.RawInline('docbook', '<xref linkend="' .. escape_xml_arg(target_without_hash) .. '" />')
end
end

View File

@@ -1,40 +0,0 @@
--[[
Converts AST for reStructuredText roles into corresponding
DocBook elements.
Currently, only a subset of roles is supported.
Reference:
List of roles:
https://www.sphinx-doc.org/en/master/usage/restructuredtext/roles.html
manpage:
https://tdg.docbook.org/tdg/5.1/citerefentry.html
file:
https://tdg.docbook.org/tdg/5.1/filename.html
]]
function Code(elem)
if elem.classes:includes('interpreted-text') then
local tag = nil
local content = elem.text
if elem.attributes['role'] == 'manpage' then
tag = 'citerefentry'
local title, volnum = content:match('^(.+)%((%w+)%)$')
if title == nil then
-- No volnum in parentheses.
title = content
end
content = '<refentrytitle>' .. title .. '</refentrytitle>' .. (volnum ~= nil and ('<manvolnum>' .. volnum .. '</manvolnum>') or '')
elseif elem.attributes['role'] == 'file' then
tag = 'filename'
elseif elem.attributes['role'] == 'command' then
tag = 'command'
elseif elem.attributes['role'] == 'option' then
tag = 'option'
end
if tag ~= nil then
return pandoc.RawInline('docbook', '<' .. tag .. '>' .. content .. '</' .. tag .. '>')
end
end
end

View File

@@ -1,17 +0,0 @@
--[[
Turns a manpage reference into a link, when a mapping is defined below.
]]
local man_urls = {
["tmpfiles.d(5)"] = "https://www.freedesktop.org/software/systemd/man/tmpfiles.d.html",
["nix.conf(5)"] = "https://nixos.org/manual/nix/stable/#sec-conf-file",
["systemd.time(7)"] = "https://www.freedesktop.org/software/systemd/man/systemd.time.html",
["systemd.timer(5)"] = "https://www.freedesktop.org/software/systemd/man/systemd.timer.html",
}
function Code(elem)
local is_man_role = elem.classes:includes('interpreted-text') and elem.attributes['role'] == 'manpage'
if is_man_role and man_urls[elem.text] ~= nil then
return pandoc.Link(elem, man_urls[elem.text])
end
end

View File

@@ -1,29 +0,0 @@
--[[
Replaces Str AST nodes containing {role}, followed by a Code node
by a Code node with attrs that would be produced by rST reader
from the role syntax.
This is to emulate MyST syntax in Pandoc.
(MyST is a CommonMark flavour with rST features mixed in.)
Reference: https://myst-parser.readthedocs.io/en/latest/syntax/syntax.html#roles-an-in-line-extension-point
]]
function Inlines(inlines)
for i = #inlines-1,1,-1 do
local first = inlines[i]
local second = inlines[i+1]
local correct_tags = first.tag == 'Str' and second.tag == 'Code'
if correct_tags then
-- docutils supports alphanumeric strings separated by [-._:]
-- We are slightly more liberal for simplicity.
local role = first.text:match('^{([-._+:%w]+)}$')
if role ~= nil then
inlines:remove(i)
second.attributes['role'] = role
second.classes:insert('interpreted-text')
end
end
end
return inlines
end

View File

@@ -1,25 +0,0 @@
--[[
Replaces Code nodes with attrs that would be produced by rST reader
from the role syntax by a Str AST node containing {role}, followed by a Code node.
This is to emulate MyST syntax in Pandoc.
(MyST is a CommonMark flavour with rST features mixed in.)
Reference: https://myst-parser.readthedocs.io/en/latest/syntax/syntax.html#roles-an-in-line-extension-point
]]
function Code(elem)
local role = elem.attributes['role']
if elem.classes:includes('interpreted-text') and role ~= nil then
elem.classes = elem.classes:filter(function (c)
return c ~= 'interpreted-text'
end)
elem.attributes['role'] = nil
return {
pandoc.Str('{' .. role .. '}'),
elem,
}
end
end

View File

@@ -1,165 +0,0 @@
# Fetchers {#chap-pkgs-fetchers}
Building software with Nix often requires downloading source code and other files from the internet.
`nixpkgs` provides *fetchers* for different protocols and services. Fetchers are functions that simplify downloading files.
## Caveats
Fetchers create [fixed output derivations](https://nixos.org/manual/nix/stable/#fixed-output-drvs) from downloaded files.
Nix can reuse the downloaded files via the hash of the resulting derivation.
The fact that the hash belongs to the Nix derivation output and not the file itself can lead to confusion.
For example, consider the following fetcher:
```nix
fetchurl {
url = "http://www.example.org/hello-1.0.tar.gz";
sha256 = "0v6r3wwnsk5pdjr188nip3pjgn1jrn5pc5ajpcfy6had6b3v4dwm";
};
```
A common mistake is to update a fetchers URL, or a version parameter, without updating the hash.
```nix
fetchurl {
url = "http://www.example.org/hello-1.1.tar.gz";
sha256 = "0v6r3wwnsk5pdjr188nip3pjgn1jrn5pc5ajpcfy6had6b3v4dwm";
};
```
**This will reuse the old contents**.
Remember to invalidate the hash argument, in this case by setting the `sha256` attribute to an empty string.
```nix
fetchurl {
url = "http://www.example.org/hello-1.1.tar.gz";
sha256 = "";
};
```
Use the resulting error message to determine the correct hash.
```
error: hash mismatch in fixed-output derivation '/path/to/my.drv':
specified: sha256-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=
got: sha256-RApQUm78dswhBLC/rfU9y0u6pSAzHceIJqgmetRD24E=
```
A similar problem arises while testing changes to a fetcher's implementation. If the output of the derivation already exists in the Nix store, test failures can go undetected. The [`invalidateFetcherByDrvHash`](#tester-invalidateFetcherByDrvHash) function helps prevent reusing cached derivations.
## `fetchurl` and `fetchzip` {#fetchurl}
Two basic fetchers are `fetchurl` and `fetchzip`. Both of these have two required arguments, a URL and a hash. The hash is typically `sha256`, although many more hash algorithms are supported. Nixpkgs contributors are currently recommended to use `sha256`. This hash will be used by Nix to identify your source. A typical usage of `fetchurl` is provided below.
```nix
{ stdenv, fetchurl }:
stdenv.mkDerivation {
name = "hello";
src = fetchurl {
url = "http://www.example.org/hello.tar.gz";
sha256 = "1111111111111111111111111111111111111111111111111111";
};
}
```
The main difference between `fetchurl` and `fetchzip` is in how they store the contents. `fetchurl` will store the unaltered contents of the URL within the Nix store. `fetchzip` on the other hand, will decompress the archive for you, making files and directories directly accessible in the future. `fetchzip` can only be used with archives. Despite the name, `fetchzip` is not limited to .zip files and can also be used with any tarball.
## `fetchpatch` {#fetchpatch}
`fetchpatch` works very similarly to `fetchurl` with the same arguments expected. It expects patch files as a source and performs normalization on them before computing the checksum. For example, it will remove comments or other unstable parts that are sometimes added by version control systems and can change over time.
- `relative`: Similar to using `git-diff`'s `--relative` flag, only keep changes inside the specified directory, making paths relative to it.
- `stripLen`: Remove the first `stripLen` components of pathnames in the patch.
- `extraPrefix`: Prefix pathnames by this string.
- `excludes`: Exclude files matching these patterns (applies after the above arguments).
- `includes`: Include only files matching these patterns (applies after the above arguments).
- `revert`: Revert the patch.
Note that because the checksum is computed after applying these effects, using or modifying these arguments will have no effect unless the `sha256` argument is changed as well.
Most other fetchers return a directory rather than a single file.
## `fetchsvn` {#fetchsvn}
Used with Subversion. Expects `url` to a Subversion directory, `rev`, and `sha256`.
## `fetchgit` {#fetchgit}
Used with Git. Expects `url` to a Git repo, `rev`, and `sha256`. `rev` in this case can be full the git commit id (SHA1 hash) or a tag name like `refs/tags/v1.0`.
Additionally, the following optional arguments can be given: `fetchSubmodules = true` makes `fetchgit` also fetch the submodules of a repository. If `deepClone` is set to true, the entire repository is cloned as opposing to just creating a shallow clone. `deepClone = true` also implies `leaveDotGit = true` which means that the `.git` directory of the clone won't be removed after checkout.
If only parts of the repository are needed, `sparseCheckout` can be used. This will prevent git from fetching unnecessary blobs from server, see [git sparse-checkout](https://git-scm.com/docs/git-sparse-checkout) and [git clone --filter](https://git-scm.com/docs/git-clone#Documentation/git-clone.txt---filterltfilter-specgt) for more information:
```nix
{ stdenv, fetchgit }:
stdenv.mkDerivation {
name = "hello";
src = fetchgit {
url = "https://...";
sparseCheckout = ''
path/to/be/included
another/path
'';
sha256 = "0000000000000000000000000000000000000000000000000000";
};
}
```
## `fetchfossil` {#fetchfossil}
Used with Fossil. Expects `url` to a Fossil archive, `rev`, and `sha256`.
## `fetchcvs` {#fetchcvs}
Used with CVS. Expects `cvsRoot`, `tag`, and `sha256`.
## `fetchhg` {#fetchhg}
Used with Mercurial. Expects `url`, `rev`, and `sha256`.
A number of fetcher functions wrap part of `fetchurl` and `fetchzip`. They are mainly convenience functions intended for commonly used destinations of source code in Nixpkgs. These wrapper fetchers are listed below.
## `fetchFromGitea` {#fetchfromgitea}
`fetchFromGitea` expects five arguments. `domain` is the gitea server name. `owner` is a string corresponding to the Gitea user or organization that controls this repository. `repo` corresponds to the name of the software repository. These are located at the top of every Gitea HTML page as `owner`/`repo`. `rev` corresponds to the Git commit hash or tag (e.g `v1.0`) that will be downloaded from Git. Finally, `sha256` corresponds to the hash of the extracted directory. Again, other hash algorithms are also available but `sha256` is currently preferred.
## `fetchFromGitHub` {#fetchfromgithub}
`fetchFromGitHub` expects four arguments. `owner` is a string corresponding to the GitHub user or organization that controls this repository. `repo` corresponds to the name of the software repository. These are located at the top of every GitHub HTML page as `owner`/`repo`. `rev` corresponds to the Git commit hash or tag (e.g `v1.0`) that will be downloaded from Git. Finally, `sha256` corresponds to the hash of the extracted directory. Again, other hash algorithms are also available, but `sha256` is currently preferred.
`fetchFromGitHub` uses `fetchzip` to download the source archive generated by GitHub for the specified revision. If `leaveDotGit`, `deepClone` or `fetchSubmodules` are set to `true`, `fetchFromGitHub` will use `fetchgit` instead. Refer to its section for documentation of these options.
## `fetchFromGitLab` {#fetchfromgitlab}
This is used with GitLab repositories. The arguments expected are very similar to `fetchFromGitHub` above.
## `fetchFromGitiles` {#fetchfromgitiles}
This is used with Gitiles repositories. The arguments expected are similar to `fetchgit`.
## `fetchFromBitbucket` {#fetchfrombitbucket}
This is used with BitBucket repositories. The arguments expected are very similar to fetchFromGitHub above.
## `fetchFromSavannah` {#fetchfromsavannah}
This is used with Savannah repositories. The arguments expected are very similar to `fetchFromGitHub` above.
## `fetchFromRepoOrCz` {#fetchfromrepoorcz}
This is used with repo.or.cz repositories. The arguments expected are very similar to `fetchFromGitHub` above.
## `fetchFromSourcehut` {#fetchfromsourcehut}
This is used with sourcehut repositories. Similar to `fetchFromGitHub` above,
it expects `owner`, `repo`, `rev` and `sha256`, but don't forget the tilde (~)
in front of the username! Expected arguments also include `vc` ("git" (default)
or "hg"), `domain` and `fetchSubmodules`.
If `fetchSubmodules` is `true`, `fetchFromSourcehut` uses `fetchgit`
or `fetchhg` with `fetchSubmodules` or `fetchSubrepos` set to `true`,
respectively. Otherwise, the fetcher uses `fetchzip`.

View File

@@ -1,12 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="chap-images">
<title>Images</title>
<para>
This chapter describes tools for creating various types of images.
</para>
<xi:include href="images/appimagetools.section.xml" />
<xi:include href="images/dockertools.section.xml" />
<xi:include href="images/ocitools.section.xml" />
<xi:include href="images/snaptools.section.xml" />
</chapter>

View File

@@ -1,48 +0,0 @@
# pkgs.appimageTools {#sec-pkgs-appimageTools}
`pkgs.appimageTools` is a set of functions for extracting and wrapping [AppImage](https://appimage.org/) files. They are meant to be used if traditional packaging from source is infeasible, or it would take too long. To quickly run an AppImage file, `pkgs.appimage-run` can be used as well.
::: {.warning}
The `appimageTools` API is unstable and may be subject to backwards-incompatible changes in the future.
:::
## AppImage formats {#ssec-pkgs-appimageTools-formats}
There are different formats for AppImages, see [the specification](https://github.com/AppImage/AppImageSpec/blob/74ad9ca2f94bf864a4a0dac1f369dd4f00bd1c28/draft.md#image-format) for details.
- Type 1 images are ISO 9660 files that are also ELF executables.
- Type 2 images are ELF executables with an appended filesystem.
They can be told apart with `file -k`:
```ShellSession
$ file -k type1.AppImage
type1.AppImage: ELF 64-bit LSB executable, x86-64, version 1 (SYSV) ISO 9660 CD-ROM filesystem data 'AppImage' (Lepton 3.x), scale 0-0,
spot sensor temperature 0.000000, unit celsius, color scheme 0, calibration: offset 0.000000, slope 0.000000, dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.18, BuildID[sha1]=d629f6099d2344ad82818172add1d38c5e11bc6d, stripped\012- data
$ file -k type2.AppImage
type2.AppImage: ELF 64-bit LSB executable, x86-64, version 1 (SYSV) (Lepton 3.x), scale 232-60668, spot sensor temperature -4.187500, color scheme 15, show scale bar, calibration: offset -0.000000, slope 0.000000 (Lepton 2.x), scale 4111-45000, spot sensor temperature 412442.250000, color scheme 3, minimum point enabled, calibration: offset -75402534979642766821519867692934234112.000000, slope 5815371847733706829839455140374904832.000000, dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.18, BuildID[sha1]=79dcc4e55a61c293c5e19edbd8d65b202842579f, stripped\012- data
```
Note how the type 1 AppImage is described as an `ISO 9660 CD-ROM filesystem`, and the type 2 AppImage is not.
## Wrapping {#ssec-pkgs-appimageTools-wrapping}
Depending on the type of AppImage you're wrapping, you'll have to use `wrapType1` or `wrapType2`.
```nix
appimageTools.wrapType2 { # or wrapType1
name = "patchwork";
src = fetchurl {
url = "https://github.com/ssbc/patchwork/releases/download/v3.11.4/Patchwork-3.11.4-linux-x86_64.AppImage";
sha256 = "1blsprpkvm0ws9b96gb36f0rbf8f5jgmw4x6dsb1kswr4ysf591s";
};
extraPkgs = pkgs: with pkgs; [ ];
}
```
- `name` specifies the name of the resulting image.
- `src` specifies the AppImage file to extract.
- `extraPkgs` allows you to pass a function to include additional packages inside the FHS environment your AppImage is going to run in. There are a few ways to learn which dependencies an application needs:
- Looking through the extracted AppImage files, reading its scripts and running `patchelf` and `ldd` on its executables. This can also be done in `appimage-run`, by setting `APPIMAGE_DEBUG_EXEC=bash`.
- Running `strace -vfefile` on the wrapped executable, looking for libraries that can't be found.

View File

@@ -1,352 +0,0 @@
# pkgs.dockerTools {#sec-pkgs-dockerTools}
`pkgs.dockerTools` is a set of functions for creating and manipulating Docker images according to the [Docker Image Specification v1.2.0](https://github.com/moby/moby/blob/master/image/spec/v1.2.md#docker-image-specification-v120). Docker itself is not used to perform any of the operations done by these functions.
## buildImage {#ssec-pkgs-dockerTools-buildImage}
This function is analogous to the `docker build` command, in that it can be used to build a Docker-compatible repository tarball containing a single image with one or multiple layers. As such, the result is suitable for being loaded in Docker with `docker load`.
The parameters of `buildImage` with relative example values are described below:
[]{#ex-dockerTools-buildImage}
[]{#ex-dockerTools-buildImage-runAsRoot}
```nix
buildImage {
name = "redis";
tag = "latest";
fromImage = someBaseImage;
fromImageName = null;
fromImageTag = "latest";
copyToRoot = pkgs.buildEnv {
name = "image-root";
paths = [ pkgs.redis ];
pathsToLink = [ "/bin" ];
};
runAsRoot = ''
#!${pkgs.runtimeShell}
mkdir -p /data
'';
config = {
Cmd = [ "/bin/redis-server" ];
WorkingDir = "/data";
Volumes = { "/data" = { }; };
};
}
```
The above example will build a Docker image `redis/latest` from the given base image. Loading and running this image in Docker results in `redis-server` being started automatically.
- `name` specifies the name of the resulting image. This is the only required argument for `buildImage`.
- `tag` specifies the tag of the resulting image. By default it's `null`, which indicates that the nix output hash will be used as tag.
- `fromImage` is the repository tarball containing the base image. It must be a valid Docker image, such as exported by `docker save`. By default it's `null`, which can be seen as equivalent to `FROM scratch` of a `Dockerfile`.
- `fromImageName` can be used to further specify the base image within the repository, in case it contains multiple images. By default it's `null`, in which case `buildImage` will peek the first image available in the repository.
- `fromImageTag` can be used to further specify the tag of the base image within the repository, in case an image contains multiple tags. By default it's `null`, in which case `buildImage` will peek the first tag available for the base image.
- `copyToRoot` is a derivation that will be copied in the new layer of the resulting image. This can be similarly seen as `ADD contents/ /` in a `Dockerfile`. By default it's `null`.
- `runAsRoot` is a bash script that will run as root in an environment that overlays the existing layers of the base image with the new resulting layer, including the previously copied `contents` derivation. This can be similarly seen as `RUN ...` in a `Dockerfile`.
> **_NOTE:_** Using this parameter requires the `kvm` device to be available.
- `config` is used to specify the configuration of the containers that will be started off the built image in Docker. The available options are listed in the [Docker Image Specification v1.2.0](https://github.com/moby/moby/blob/master/image/spec/v1.2.md#image-json-field-descriptions).
After the new layer has been created, its closure (to which `contents`, `config` and `runAsRoot` contribute) will be copied in the layer itself. Only new dependencies that are not already in the existing layers will be copied.
At the end of the process, only one new single layer will be produced and added to the resulting image.
The resulting repository will only list the single image `image/tag`. In the case of [the `buildImage` example](#ex-dockerTools-buildImage), it would be `redis/latest`.
It is possible to inspect the arguments with which an image was built using its `buildArgs` attribute.
> **_NOTE:_** If you see errors similar to `getProtocolByName: does not exist (no such protocol name: tcp)` you may need to add `pkgs.iana-etc` to `contents`.
> **_NOTE:_** If you see errors similar to `Error_Protocol ("certificate has unknown CA",True,UnknownCa)` you may need to add `pkgs.cacert` to `contents`.
By default `buildImage` will use a static date of one second past the UNIX Epoch. This allows `buildImage` to produce binary reproducible images. When listing images with `docker images`, the newly created images will be listed like this:
```ShellSession
$ docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
hello latest 08c791c7846e 48 years ago 25.2MB
```
You can break binary reproducibility but have a sorted, meaningful `CREATED` column by setting `created` to `now`.
```nix
pkgs.dockerTools.buildImage {
name = "hello";
tag = "latest";
created = "now";
copyToRoot = pkgs.buildEnv {
name = "image-root";
paths = [ pkgs.hello ];
pathsToLink = [ "/bin" ];
};
config.Cmd = [ "/bin/hello" ];
}
```
Now the Docker CLI will display a reasonable date and sort the images as expected:
```ShellSession
$ docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
hello latest de2bf4786de6 About a minute ago 25.2MB
```
However, the produced images will not be binary reproducible.
## buildLayeredImage {#ssec-pkgs-dockerTools-buildLayeredImage}
Create a Docker image with many of the store paths being on their own layer to improve sharing between images. The image is realized into the Nix store as a gzipped tarball. Depending on the intended usage, many users might prefer to use `streamLayeredImage` instead, which this function uses internally.
`name`
: The name of the resulting image.
`tag` _optional_
: Tag of the generated image.
*Default:* the output path's hash
`fromImage` _optional_
: The repository tarball containing the base image. It must be a valid Docker image, such as one exported by `docker save`.
*Default:* `null`, which can be seen as equivalent to `FROM scratch` of a `Dockerfile`.
`contents` _optional_
: Top-level paths in the container. Either a single derivation, or a list of derivations.
*Default:* `[]`
`config` _optional_
: Run-time configuration of the container. A full list of the options are available at in the [Docker Image Specification v1.2.0](https://github.com/moby/moby/blob/master/image/spec/v1.2.md#image-json-field-descriptions).
*Default:* `{}`
`created` _optional_
: Date and time the layers were created. Follows the same `now` exception supported by `buildImage`.
*Default:* `1970-01-01T00:00:01Z`
`maxLayers` _optional_
: Maximum number of layers to create.
*Default:* `100`
*Maximum:* `125`
`extraCommands` _optional_
: Shell commands to run while building the final layer, without access to most of the layer contents. Changes to this layer are "on top" of all the other layers, so can create additional directories and files.
`fakeRootCommands` _optional_
: Shell commands to run while creating the archive for the final layer in a fakeroot environment. Unlike `extraCommands`, you can run `chown` to change the owners of the files in the archive, changing fakeroot's state instead of the real filesystem. The latter would require privileges that the build user does not have. Static binaries do not interact with the fakeroot environment. By default all files in the archive will be owned by root.
`enableFakechroot` _optional_
: Whether to run in `fakeRootCommands` in `fakechroot`, making programs behave as though `/` is the root of the image being created, while files in the Nix store are available as usual. This allows scripts that perform installation in `/` to work as expected. Considering that `fakechroot` is implemented via the same mechanism as `fakeroot`, the same caveats apply.
*Default:* `false`
### Behavior of `contents` in the final image {#dockerTools-buildLayeredImage-arg-contents}
Each path directly listed in `contents` will have a symlink in the root of the image.
For example:
```nix
pkgs.dockerTools.buildLayeredImage {
name = "hello";
contents = [ pkgs.hello ];
}
```
will create symlinks for all the paths in the `hello` package:
```ShellSession
/bin/hello -> /nix/store/h1zb1padqbbb7jicsvkmrym3r6snphxg-hello-2.10/bin/hello
/share/info/hello.info -> /nix/store/h1zb1padqbbb7jicsvkmrym3r6snphxg-hello-2.10/share/info/hello.info
/share/locale/bg/LC_MESSAGES/hello.mo -> /nix/store/h1zb1padqbbb7jicsvkmrym3r6snphxg-hello-2.10/share/locale/bg/LC_MESSAGES/hello.mo
```
### Automatic inclusion of `config` references {#dockerTools-buildLayeredImage-arg-config}
The closure of `config` is automatically included in the closure of the final image.
This allows you to make very simple Docker images with very little code. This container will start up and run `hello`:
```nix
pkgs.dockerTools.buildLayeredImage {
name = "hello";
config.Cmd = [ "${pkgs.hello}/bin/hello" ];
}
```
### Adjusting `maxLayers` {#dockerTools-buildLayeredImage-arg-maxLayers}
Increasing the `maxLayers` increases the number of layers which have a chance to be shared between different images.
Modern Docker installations support up to 128 layers, but older versions support as few as 42.
If the produced image will not be extended by other Docker builds, it is safe to set `maxLayers` to `128`. However, it will be impossible to extend the image further.
The first (`maxLayers-2`) most "popular" paths will have their own individual layers, then layer \#`maxLayers-1` will contain all the remaining "unpopular" paths, and finally layer \#`maxLayers` will contain the Image configuration.
Docker's Layers are not inherently ordered, they are content-addressable and are not explicitly layered until they are composed in to an Image.
## streamLayeredImage {#ssec-pkgs-dockerTools-streamLayeredImage}
Builds a script which, when run, will stream an uncompressed tarball of a Docker image to stdout. The arguments to this function are as for `buildLayeredImage`. This method of constructing an image does not realize the image into the Nix store, so it saves on IO and disk/cache space, particularly with large images.
The image produced by running the output script can be piped directly into `docker load`, to load it into the local docker daemon:
```ShellSession
$(nix-build) | docker load
```
Alternatively, the image be piped via `gzip` into `skopeo`, e.g., to copy it into a registry:
```ShellSession
$(nix-build) | gzip --fast | skopeo copy docker-archive:/dev/stdin docker://some_docker_registry/myimage:tag
```
## pullImage {#ssec-pkgs-dockerTools-fetchFromRegistry}
This function is analogous to the `docker pull` command, in that it can be used to pull a Docker image from a Docker registry. By default [Docker Hub](https://hub.docker.com/) is used to pull images.
Its parameters are described in the example below:
```nix
pullImage {
imageName = "nixos/nix";
imageDigest =
"sha256:20d9485b25ecfd89204e843a962c1bd70e9cc6858d65d7f5fadc340246e2116b";
finalImageName = "nix";
finalImageTag = "1.11";
sha256 = "0mqjy3zq2v6rrhizgb9nvhczl87lcfphq9601wcprdika2jz7qh8";
os = "linux";
arch = "x86_64";
}
```
- `imageName` specifies the name of the image to be downloaded, which can also include the registry namespace (e.g. `nixos`). This argument is required.
- `imageDigest` specifies the digest of the image to be downloaded. This argument is required.
- `finalImageName`, if specified, this is the name of the image to be created. Note it is never used to fetch the image since we prefer to rely on the immutable digest ID. By default it's equal to `imageName`.
- `finalImageTag`, if specified, this is the tag of the image to be created. Note it is never used to fetch the image since we prefer to rely on the immutable digest ID. By default it's `latest`.
- `sha256` is the checksum of the whole fetched image. This argument is required.
- `os`, if specified, is the operating system of the fetched image. By default it's `linux`.
- `arch`, if specified, is the cpu architecture of the fetched image. By default it's `x86_64`.
`nix-prefetch-docker` command can be used to get required image parameters:
```ShellSession
$ nix run nixpkgs.nix-prefetch-docker -c nix-prefetch-docker --image-name mysql --image-tag 5
```
Since a given `imageName` may transparently refer to a manifest list of images which support multiple architectures and/or operating systems, you can supply the `--os` and `--arch` arguments to specify exactly which image you want. By default it will match the OS and architecture of the host the command is run on.
```ShellSession
$ nix-prefetch-docker --image-name mysql --image-tag 5 --arch x86_64 --os linux
```
Desired image name and tag can be set using `--final-image-name` and `--final-image-tag` arguments:
```ShellSession
$ nix-prefetch-docker --image-name mysql --image-tag 5 --final-image-name eu.gcr.io/my-project/mysql --final-image-tag prod
```
## exportImage {#ssec-pkgs-dockerTools-exportImage}
This function is analogous to the `docker export` command, in that it can be used to flatten a Docker image that contains multiple layers. It is in fact the result of the merge of all the layers of the image. As such, the result is suitable for being imported in Docker with `docker import`.
> **_NOTE:_** Using this function requires the `kvm` device to be available.
The parameters of `exportImage` are the following:
```nix
exportImage {
fromImage = someLayeredImage;
fromImageName = null;
fromImageTag = null;
name = someLayeredImage.name;
}
```
The parameters relative to the base image have the same synopsis as described in [buildImage](#ssec-pkgs-dockerTools-buildImage), except that `fromImage` is the only required argument in this case.
The `name` argument is the name of the derivation output, which defaults to `fromImage.name`.
## shadowSetup {#ssec-pkgs-dockerTools-shadowSetup}
This constant string is a helper for setting up the base files for managing users and groups, only if such files don't exist already. It is suitable for being used in a [`buildImage` `runAsRoot`](#ex-dockerTools-buildImage-runAsRoot) script for cases like in the example below:
```nix
buildImage {
name = "shadow-basic";
runAsRoot = ''
#!${pkgs.runtimeShell}
${pkgs.dockerTools.shadowSetup}
groupadd -r redis
useradd -r -g redis redis
mkdir /data
chown redis:redis /data
'';
}
```
Creating base files like `/etc/passwd` or `/etc/login.defs` is necessary for shadow-utils to manipulate users and groups.
## fakeNss {#ssec-pkgs-dockerTools-fakeNss}
If your primary goal is providing a basic skeleton for user lookups to work,
and/or a lesser privileged user, adding `pkgs.fakeNss` to
the container image root might be the better choice than a custom script
running `useradd` and friends.
It provides a `/etc/passwd` and `/etc/group`, containing `root` and `nobody`
users and groups.
It also provides a `/etc/nsswitch.conf`, configuring NSS host resolution to
first check `/etc/hosts`, before checking DNS, as the default in the absence of
a config file (`dns [!UNAVAIL=return] files`) is quite unexpected.
You can pair it with `binSh`, which provides `bin/sh` as a symlink
to `bashInteractive` (as `/bin/sh` is configured as a shell).
```nix
buildImage {
name = "shadow-basic";
copyToRoot = pkgs.buildEnv {
name = "image-root";
paths = [ binSh pkgs.fakeNss ];
pathsToLink = [ "/bin" "/etc" "/var" ];
};
}
```

View File

@@ -1,37 +0,0 @@
# pkgs.ociTools {#sec-pkgs-ociTools}
`pkgs.ociTools` is a set of functions for creating containers according to the [OCI container specification v1.0.0](https://github.com/opencontainers/runtime-spec). Beyond that, it makes no assumptions about the container runner you choose to use to run the created container.
## buildContainer {#ssec-pkgs-ociTools-buildContainer}
This function creates a simple OCI container that runs a single command inside of it. An OCI container consists of a `config.json` and a rootfs directory. The nix store of the container will contain all referenced dependencies of the given command.
The parameters of `buildContainer` with an example value are described below:
```nix
buildContainer {
args = [
(with pkgs;
writeScript "run.sh" ''
#!${bash}/bin/bash
exec ${bash}/bin/bash
'').outPath
];
mounts = {
"/data" = {
type = "none";
source = "/var/lib/mydata";
options = [ "bind" ];
};
};
readonly = false;
}
```
- `args` specifies a set of arguments to run inside the container. This is the only required argument for `buildContainer`. All referenced packages inside the derivation will be made available inside the container.
- `mounts` specifies additional mount points chosen by the user. By default only a minimal set of necessary filesystems are mounted into the container (e.g procfs, cgroupfs)
- `readonly` makes the container\'s rootfs read-only if it is set to true. The default value is false `false`.

View File

@@ -1,71 +0,0 @@
# pkgs.snapTools {#sec-pkgs-snapTools}
`pkgs.snapTools` is a set of functions for creating Snapcraft images. Snap and Snapcraft is not used to perform these operations.
## The makeSnap Function {#ssec-pkgs-snapTools-makeSnap-signature}
`makeSnap` takes a single named argument, `meta`. This argument mirrors [the upstream `snap.yaml` format](https://docs.snapcraft.io/snap-format) exactly.
The `base` should not be specified, as `makeSnap` will force set it.
Currently, `makeSnap` does not support creating GUI stubs.
## Build a Hello World Snap {#ssec-pkgs-snapTools-build-a-snap-hello}
The following expression packages GNU Hello as a Snapcraft snap.
``` {#ex-snapTools-buildSnap-hello .nix}
let
inherit (import <nixpkgs> { }) snapTools hello;
in snapTools.makeSnap {
meta = {
name = "hello";
summary = hello.meta.description;
description = hello.meta.longDescription;
architectures = [ "amd64" ];
confinement = "strict";
apps.hello.command = "${hello}/bin/hello";
};
}
```
`nix-build` this expression and install it with `snap install ./result --dangerous`. `hello` will now be the Snapcraft version of the package.
## Build a Graphical Snap {#ssec-pkgs-snapTools-build-a-snap-firefox}
Graphical programs require many more integrations with the host. This example uses Firefox as an example because it is one of the most complicated programs we could package.
``` {#ex-snapTools-buildSnap-firefox .nix}
let
inherit (import <nixpkgs> { }) snapTools firefox;
in snapTools.makeSnap {
meta = {
name = "nix-example-firefox";
summary = firefox.meta.description;
architectures = [ "amd64" ];
apps.nix-example-firefox = {
command = "${firefox}/bin/firefox";
plugs = [
"pulseaudio"
"camera"
"browser-support"
"avahi-observe"
"cups-control"
"desktop"
"desktop-legacy"
"gsettings"
"home"
"network"
"mount-observe"
"removable-media"
"x11"
];
};
confinement = "strict";
};
}
```
`nix-build` this expression and install it with `snap install ./result --dangerous`. `nix-example-firefox` will now be the Snapcraft version of the Firefox package.
The specific meaning behind plugs can be looked up in the [Snapcraft interface documentation](https://docs.snapcraft.io/supported-interfaces).

View File

@@ -1,129 +0,0 @@
# Cataclysm: Dark Days Ahead {#cataclysm-dark-days-ahead}
## How to install Cataclysm DDA {#how-to-install-cataclysm-dda}
To install the latest stable release of Cataclysm DDA to your profile, execute
`nix-env -f "<nixpkgs>" -iA cataclysm-dda`. For the curses build (build
without tiles), install `cataclysmDDA.stable.curses`. Note: `cataclysm-dda` is
an alias to `cataclysmDDA.stable.tiles`.
If you like access to a development build of your favorite git revision,
override `cataclysm-dda-git` (or `cataclysmDDA.git.curses` if you like curses
build):
```nix
cataclysm-dda-git.override {
version = "YYYY-MM-DD";
rev = "YOUR_FAVORITE_REVISION";
sha256 = "CHECKSUM_OF_THE_REVISION";
}
```
The sha256 checksum can be obtained by
```sh
nix-prefetch-url --unpack "https://github.com/CleverRaven/Cataclysm-DDA/archive/${YOUR_FAVORITE_REVISION}.tar.gz"
```
The default configuration directory is `~/.cataclysm-dda`. If you prefer
`$XDG_CONFIG_HOME/cataclysm-dda`, override the derivation:
```nix
cataclysm-dda.override {
useXdgDir = true;
}
```
## Important note for overriding packages {#important-note-for-overriding-packages}
After applying `overrideAttrs`, you need to fix `passthru.pkgs` and
`passthru.withMods` attributes either manually or by using `attachPkgs`:
```nix
let
# You enabled parallel building.
myCDDA = cataclysm-dda-git.overrideAttrs (_: {
enableParallelBuilding = true;
});
# Unfortunately, this refers to the package before overriding and
# parallel building is still disabled.
badExample = myCDDA.withMods (_: []);
inherit (cataclysmDDA) attachPkgs pkgs wrapCDDA;
# You can fix it by hand
goodExample1 = myCDDA.overrideAttrs (old: {
passthru = old.passthru // {
pkgs = pkgs.override { build = goodExample1; };
withMods = wrapCDDA goodExample1;
};
});
# or by using a helper function `attachPkgs`.
goodExample2 = attachPkgs pkgs myCDDA;
in
# badExample # parallel building disabled
# goodExample1.withMods (_: []) # parallel building enabled
goodExample2.withMods (_: []) # parallel building enabled
```
## Customizing with mods {#customizing-with-mods}
To install Cataclysm DDA with mods of your choice, you can use `withMods`
attribute:
```nix
cataclysm-dda.withMods (mods: with mods; [
tileset.UndeadPeople
])
```
All mods, soundpacks, and tilesets available in nixpkgs are found in
`cataclysmDDA.pkgs`.
Here is an example to modify existing mods and/or add more mods not available
in nixpkgs:
```nix
let
customMods = self: super: lib.recursiveUpdate super {
# Modify existing mod
tileset.UndeadPeople = super.tileset.UndeadPeople.overrideAttrs (old: {
# If you like to apply a patch to the tileset for example
patches = [ ./path/to/your.patch ];
});
# Add another mod
mod.Awesome = cataclysmDDA.buildMod {
modName = "Awesome";
version = "0.x";
src = fetchFromGitHub {
owner = "Someone";
repo = "AwesomeMod";
rev = "...";
sha256 = "...";
};
# Path to be installed in the unpacked source (default: ".")
modRoot = "contents/under/this/path/will/be/installed";
};
# Add another soundpack
soundpack.Fantastic = cataclysmDDA.buildSoundPack {
# ditto
};
# Add another tileset
tileset.SuperDuper = cataclysmDDA.buildTileSet {
# ditto
};
};
in
cataclysm-dda.withMods (mods: with mods.extend customMods; [
tileset.UndeadPeople
mod.Awesome
soundpack.Fantastic
tileset.SuperDuper
])
```

View File

@@ -1,32 +0,0 @@
# Citrix Workspace {#sec-citrix}
The [Citrix Workspace App](https://www.citrix.com/products/workspace-app/) is a remote desktop viewer which provides access to [XenDesktop](https://www.citrix.com/products/xenapp-xendesktop/) installations.
## Basic usage {#sec-citrix-base}
The tarball archive needs to be downloaded manually, as the license agreements of the vendor for [Citrix Workspace](https://www.citrix.de/downloads/workspace-app/linux/workspace-app-for-linux-latest.html) needs to be accepted first. Then run `nix-prefetch-url file://$PWD/linuxx64-$version.tar.gz`. With the archive available in the store, the package can be built and installed with Nix.
## Citrix Self-service {#sec-citrix-selfservice}
The [self-service](https://support.citrix.com/article/CTX200337) is an application managing Citrix desktops and applications. Please note that this feature only works with at least citrix_workspace_20_06_0 and later versions.
In order to set this up, you first have to [download the `.cr` file from the Netscaler Gateway](https://its.uiowa.edu/support/article/102186). After that, you can configure the `selfservice` like this:
```ShellSession
$ storebrowse -C ~/Downloads/receiverconfig.cr
$ selfservice
```
## Custom certificates {#sec-citrix-custom-certs}
The `Citrix Workspace App` in `nixpkgs` trusts several certificates [from the Mozilla database](https://curl.haxx.se/docs/caextract.html) by default. However, several companies using Citrix might require their own corporate certificate. On distros with imperative packaging, these certs can be stored easily in [`$ICAROOT`](https://developer-docs.citrix.com/projects/receiver-for-linux-command-reference/en/13.7/), however this directory is a store path in `nixpkgs`. In order to work around this issue, the package provides a simple mechanism to add custom certificates without rebuilding the entire package using `symlinkJoin`:
```nix
with import <nixpkgs> { config.allowUnfree = true; };
let
extraCerts = [
./custom-cert-1.pem
./custom-cert-2.pem # ...
];
in citrix_workspace.override { inherit extraCerts; }
```

View File

@@ -1,13 +0,0 @@
# DLib {#dlib}
[DLib](http://dlib.net/) is a modern, C++-based toolkit which provides several machine learning algorithms.
## Compiling without AVX support {#compiling-without-avx-support}
Especially older CPUs don\'t support [AVX](https://en.wikipedia.org/wiki/Advanced_Vector_Extensions) (Advanced Vector Extensions) instructions that are used by DLib to optimize their algorithms.
On the affected hardware errors like `Illegal instruction` will occur. In those cases AVX support needs to be disabled:
```nix
self: super: { dlib = super.dlib.override { avxSupport = false; }; }
```

View File

@@ -1,64 +0,0 @@
# Eclipse {#sec-eclipse}
The Nix expressions related to the Eclipse platform and IDE are in [`pkgs/applications/editors/eclipse`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/editors/eclipse).
Nixpkgs provides a number of packages that will install Eclipse in its various forms. These range from the bare-bones Eclipse Platform to the more fully featured Eclipse SDK or Scala-IDE packages and multiple version are often available. It is possible to list available Eclipse packages by issuing the command:
```ShellSession
$ nix-env -f '<nixpkgs>' -qaP -A eclipses --description
```
Once an Eclipse variant is installed, it can be run using the `eclipse` command, as expected. From within Eclipse, it is then possible to install plugins in the usual manner by either manually specifying an Eclipse update site or by installing the Marketplace Client plugin and using it to discover and install other plugins. This installation method provides an Eclipse installation that closely resemble a manually installed Eclipse.
If you prefer to install plugins in a more declarative manner, then Nixpkgs also offer a number of Eclipse plugins that can be installed in an _Eclipse environment_. This type of environment is created using the function `eclipseWithPlugins` found inside the `nixpkgs.eclipses` attribute set. This function takes as argument `{ eclipse, plugins ? [], jvmArgs ? [] }` where `eclipse` is a one of the Eclipse packages described above, `plugins` is a list of plugin derivations, and `jvmArgs` is a list of arguments given to the JVM running the Eclipse. For example, say you wish to install the latest Eclipse Platform with the popular Eclipse Color Theme plugin and also allow Eclipse to use more RAM. You could then add:
```nix
packageOverrides = pkgs: {
myEclipse = with pkgs.eclipses; eclipseWithPlugins {
eclipse = eclipse-platform;
jvmArgs = [ "-Xmx2048m" ];
plugins = [ plugins.color-theme ];
};
}
```
to your Nixpkgs configuration (`~/.config/nixpkgs/config.nix`) and install it by running `nix-env -f '<nixpkgs>' -iA myEclipse` and afterward run Eclipse as usual. It is possible to find out which plugins are available for installation using `eclipseWithPlugins` by running:
```ShellSession
$ nix-env -f '<nixpkgs>' -qaP -A eclipses.plugins --description
```
If there is a need to install plugins that are not available in Nixpkgs then it may be possible to define these plugins outside Nixpkgs using the `buildEclipseUpdateSite` and `buildEclipsePlugin` functions found in the `nixpkgs.eclipses.plugins` attribute set. Use the `buildEclipseUpdateSite` function to install a plugin distributed as an Eclipse update site. This function takes `{ name, src }` as argument, where `src` indicates the Eclipse update site archive. All Eclipse features and plugins within the downloaded update site will be installed. When an update site archive is not available, then the `buildEclipsePlugin` function can be used to install a plugin that consists of a pair of feature and plugin JARs. This function takes an argument `{ name, srcFeature, srcPlugin }` where `srcFeature` and `srcPlugin` are the feature and plugin JARs, respectively.
Expanding the previous example with two plugins using the above functions, we have:
```nix
packageOverrides = pkgs: {
myEclipse = with pkgs.eclipses; eclipseWithPlugins {
eclipse = eclipse-platform;
jvmArgs = [ "-Xmx2048m" ];
plugins = [
plugins.color-theme
(plugins.buildEclipsePlugin {
name = "myplugin1-1.0";
srcFeature = fetchurl {
url = "http:///features/myplugin1.jar";
sha256 = "123";
};
srcPlugin = fetchurl {
url = "http:///plugins/myplugin1.jar";
sha256 = "123";
};
});
(plugins.buildEclipseUpdateSite {
name = "myplugin2-1.0";
src = fetchurl {
stripRoot = false;
url = "http:///myplugin2.zip";
sha256 = "123";
};
});
];
};
}
```

View File

@@ -1,11 +0,0 @@
# Elm {#sec-elm}
To start a development environment, run:
```ShellSession
nix-shell -p elmPackages.elm elmPackages.elm-format
```
To update the Elm compiler, see `nixpkgs/pkgs/development/compilers/elm/README.md`.
To package Elm applications, [read about elm2nix](https://github.com/hercules-ci/elm2nix#elm2nix).

View File

@@ -1,119 +0,0 @@
# Emacs {#sec-emacs}
## Configuring Emacs {#sec-emacs-config}
The Emacs package comes with some extra helpers to make it easier to configure. `emacs.pkgs.withPackages` allows you to manage packages from ELPA. This means that you will not have to install that packages from within Emacs. For instance, if you wanted to use `company` `counsel`, `flycheck`, `ivy`, `magit`, `projectile`, and `use-package` you could use this as a `~/.config/nixpkgs/config.nix` override:
```nix
{
packageOverrides = pkgs: with pkgs; {
myEmacs = emacs.pkgs.withPackages (epkgs: (with epkgs.melpaStablePackages; [
company
counsel
flycheck
ivy
magit
projectile
use-package
]));
}
}
```
You can install it like any other packages via `nix-env -iA myEmacs`. However, this will only install those packages. It will not `configure` them for us. To do this, we need to provide a configuration file. Luckily, it is possible to do this from within Nix! By modifying the above example, we can make Emacs load a custom config file. The key is to create a package that provides a `default.el` file in `/share/emacs/site-start/`. Emacs knows to load this file automatically when it starts.
```nix
{
packageOverrides = pkgs: with pkgs; rec {
myEmacsConfig = writeText "default.el" ''
;; initialize package
(require 'package)
(package-initialize 'noactivate)
(eval-when-compile
(require 'use-package))
;; load some packages
(use-package company
:bind ("<C-tab>" . company-complete)
:diminish company-mode
:commands (company-mode global-company-mode)
:defer 1
:config
(global-company-mode))
(use-package counsel
:commands (counsel-descbinds)
:bind (([remap execute-extended-command] . counsel-M-x)
("C-x C-f" . counsel-find-file)
("C-c g" . counsel-git)
("C-c j" . counsel-git-grep)
("C-c k" . counsel-ag)
("C-x l" . counsel-locate)
("M-y" . counsel-yank-pop)))
(use-package flycheck
:defer 2
:config (global-flycheck-mode))
(use-package ivy
:defer 1
:bind (("C-c C-r" . ivy-resume)
("C-x C-b" . ivy-switch-buffer)
:map ivy-minibuffer-map
("C-j" . ivy-call))
:diminish ivy-mode
:commands ivy-mode
:config
(ivy-mode 1))
(use-package magit
:defer
:if (executable-find "git")
:bind (("C-x g" . magit-status)
("C-x G" . magit-dispatch-popup))
:init
(setq magit-completing-read-function 'ivy-completing-read))
(use-package projectile
:commands projectile-mode
:bind-keymap ("C-c p" . projectile-command-map)
:defer 5
:config
(projectile-global-mode))
'';
myEmacs = emacs.pkgs.withPackages (epkgs: (with epkgs.melpaStablePackages; [
(runCommand "default.el" {} ''
mkdir -p $out/share/emacs/site-lisp
cp ${myEmacsConfig} $out/share/emacs/site-lisp/default.el
'')
company
counsel
flycheck
ivy
magit
projectile
use-package
]));
};
}
```
This provides a fairly full Emacs start file. It will load in addition to the user's personal config. You can always disable it by passing `-q` to the Emacs command.
Sometimes `emacs.pkgs.withPackages` is not enough, as this package set has some priorities imposed on packages (with the lowest priority assigned to Melpa Unstable, and the highest for packages manually defined in `pkgs/top-level/emacs-packages.nix`). But you can't control these priorities when some package is installed as a dependency. You can override it on a per-package-basis, providing all the required dependencies manually, but it's tedious and there is always a possibility that an unwanted dependency will sneak in through some other package. To completely override such a package, you can use `overrideScope'`.
```nix
overrides = self: super: rec {
haskell-mode = self.melpaPackages.haskell-mode;
...
};
((emacsPackagesFor emacs).overrideScope' overrides).withPackages
(p: with p; [
# here both these package will use haskell-mode of our own choice
ghc-mod
dante
])
```

View File

@@ -1,18 +0,0 @@
# /etc files {#etc}
Certain calls in glibc require access to runtime files found in `/etc` such as `/etc/protocols` or `/etc/services` -- [getprotobyname](https://linux.die.net/man/3/getprotobyname) is one such function.
On non-NixOS distributions these files are typically provided by packages (i.e., [netbase](https://packages.debian.org/sid/netbase)) if not already pre-installed in your distribution. This can cause non-reproducibility for code if they rely on these files being present.
If [iana-etc](https://hydra.nixos.org/job/nixos/trunk-combined/nixpkgs.iana-etc.x86_64-linux) is part of your `buildInputs`, then it will set the environment variables `NIX_ETC_PROTOCOLS` and `NIX_ETC_SERVICES` to the corresponding files in the package through a setup hook.
```bash
> nix-shell -p iana-etc
[nix-shell:~]$ env | grep NIX_ETC
NIX_ETC_SERVICES=/nix/store/aj866hr8fad8flnggwdhrldm0g799ccz-iana-etc-20210225/etc/services
NIX_ETC_PROTOCOLS=/nix/store/aj866hr8fad8flnggwdhrldm0g799ccz-iana-etc-20210225/etc/protocols
```
Nixpkg's version of [glibc](https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/libraries/glibc/default.nix) has been patched to check for the existence of these environment variables. If the environment variables are *not* set, then it will attempt to find the files at the default location within `/etc`.

View File

@@ -1,55 +0,0 @@
# Firefox {#sec-firefox}
## Build wrapped Firefox with extensions and policies {#build-wrapped-firefox-with-extensions-and-policies}
The `wrapFirefox` function allows to pass policies, preferences and extensions that are available to Firefox. With the help of `fetchFirefoxAddon` this allows to build a Firefox version that already comes with add-ons pre-installed:
```nix
{
# Nix firefox addons only work with the firefox-esr package.
myFirefox = wrapFirefox firefox-esr-unwrapped {
nixExtensions = [
(fetchFirefoxAddon {
name = "ublock"; # Has to be unique!
url = "https://addons.mozilla.org/firefox/downloads/file/3679754/ublock_origin-1.31.0-an+fx.xpi";
sha256 = "1h768ljlh3pi23l27qp961v1hd0nbj2vasgy11bmcrlqp40zgvnr";
})
];
extraPolicies = {
CaptivePortal = false;
DisableFirefoxStudies = true;
DisablePocket = true;
DisableTelemetry = true;
DisableFirefoxAccounts = true;
FirefoxHome = {
Pocket = false;
Snippets = false;
};
UserMessaging = {
ExtensionRecommendations = false;
SkipOnboarding = true;
};
SecurityDevices = {
# Use a proxy module rather than `nixpkgs.config.firefox.smartcardSupport = true`
"PKCS#11 Proxy Module" = "${pkgs.p11-kit}/lib/p11-kit-proxy.so";
};
};
extraPrefs = ''
// Show more ssl cert infos
lockPref("security.identityblock.show_extended_validation", true);
'';
};
}
```
If `nixExtensions != null`, then all manually installed add-ons will be uninstalled from your browser profile.
To view available enterprise policies, visit [enterprise policies](https://github.com/mozilla/policy-templates#enterprisepoliciesenabled)
or type into the Firefox URL bar: `about:policies#documentation`.
Nix installed add-ons do not have a valid signature, which is why signature verification is disabled. This does not compromise security because downloaded add-ons are checksummed and manual add-ons can't be installed. Also, make sure that the `name` field of `fetchFirefoxAddon` is unique. If you remove an add-on from the `nixExtensions` array, rebuild and start Firefox: the removed add-on will be completely removed with all of its settings.
## Troubleshooting {#sec-firefox-troubleshooting}
If add-ons are marked as broken or the signature is invalid, make sure you have Firefox ESR installed. Normal Firefox does not provide the ability anymore to disable signature verification for add-ons thus nix add-ons get disabled by the normal Firefox binary.
If add-ons do not appear installed despite being defined in your nix configuration file, reset the local add-on state of your Firefox profile by clicking `Help -> More Troubleshooting Information -> Refresh Firefox`. This can happen if you switch from manual add-on mode to nix add-on mode and then back to manual mode and then again to nix add-on mode.

View File

@@ -1,50 +0,0 @@
# Fish {#sec-fish}
Fish is a "smart and user-friendly command line shell" with support for plugins.
## Vendor Fish scripts {#sec-fish-vendor}
Any package may ship its own Fish completions, configuration snippets, and
functions. Those should be installed to
`$out/share/fish/vendor_{completions,conf,functions}.d` respectively.
When the `programs.fish.enable` and
`programs.fish.vendor.{completions,config,functions}.enable` options from the
NixOS Fish module are set to true, those paths are symlinked in the current
system environment and automatically loaded by Fish.
## Packaging Fish plugins {#sec-fish-plugins-pkg}
While packages providing standalone executables belong to the top level,
packages which have the sole purpose of extending Fish belong to the
`fishPlugins` scope and should be registered in
`pkgs/shells/fish/plugins/default.nix`.
The `buildFishPlugin` utility function can be used to automatically copy Fish
scripts from `$src/{completions,conf,conf.d,functions}` to the standard vendor
installation paths. It also sets up the test environment so that the optional
`checkPhase` is executed in a Fish shell with other already packaged plugins
and package-local Fish functions specified in `checkPlugins` and
`checkFunctionDirs` respectively.
See `pkgs/shells/fish/plugins/pure.nix` for an example of Fish plugin package
using `buildFishPlugin` and running unit tests with the `fishtape` test runner.
## Fish wrapper {#sec-fish-wrapper}
The `wrapFish` package is a wrapper around Fish which can be used to create
Fish shells initialized with some plugins as well as completions, configuration
snippets and functions sourced from the given paths. This provides a convenient
way to test Fish plugins and scripts without having to alter the environment.
```nix
wrapFish {
pluginPkgs = with fishPlugins; [ pure foreign-env ];
completionDirs = [];
functionDirs = [];
confDirs = [ "/path/to/some/fish/init/dir/" ];
}
```

View File

@@ -1,45 +0,0 @@
# FUSE {#sec-fuse}
Some packages rely on
[FUSE](https://www.kernel.org/doc/html/latest/filesystems/fuse.html) to provide
support for additional filesystems not supported by the kernel.
In general, FUSE software are primarily developed for Linux but many of them can
also run on macOS. Nixpkgs supports FUSE packages on macOS, but it requires
[macFUSE](https://osxfuse.github.io) to be installed outside of Nix. macFUSE
currently isn't packaged in Nixpkgs mainly because it includes a kernel
extension, which isn't supported by Nix outside of NixOS.
If a package fails to run on macOS with an error message similar to the
following, it's a likely sign that you need to have macFUSE installed.
dyld: Library not loaded: /usr/local/lib/libfuse.2.dylib
Referenced from: /nix/store/w8bi72bssv0bnxhwfw3xr1mvn7myf37x-sshfs-fuse-2.10/bin/sshfs
Reason: image not found
[1] 92299 abort /nix/store/w8bi72bssv0bnxhwfw3xr1mvn7myf37x-sshfs-fuse-2.10/bin/sshfs
Package maintainers may often encounter the following error when building FUSE
packages on macOS:
checking for fuse.h... no
configure: error: No fuse.h found.
This happens on autoconf based projects that use `AC_CHECK_HEADERS` or
`AC_CHECK_LIBS` to detect libfuse, and will occur even when the `fuse` package
is included in `buildInputs`. It happens because libfuse headers throw an error
on macOS if the `FUSE_USE_VERSION` macro is undefined. Many projects do define
`FUSE_USE_VERSION`, but only inside C source files. This results in the above
error at configure time because the configure script would attempt to compile
sample FUSE programs without defining `FUSE_USE_VERSION`.
There are two possible solutions for this problem in Nixpkgs:
1. Pass `FUSE_USE_VERSION` to the configure script by adding
`CFLAGS=-DFUSE_USE_VERSION=25` in `configureFlags`. The actual value would
have to match the definition used in the upstream source code.
2. Remove `AC_CHECK_HEADERS` / `AC_CHECK_LIBS` for libfuse.
However, a better solution might be to fix the build script upstream to use
`PKG_CHECK_MODULES` instead. This approach wouldn't suffer from the problem that
`AC_CHECK_HEADERS`/`AC_CHECK_LIBS` has at the price of introducing a dependency
on pkg-config.

View File

@@ -1,38 +0,0 @@
# ibus-engines.typing-booster {#sec-ibus-typing-booster}
This package is an ibus-based completion method to speed up typing.
## Activating the engine {#sec-ibus-typing-booster-activate}
IBus needs to be configured accordingly to activate `typing-booster`. The configuration depends on the desktop manager in use. For detailed instructions, please refer to the [upstream docs](https://mike-fabian.github.io/ibus-typing-booster/documentation.html).
On NixOS, you need to explicitly enable `ibus` with given engines before customizing your desktop to use `typing-booster`. This can be achieved using the `ibus` module:
```nix
{ pkgs, ... }: {
i18n.inputMethod = {
enabled = "ibus";
ibus.engines = with pkgs.ibus-engines; [ typing-booster ];
};
}
```
## Using custom hunspell dictionaries {#sec-ibus-typing-booster-customize-hunspell}
The IBus engine is based on `hunspell` to support completion in many languages. By default, the dictionaries `de-de`, `en-us`, `fr-moderne` `es-es`, `it-it`, `sv-se` and `sv-fi` are in use. To add another dictionary, the package can be overridden like this:
```nix
ibus-engines.typing-booster.override { langs = [ "de-at" "en-gb" ]; }
```
_Note: each language passed to `langs` must be an attribute name in `pkgs.hunspellDicts`._
## Built-in emoji picker {#sec-ibus-typing-booster-emoji-picker}
The `ibus-engines.typing-booster` package contains a program named `emoji-picker`. To display all emojis correctly, a special font such as `noto-fonts-emoji` is needed:
On NixOS, it can be installed using the following expression:
```nix
{ pkgs, ... }: { fonts.fonts = with pkgs; [ noto-fonts-emoji ]; }
```

View File

@@ -1,29 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="chap-packages">
<title>Packages</title>
<para>
This chapter contains information about how to use and maintain the Nix expressions for a number of specific packages, such as the Linux kernel or X.org.
</para>
<xi:include href="citrix.section.xml" />
<xi:include href="dlib.section.xml" />
<xi:include href="eclipse.section.xml" />
<xi:include href="elm.section.xml" />
<xi:include href="emacs.section.xml" />
<xi:include href="firefox.section.xml" />
<xi:include href="fish.section.xml" />
<xi:include href="fuse.section.xml" />
<xi:include href="ibus.section.xml" />
<xi:include href="kakoune.section.xml" />
<xi:include href="linux.section.xml" />
<xi:include href="locales.section.xml" />
<xi:include href="etc-files.section.xml" />
<xi:include href="nginx.section.xml" />
<xi:include href="opengl.section.xml" />
<xi:include href="shell-helpers.section.xml" />
<xi:include href="steam.section.xml" />
<xi:include href="cataclysm-dda.section.xml" />
<xi:include href="urxvt.section.xml" />
<xi:include href="weechat.section.xml" />
<xi:include href="xorg.section.xml" />
</chapter>

View File

@@ -1,9 +0,0 @@
# Kakoune {#sec-kakoune}
Kakoune can be built to autoload plugins:
```nix
(kakoune.override {
plugins = with pkgs.kakounePlugins; [ parinfer-rust ];
})
```

View File

@@ -1,41 +0,0 @@
# Linux kernel {#sec-linux-kernel}
The Nix expressions to build the Linux kernel are in [`pkgs/os-specific/linux/kernel`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/os-specific/linux/kernel).
The function that builds the kernel has an argument `kernelPatches` which should be a list of `{name, patch, extraConfig}` attribute sets, where `name` is the name of the patch (which is included in the kernels `meta.description` attribute), `patch` is the patch itself (possibly compressed), and `extraConfig` (optional) is a string specifying extra options to be concatenated to the kernel configuration file (`.config`).
The kernel derivation exports an attribute `features` specifying whether optional functionality is or isnt enabled. This is used in NixOS to implement kernel-specific behaviour. For instance, if the kernel has the `iwlwifi` feature (i.e., has built-in support for Intel wireless chipsets), then NixOS doesnt have to build the external `iwlwifi` package:
```nix
modulesTree = [kernel]
++ pkgs.lib.optional (!kernel.features ? iwlwifi) kernelPackages.iwlwifi
++ ...;
```
How to add a new (major) version of the Linux kernel to Nixpkgs:
1. Copy the old Nix expression (e.g., `linux-2.6.21.nix`) to the new one (e.g., `linux-2.6.22.nix`) and update it.
2. Add the new kernel to the `kernels` attribute set in `linux-kernels.nix` (e.g., create an attribute `kernel_2_6_22`).
3. Now were going to update the kernel configuration. First unpack the kernel. Then for each supported platform (`i686`, `x86_64`, `uml`) do the following:
1. Make a copy from the old config (e.g., `config-2.6.21-i686-smp`) to the new one (e.g., `config-2.6.22-i686-smp`).
2. Copy the config file for this platform (e.g., `config-2.6.22-i686-smp`) to `.config` in the kernel source tree.
3. Run `make oldconfig ARCH={i386,x86_64,um}` and answer all questions. (For the uml configuration, also add `SHELL=bash`.) Make sure to keep the configuration consistent between platforms (i.e., dont enable some feature on `i686` and disable it on `x86_64`).
4. If needed, you can also run `make menuconfig`:
```ShellSession
$ nix-env -f "<nixpkgs>" -iA ncurses
$ export NIX_CFLAGS_LINK=-lncurses
$ make menuconfig ARCH=arch
```
5. Copy `.config` over the new config file (e.g., `config-2.6.22-i686-smp`).
4. Test building the kernel: `nix-build -A linuxKernel.kernels.kernel_2_6_22`. If it compiles, ship it! For extra credit, try booting NixOS with it.
5. It may be that the new kernel requires updating the external kernel modules and kernel-dependent packages listed in the `linuxPackagesFor` function in `linux-kernels.nix` (such as the NVIDIA drivers, AUFS, etc.). If the updated packages arent backwards compatible with older kernels, you may need to keep the older versions around.

View File

@@ -1,5 +0,0 @@
# Locales {#locales}
To allow simultaneous use of packages linked against different versions of `glibc` with different locale archive formats, Nixpkgs patches `glibc` to rely on `LOCALE_ARCHIVE` environment variable.
On non-NixOS distributions, this variable is obviously not set. This can cause regressions in language support or even crashes in some Nixpkgs-provided programs. The simplest way to mitigate this problem is exporting the `LOCALE_ARCHIVE` variable pointing to `${glibcLocales}/lib/locale/locale-archive`. The drawback (and the reason this is not the default) is the relatively large (a hundred MiB) size of the full set of locales. It is possible to build a custom set of locales by overriding parameters `allLocales` and `locales` of the package.

View File

@@ -1,11 +0,0 @@
# Nginx {#sec-nginx}
[Nginx](https://nginx.org) is a reverse proxy and lightweight webserver.
## ETags on static files served from the Nix store {#sec-nginx-etag}
HTTP has a couple of different mechanisms for caching to prevent clients from having to download the same content repeatedly if a resource has not changed since the last time it was requested. When nginx is used as a server for static files, it implements the caching mechanism based on the [`Last-Modified`](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Last-Modified) response header automatically; unfortunately, it works by using filesystem timestamps to determine the value of the `Last-Modified` header. This doesn't give the desired behavior when the file is in the Nix store because all file timestamps are set to 0 (for reasons related to build reproducibility).
Fortunately, HTTP supports an alternative (and more effective) caching mechanism: the [`ETag`](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/ETag) response header. The value of the `ETag` header specifies some identifier for the particular content that the server is sending (e.g., a hash). When a client makes a second request for the same resource, it sends that value back in an `If-None-Match` header. If the ETag value is unchanged, then the server does not need to resend the content.
As of NixOS 19.09, the nginx package in Nixpkgs is patched such that when nginx serves a file out of `/nix/store`, the hash in the store path is used as the `ETag` header in the HTTP response, thus providing proper caching functionality. This happens automatically; you do not need to do modify any configuration to get this behavior.

View File

@@ -1,15 +0,0 @@
# OpenGL {#sec-opengl}
OpenGL support varies depending on which hardware is used and which drivers are available and loaded.
Broadly, we support both GL vendors: Mesa and NVIDIA.
## NixOS Desktop {#nixos-desktop}
The NixOS desktop or other non-headless configurations are the primary target for OpenGL libraries and applications. The current solution for discovering which drivers are available is based on [libglvnd](https://gitlab.freedesktop.org/glvnd/libglvnd). `libglvnd` performs "vendor-neutral dispatch", trying a variety of techniques to find the system's GL implementation. In practice, this will be either via standard GLX for X11 users or EGL for Wayland users, and supporting either NVIDIA or Mesa extensions.
## Nix on GNU/Linux {#nix-on-gnulinux}
If you are using a non-NixOS GNU/Linux/X11 desktop with free software video drivers, consider launching OpenGL-dependent programs from Nixpkgs with Nixpkgs versions of `libglvnd` and `mesa.drivers` in `LD_LIBRARY_PATH`. For Mesa drivers, the Linux kernel version doesn't have to match nixpkgs.
For proprietary video drivers, you might have luck with also adding the corresponding video driver package.

View File

@@ -1,12 +0,0 @@
# Interactive shell helpers {#sec-shell-helpers}
Some packages provide the shell integration to be more useful. But unlike other systems, nix doesn't have a standard `share` directory location. This is why a bunch `PACKAGE-share` scripts are shipped that print the location of the corresponding shared folder. Current list of such packages is as following:
- `fzf` : `fzf-share`
E.g. `fzf` can then be used in the `.bashrc` like this:
```bash
source "$(fzf-share)/completion.bash"
source "$(fzf-share)/key-bindings.bash"
```

View File

@@ -1,63 +0,0 @@
# Steam {#sec-steam}
## Steam in Nix {#sec-steam-nix}
Steam is distributed as a `.deb` file, for now only as an i686 package (the amd64 package only has documentation). When unpacked, it has a script called `steam` that in Ubuntu (their target distro) would go to `/usr/bin`. When run for the first time, this script copies some files to the user's home, which include another script that is the ultimate responsible for launching the steam binary, which is also in `$HOME`.
Nix problems and constraints:
- We don't have `/bin/bash` and many scripts point there. Same thing for `/usr/bin/python`.
- We don't have the dynamic loader in `/lib`.
- The `steam.sh` script in `$HOME` cannot be patched, as it is checked and rewritten by steam.
- The steam binary cannot be patched, it's also checked.
The current approach to deploy Steam in NixOS is composing a FHS-compatible chroot environment, as documented [here](http://sandervanderburg.blogspot.nl/2013/09/composing-fhs-compatible-chroot.html). This allows us to have binaries in the expected paths without disrupting the system, and to avoid patching them to work in a non FHS environment.
## How to play {#sec-steam-play}
Use `programs.steam.enable = true;` if you want to add steam to `systemPackages` and also enable a few workarounds as well as Steam controller support or other Steam supported controllers such as the DualShock 4 or Nintendo Switch Pro Controller.
## Troubleshooting {#sec-steam-troub}
- **Steam fails to start. What do I do?**
Try to run
```ShellSession
strace steam
```
to see what is causing steam to fail.
- **Using the FOSS Radeon or nouveau (nvidia) drivers**
- The `newStdcpp` parameter was removed since NixOS 17.09 and should not be needed anymore.
- Steam ships statically linked with a version of `libcrypto` that conflicts with the one dynamically loaded by radeonsi_dri.so. If you get the error:
```
steam.sh: line 713: 7842 Segmentation fault (core dumped)
```
have a look at [this pull request](https://github.com/NixOS/nixpkgs/pull/20269).
- **Java**
1. There is no java in steam chrootenv by default. If you get a message like:
```
/home/foo/.local/share/Steam/SteamApps/common/towns/towns.sh: line 1: java: command not found
```
you need to add:
```nix
steam.override { withJava = true; };
```
## steam-run {#sec-steam-run}
The FHS-compatible chroot used for Steam can also be used to run other Linux games that expect a FHS environment. To use it, install the `steam-run` package and run the game with:
```
steam-run ./foo
```

View File

@@ -1,71 +0,0 @@
# Urxvt {#sec-urxvt}
Urxvt, also known as rxvt-unicode, is a highly customizable terminal emulator.
## Configuring urxvt {#sec-urxvt-conf}
In `nixpkgs`, urxvt is provided by the package `rxvt-unicode`. It can be configured to include your choice of plugins, reducing its closure size from the default configuration which includes all available plugins. To make use of this functionality, use an overlay or directly install an expression that overrides its configuration, such as:
```nix
rxvt-unicode.override {
configure = { availablePlugins, ... }: {
plugins = with availablePlugins; [ perls resize-font vtwheel ];
};
}
```
If the `configure` function returns an attrset without the `plugins` attribute, `availablePlugins` will be used automatically.
In order to add plugins but also keep all default plugins installed, it is possible to use the following method:
```nix
rxvt-unicode.override {
configure = { availablePlugins, ... }: {
plugins = (builtins.attrValues availablePlugins) ++ [ custom-plugin ];
};
}
```
To get a list of all the plugins available, open the Nix REPL and run
```ShellSession
$ nix repl
:l <nixpkgs>
map (p: p.name) pkgs.rxvt-unicode.plugins
```
Alternatively, if your shell is bash or zsh and have completion enabled, simply type `nixpkgs.rxvt-unicode.plugins.<tab>`.
In addition to `plugins` the options `extraDeps` and `perlDeps` can be used to install extra packages. `extraDeps` can be used, for example, to provide `xsel` (a clipboard manager) to the clipboard plugin, without installing it globally:
```nix
rxvt-unicode.override {
configure = { availablePlugins, ... }: {
pluginsDeps = [ xsel ];
};
}
```
`perlDeps` is a handy way to provide Perl packages to your custom plugins (in `$HOME/.urxvt/ext`). For example, if you need `AnyEvent` you can do:
```nix
rxvt-unicode.override {
configure = { availablePlugins, ... }: {
perlDeps = with perlPackages; [ AnyEvent ];
};
}
```
## Packaging urxvt plugins {#sec-urxvt-pkg}
Urxvt plugins resides in `pkgs/applications/misc/rxvt-unicode-plugins`. To add a new plugin, create an expression in a subdirectory and add the package to the set in `pkgs/applications/misc/rxvt-unicode-plugins/default.nix`.
A plugin can be any kind of derivation, the only requirement is that it should always install perl scripts in `$out/lib/urxvt/perl`. Look for existing plugins for examples.
If the plugin is itself a Perl package that needs to be imported from other plugins or scripts, add the following passthrough:
```nix
passthru.perlPackages = [ "self" ];
```
This will make the urxvt wrapper pick up the dependency and set up the Perl path accordingly.

View File

@@ -1,85 +0,0 @@
# WeeChat {#sec-weechat}
WeeChat can be configured to include your choice of plugins, reducing its closure size from the default configuration which includes all available plugins. To make use of this functionality, install an expression that overrides its configuration, such as:
```nix
weechat.override {configure = {availablePlugins, ...}: {
plugins = with availablePlugins; [ python perl ];
}
}
```
If the `configure` function returns an attrset without the `plugins` attribute, `availablePlugins` will be used automatically.
The plugins currently available are `python`, `perl`, `ruby`, `guile`, `tcl` and `lua`.
The Python and Perl plugins allows the addition of extra libraries. For instance, the `inotify.py` script in `weechat-scripts` requires D-Bus or libnotify, and the `fish.py` script requires `pycrypto`. To use these scripts, use the plugin's `withPackages` attribute:
```nix
weechat.override { configure = {availablePlugins, ...}: {
plugins = with availablePlugins; [
(python.withPackages (ps: with ps; [ pycrypto python-dbus ]))
];
};
}
```
In order to also keep all default plugins installed, it is possible to use the following method:
```nix
weechat.override { configure = { availablePlugins, ... }: {
plugins = builtins.attrValues (availablePlugins // {
python = availablePlugins.python.withPackages (ps: with ps; [ pycrypto python-dbus ]);
});
}; }
```
WeeChat allows to set defaults on startup using the `--run-command`. The `configure` method can be used to pass commands to the program:
```nix
weechat.override {
configure = { availablePlugins, ... }: {
init = ''
/set foo bar
/server add libera irc.libera.chat
'';
};
}
```
Further values can be added to the list of commands when running `weechat --run-command "your-commands"`.
Additionally, it's possible to specify scripts to be loaded when starting `weechat`. These will be loaded before the commands from `init`:
```nix
weechat.override {
configure = { availablePlugins, ... }: {
scripts = with pkgs.weechatScripts; [
weechat-xmpp weechat-matrix-bridge wee-slack
];
init = ''
/set plugins.var.python.jabber.key "val"
'':
};
}
```
In `nixpkgs` there's a subpackage which contains derivations for WeeChat scripts. Such derivations expect a `passthru.scripts` attribute, which contains a list of all scripts inside the store path. Furthermore, all scripts have to live in `$out/share`. An exemplary derivation looks like this:
```nix
{ stdenv, fetchurl }:
stdenv.mkDerivation {
name = "exemplary-weechat-script";
src = fetchurl {
url = "https://scripts.tld/your-scripts.tar.gz";
sha256 = "...";
};
passthru.scripts = [ "foo.py" "bar.lua" ];
installPhase = ''
mkdir $out/share
cp foo.py $out/share
cp bar.lua $out/share
'';
}
```

View File

@@ -1,34 +0,0 @@
# X.org {#sec-xorg}
The Nix expressions for the X.org packages reside in `pkgs/servers/x11/xorg/default.nix`. This file is automatically generated from lists of tarballs in an X.org release. As such it should not be modified directly; rather, you should modify the lists, the generator script or the file `pkgs/servers/x11/xorg/overrides.nix`, in which you can override or add to the derivations produced by the generator.
## Katamari Tarballs {#katamari-tarballs}
X.org upstream releases used to include [katamari](https://en.wiktionary.org/wiki/%E3%81%8B%E3%81%9F%E3%81%BE%E3%82%8A) releases, which included a holistic recommended version for each tarball, up until 7.7. To create a list of tarballs in a katamari release:
```ShellSession
export release="X11R7.7"
export url="mirror://xorg/$release/src/everything/"
cat $(PRINT_PATH=1 nix-prefetch-url $url | tail -n 1) \
| perl -e 'while (<>) { if (/(href|HREF)="([^"]*.bz2)"/) { print "$ENV{'url'}$2\n"; }; }' \
| sort > "tarballs-$release.list"
```
## Individual Tarballs {#individual-tarballs}
The upstream release process for [X11R7.8](https://x.org/wiki/Releases/7.8/) does not include a planned katamari. Instead, each component of X.org is released as its own tarball. We maintain `pkgs/servers/x11/xorg/tarballs.list` as a list of tarballs for each individual package. This list includes X.org core libraries and protocol descriptions, extra newer X11 interface libraries, like `xorg.libxcb`, and classic utilities which are largely unused but still available if needed, like `xorg.imake`.
## Generating Nix Expressions {#generating-nix-expressions}
The generator is invoked as follows:
```ShellSession
cd pkgs/servers/x11/xorg
<tarballs.list perl ./generate-expr-from-tarballs.pl
```
For each of the tarballs in the `.list` files, the script downloads it, unpacks it, and searches its `configure.ac` and `*.pc.in` files for dependencies. This information is used to generate `default.nix`. The generator caches downloaded tarballs between runs. Pay close attention to the `NOT FOUND: $NAME` messages at the end of the run, since they may indicate missing dependencies. (Some might be optional dependencies, however.)
## Overriding the Generator {#overriding-the-generator}
If the expression for a package requires derivation attributes that the generator cannot figure out automatically (say, `patches` or a `postInstall` hook), you should modify `pkgs/servers/x11/xorg/overrides.nix`.

View File

@@ -1,10 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="chap-special">
<title>Special builders</title>
<para>
This chapter describes several special builders.
</para>
<xi:include href="special/fhs-environments.section.xml" />
<xi:include href="special/mkshell.section.xml" />
</chapter>

View File

@@ -1,49 +0,0 @@
# buildFHSUserEnv {#sec-fhs-environments}
`buildFHSUserEnv` provides a way to build and run FHS-compatible lightweight sandboxes. It creates an isolated root with bound `/nix/store`, so its footprint in terms of disk space needed is quite small. This allows one to run software which is hard or unfeasible to patch for NixOS -- 3rd-party source trees with FHS assumptions, games distributed as tarballs, software with integrity checking and/or external self-updated binaries. It uses Linux namespaces feature to create temporary lightweight environments which are destroyed after all child processes exit, without root user rights requirement. Accepted arguments are:
- `name`
Environment name.
- `targetPkgs`
Packages to be installed for the main host's architecture (i.e. x86_64 on x86_64 installations). Along with libraries binaries are also installed.
- `multiPkgs`
Packages to be installed for all architectures supported by a host (i.e. i686 and x86_64 on x86_64 installations). Only libraries are installed by default.
- `extraBuildCommands`
Additional commands to be executed for finalizing the directory structure.
- `extraBuildCommandsMulti`
Like `extraBuildCommands`, but executed only on multilib architectures.
- `extraOutputsToInstall`
Additional derivation outputs to be linked for both target and multi-architecture packages.
- `extraInstallCommands`
Additional commands to be executed for finalizing the derivation with runner script.
- `runScript`
A command that would be executed inside the sandbox and passed all the command line arguments. It defaults to `bash`.
- `profile`
Optional script for `/etc/profile` within the sandbox.
One can create a simple environment using a `shell.nix` like that:
```nix
{ pkgs ? import <nixpkgs> {} }:
(pkgs.buildFHSUserEnv {
name = "simple-x11-env";
targetPkgs = pkgs: (with pkgs;
[ udev
alsa-lib
]) ++ (with pkgs.xorg;
[ libX11
libXcursor
libXrandr
]);
multiPkgs = pkgs: (with pkgs;
[ udev
alsa-lib
]);
runScript = "bash";
}).env
```
Running `nix-shell` would then drop you into a shell with these libraries and binaries available. You can use this to run closed-source applications which expect FHS structure without hassles: simply change `runScript` to the application path, e.g. `./bin/start.sh` -- relative paths are supported.
Additionally, the FHS builder links all relocated gsettings-schemas (the glib setup-hook moves them to `share/gsettings-schemas/${name}/glib-2.0/schemas`) to their standard FHS location. This means you don't need to wrap binaries with `wrapGAppsHook`.

View File

@@ -1,37 +0,0 @@
# pkgs.mkShell {#sec-pkgs-mkShell}
`pkgs.mkShell` is a specialized `stdenv.mkDerivation` that removes some
repetition when using it with `nix-shell` (or `nix develop`).
## Usage {#sec-pkgs-mkShell-usage}
Here is a common usage example:
```nix
{ pkgs ? import <nixpkgs> {} }:
pkgs.mkShell {
packages = [ pkgs.gnumake ];
inputsFrom = [ pkgs.hello pkgs.gnutar ];
shellHook = ''
export DEBUG=1
'';
}
```
## Attributes
* `name` (default: `nix-shell`). Set the name of the derivation.
* `packages` (default: `[]`). Add executable packages to the `nix-shell` environment.
* `inputsFrom` (default: `[]`). Add build dependencies of the listed derivations to the `nix-shell` environment.
* `shellHook` (default: `""`). Bash statements that are executed by `nix-shell`.
... all the attributes of `stdenv.mkDerivation`.
## Building the shell
This derivation output will contain a text file that contains a reference to
all the build inputs. This is useful in CI where we want to make sure that
every derivation, and its dependencies, build properly. Or when creating a GC
root so that the build dependencies don't get garbage-collected.

View File

@@ -1,128 +0,0 @@
# Testers {#chap-testers}
This chapter describes several testing builders which are available in the <literal>testers</literal> namespace.
## `testVersion` {#tester-testVersion}
Checks the command output contains the specified version
Although simplistic, this test assures that the main program
can run. While there's no substitute for a real test case,
it does catch dynamic linking errors and such. It also provides
some protection against accidentally building the wrong version,
for example when using an 'old' hash in a fixed-output derivation.
Examples:
```nix
passthru.tests.version = testVersion { package = hello; };
passthru.tests.version = testVersion {
package = seaweedfs;
command = "weed version";
};
passthru.tests.version = testVersion {
package = key;
command = "KeY --help";
# Wrong '2.5' version in the code. Drop on next version.
version = "2.5";
};
```
## `testEqualDerivation` {#tester-testEqualDerivation}
Checks that two packages produce the exact same build instructions.
This can be used to make sure that a certain difference of configuration,
such as the presence of an overlay does not cause a cache miss.
When the derivations are equal, the return value is an empty file.
Otherwise, the build log explains the difference via `nix-diff`.
Example:
```nix
testEqualDerivation
"The hello package must stay the same when enabling checks."
hello
(hello.overrideAttrs(o: { doCheck = true; }))
```
## `invalidateFetcherByDrvHash` {#tester-invalidateFetcherByDrvHash}
Use the derivation hash to invalidate the output via name, for testing.
Type: `(a@{ name, ... } -> Derivation) -> a -> Derivation`
Normally, fixed output derivations can and should be cached by their output
hash only, but for testing we want to re-fetch everytime the fetcher changes.
Changes to the fetcher become apparent in the drvPath, which is a hash of
how to fetch, rather than a fixed store path.
By inserting this hash into the name, we can make sure to re-run the fetcher
every time the fetcher changes.
This relies on the assumption that Nix isn't clever enough to reuse its
database of local store contents to optimize fetching.
You might notice that the "salted" name derives from the normal invocation,
not the final derivation. `invalidateFetcherByDrvHash` has to invoke the fetcher
function twice: once to get a derivation hash, and again to produce the final
fixed output derivation.
Example:
```nix
tests.fetchgit = invalidateFetcherByDrvHash fetchgit {
name = "nix-source";
url = "https://github.com/NixOS/nix";
rev = "9d9dbe6ed05854e03811c361a3380e09183f4f4a";
sha256 = "sha256-7DszvbCNTjpzGRmpIVAWXk20P0/XTrWZ79KSOGLrUWY=";
};
```
## `nixosTest` {#tester-nixosTest}
Run a NixOS VM network test using this evaluation of Nixpkgs.
NOTE: This function is primarily for external use. NixOS itself uses `make-test-python.nix` directly. Packages defined in Nixpkgs [reuse NixOS tests via `nixosTests`, plural](#ssec-nixos-tests-linking).
It is mostly equivalent to the function `import ./make-test-python.nix` from the
[NixOS manual](https://nixos.org/nixos/manual/index.html#sec-nixos-tests),
except that the current application of Nixpkgs (`pkgs`) will be used, instead of
letting NixOS invoke Nixpkgs anew.
If a test machine needs to set NixOS options under `nixpkgs`, it must set only the
`nixpkgs.pkgs` option.
### Parameter
A [NixOS VM test network](https://nixos.org/nixos/manual/index.html#sec-nixos-tests), or path to it. Example:
```nix
{
name = "my-test";
nodes = {
machine1 = { lib, pkgs, nodes, ... }: {
environment.systemPackages = [ pkgs.hello ];
services.foo.enable = true;
};
# machine2 = ...;
};
testScript = ''
start_all()
machine1.wait_for_unit("foo.service")
machine1.succeed("hello | foo-send")
'';
}
```
### Result
A derivation that runs the VM test.
Notable attributes:
* `nodes`: the evaluated NixOS configurations. Useful for debugging and exploring the configuration.
* `driverInteractive`: a script that launches an interactive Python session in the context of the `testScript`.

View File

@@ -1,223 +0,0 @@
# Trivial builders {#chap-trivial-builders}
Nixpkgs provides a couple of functions that help with building derivations. The most important one, `stdenv.mkDerivation`, has already been documented above. The following functions wrap `stdenv.mkDerivation`, making it easier to use in certain cases.
## `runCommand` {#trivial-builder-runCommand}
This takes three arguments, `name`, `env`, and `buildCommand`. `name` is just the name that Nix will append to the store path in the same way that `stdenv.mkDerivation` uses its `name` attribute. `env` is an attribute set specifying environment variables that will be set for this derivation. These attributes are then passed to the wrapped `stdenv.mkDerivation`. `buildCommand` specifies the commands that will be run to create this derivation. Note that you will need to create `$out` for Nix to register the command as successful.
An example of using `runCommand` is provided below.
```nix
(import <nixpkgs> {}).runCommand "my-example" {} ''
echo My example command is running
mkdir $out
echo I can write data to the Nix store > $out/message
echo I can also run basic commands like:
echo ls
ls
echo whoami
whoami
echo date
date
''
```
## `runCommandCC` {#trivial-builder-runCommandCC}
This works just like `runCommand`. The only difference is that it also provides a C compiler in `buildCommand`'s environment. To minimize your dependencies, you should only use this if you are sure you will need a C compiler as part of running your command.
## `runCommandLocal` {#trivial-builder-runCommandLocal}
Variant of `runCommand` that forces the derivation to be built locally, it is not substituted. This is intended for very cheap commands (<1s execution time). It saves on the network round-trip and can speed up a build.
::: {.note}
This sets [`allowSubstitutes` to `false`](https://nixos.org/nix/manual/#adv-attr-allowSubstitutes), so only use `runCommandLocal` if you are certain the user will always have a builder for the `system` of the derivation. This should be true for most trivial use cases (e.g., just copying some files to a different location or adding symlinks) because there the `system` is usually the same as `builtins.currentSystem`.
:::
## `writeTextFile`, `writeText`, `writeTextDir`, `writeScript`, `writeScriptBin` {#trivial-builder-writeText}
These functions write `text` to the Nix store. This is useful for creating scripts from Nix expressions. `writeTextFile` takes an attribute set and expects two arguments, `name` and `text`. `name` corresponds to the name used in the Nix store path. `text` will be the contents of the file. You can also set `executable` to true to make this file have the executable bit set.
Many more commands wrap `writeTextFile` including `writeText`, `writeTextDir`, `writeScript`, and `writeScriptBin`. These are convenience functions over `writeTextFile`.
Here are a few examples:
```nix
# Writes my-file to /nix/store/<store path>
writeTextFile {
name = "my-file";
text = ''
Contents of File
'';
}
# See also the `writeText` helper function below.
# Writes executable my-file to /nix/store/<store path>/bin/my-file
writeTextFile {
name = "my-file";
text = ''
Contents of File
'';
executable = true;
destination = "/bin/my-file";
}
# Writes contents of file to /nix/store/<store path>
writeText "my-file"
''
Contents of File
'';
# Writes contents of file to /nix/store/<store path>/share/my-file
writeTextDir "share/my-file"
''
Contents of File
'';
# Writes my-file to /nix/store/<store path> and makes executable
writeScript "my-file"
''
Contents of File
'';
# Writes my-file to /nix/store/<store path>/bin/my-file and makes executable.
writeScriptBin "my-file"
''
Contents of File
'';
# Writes my-file to /nix/store/<store path> and makes executable.
writeShellScript "my-file"
''
Contents of File
'';
# Writes my-file to /nix/store/<store path>/bin/my-file and makes executable.
writeShellScriptBin "my-file"
''
Contents of File
'';
```
## `concatTextFile`, `concatText`, `concatScript` {#trivial-builder-concatText}
These functions concatenate `files` to the Nix store in a single file. This is useful for configuration files structured in lines of text. `concatTextFile` takes an attribute set and expects two arguments, `name` and `files`. `name` corresponds to the name used in the Nix store path. `files` will be the files to be concatenated. You can also set `executable` to true to make this file have the executable bit set.
`concatText` and`concatScript` are simple wrappers over `concatTextFile`.
Here are a few examples:
```nix
# Writes my-file to /nix/store/<store path>
concatTextFile {
name = "my-file";
files = [ drv1 "${drv2}/path/to/file" ];
}
# See also the `concatText` helper function below.
# Writes executable my-file to /nix/store/<store path>/bin/my-file
concatTextFile {
name = "my-file";
files = [ drv1 "${drv2}/path/to/file" ];
executable = true;
destination = "/bin/my-file";
}
# Writes contents of files to /nix/store/<store path>
concatText "my-file" [ file1 file2 ]
# Writes contents of files to /nix/store/<store path>
concatScript "my-file" [ file1 file2 ]
```
## `writeShellApplication` {#trivial-builder-writeShellApplication}
This can be used to easily produce a shell script that has some dependencies (`runtimeInputs`). It automatically sets the `PATH` of the script to contain all of the listed inputs, sets some sanity shellopts (`errexit`, `nounset`, `pipefail`), and checks the resulting script with [`shellcheck`](https://github.com/koalaman/shellcheck).
For example, look at the following code:
```nix
writeShellApplication {
name = "show-nixos-org";
runtimeInputs = [ curl w3m ];
text = ''
curl -s 'https://nixos.org' | w3m -dump -T text/html
'';
}
```
Unlike with normal `writeShellScriptBin`, there is no need to manually write out `${curl}/bin/curl`, setting the PATH
was handled by `writeShellApplication`. Moreover, the script is being checked with `shellcheck` for more strict
validation.
## `symlinkJoin` {#trivial-builder-symlinkJoin}
This can be used to put many derivations into the same directory structure. It works by creating a new derivation and adding symlinks to each of the paths listed. It expects two arguments, `name`, and `paths`. `name` is the name used in the Nix store path for the created derivation. `paths` is a list of paths that will be symlinked. These paths can be to Nix store derivations or any other subdirectory contained within.
Here is an example:
```nix
# adds symlinks of hello and stack to current build and prints "links added"
symlinkJoin { name = "myexample"; paths = [ pkgs.hello pkgs.stack ]; postBuild = "echo links added"; }
```
This creates a derivation with a directory structure like the following:
```
/nix/store/sglsr5g079a5235hy29da3mq3hv8sjmm-myexample
|-- bin
| |-- hello -> /nix/store/qy93dp4a3rqyn2mz63fbxjg228hffwyw-hello-2.10/bin/hello
| `-- stack -> /nix/store/6lzdpxshx78281vy056lbk553ijsdr44-stack-2.1.3.1/bin/stack
`-- share
|-- bash-completion
| `-- completions
| `-- stack -> /nix/store/6lzdpxshx78281vy056lbk553ijsdr44-stack-2.1.3.1/share/bash-completion/completions/stack
|-- fish
| `-- vendor_completions.d
| `-- stack.fish -> /nix/store/6lzdpxshx78281vy056lbk553ijsdr44-stack-2.1.3.1/share/fish/vendor_completions.d/stack.fish
...
```
## `writeReferencesToFile` {#trivial-builder-writeReferencesToFile}
Writes the closure of transitive dependencies to a file.
This produces the equivalent of `nix-store -q --requisites`.
For example,
```nix
writeReferencesToFile (writeScriptBin "hi" ''${hello}/bin/hello'')
```
produces an output path `/nix/store/<hash>-runtime-deps` containing
```nix
/nix/store/<hash>-hello-2.10
/nix/store/<hash>-hi
/nix/store/<hash>-libidn2-2.3.0
/nix/store/<hash>-libunistring-0.9.10
/nix/store/<hash>-glibc-2.32-40
```
You can see that this includes `hi`, the original input path,
`hello`, which is a direct reference, but also
the other paths that are indirectly required to run `hello`.
## `writeDirectReferencesToFile` {#trivial-builder-writeDirectReferencesToFile}
Writes the set of references to the output file, that is, their immediate dependencies.
This produces the equivalent of `nix-store -q --references`.
For example,
```nix
writeDirectReferencesToFile (writeScriptBin "hi" ''${hello}/bin/hello'')
```
produces an output path `/nix/store/<hash>-runtime-references` containing
```nix
/nix/store/<hash>-hello-2.10
```
but none of `hello`'s dependencies because those are not referenced directly
by `hi`'s output.

603
doc/coding-conventions.xml Normal file
View File

@@ -0,0 +1,603 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-conventions">
<title>Coding conventions</title>
<section><title>Syntax</title>
<itemizedlist>
<listitem><para>Use 2 spaces of indentation per indentation level in
Nix expressions, 4 spaces in shell scripts.</para></listitem>
<listitem><para>Do not use tab characters, i.e. configure your
editor to use soft tabs. For instance, use <literal>(setq-default
indent-tabs-mode nil)</literal> in Emacs. Everybody has different
tab settings so its asking for trouble.</para></listitem>
<listitem><para>Use <literal>lowerCamelCase</literal> for variable
names, not <literal>UpperCamelCase</literal>. TODO: naming of
attributes in
<filename>all-packages.nix</filename>?</para></listitem>
<listitem><para>Function calls with attribute set arguments are
written as
<programlisting>
foo {
arg = ...;
}
</programlisting>
not
<programlisting>
foo
{
arg = ...;
}
</programlisting>
Also fine is
<programlisting>
foo { arg = ...; }
</programlisting>
if it's a short call.</para></listitem>
<listitem><para>In attribute sets or lists that span multiple lines,
the attribute names or list elements should be aligned:
<programlisting>
# A long list.
list =
[ elem1
elem2
elem3
];
# A long attribute set.
attrs =
{ attr1 = short_expr;
attr2 =
if true then big_expr else big_expr;
};
# Alternatively:
attrs = {
attr1 = short_expr;
attr2 =
if true then big_expr else big_expr;
};
</programlisting>
</para></listitem>
<listitem><para>Short lists or attribute sets can be written on one
line:
<programlisting>
# A short list.
list = [ elem1 elem2 elem3 ];
# A short set.
attrs = { x = 1280; y = 1024; };
</programlisting>
</para></listitem>
<listitem><para>Breaking in the middle of a function argument can
give hard-to-read code, like
<programlisting>
someFunction { x = 1280;
y = 1024; } otherArg
yetAnotherArg
</programlisting>
(especially if the argument is very large, spanning multiple
lines).</para>
<para>Better:
<programlisting>
someFunction
{ x = 1280; y = 1024; }
otherArg
yetAnotherArg
</programlisting>
or
<programlisting>
let res = { x = 1280; y = 1024; };
in someFunction res otherArg yetAnotherArg
</programlisting>
</para></listitem>
<listitem><para>The bodies of functions, asserts, and withs are not
indented to prevent a lot of superfluous indentation levels, i.e.
<programlisting>
{ arg1, arg2 }:
assert system == "i686-linux";
stdenv.mkDerivation { ...
</programlisting>
not
<programlisting>
{ arg1, arg2 }:
assert system == "i686-linux";
stdenv.mkDerivation { ...
</programlisting>
</para></listitem>
<listitem><para>Function formal arguments are written as:
<programlisting>
{ arg1, arg2, arg3 }:
</programlisting>
but if they don't fit on one line they're written as:
<programlisting>
{ arg1, arg2, arg3
, arg4, ...
, # Some comment...
argN
}:
</programlisting>
</para></listitem>
<listitem><para>Functions should list their expected arguments as
precisely as possible. That is, write
<programlisting>
{ stdenv, fetchurl, perl }: <replaceable>...</replaceable>
</programlisting>
instead of
<programlisting>
args: with args; <replaceable>...</replaceable>
</programlisting>
or
<programlisting>
{ stdenv, fetchurl, perl, ... }: <replaceable>...</replaceable>
</programlisting>
</para>
<para>For functions that are truly generic in the number of
arguments (such as wrappers around <varname>mkDerivation</varname>)
that have some required arguments, you should write them using an
<literal>@</literal>-pattern:
<programlisting>
{ stdenv, doCoverageAnalysis ? false, ... } @ args:
stdenv.mkDerivation (args // {
<replaceable>...</replaceable> if doCoverageAnalysis then "bla" else "" <replaceable>...</replaceable>
})
</programlisting>
instead of
<programlisting>
args:
args.stdenv.mkDerivation (args // {
<replaceable>...</replaceable> if args ? doCoverageAnalysis &amp;&amp; args.doCoverageAnalysis then "bla" else "" <replaceable>...</replaceable>
})
</programlisting>
</para></listitem>
</itemizedlist>
</section>
<section><title>Package naming</title>
<para>In Nixpkgs, there are generally three different names associated with a package:
<itemizedlist>
<listitem><para>The <varname>name</varname> attribute of the
derivation (excluding the version part). This is what most users
see, in particular when using
<command>nix-env</command>.</para></listitem>
<listitem><para>The variable name used for the instantiated package
in <filename>all-packages.nix</filename>, and when passing it as a
dependency to other functions. This is what Nix expression authors
see. It can also be used when installing using <command>nix-env
-iA</command>.</para></listitem>
<listitem><para>The filename for (the directory containing) the Nix
expression.</para></listitem>
</itemizedlist>
Most of the time, these are the same. For instance, the package
<literal>e2fsprogs</literal> has a <varname>name</varname> attribute
<literal>"e2fsprogs-<replaceable>version</replaceable>"</literal>, is
bound to the variable name <varname>e2fsprogs</varname> in
<filename>all-packages.nix</filename>, and the Nix expression is in
<filename>pkgs/os-specific/linux/e2fsprogs/default.nix</filename>.
</para>
<para>There are a few naming guidelines:
<itemizedlist>
<listitem><para>Generally, try to stick to the upstream package
name.</para></listitem>
<listitem><para>Dont use uppercase letters in the
<literal>name</literal> attribute — e.g.,
<literal>"mplayer-1.0rc2"</literal> instead of
<literal>"MPlayer-1.0rc2"</literal>.</para></listitem>
<listitem><para>The version part of the <literal>name</literal>
attribute <emphasis>must</emphasis> start with a digit (following a
dash) — e.g., <literal>"hello-0.3-pre-r3910"</literal> instead of
<literal>"hello-svn-r3910"</literal>, as the latter would be seen as
a package named <literal>hello-svn</literal> by
<command>nix-env</command>.</para></listitem>
<listitem><para>Dashes in the package name should be preserved
in new variable names, rather than converted to underscores
(which was convention up to around 2013 and most names
still have underscores instead of dashes) — e.g.,
<varname>http-parser</varname> instead of
<varname>http_parser</varname>.</para></listitem>
<listitem><para>If there are multiple versions of a package, this
should be reflected in the variable names in
<filename>all-packages.nix</filename>,
e.g. <varname>json-c-0-9</varname> and <varname>json-c-0-11</varname>.
If there is an obvious “default” version, make an attribute like
<literal>json-c = json-c-0-9;</literal>.
See also <xref linkend="sec-versioning" /></para></listitem>
</itemizedlist>
</para>
</section>
<section xml:id="sec-organisation"><title>File naming and organisation</title>
<para>Names of files and directories should be in lowercase, with
dashes between words — not in camel case. For instance, it should be
<filename>all-packages.nix</filename>, not
<filename>allPackages.nix</filename> or
<filename>AllPackages.nix</filename>.</para>
<section><title>Hierarchy</title>
<para>Each package should be stored in its own directory somewhere in
the <filename>pkgs/</filename> tree, i.e. in
<filename>pkgs/<replaceable>category</replaceable>/<replaceable>subcategory</replaceable>/<replaceable>...</replaceable>/<replaceable>pkgname</replaceable></filename>.
Below are some rules for picking the right category for a package.
Many packages fall under several categories; what matters is the
<emphasis>primary</emphasis> purpose of a package. For example, the
<literal>libxml2</literal> package builds both a library and some
tools; but its a library foremost, so it goes under
<filename>pkgs/development/libraries</filename>.</para>
<para>When in doubt, consider refactoring the
<filename>pkgs/</filename> tree, e.g. creating new categories or
splitting up an existing category.</para>
<variablelist>
<varlistentry>
<term>If its used to support <emphasis>software development</emphasis>:</term>
<listitem>
<variablelist>
<varlistentry>
<term>If its a <emphasis>library</emphasis> used by other packages:</term>
<listitem>
<para><filename>development/libraries</filename> (e.g. <filename>libxml2</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>compiler</emphasis>:</term>
<listitem>
<para><filename>development/compilers</filename> (e.g. <filename>gcc</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its an <emphasis>interpreter</emphasis>:</term>
<listitem>
<para><filename>development/interpreters</filename> (e.g. <filename>guile</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a (set of) development <emphasis>tool(s)</emphasis>:</term>
<listitem>
<variablelist>
<varlistentry>
<term>If its a <emphasis>parser generator</emphasis> (including lexers):</term>
<listitem>
<para><filename>development/tools/parsing</filename> (e.g. <filename>bison</filename>, <filename>flex</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>build manager</emphasis>:</term>
<listitem>
<para><filename>development/tools/build-managers</filename> (e.g. <filename>gnumake</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>Else:</term>
<listitem>
<para><filename>development/tools/misc</filename> (e.g. <filename>binutils</filename>)</para>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry>
<term>Else:</term>
<listitem>
<para><filename>development/misc</filename></para>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a (set of) <emphasis>tool(s)</emphasis>:</term>
<listitem>
<para>(A tool is a relatively small program, especially one intented
to be used non-interactively.)</para>
<variablelist>
<varlistentry>
<term>If its for <emphasis>networking</emphasis>:</term>
<listitem>
<para><filename>tools/networking</filename> (e.g. <filename>wget</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its for <emphasis>text processing</emphasis>:</term>
<listitem>
<para><filename>tools/text</filename> (e.g. <filename>diffutils</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>system utility</emphasis>, i.e.,
something related or essential to the operation of a
system:</term>
<listitem>
<para><filename>tools/system</filename> (e.g. <filename>cron</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its an <emphasis>archiver</emphasis> (which may
include a compression function):</term>
<listitem>
<para><filename>tools/archivers</filename> (e.g. <filename>zip</filename>, <filename>tar</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>compression</emphasis> program:</term>
<listitem>
<para><filename>tools/compression</filename> (e.g. <filename>gzip</filename>, <filename>bzip2</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>security</emphasis>-related program:</term>
<listitem>
<para><filename>tools/security</filename> (e.g. <filename>nmap</filename>, <filename>gnupg</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>Else:</term>
<listitem>
<para><filename>tools/misc</filename></para>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>shell</emphasis>:</term>
<listitem>
<para><filename>shells</filename> (e.g. <filename>bash</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>server</emphasis>:</term>
<listitem>
<variablelist>
<varlistentry>
<term>If its a web server:</term>
<listitem>
<para><filename>servers/http</filename> (e.g. <filename>apache-httpd</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its an implementation of the X Windowing System:</term>
<listitem>
<para><filename>servers/x11</filename> (e.g. <filename>xorg</filename> — this includes the client libraries and programs)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>Else:</term>
<listitem>
<para><filename>servers/misc</filename></para>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>desktop environment</emphasis>
(including <emphasis>window managers</emphasis>):</term>
<listitem>
<para><filename>desktops</filename> (e.g. <filename>kde</filename>, <filename>gnome</filename>, <filename>enlightenment</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its an <emphasis>application</emphasis>:</term>
<listitem>
<para>A (typically large) program with a distinct user
interface, primarily used interactively.</para>
<variablelist>
<varlistentry>
<term>If its a <emphasis>version management system</emphasis>:</term>
<listitem>
<para><filename>applications/version-management</filename> (e.g. <filename>subversion</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its for <emphasis>video playback / editing</emphasis>:</term>
<listitem>
<para><filename>applications/video</filename> (e.g. <filename>vlc</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its for <emphasis>graphics viewing / editing</emphasis>:</term>
<listitem>
<para><filename>applications/graphics</filename> (e.g. <filename>gimp</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its for <emphasis>networking</emphasis>:</term>
<listitem>
<variablelist>
<varlistentry>
<term>If its a <emphasis>mailreader</emphasis>:</term>
<listitem>
<para><filename>applications/networking/mailreaders</filename> (e.g. <filename>thunderbird</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>newsreader</emphasis>:</term>
<listitem>
<para><filename>applications/networking/newsreaders</filename> (e.g. <filename>pan</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>web browser</emphasis>:</term>
<listitem>
<para><filename>applications/networking/browsers</filename> (e.g. <filename>firefox</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>Else:</term>
<listitem>
<para><filename>applications/networking/misc</filename></para>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry>
<term>Else:</term>
<listitem>
<para><filename>applications/misc</filename></para>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry>
<term>If its <emphasis>data</emphasis> (i.e., does not have a
straight-forward executable semantics):</term>
<listitem>
<variablelist>
<varlistentry>
<term>If its a <emphasis>font</emphasis>:</term>
<listitem>
<para><filename>data/fonts</filename></para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its related to <emphasis>SGML/XML processing</emphasis>:</term>
<listitem>
<variablelist>
<varlistentry>
<term>If its an <emphasis>XML DTD</emphasis>:</term>
<listitem>
<para><filename>data/sgml+xml/schemas/xml-dtd</filename> (e.g. <filename>docbook</filename>)</para>
</listitem>
</varlistentry>
<varlistentry>
<term>If its an <emphasis>XSLT stylesheet</emphasis>:</term>
<listitem>
<para>(Okay, these are executable...)</para>
<para><filename>data/sgml+xml/stylesheets/xslt</filename> (e.g. <filename>docbook-xsl</filename>)</para>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
</variablelist>
</listitem>
</varlistentry>
<varlistentry>
<term>If its a <emphasis>game</emphasis>:</term>
<listitem>
<para><filename>games</filename></para>
</listitem>
</varlistentry>
<varlistentry>
<term>Else:</term>
<listitem>
<para><filename>misc</filename></para>
</listitem>
</varlistentry>
</variablelist>
</section>
<section xml:id="sec-versioning"><title>Versioning</title>
<para>Because every version of a package in Nixpkgs creates a
potential maintenance burden, old versions of a package should not be
kept unless there is a good reason to do so. For instance, Nixpkgs
contains several versions of GCC because other packages dont build
with the latest version of GCC. Other examples are having both the
latest stable and latest pre-release version of a package, or to keep
several major releases of an application that differ significantly in
functionality.</para>
<para>If there is only one version of a package, its Nix expression
should be named <filename>e2fsprogs/default.nix</filename>. If there
are multiple versions, this should be reflected in the filename,
e.g. <filename>e2fsprogs/1.41.8.nix</filename> and
<filename>e2fsprogs/1.41.9.nix</filename>. The version in the
filename should leave out unnecessary detail. For instance, if we
keep the latest Firefox 2.0.x and 3.5.x versions in Nixpkgs, they
should be named <filename>firefox/2.0.nix</filename> and
<filename>firefox/3.5.nix</filename>, respectively (which, at a given
point, might contain versions <literal>2.0.0.20</literal> and
<literal>3.5.4</literal>). If a version requires many auxiliary
files, you can use a subdirectory for each version,
e.g. <filename>firefox/2.0/default.nix</filename> and
<filename>firefox/3.5/default.nix</filename>.</para>
<para>All versions of a package <emphasis>must</emphasis> be included
in <filename>all-packages.nix</filename> to make sure that they
evaluate correctly.</para>
</section>
</section>
</chapter>

19
doc/contributing.xml Normal file
View File

@@ -0,0 +1,19 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-contributing">
<title>Contributing</title>
<para>If you make modifications to the manual, it's important to build the manual before contributing:</para>
<orderedlist>
<listitem><para><command>$ git clone git://github.com/NixOS/nixpkgs.git</command></para></listitem>
<listitem><para><command>$ nix-build -A manual nixpkgs/pkgs/top-level/release.nix</command></para></listitem>
<listitem><para>Inside the built derivation you shall see <literal>manual/index.html</literal> file.</para></listitem>
</orderedlist>
</chapter>

View File

@@ -1,660 +0,0 @@
# Coding conventions {#chap-conventions}
## Syntax {#sec-syntax}
- Use 2 spaces of indentation per indentation level in Nix expressions, 4 spaces in shell scripts.
- Do not use tab characters, i.e. configure your editor to use soft tabs. For instance, use `(setq-default indent-tabs-mode nil)` in Emacs. Everybody has different tab settings so its asking for trouble.
- Use `lowerCamelCase` for variable names, not `UpperCamelCase`. Note, this rule does not apply to package attribute names, which instead follow the rules in [](#sec-package-naming).
- Function calls with attribute set arguments are written as
```nix
foo {
arg = ...;
}
```
not
```nix
foo
{
arg = ...;
}
```
Also fine is
```nix
foo { arg = ...; }
```
if it's a short call.
- In attribute sets or lists that span multiple lines, the attribute names or list elements should be aligned:
```nix
# A long list.
list = [
elem1
elem2
elem3
];
# A long attribute set.
attrs = {
attr1 = short_expr;
attr2 =
if true then big_expr else big_expr;
};
# Combined
listOfAttrs = [
{
attr1 = 3;
attr2 = "fff";
}
{
attr1 = 5;
attr2 = "ggg";
}
];
```
- Short lists or attribute sets can be written on one line:
```nix
# A short list.
list = [ elem1 elem2 elem3 ];
# A short set.
attrs = { x = 1280; y = 1024; };
```
- Breaking in the middle of a function argument can give hard-to-read code, like
```nix
someFunction { x = 1280;
y = 1024; } otherArg
yetAnotherArg
```
(especially if the argument is very large, spanning multiple lines).
Better:
```nix
someFunction
{ x = 1280; y = 1024; }
otherArg
yetAnotherArg
```
or
```nix
let res = { x = 1280; y = 1024; };
in someFunction res otherArg yetAnotherArg
```
- The bodies of functions, asserts, and withs are not indented to prevent a lot of superfluous indentation levels, i.e.
```nix
{ arg1, arg2 }:
assert system == "i686-linux";
stdenv.mkDerivation { ...
```
not
```nix
{ arg1, arg2 }:
assert system == "i686-linux";
stdenv.mkDerivation { ...
```
- Function formal arguments are written as:
```nix
{ arg1, arg2, arg3 }:
```
but if they don't fit on one line they're written as:
```nix
{ arg1, arg2, arg3
, arg4, ...
, # Some comment...
argN
}:
```
- Functions should list their expected arguments as precisely as possible. That is, write
```nix
{ stdenv, fetchurl, perl }: ...
```
instead of
```nix
args: with args; ...
```
or
```nix
{ stdenv, fetchurl, perl, ... }: ...
```
For functions that are truly generic in the number of arguments (such as wrappers around `mkDerivation`) that have some required arguments, you should write them using an `@`-pattern:
```nix
{ stdenv, doCoverageAnalysis ? false, ... } @ args:
stdenv.mkDerivation (args // {
... if doCoverageAnalysis then "bla" else "" ...
})
```
instead of
```nix
args:
args.stdenv.mkDerivation (args // {
... if args ? doCoverageAnalysis && args.doCoverageAnalysis then "bla" else "" ...
})
```
- Unnecessary string conversions should be avoided. Do
```nix
rev = version;
```
instead of
```nix
rev = "${version}";
```
- Building lists conditionally _should_ be done with `lib.optional(s)` instead of using `if cond then [ ... ] else null` or `if cond then [ ... ] else [ ]`.
```nix
buildInputs = lib.optional stdenv.isDarwin iconv;
```
instead of
```nix
buildInputs = if stdenv.isDarwin then [ iconv ] else null;
```
As an exception, an explicit conditional expression with null can be used when fixing a important bug without triggering a mass rebuild.
If this is done a follow up pull request _should_ be created to change the code to `lib.optional(s)`.
- Arguments should be listed in the order they are used, with the exception of `lib`, which always goes first.
## Package naming {#sec-package-naming}
The key words _must_, _must not_, _required_, _shall_, _shall not_, _should_, _should not_, _recommended_, _may_, and _optional_ in this section are to be interpreted as described in [RFC 2119](https://tools.ietf.org/html/rfc2119). Only _emphasized_ words are to be interpreted in this way.
In Nixpkgs, there are generally three different names associated with a package:
- The `name` attribute of the derivation (excluding the version part). This is what most users see, in particular when using `nix-env`.
- The variable name used for the instantiated package in `all-packages.nix`, and when passing it as a dependency to other functions. Typically this is called the _package attribute name_. This is what Nix expression authors see. It can also be used when installing using `nix-env -iA`.
- The filename for (the directory containing) the Nix expression.
Most of the time, these are the same. For instance, the package `e2fsprogs` has a `name` attribute `"e2fsprogs-version"`, is bound to the variable name `e2fsprogs` in `all-packages.nix`, and the Nix expression is in `pkgs/os-specific/linux/e2fsprogs/default.nix`.
There are a few naming guidelines:
- The `pname` attribute _should_ be identical to the upstream package name.
- The `pname` and the `version` attribute _must not_ contain uppercase letters — e.g., `"mplayer" instead of `"MPlayer"`.
- The `version` attribute _must_ start with a digit e.g`"0.3.1rc2".
- If a package is not a release but a commit from a repository, then the `version` attribute _must_ be the date of that (fetched) commit. The date _must_ be in `"unstable-YYYY-MM-DD"` format.
- Dashes in the package `pname` _should_ be preserved in new variable names, rather than converted to underscores or camel cased — e.g., `http-parser` instead of `http_parser` or `httpParser`. The hyphenated style is preferred in all three package names.
- If there are multiple versions of a package, this _should_ be reflected in the variable names in `all-packages.nix`, e.g. `json-c_0_9` and `json-c_0_11`. If there is an obvious “default” version, make an attribute like `json-c = json-c_0_9;`. See also [](#sec-versioning)
## File naming and organisation {#sec-organisation}
Names of files and directories should be in lowercase, with dashes between words — not in camel case. For instance, it should be `all-packages.nix`, not `allPackages.nix` or `AllPackages.nix`.
### Hierarchy {#sec-hierarchy}
Each package should be stored in its own directory somewhere in the `pkgs/` tree, i.e. in `pkgs/category/subcategory/.../pkgname`. Below are some rules for picking the right category for a package. Many packages fall under several categories; what matters is the _primary_ purpose of a package. For example, the `libxml2` package builds both a library and some tools; but its a library foremost, so it goes under `pkgs/development/libraries`.
When in doubt, consider refactoring the `pkgs/` tree, e.g. creating new categories or splitting up an existing category.
**If its used to support _software development_:**
- **If its a _library_ used by other packages:**
- `development/libraries` (e.g. `libxml2`)
- **If its a _compiler_:**
- `development/compilers` (e.g. `gcc`)
- **If its an _interpreter_:**
- `development/interpreters` (e.g. `guile`)
- **If its a (set of) development _tool(s)_:**
- **If its a _parser generator_ (including lexers):**
- `development/tools/parsing` (e.g. `bison`, `flex`)
- **If its a _build manager_:**
- `development/tools/build-managers` (e.g. `gnumake`)
- **Else:**
- `development/tools/misc` (e.g. `binutils`)
- **Else:**
- `development/misc`
**If its a (set of) _tool(s)_:**
(A tool is a relatively small program, especially one intended to be used non-interactively.)
- **If its for _networking_:**
- `tools/networking` (e.g. `wget`)
- **If its for _text processing_:**
- `tools/text` (e.g. `diffutils`)
- **If its a _system utility_, i.e., something related or essential to the operation of a system:**
- `tools/system` (e.g. `cron`)
- **If its an _archiver_ (which may include a compression function):**
- `tools/archivers` (e.g. `zip`, `tar`)
- **If its a _compression_ program:**
- `tools/compression` (e.g. `gzip`, `bzip2`)
- **If its a _security_-related program:**
- `tools/security` (e.g. `nmap`, `gnupg`)
- **Else:**
- `tools/misc`
**If its a _shell_:**
- `shells` (e.g. `bash`)
**If its a _server_:**
- **If its a web server:**
- `servers/http` (e.g. `apache-httpd`)
- **If its an implementation of the X Windowing System:**
- `servers/x11` (e.g. `xorg` — this includes the client libraries and programs)
- **Else:**
- `servers/misc`
**If its a _desktop environment_:**
- `desktops` (e.g. `kde`, `gnome`, `enlightenment`)
**If its a _window manager_:**
- `applications/window-managers` (e.g. `awesome`, `stumpwm`)
**If its an _application_:**
A (typically large) program with a distinct user interface, primarily used interactively.
- **If its a _version management system_:**
- `applications/version-management` (e.g. `subversion`)
- **If its a _terminal emulator_:**
- `applications/terminal-emulators` (e.g. `alacritty` or `rxvt` or `termite`)
- **If its a _file manager_:**
- `applications/file-managers` (e.g. `mc` or `ranger` or `pcmanfm`)
- **If its for _video playback / editing_:**
- `applications/video` (e.g. `vlc`)
- **If its for _graphics viewing / editing_:**
- `applications/graphics` (e.g. `gimp`)
- **If its for _networking_:**
- **If its a _mailreader_:**
- `applications/networking/mailreaders` (e.g. `thunderbird`)
- **If its a _newsreader_:**
- `applications/networking/newsreaders` (e.g. `pan`)
- **If its a _web browser_:**
- `applications/networking/browsers` (e.g. `firefox`)
- **Else:**
- `applications/networking/misc`
- **Else:**
- `applications/misc`
**If its _data_ (i.e., does not have a straight-forward executable semantics):**
- **If its a _font_:**
- `data/fonts`
- **If its an _icon theme_:**
- `data/icons`
- **If its related to _SGML/XML processing_:**
- **If its an _XML DTD_:**
- `data/sgml+xml/schemas/xml-dtd` (e.g. `docbook`)
- **If its an _XSLT stylesheet_:**
(Okay, these are executable...)
- `data/sgml+xml/stylesheets/xslt` (e.g. `docbook-xsl`)
- **If its a _theme_ for a _desktop environment_, a _window manager_ or a _display manager_:**
- `data/themes`
**If its a _game_:**
- `games`
**Else:**
- `misc`
### Versioning {#sec-versioning}
Because every version of a package in Nixpkgs creates a potential maintenance burden, old versions of a package should not be kept unless there is a good reason to do so. For instance, Nixpkgs contains several versions of GCC because other packages dont build with the latest version of GCC. Other examples are having both the latest stable and latest pre-release version of a package, or to keep several major releases of an application that differ significantly in functionality.
If there is only one version of a package, its Nix expression should be named `e2fsprogs/default.nix`. If there are multiple versions, this should be reflected in the filename, e.g. `e2fsprogs/1.41.8.nix` and `e2fsprogs/1.41.9.nix`. The version in the filename should leave out unnecessary detail. For instance, if we keep the latest Firefox 2.0.x and 3.5.x versions in Nixpkgs, they should be named `firefox/2.0.nix` and `firefox/3.5.nix`, respectively (which, at a given point, might contain versions `2.0.0.20` and `3.5.4`). If a version requires many auxiliary files, you can use a subdirectory for each version, e.g. `firefox/2.0/default.nix` and `firefox/3.5/default.nix`.
All versions of a package _must_ be included in `all-packages.nix` to make sure that they evaluate correctly.
## Fetching Sources {#sec-sources}
There are multiple ways to fetch a package source in nixpkgs. The general guideline is that you should package reproducible sources with a high degree of availability. Right now there is only one fetcher which has mirroring support and that is `fetchurl`. Note that you should also prefer protocols which have a corresponding proxy environment variable.
You can find many source fetch helpers in `pkgs/build-support/fetch*`.
In the file `pkgs/top-level/all-packages.nix` you can find fetch helpers, these have names on the form `fetchFrom*`. The intention of these are to provide snapshot fetches but using the same api as some of the version controlled fetchers from `pkgs/build-support/`. As an example going from bad to good:
- Bad: Uses `git://` which won't be proxied.
```nix
src = fetchgit {
url = "git://github.com/NixOS/nix.git";
rev = "1f795f9f44607cc5bec70d1300150bfefcef2aae";
sha256 = "1cw5fszffl5pkpa6s6wjnkiv6lm5k618s32sp60kvmvpy7a2v9kg";
}
```
- Better: This is ok, but an archive fetch will still be faster.
```nix
src = fetchgit {
url = "https://github.com/NixOS/nix.git";
rev = "1f795f9f44607cc5bec70d1300150bfefcef2aae";
sha256 = "1cw5fszffl5pkpa6s6wjnkiv6lm5k618s32sp60kvmvpy7a2v9kg";
}
```
- Best: Fetches a snapshot archive and you get the rev you want.
```nix
src = fetchFromGitHub {
owner = "NixOS";
repo = "nix";
rev = "1f795f9f44607cc5bec70d1300150bfefcef2aae";
sha256 = "1i2yxndxb6yc9l6c99pypbd92lfq5aac4klq7y2v93c9qvx2cgpc";
}
```
Find the value to put as `sha256` by running `nix-shell -p nix-prefetch-github --run "nix-prefetch-github --rev 1f795f9f44607cc5bec70d1300150bfefcef2aae NixOS nix"`.
## Obtaining source hash {#sec-source-hashes}
Preferred source hash type is sha256. There are several ways to get it.
1. Prefetch URL (with `nix-prefetch-XXX URL`, where `XXX` is one of `url`, `git`, `hg`, `cvs`, `bzr`, `svn`). Hash is printed to stdout.
2. Prefetch by package source (with `nix-prefetch-url '<nixpkgs>' -A PACKAGE.src`, where `PACKAGE` is package attribute name). Hash is printed to stdout.
This works well when you've upgraded existing package version and want to find out new hash, but is useless if package can't be accessed by attribute or package has multiple sources (`.srcs`, architecture-dependent sources, etc).
3. Upstream provided hash: use it when upstream provides `sha256` or `sha512` (when upstream provides `md5`, don't use it, compute `sha256` instead).
A little nuance is that `nix-prefetch-*` tools produce hash encoded with `base32`, but upstream usually provides hexadecimal (`base16`) encoding. Fetchers understand both formats. Nixpkgs does not standardize on any one format.
You can convert between formats with nix-hash, for example:
```ShellSession
$ nix-hash --type sha256 --to-base32 HASH
```
4. Extracting hash from local source tarball can be done with `sha256sum`. Use `nix-prefetch-url file:///path/to/tarball` if you want base32 hash.
5. Fake hash: set fake hash in package expression, perform build and extract correct hash from error Nix prints.
For package updates it is enough to change one symbol to make hash fake. For new packages, you can use `lib.fakeSha256`, `lib.fakeSha512` or any other fake hash.
This is last resort method when reconstructing source URL is non-trivial and `nix-prefetch-url -A` isnt applicable (for example, [one of `kodi` dependencies](https://github.com/NixOS/nixpkgs/blob/d2ab091dd308b99e4912b805a5eb088dd536adb9/pkgs/applications/video/kodi/default.nix#L73)). The easiest way then would be replace hash with a fake one and rebuild. Nix build will fail and error message will contain desired hash.
::: {.warning}
This method has security problems. Check below for details.
:::
### Obtaining hashes securely {#sec-source-hashes-security}
Let's say Man-in-the-Middle (MITM) sits close to your network. Then instead of fetching source you can fetch malware, and instead of source hash you get hash of malware. Here are security considerations for this scenario:
- `http://` URLs are not secure to prefetch hash from;
- hashes from upstream (in method 3) should be obtained via secure protocol;
- `https://` URLs are secure in methods 1, 2, 3;
- `https://` URLs are not secure in method 5. When obtaining hashes with fake hash method, TLS checks are disabled. So refetch source hash from several different networks to exclude MITM scenario. Alternatively, use fake hash method to make Nix error, but instead of extracting hash from error, extract `https://` URL and prefetch it with method 1.
## Patches {#sec-patches}
Patches available online should be retrieved using `fetchpatch`.
```nix
patches = [
(fetchpatch {
name = "fix-check-for-using-shared-freetype-lib.patch";
url = "http://git.ghostscript.com/?p=ghostpdl.git;a=patch;h=8f5d285";
sha256 = "1f0k043rng7f0rfl9hhb89qzvvksqmkrikmm38p61yfx51l325xr";
})
];
```
Otherwise, you can add a `.patch` file to the `nixpkgs` repository. In the interest of keeping our maintenance burden to a minimum, only patches that are unique to `nixpkgs` should be added in this way.
If a patch is available online but does not cleanly apply, it can be modified in some fixed ways by using additional optional arguments for `fetchpatch`. Check [](#fetchpatch) for details.
```nix
patches = [ ./0001-changes.patch ];
```
If you do need to do create this sort of patch file, one way to do so is with git:
1. Move to the root directory of the source code you're patching.
```ShellSession
$ cd the/program/source
```
2. If a git repository is not already present, create one and stage all of the source files.
```ShellSession
$ git init
$ git add .
```
3. Edit some files to make whatever changes need to be included in the patch.
4. Use git to create a diff, and pipe the output to a patch file:
```ShellSession
$ git diff -a > nixpkgs/pkgs/the/package/0001-changes.patch
```
## Package tests {#sec-package-tests}
Tests are important to ensure quality and make reviews and automatic updates easy.
The following types of tests exists:
* [NixOS **module tests**](https://nixos.org/manual/nixos/stable/#sec-nixos-tests), which spawn one or more NixOS VMs. They exercise both NixOS modules and the packaged programs used within them. For example, a NixOS module test can start a web server VM running the `nginx` module, and a client VM running `curl` or a graphical `firefox`, and test that they can talk to each other and display the correct content.
* Nix **package tests** are a lightweight alternative to NixOS module tests. They should be used to create simple integration tests for packages, but cannot test NixOS services, and some programs with graphical user interfaces may also be difficult to test with them.
* The **`checkPhase` of a package**, which should execute the unit tests that are included in the source code of a package.
Here in the nixpkgs manual we describe mostly _package tests_; for _module tests_ head over to the corresponding [section in the NixOS manual](https://nixos.org/manual/nixos/stable/#sec-nixos-tests).
### Writing inline package tests {#ssec-inline-package-tests-writing}
For very simple tests, they can be written inline:
```nix
{ …, yq-go }:
buildGoModule rec {
passthru.tests = {
simple = runCommand "${pname}-test" {} ''
echo "test: 1" | ${yq-go}/bin/yq eval -j > $out
[ "$(cat $out | tr -d $'\n ')" = '{"test":1}' ]
'';
};
}
```
### Writing larger package tests {#ssec-package-tests-writing}
This is an example using the `phoronix-test-suite` package with the current best practices.
Add the tests in `passthru.tests` to the package definition like this:
```nix
{ stdenv, lib, fetchurl, callPackage }:
stdenv.mkDerivation {
passthru.tests = {
simple-execution = callPackage ./tests.nix { };
};
meta = { … };
}
```
Create `tests.nix` in the package directory:
```nix
{ runCommand, phoronix-test-suite }:
let
inherit (phoronix-test-suite) pname version;
in
runCommand "${pname}-tests" { meta.timeout = 60; }
''
# automatic initial setup to prevent interactive questions
${phoronix-test-suite}/bin/phoronix-test-suite enterprise-setup >/dev/null
# get version of installed program and compare with package version
if [[ `${phoronix-test-suite}/bin/phoronix-test-suite version` != *"${version}"* ]]; then
echo "Error: program version does not match package version"
exit 1
fi
# run dummy command
${phoronix-test-suite}/bin/phoronix-test-suite dummy_module.dummy-command >/dev/null
# needed for Nix to register the command as successful
touch $out
''
```
### Running package tests {#ssec-package-tests-running}
You can run these tests with:
```ShellSession
$ cd path/to/nixpkgs
$ nix-build -A phoronix-test-suite.tests
```
### Examples of package tests {#ssec-package-tests-examples}
Here are examples of package tests:
- [Jasmin compile test](https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/compilers/jasmin/test-assemble-hello-world/default.nix)
- [Lobster compile test](https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/compilers/lobster/test-can-run-hello-world.nix)
- [Spacy annotation test](https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/python-modules/spacy/annotation-test/default.nix)
- [Libtorch test](https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/libraries/science/math/libtorch/test/default.nix)
- [Multiple tests for nanopb](https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/libraries/nanopb/default.nix)
### Linking NixOS module tests to a package {#ssec-nixos-tests-linking}
Like [package tests](#ssec-package-tests-writing) as shown above, [NixOS module tests](https://nixos.org/manual/nixos/stable/#sec-nixos-tests) can also be linked to a package, so that the tests can be easily run when changing the related package.
For example, assuming we're packaging `nginx`, we can link its module test via `passthru.tests`:
```nix
{ stdenv, lib, nixosTests }:
stdenv.mkDerivation {
...
passthru.tests = {
nginx = nixosTests.nginx;
};
...
}
```

View File

@@ -1,120 +0,0 @@
# Contributing to this documentation {#chap-contributing}
The sources of the Nixpkgs manual are in the [doc](https://github.com/NixOS/nixpkgs/tree/master/doc) subdirectory of the Nixpkgs repository. The manual is still partially written in DocBook but it is progressively being converted to [Markdown](#sec-contributing-markup).
You can quickly check your edits with `make`:
```ShellSession
$ cd /path/to/nixpkgs/doc
$ nix-shell
[nix-shell]$ make
```
If you experience problems, run `make debug` to help understand the docbook errors.
After making modifications to the manual, it's important to build it before committing. You can do that as follows:
```ShellSession
$ cd /path/to/nixpkgs/doc
$ nix-shell
[nix-shell]$ make clean
[nix-shell]$ nix-build .
```
If the build succeeds, the manual will be in `./result/share/doc/nixpkgs/manual.html`.
## Syntax {#sec-contributing-markup}
As per [RFC 0072](https://github.com/NixOS/rfcs/pull/72), all new documentation content should be written in [CommonMark](https://commonmark.org/) Markdown dialect.
Additional syntax extensions are available, though not all extensions can be used in NixOS option documentation. The following extensions are currently used:
- []{#ssec-contributing-markup-anchors}
Explicitly defined **anchors** on headings, to allow linking to sections. These should be always used, to ensure the anchors can be linked even when the heading text changes, and to prevent conflicts between [automatically assigned identifiers](https://github.com/jgm/commonmark-hs/blob/master/commonmark-extensions/test/auto_identifiers.md).
It uses the widely compatible [header attributes](https://github.com/jgm/commonmark-hs/blob/master/commonmark-extensions/test/attributes.md) syntax:
```markdown
## Syntax {#sec-contributing-markup}
```
- []{#ssec-contributing-markup-anchors-inline}
**Inline anchors**, which allow linking arbitrary place in the text (e.g. individual list items, sentences…).
They are defined using a hybrid of the link syntax with the attributes syntax known from headings, called [bracketed spans](https://github.com/jgm/commonmark-hs/blob/master/commonmark-extensions/test/bracketed_spans.md):
```markdown
- []{#ssec-gnome-hooks-glib} `glib` setup hook will populate `GSETTINGS_SCHEMAS_PATH` and then `wrapGAppsHook` will prepend it to `XDG_DATA_DIRS`.
```
- []{#ssec-contributing-markup-automatic-links}
If you **omit a link text** for a link pointing to a section, the text will be substituted automatically. For example, `[](#chap-contributing)` will result in [](#chap-contributing).
This syntax is taken from [MyST](https://myst-parser.readthedocs.io/en/latest/using/syntax.html#targets-and-cross-referencing).
- []{#ssec-contributing-markup-inline-roles}
If you want to link to a man page, you can use `` {manpage}`nix.conf(5)` ``, which will turn into {manpage}`nix.conf(5)`. The references will turn into links when a mapping exists in {file}`doc/build-aux/pandoc-filters/link-unix-man-references.lua`.
A few markups for other kinds of literals are also available:
- `` {command}`rm -rfi` `` turns into {command}`rm -rfi`
- `` {option}`networking.useDHCP` `` turns into {option}`networking.useDHCP`
- `` {file}`/etc/passwd` `` turns into {file}`/etc/passwd`
These literal kinds are used mostly in NixOS option documentation.
This syntax is taken from [MyST](https://myst-parser.readthedocs.io/en/latest/syntax/syntax.html#roles-an-in-line-extension-point). Though, the feature originates from [reStructuredText](https://www.sphinx-doc.org/en/master/usage/restructuredtext/roles.html#role-manpage) with slightly different syntax.
::: {.note}
Inline roles are available for option documentation.
:::
- []{#ssec-contributing-markup-admonitions}
**Admonitions**, set off from the text to bring attention to something.
It uses pandocs [fenced `div`s syntax](https://github.com/jgm/commonmark-hs/blob/master/commonmark-extensions/test/fenced_divs.md):
```markdown
::: {.warning}
This is a warning
:::
```
which renders as
> ::: {.warning}
> This is a warning.
> :::
The following are supported:
- [`caution`](https://tdg.docbook.org/tdg/5.0/caution.html)
- [`important`](https://tdg.docbook.org/tdg/5.0/important.html)
- [`note`](https://tdg.docbook.org/tdg/5.0/note.html)
- [`tip`](https://tdg.docbook.org/tdg/5.0/tip.html)
- [`warning`](https://tdg.docbook.org/tdg/5.0/warning.html)
::: {.note}
Admonitions are available for option documentation.
:::
- []{#ssec-contributing-markup-definition-lists}
[**Definition lists**](https://github.com/jgm/commonmark-hs/blob/master/commonmark-extensions/test/definition_lists.md), for defining a group of terms:
```markdown
pear
: green or yellow bulbous fruit
watermelon
: green fruit with red flesh
```
which renders as
> pear
> : green or yellow bulbous fruit
>
> watermelon
> : green fruit with red flesh
For contributing to the legacy parts, please see [DocBook: The Definitive Guide](https://tdg.docbook.org/) or the [DocBook rocks! primer](https://web.archive.org/web/20200816233747/https://docbook.rocks/).

View File

@@ -1,77 +0,0 @@
# Quick Start to Adding a Package {#chap-quick-start}
To add a package to Nixpkgs:
1. Checkout the Nixpkgs source tree:
```ShellSession
$ git clone https://github.com/NixOS/nixpkgs
$ cd nixpkgs
```
2. Find a good place in the Nixpkgs tree to add the Nix expression for your package. For instance, a library package typically goes into `pkgs/development/libraries/pkgname`, while a web browser goes into `pkgs/applications/networking/browsers/pkgname`. See [](#sec-organisation) for some hints on the tree organisation. Create a directory for your package, e.g.
```ShellSession
$ mkdir pkgs/development/libraries/libfoo
```
3. In the package directory, create a Nix expression — a piece of code that describes how to build the package. In this case, it should be a _function_ that is called with the package dependencies as arguments, and returns a build of the package in the Nix store. The expression should usually be called `default.nix`.
```ShellSession
$ emacs pkgs/development/libraries/libfoo/default.nix
$ git add pkgs/development/libraries/libfoo/default.nix
```
You can have a look at the existing Nix expressions under `pkgs/` to see how its done. Here are some good ones:
- GNU Hello: [`pkgs/applications/misc/hello/default.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/misc/hello/default.nix). Trivial package, which specifies some `meta` attributes which is good practice.
- GNU cpio: [`pkgs/tools/archivers/cpio/default.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/tools/archivers/cpio/default.nix). Also a simple package. The generic builder in `stdenv` does everything for you. It has no dependencies beyond `stdenv`.
- GNU Multiple Precision arithmetic library (GMP): [`pkgs/development/libraries/gmp/5.1.x.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/libraries/gmp/5.1.x.nix). Also done by the generic builder, but has a dependency on `m4`.
- Pan, a GTK-based newsreader: [`pkgs/applications/networking/newsreaders/pan/default.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/networking/newsreaders/pan/default.nix). Has an optional dependency on `gtkspell`, which is only built if `spellCheck` is `true`.
- Apache HTTPD: [`pkgs/servers/http/apache-httpd/2.4.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/servers/http/apache-httpd/2.4.nix). A bunch of optional features, variable substitutions in the configure flags, a post-install hook, and miscellaneous hackery.
- Thunderbird: [`pkgs/applications/networking/mailreaders/thunderbird/default.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/networking/mailreaders/thunderbird/default.nix). Lots of dependencies.
- JDiskReport, a Java utility: [`pkgs/tools/misc/jdiskreport/default.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/tools/misc/jdiskreport/default.nix). Nixpkgs doesnt have a decent `stdenv` for Java yet so this is pretty ad-hoc.
- XML::Simple, a Perl module: [`pkgs/top-level/perl-packages.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/top-level/perl-packages.nix) (search for the `XMLSimple` attribute). Most Perl modules are so simple to build that they are defined directly in `perl-packages.nix`; no need to make a separate file for them.
- Adobe Reader: [`pkgs/applications/misc/adobe-reader/default.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/misc/adobe-reader/default.nix). Shows how binary-only packages can be supported. In particular the [builder](https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/misc/adobe-reader/builder.sh) uses `patchelf` to set the RUNPATH and ELF interpreter of the executables so that the right libraries are found at runtime.
Some notes:
- All [`meta`](#chap-meta) attributes are optional, but its still a good idea to provide at least the `description`, `homepage` and [`license`](#sec-meta-license).
- You can use `nix-prefetch-url url` to get the SHA-256 hash of source distributions. There are similar commands as `nix-prefetch-git` and `nix-prefetch-hg` available in `nix-prefetch-scripts` package.
- A list of schemes for `mirror://` URLs can be found in [`pkgs/build-support/fetchurl/mirrors.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/build-support/fetchurl/mirrors.nix).
The exact syntax and semantics of the Nix expression language, including the built-in function, are described in the Nix manual in the [chapter on writing Nix expressions](https://hydra.nixos.org/job/nix/trunk/tarball/latest/download-by-type/doc/manual/#chap-writing-nix-expressions).
4. Add a call to the function defined in the previous step to [`pkgs/top-level/all-packages.nix`](https://github.com/NixOS/nixpkgs/blob/master/pkgs/top-level/all-packages.nix) with some descriptive name for the variable, e.g. `libfoo`.
```ShellSession
$ emacs pkgs/top-level/all-packages.nix
```
The attributes in that file are sorted by category (like “Development / Libraries”) that more-or-less correspond to the directory structure of Nixpkgs, and then by attribute name.
5. To test whether the package builds, run the following command from the root of the nixpkgs source tree:
```ShellSession
$ nix-build -A libfoo
```
where `libfoo` should be the variable name defined in the previous step. You may want to add the flag `-K` to keep the temporary build directory in case something fails. If the build succeeds, a symlink `./result` to the package in the Nix store is created.
6. If you want to install the package into your profile (optional), do
```ShellSession
$ nix-env -f . -iA libfoo
```
7. Optionally commit the new package and open a pull request [to nixpkgs](https://github.com/NixOS/nixpkgs/pulls), or use [the Patches category](https://discourse.nixos.org/t/about-the-patches-category/477) on Discourse for sending a patch without a GitHub account.

View File

@@ -1,313 +0,0 @@
# Reviewing contributions {#chap-reviewing-contributions}
::: {.warning}
The following section is a draft, and the policy for reviewing is still being discussed in issues such as [#11166](https://github.com/NixOS/nixpkgs/issues/11166) and [#20836](https://github.com/NixOS/nixpkgs/issues/20836).
:::
The Nixpkgs project receives a fairly high number of contributions via GitHub pull requests. Reviewing and approving these is an important task and a way to contribute to the project.
The high change rate of Nixpkgs makes any pull request that remains open for too long subject to conflicts that will require extra work from the submitter or the merger. Reviewing pull requests in a timely manner and being responsive to the comments is the key to avoid this issue. GitHub provides sort filters that can be used to see the [most recently](https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+sort%3Aupdated-desc) and the [least recently](https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+sort%3Aupdated-asc) updated pull requests. We highly encourage looking at [this list of ready to merge, unreviewed pull requests](https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+review%3Anone+status%3Asuccess+-label%3A%222.status%3A+work-in-progress%22+no%3Aproject+no%3Aassignee+no%3Amilestone).
When reviewing a pull request, please always be nice and polite. Controversial changes can lead to controversial opinions, but it is important to respect every community member and their work.
GitHub provides reactions as a simple and quick way to provide feedback to pull requests or any comments. The thumb-down reaction should be used with care and if possible accompanied with some explanation so the submitter has directions to improve their contribution.
pull request reviews should include a list of what has been reviewed in a comment, so other reviewers and mergers can know the state of the review.
All the review template samples provided in this section are generic and meant as examples. Their usage is optional and the reviewer is free to adapt them to their liking.
## Package updates {#reviewing-contributions-package-updates}
A package update is the most trivial and common type of pull request. These pull requests mainly consist of updating the version part of the package name and the source hash.
It can happen that non-trivial updates include patches or more complex changes.
Reviewing process:
- Ensure that the package versioning fits the guidelines.
- Ensure that the commit text fits the guidelines.
- Ensure that the package maintainers are notified.
- [CODEOWNERS](https://help.github.com/articles/about-codeowners) will make GitHub notify users based on the submitted changes, but it can happen that it misses some of the package maintainers.
- Ensure that the meta field information is correct.
- License can change with version updates, so it should be checked to match the upstream license.
- If the package has no maintainer, a maintainer must be set. This can be the update submitter or a community member that accepts to take maintainership of the package.
- Ensure that the code contains no typos.
- Building the package locally.
- pull requests are often targeted to the master or staging branch, and building the pull request locally when it is submitted can trigger many source builds.
- It is possible to rebase the changes on nixos-unstable or nixpkgs-unstable for easier review by running the following commands from a nixpkgs clone.
```ShellSession
$ git fetch origin nixos-unstable
$ git fetch origin pull/PRNUMBER/head
$ git rebase --onto nixos-unstable BASEBRANCH FETCH_HEAD
```
- The first command fetches the nixos-unstable branch.
- The second command fetches the pull request changes, `PRNUMBER` is the number at the end of the pull request title and `BASEBRANCH` the base branch of the pull request.
- The third command rebases the pull request changes to the nixos-unstable branch.
- The [nixpkgs-review](https://github.com/Mic92/nixpkgs-review) tool can be used to review a pull request content in a single command. `PRNUMBER` should be replaced by the number at the end of the pull request title. You can also provide the full github pull request url.
```ShellSession
$ nix-shell -p nixpkgs-review --run "nixpkgs-review pr PRNUMBER"
```
- Running every binary.
Sample template for a package update review is provided below.
```markdown
##### Reviewed points
- [ ] package name fits guidelines
- [ ] package version fits guidelines
- [ ] package build on ARCHITECTURE
- [ ] executables tested on ARCHITECTURE
- [ ] all depending packages build
##### Possible improvements
##### Comments
```
## New packages {#reviewing-contributions-new-packages}
New packages are a common type of pull requests. These pull requests consists in adding a new nix-expression for a package.
Review process:
- Ensure that the package versioning fits the guidelines.
- Ensure that the commit name fits the guidelines.
- Ensure that the meta fields contain correct information.
- License must match the upstream license.
- Platforms should be set (or the package will not get binary substitutes).
- Maintainers must be set. This can be the package submitter or a community member that accepts taking up maintainership of the package.
- Report detected typos.
- Ensure the package source:
- Uses mirror URLs when available.
- Uses the most appropriate functions (e.g. packages from GitHub should use `fetchFromGitHub`).
- Building the package locally.
- Running every binary.
Sample template for a new package review is provided below.
```markdown
##### Reviewed points
- [ ] package path fits guidelines
- [ ] package name fits guidelines
- [ ] package version fits guidelines
- [ ] package build on ARCHITECTURE
- [ ] executables tested on ARCHITECTURE
- [ ] `meta.description` is set and fits guidelines
- [ ] `meta.license` fits upstream license
- [ ] `meta.platforms` is set
- [ ] `meta.maintainers` is set
- [ ] build time only dependencies are declared in `nativeBuildInputs`
- [ ] source is fetched using the appropriate function
- [ ] the list of `phases` is not overridden
- [ ] when a phase (like `installPhase`) is overridden it starts with `runHook preInstall` and ends with `runHook postInstall`.
- [ ] patches that are remotely available are fetched with `fetchpatch`
##### Possible improvements
##### Comments
```
## Module updates {#reviewing-contributions-module-updates}
Module updates are submissions changing modules in some ways. These often contains changes to the options or introduce new options.
Reviewing process:
- Ensure that the module maintainers are notified.
- [CODEOWNERS](https://help.github.com/articles/about-codeowners/) will make GitHub notify users based on the submitted changes, but it can happen that it misses some of the package maintainers.
- Ensure that the module tests, if any, are succeeding.
- Ensure that the introduced options are correct.
- Type should be appropriate (string related types differs in their merging capabilities, `loaOf` and `string` types are deprecated).
- Description, default and example should be provided.
- Ensure that option changes are backward compatible.
- `mkRenamedOptionModuleWith` provides a way to make option changes backward compatible.
- Ensure that removed options are declared with `mkRemovedOptionModule`
- Ensure that changes that are not backward compatible are mentioned in release notes.
- Ensure that documentations affected by the change is updated.
Sample template for a module update review is provided below.
```markdown
##### Reviewed points
- [ ] changes are backward compatible
- [ ] removed options are declared with `mkRemovedOptionModule`
- [ ] changes that are not backward compatible are documented in release notes
- [ ] module tests succeed on ARCHITECTURE
- [ ] options types are appropriate
- [ ] options description is set
- [ ] options example is provided
- [ ] documentation affected by the changes is updated
##### Possible improvements
##### Comments
```
## New modules {#reviewing-contributions-new-modules}
New modules submissions introduce a new module to NixOS.
Reviewing process:
- Ensure that the module tests, if any, are succeeding.
- Ensure that the introduced options are correct.
- Type should be appropriate (string related types differs in their merging capabilities, `loaOf` and `string` types are deprecated).
- Description, default and example should be provided.
- Ensure that module `meta` field is present
- Maintainers should be declared in `meta.maintainers`.
- Module documentation should be declared with `meta.doc`.
- Ensure that the module respect other modules functionality.
- For example, enabling a module should not open firewall ports by default.
Sample template for a new module review is provided below.
```markdown
##### Reviewed points
- [ ] module path fits the guidelines
- [ ] module tests succeed on ARCHITECTURE
- [ ] options have appropriate types
- [ ] options have default
- [ ] options have example
- [ ] options have descriptions
- [ ] No unneeded package is added to environment.systemPackages
- [ ] meta.maintainers is set
- [ ] module documentation is declared in meta.doc
##### Possible improvements
##### Comments
```
## Individual maintainer list {#reviewing-contributions-indvidual-maintainer-list}
When adding users to `maintainers/maintainer-list.nix`, the following
checks should be performed:
- If the user has specified a GPG key, verify that the commit is
signed by their key.
First, validate that the commit adding the maintainer is signed by
the key the maintainer listed. Check out the pull request and
compare its signing key with the listed key in the commit.
If the commit is not signed or it is signed by a different user, ask
them to either recommit using that key or to remove their key
information.
Given a maintainter entry like this:
``` nix
{
example = {
email = "user@example.com";
name = "Example User";
keys = [{
fingerprint = "0000 0000 2A70 6423 0AED 3C11 F04F 7A19 AAA6 3AFE";
}];
}
};
```
First receive their key from a keyserver:
$ gpg --recv-keys 0xF04F7A19AAA63AFE
gpg: key 0xF04F7A19AAA63AFE: public key "Example <user@example.com>" imported
gpg: Total number processed: 1
gpg: imported: 1
Then check the commit is signed by that key:
$ git log --show-signature
commit b87862a4f7d32319b1de428adb6cdbdd3a960153
gpg: Signature made Wed Mar 12 13:32:24 2003 +0000
gpg: using RSA key 000000002A7064230AED3C11F04F7A19AAA63AFE
gpg: Good signature from "Example User <user@example.com>
Author: Example User <user@example.com>
Date: Wed Mar 12 13:32:24 2003 +0000
maintainers: adding example
and validate that there is a `Good signature` and the printed key
matches the user's submitted key.
Note: GitHub's "Verified" label does not display the user's full key
fingerprint, and should not be used for validating the key matches.
- If the user has specified a `github` account name, ensure they have
also specified a `githubId` and verify the two match.
Maintainer entries that include a `github` field must also include
their `githubId`. People can and do change their GitHub name
frequently, and the ID is used as the official and stable identity
of the maintainer.
Given a maintainer entry like this:
``` nix
{
example = {
email = "user@example.com";
name = "Example User";
github = "ghost";
githubId = 10137;
}
};
```
First, make sure that the listed GitHub handle matches the author of
the commit.
Then, visit the URL `https://api.github.com/users/ghost` and
validate that the `id` field matches the provided `githubId`.
## Maintainer teams {#reviewing-contributions-maintainer-teams}
Feel free to create a new maintainer team in `maintainers/team-list.nix`
when a group is collectively responsible for a collection of packages.
Use taste and personal judgement when deciding if a team is warranted.
Teams are allowed to define their own rules about membership.
For example, some teams will represent a business or other group which
wants to carefully track its members. Other teams may be very open about
who can join, and allow anybody to participate.
When reviewing changes to a team, read the team's scope and the context
around the member list for indications about the team's membership
policy.
In any case, request reviews from the existing team members. If the team
lists no specific membership policy, feel free to merge changes to the
team after giving the existing members a few days to respond.
*Important:* If a team says it is a closed group, do not merge additions
to the team without an approval by at least one existing member.
## Other submissions {#reviewing-contributions-other-submissions}
Other type of submissions requires different reviewing steps.
If you consider having enough knowledge and experience in a topic and would like to be a long-term reviewer for related submissions, please contact the current reviewers for that topic. They will give you information about the reviewing process. The main reviewers for a topic can be hard to find as there is no list, but checking past pull requests to see who reviewed or git-blaming the code to see who committed to that topic can give some hints.
Container system, boot system and library changes are some examples of the pull requests fitting this category.
## Merging pull requests {#reviewing-contributions--merging-pull-requests}
It is possible for community members that have enough knowledge and experience on a special topic to contribute by merging pull requests.
<!--
The following paragraphs about how to deal with unactive contributors is just a proposition and should be modified to what the community agrees to be the right policy.
Please note that contributors with commit rights unactive for more than three months will have their commit rights revoked.
-->
Please see the discussion in [GitHub nixpkgs issue #50105](https://github.com/NixOS/nixpkgs/issues/50105) for information on how to proceed to be granted this level of access.
In a case a contributor definitively leaves the Nix community, they should create an issue or post on [Discourse](https://discourse.nixos.org) with references of packages and modules they maintain so the maintainership can be taken over by other contributors.

View File

@@ -1,298 +0,0 @@
# Submitting changes {#chap-submitting-changes}
## Making patches {#submitting-changes-making-patches}
- Read [Manual (How to write packages for Nix)](https://nixos.org/nixpkgs/manual/).
- Fork [the Nixpkgs repository](https://github.com/nixos/nixpkgs/) on GitHub.
- Create a branch for your future fix.
- You can make branch from a commit of your local `nixos-version`. That will help you to avoid additional local compilations. Because you will receive packages from binary cache. For example
```ShellSession
$ nixos-version --hash
0998212
$ git checkout 0998212
$ git checkout -b 'fix/pkg-name-update'
```
- Please avoid working directly on the `master` branch.
- Make commits of logical units.
- If you removed pkgs or made some major NixOS changes, write about it in the release notes for the next stable release. For example `nixos/doc/manual/release-notes/rl-2003.xml`.
- Check for unnecessary whitespace with `git diff --check` before committing.
- Format the commit in a following way:
```
(pkg-name | nixos/<module>): (from -> to | init at version | refactor | etc)
Additional information.
```
- Examples:
- `nginx: init at 2.0.1`
- `firefox: 54.0.1 -> 55.0`
- `nixos/hydra: add bazBaz option`
- `nixos/nginx: refactor config generation`
- Test your changes. If you work with
- nixpkgs:
- update pkg
- `nix-env -iA pkg-attribute-name -f <path to your local nixpkgs folder>`
- add pkg
- Make sure its in `pkgs/top-level/all-packages.nix`
- `nix-env -iA pkg-attribute-name -f <path to your local nixpkgs folder>`
- _If you dont want to install pkg in you profile_.
- `nix-build -A pkg-attribute-name <path to your local nixpkgs folder>` and check results in the folder `result`. It will appear in the same directory where you did `nix-build`.
- If you installed your package with `nix-env`, you can run `nix-env -e pkg-name` where `pkg-name` is as reported by `nix-env -q` to uninstall it from your system.
- NixOS and its modules:
- You can add new module to your NixOS configuration file (usually its `/etc/nixos/configuration.nix`). And do `sudo nixos-rebuild test -I nixpkgs=<path to your local nixpkgs folder> --fast`.
- If you have commits `pkg-name: oh, forgot to insert whitespace`: squash commits in this case. Use `git rebase -i`.
- [Rebase](https://git-scm.com/book/en/v2/Git-Branching-Rebasing) your branch against current `master`.
## Submitting changes {#submitting-changes-submitting-changes}
- Push your changes to your fork of nixpkgs.
- Create the pull request
- Follow [the contribution guidelines](https://github.com/NixOS/nixpkgs/blob/master/CONTRIBUTING.md#submitting-changes).
## Submitting security fixes {#submitting-changes-submitting-security-fixes}
Security fixes are submitted in the same way as other changes and thus the same guidelines apply.
- If a new version fixing the vulnerability has been released, update the package;
- If the security fix comes in the form of a patch and a CVE is available, then add the patch to the Nixpkgs tree, and apply it to the package.
The name of the patch should be the CVE identifier, so e.g. `CVE-2019-13636.patch`; If a patch is fetched the name needs to be set as well, e.g.:
```nix
(fetchpatch {
name = "CVE-2019-11068.patch";
url = "https://gitlab.gnome.org/GNOME/libxslt/commit/e03553605b45c88f0b4b2980adfbbb8f6fca2fd6.patch";
sha256 = "0pkpb4837km15zgg6h57bncp66d5lwrlvkr73h0lanywq7zrwhj8";
})
```
If a security fix applies to both master and a stable release then, similar to regular changes, they are preferably delivered via master first and cherry-picked to the release branch.
Critical security fixes may by-pass the staging branches and be delivered directly to release branches such as `master` and `release-*`.
## Deprecating/removing packages {#submitting-changes-deprecating-packages}
There is currently no policy when to remove a package.
Before removing a package, one should try to find a new maintainer or fix smaller issues first.
### Steps to remove a package from Nixpkgs {#steps-to-remove-a-package-from-nixpkgs}
We use jbidwatcher as an example for a discontinued project here.
1. Have Nixpkgs checked out locally and up to date.
1. Create a new branch for your change, e.g. `git checkout -b jbidwatcher`
1. Remove the actual package including its directory, e.g. `git rm -rf pkgs/applications/misc/jbidwatcher`
1. Remove the package from the list of all packages (`pkgs/top-level/all-packages.nix`).
1. Add an alias for the package name in `pkgs/top-level/aliases.nix` (There is also `pkgs/applications/editors/vim/plugins/aliases.nix`. Package sets typically do not have aliases, so we can't add them there.)
For example in this case:
```
jbidwatcher = throw "jbidwatcher was discontinued in march 2021"; # added 2021-03-15
```
The throw message should explain in short why the package was removed for users that still have it installed.
1. Test if the changes introduced any issues by running `nix-env -qaP -f . --show-trace`. It should show the list of packages without errors.
1. Commit the changes. Explain again why the package was removed. If it was declared discontinued upstream, add a link to the source.
```ShellSession
$ git add pkgs/applications/misc/jbidwatcher/default.nix pkgs/top-level/all-packages.nix pkgs/top-level/aliases.nix
$ git commit
```
Example commit message:
```
jbidwatcher: remove
project was discontinued in march 2021. the program does not work anymore because ebay changed the login.
https://web.archive.org/web/20210315205723/http://www.jbidwatcher.com/
```
1. Push changes to your GitHub fork with `git push`
1. Create a pull request against Nixpkgs. Mention the package maintainer.
This is how the pull request looks like in this case: [https://github.com/NixOS/nixpkgs/pull/116470](https://github.com/NixOS/nixpkgs/pull/116470)
## Pull Request Template {#submitting-changes-pull-request-template}
The pull request template helps determine what steps have been made for a contribution so far, and will help guide maintainers on the status of a change. The motivation section of the PR should include any extra details the title does not address and link any existing issues related to the pull request.
When a PR is created, it will be pre-populated with some checkboxes detailed below:
### Tested using sandboxing {#submitting-changes-tested-with-sandbox}
When sandbox builds are enabled, Nix will setup an isolated environment for each build process. It is used to remove further hidden dependencies set by the build environment to improve reproducibility. This includes access to the network during the build outside of `fetch*` functions and files outside the Nix store. Depending on the operating system access to other resources are blocked as well (ex. inter process communication is isolated on Linux); see [sandbox](https://nixos.org/nix/manual/#conf-sandbox) in Nix manual for details.
Sandboxing is not enabled by default in Nix due to a small performance hit on each build. In pull requests for [nixpkgs](https://github.com/NixOS/nixpkgs/) people are asked to test builds with sandboxing enabled (see `Tested using sandboxing` in the pull request template) because in<https://nixos.org/hydra/> sandboxing is also used.
Depending if you use NixOS or other platforms you can use one of the following methods to enable sandboxing **before** building the package:
- **Globally enable sandboxing on NixOS**: add the following to `configuration.nix`
```nix
nix.useSandbox = true;
```
- **Globally enable sandboxing on non-NixOS platforms**: add the following to: `/etc/nix/nix.conf`
```ini
sandbox = true
```
### Built on platform(s) {#submitting-changes-platform-diversity}
Many Nix packages are designed to run on multiple platforms. As such, its important to let the maintainer know which platforms your changes have been tested on. Its not always practical to test a change on all platforms, and is not required for a pull request to be merged. Only check the systems you tested the build on in this section.
### Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests) {#submitting-changes-nixos-tests}
Packages with automated tests are much more likely to be merged in a timely fashion because it doesnt require as much manual testing by the maintainer to verify the functionality of the package. If there are existing tests for the package, they should be run to verify your changes do not break the tests. Tests can only be run on Linux. For more details on writing and running tests, see the [section in the NixOS manual](https://nixos.org/nixos/manual/index.html#sec-nixos-tests).
### Tested compilation of all pkgs that depend on this change using `nixpkgs-review` {#submitting-changes-tested-compilation}
If you are updating a packages version, you can use `nixpkgs-review` to make sure all packages that depend on the updated package still compile correctly. The `nixpkgs-review` utility can look for and build all dependencies either based on uncommitted changes with the `wip` option or specifying a GitHub pull request number.
Review changes from pull request number 12345:
```ShellSession
nix-shell -p nixpkgs-review --run "nixpkgs-review pr 12345"
```
Alternatively, with flakes (and analogously for the other commands below):
```ShellSession
nix run nixpkgs#nixpkgs-review -- pr 12345
```
Review uncommitted changes:
```ShellSession
nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
```
Review changes from last commit:
```ShellSession
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
```
### Tested execution of all binary files (usually in `./result/bin/`) {#submitting-changes-tested-execution}
Its important to test any executables generated by a build when you change or create a package in nixpkgs. This can be done by looking in `./result/bin` and running any files in there, or at a minimum, the main executable for the package. For example, if you make a change to texlive, you probably would only check the binaries associated with the change you made rather than testing all of them.
### Meets Nixpkgs contribution standards {#submitting-changes-contribution-standards}
The last checkbox is fits [CONTRIBUTING.md](https://github.com/NixOS/nixpkgs/blob/master/CONTRIBUTING.md). The contributing document has detailed information on standards the Nix community has for commit messages, reviews, licensing of contributions you make to the project, etc\... Everyone should read and understand the standards the community has for contributing before submitting a pull request.
## Hotfixing pull requests {#submitting-changes-hotfixing-pull-requests}
- Make the appropriate changes in you branch.
- Dont create additional commits, do
- `git rebase -i`
- `git push --force` to your branch.
## Commit policy {#submitting-changes-commit-policy}
- Commits must be sufficiently tested before being merged, both for the master and staging branches.
- Hydra builds for master and staging should not be used as testing platform, its a build farm for changes that have been already tested.
- When changing the bootloader installation process, extra care must be taken. Grub installations cannot be rolled back, hence changes may break peoples installations forever. For any non-trivial change to the bootloader please file a PR asking for review, especially from \@edolstra.
```{.graphviz caption="Staging workflow"}
digraph {
"small changes" [shape=none]
"mass-rebuilds and other large changes" [shape=none]
"critical security fixes" [shape=none]
"broken staging-next fixes" [shape=none]
"small changes" -> master
"mass-rebuilds and other large changes" -> staging
"critical security fixes" -> master
"broken staging-next fixes" -> "staging-next"
"staging-next" -> master [color="#E85EB0"] [label="stabilization ends"] [fontcolor="#E85EB0"]
"staging" -> "staging-next" [color="#E85EB0"] [label="stabilization starts"] [fontcolor="#E85EB0"]
master -> "staging-next" -> staging [color="#5F5EE8"] [label="every six hours (GitHub Action)"] [fontcolor="#5F5EE8"]
}
```
[This GitHub Action](https://github.com/NixOS/nixpkgs/blob/master/.github/workflows/periodic-merge-6h.yml) brings changes from `master` to `staging-next` and from `staging-next` to `staging` every 6 hours; these are the blue arrows in the diagram above. The purple arrows in the diagram above are done manually and much less frequently. You can get an idea of how often these merges occur by looking at the git history.
### Master branch {#submitting-changes-master-branch}
The `master` branch is the main development branch. It should only see non-breaking commits that do not cause mass rebuilds.
### Staging branch {#submitting-changes-staging-branch}
The `staging` branch is a development branch where mass-rebuilds go. Mass rebuilds are commits that cause rebuilds for many packages, like more than 500 (or perhaps, if it's 'light' packages, 1000). It should only see non-breaking mass-rebuild commits. That means it is not to be used for testing, and changes must have been well tested already. If the branch is already in a broken state, please refrain from adding extra new breakages.
### Staging-next branch {#submitting-changes-staging-next-branch}
The `staging-next` branch is for stabilizing mass-rebuilds submitted to the `staging` branch prior to merging them into `master`. Mass-rebuilds must go via the `staging` branch. It must only see non-breaking commits that are fixing issues blocking it from being merged into the `master ` branch.
If the branch is already in a broken state, please refrain from adding extra new breakages. Stabilize it for a few days and then merge into master.
### Stable release branches {#submitting-changes-stable-release-branches}
The same staging workflow applies to stable release branches, but the main branch is called `release-*` instead of `master`.
Example branch names: `release-21.11`, `staging-21.11`, `staging-next-21.11`.
Most changes added to the stable release branches are cherry-picked (“backported”) from the `master` and staging branches.
#### Automatically backporting a Pull Request {#submitting-changes-stable-release-branches-automatic-backports}
Assign label `backport <branch>` (e.g. `backport release-21.11`) to the PR and a backport PR is automatically created after the PR is merged.
#### Manually backporting changes {#submitting-changes-stable-release-branches-manual-backports}
Cherry-pick changes via `git cherry-pick -x <original commit>` so that the original commit id is included in the commit message.
Add a reason for the backport when it is not obvious from the original commit message. You can do this by cherry picking with `git cherry-pick -xe <original commit>`, which allows editing the commit message. This is not needed for minor version updates that include security and bug fixes but don't add new features or when the commit fixes an otherwise broken package.
Here is an example of a cherry-picked commit message with good reason description:
```
zfs: Keep trying root import until it works
Works around #11003.
(cherry picked from commit 98b213a11041af39b39473906b595290e2a4e2f9)
Reason: several people cannot boot with ZFS on NVMe
```
Other examples of reasons are:
- Previously the build would fail due to, e.g., `getaddrinfo` not being defined
- The previous download links were all broken
- Crash when starting on some X11 systems
#### Acceptable backport criteria
The stable branch does have some changes which cannot be backported. Most notable are breaking changes. The desire is to have stable users be uninterrupted when updating packages.
However, many changes are able to be backported, including:
- New Packages / Modules
- Security / Patch updates
- Version updates which include new functionality (but no breaking changes)
- Services which require a client to be up-to-date regardless. (E.g. `spotify`, `steam`, or `discord`)
- Security critical applications (E.g. `firefox`)

View File

@@ -1,45 +0,0 @@
# Vulnerability Roundup {#chap-vulnerability-roundup}
## Issues {#vulnerability-roundup-issues}
Vulnerable packages in Nixpkgs are managed using issues.
Currently opened ones can be found using the following:
[github.com/NixOS/nixpkgs/issues?q=is:issue+is:open+"Vulnerability+roundup"](https://github.com/NixOS/nixpkgs/issues?q=is%3Aissue+is%3Aopen+%22Vulnerability+roundup%22)
Each issue correspond to a vulnerable version of a package; As a consequence:
- One issue can contain several CVEs;
- One CVE can be shared across several issues;
- A single package can be concerned by several issues.
A "Vulnerability roundup" issue usually respects the following format:
```txt
<link to relevant package search on search.nix.gsc.io>, <link to relevant files in Nixpkgs on GitHub>
<list of related CVEs, their CVSS score, and the impacted NixOS version>
<list of the scanned Nixpkgs versions>
<list of relevant contributors>
```
Note that there can be an extra comment containing links to previously reported (and still open) issues for the same package.
## Triaging and Fixing {#vulnerability-roundup-triaging-and-fixing}
**Note**: An issue can be a "false positive" (i.e. automatically opened, but without the package it refers to being actually vulnerable).
If you find such a "false positive", comment on the issue an explanation of why it falls into this category, linking as much information as the necessary to help maintainers double check.
If you are investigating a "true positive":
- Find the earliest patched version or a code patch in the CVE details;
- Is the issue already patched (version up-to-date or patch applied manually) in Nixpkgs's `master` branch?
- **No**:
- [Submit a security fix](#submitting-changes-submitting-security-fixes);
- Once the fix is merged into `master`, [submit the change to the vulnerable release branch(es)](https://nixos.org/manual/nixpkgs/stable/#submitting-changes-stable-release-branches);
- **Yes**: [Backport the change to the vulnerable release branch(es)](https://nixos.org/manual/nixpkgs/stable/#submitting-changes-stable-release-branches).
- When the patch has made it into all the relevant branches (`master`, and the vulnerable releases), close the relevant issue(s).

View File

@@ -1,39 +1,42 @@
{ pkgs ? (import ./.. { }), nixpkgs ? { }}:
let
lib = pkgs.lib;
doc-support = import ./doc-support { inherit pkgs nixpkgs; };
in pkgs.stdenv.mkDerivation {
with import ./.. { };
with lib;
stdenv.mkDerivation {
name = "nixpkgs-manual";
nativeBuildInputs = with pkgs; [
pandoc
graphviz
libxml2
libxslt
zip
jing
xmlformat
];
sources = sourceFilesBySuffices ./. [".xml"];
src = lib.cleanSource ./.;
buildInputs = [ libxml2 libxslt ];
postPatch = ''
ln -s ${doc-support} ./doc-support/result
xsltFlags = ''
--param section.autolabel 1
--param section.label.includes.component.label 1
--param html.stylesheet 'style.css'
--param xref.with.number.and.title 1
--param toc.section.depth 3
--param admon.style '''
--param callout.graphics.extension '.gif'
'';
installPhase = ''
dest="$out/share/doc/nixpkgs"
mkdir -p "$(dirname "$dest")"
mv out/html "$dest"
mv "$dest/index.html" "$dest/manual.html"
buildCommand = ''
ln -s $sources/*.xml . # */
mv out/epub/manual.epub "$dest/nixpkgs-manual.epub"
echo ${nixpkgsVersion} > .version
mkdir -p $out/nix-support/
echo "doc manual $dest manual.html" >> $out/nix-support/hydra-build-products
echo "doc manual $dest nixpkgs-manual.epub" >> $out/nix-support/hydra-build-products
xmllint --noout --nonet --xinclude --noxincludenode \
--relaxng ${docbook5}/xml/rng/docbook/docbook.rng \
manual.xml
dst=$out/share/doc/nixpkgs
mkdir -p $dst
xsltproc $xsltFlags --nonet --xinclude \
--output $dst/manual.html \
${docbook5_xsl}/xml/xsl/docbook/xhtml/docbook.xsl \
./manual.xml
cp ${./style.css} $dst/style.css
mkdir -p $out/nix-support
echo "doc manual $dst manual.html" >> $out/nix-support/hydra-build-products
'';
# Environment variables
PANDOC_LUA_FILTERS_DIR = "${pkgs.pandoc-lua-filters}/share/pandoc/filters";
}

View File

@@ -1,69 +0,0 @@
{ pkgs ? (import ../.. {}), nixpkgs ? { }}:
let
inherit (pkgs) lib;
inherit (lib) hasPrefix removePrefix;
locationsXml = import ./lib-function-locations.nix { inherit pkgs nixpkgs; };
functionDocs = import ./lib-function-docs.nix { inherit locationsXml pkgs; };
version = pkgs.lib.version;
epub-xsl = pkgs.writeText "epub.xsl" ''
<?xml version='1.0'?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:import href="${pkgs.docbook_xsl_ns}/xml/xsl/docbook/epub/docbook.xsl" />
<xsl:import href="${./parameters.xml}"/>
</xsl:stylesheet>
'';
xhtml-xsl = pkgs.writeText "xhtml.xsl" ''
<?xml version='1.0'?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:import href="${pkgs.docbook_xsl_ns}/xml/xsl/docbook/xhtml/docbook.xsl" />
<xsl:import href="${./parameters.xml}"/>
</xsl:stylesheet>
'';
# NB: This file describes the Nixpkgs manual, which happens to use module
# docs infra originally developed for NixOS.
optionsDoc = pkgs.nixosOptionsDoc {
inherit (pkgs.lib.evalModules { modules = [ ../../pkgs/top-level/config.nix ]; }) options;
documentType = "none";
transformOptions = opt:
opt // {
declarations =
map
(decl:
if hasPrefix (toString ../..) (toString decl)
then
let subpath = removePrefix "/" (removePrefix (toString ../..) (toString decl));
in { url = "https://github.com/NixOS/nixpkgs/blob/master/${subpath}"; name = subpath; }
else decl)
opt.declarations;
};
};
in pkgs.runCommand "doc-support" {}
''
mkdir result
(
cd result
ln -s ${locationsXml} ./function-locations.xml
ln -s ${functionDocs} ./function-docs
ln -s ${optionsDoc.optionsDocBook} ./config-options.docbook.xml
ln -s ${pkgs.docbook5}/xml/rng/docbook/docbook.rng ./docbook.rng
ln -s ${pkgs.docbook_xsl_ns}/xml/xsl ./xsl
ln -s ${epub-xsl} ./epub.xsl
ln -s ${xhtml-xsl} ./xhtml.xsl
ln -s ${../../nixos/doc/xmlformat.conf} ./xmlformat.conf
ln -s ${pkgs.documentation-highlighter} ./highlightjs
echo -n "${version}" > ./version
)
mv result $out
''

View File

@@ -1,27 +0,0 @@
# Generates the documentation for library functons via nixdoc. To add
# another library function file to this list, the include list in the
# file `doc/functions/library.xml` must also be updated.
{ pkgs ? import ./.. {}, locationsXml }:
with pkgs; stdenv.mkDerivation {
name = "nixpkgs-lib-docs";
src = ./../../lib;
buildInputs = [ nixdoc ];
installPhase = ''
function docgen {
nixdoc -c "$1" -d "$2" -f "../lib/$1.nix" > "$out/$1.xml"
}
mkdir -p $out
ln -s ${locationsXml} $out/locations.xml
docgen strings 'String manipulation functions'
docgen trivial 'Miscellaneous functions'
docgen lists 'List manipulation functions'
docgen debug 'Debugging functions'
docgen options 'NixOS / nixpkgs option handling'
docgen sources 'Source filtering functions'
'';
}

View File

@@ -1,85 +0,0 @@
{ pkgs ? (import ./.. { }), nixpkgs ? { }}:
let
revision = pkgs.lib.trivial.revisionWithDefault (nixpkgs.revision or "master");
libDefPos = set:
builtins.map
(name: {
name = name;
location = builtins.unsafeGetAttrPos name set;
})
(builtins.attrNames set);
libset = toplib:
builtins.map
(subsetname: {
subsetname = subsetname;
functions = libDefPos toplib.${subsetname};
})
(builtins.filter
(name: builtins.isAttrs toplib.${name})
(builtins.attrNames toplib));
nixpkgsLib = pkgs.lib;
flattenedLibSubset = { subsetname, functions }:
builtins.map
(fn: {
name = "lib.${subsetname}.${fn.name}";
value = fn.location;
})
functions;
locatedlibsets = libs: builtins.map flattenedLibSubset (libset libs);
removeFilenamePrefix = prefix: filename:
let
prefixLen = (builtins.stringLength prefix) + 1; # +1 to remove the leading /
filenameLen = builtins.stringLength filename;
substr = builtins.substring prefixLen filenameLen filename;
in substr;
removeNixpkgs = removeFilenamePrefix (builtins.toString pkgs.path);
liblocations =
builtins.filter
(elem: elem.value != null)
(nixpkgsLib.lists.flatten
(locatedlibsets nixpkgsLib));
fnLocationRelative = { name, value }:
{
inherit name;
value = value // { file = removeNixpkgs value.file; };
};
relativeLocs = (builtins.map fnLocationRelative liblocations);
sanitizeId = builtins.replaceStrings
[ "'" ]
[ "-prime" ];
urlPrefix = "https://github.com/NixOS/nixpkgs/blob/${revision}";
xmlstrings = (nixpkgsLib.strings.concatMapStrings
({ name, value }:
''
<section><title>${name}</title>
<para xml:id="${sanitizeId name}">
Located at
<link
xlink:href="${urlPrefix}/${value.file}#L${builtins.toString value.line}">${value.file}:${builtins.toString value.line}</link>
in <literal>&lt;nixpkgs&gt;</literal>.
</para>
</section>
'')
relativeLocs);
in pkgs.writeText
"locations.xml"
''
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
version="5">
<title>All the locations for every lib function</title>
<para>This file is only for inclusion by other files.</para>
${xmlstrings}
</section>
''

View File

@@ -1,15 +0,0 @@
<?xml version='1.0'?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:param name="section.autolabel" select="1" />
<xsl:param name="section.label.includes.component.label" select="1" />
<xsl:param name="html.stylesheet" select="'style.css overrides.css highlightjs/mono-blue.css'" />
<xsl:param name="html.script" select="'./highlightjs/highlight.pack.js ./highlightjs/loader.js'" />
<xsl:param name="xref.with.number.and.title" select="1" />
<xsl:param name="use.id.as.filename" select="1" />
<xsl:param name="toc.section.depth" select="0" />
<xsl:param name="admon.style" select="''" />
<xsl:param name="callout.graphics.extension" select="'.svg'" />
<xsl:param name="generate.consistent.ids" select="1" />
</xsl:stylesheet>

View File

@@ -1,14 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="chap-functions">
<title>Functions reference</title>
<para>
The nixpkgs repository has several utility functions to manipulate Nix expressions.
</para>
<xi:include href="functions/library.xml" />
<xi:include href="functions/generators.section.xml" />
<xi:include href="functions/debug.section.xml" />
<xi:include href="functions/prefer-remote-fetch.section.xml" />
<xi:include href="functions/nix-gitignore.section.xml" />
</chapter>

View File

@@ -1,5 +0,0 @@
# Debugging Nix Expressions {#sec-debug}
Nix is a unityped, dynamic language, this means every value can potentially appear anywhere. Since it is also non-strict, evaluation order and what ultimately is evaluated might surprise you. Therefore it is important to be able to debug nix expressions.
In the `lib/debug.nix` file you will find a number of functions that help (pretty-)printing values while evaluation is running. You can even specify how deep these values should be printed recursively, and transform them on the fly. Please consult the docstrings in `lib/debug.nix` for usage information.

View File

@@ -1,56 +0,0 @@
# Generators {#sec-generators}
Generators are functions that create file formats from nix data structures, e.g. for configuration files. There are generators available for: `INI`, `JSON` and `YAML`
All generators follow a similar call interface: `generatorName configFunctions data`, where `configFunctions` is an attrset of user-defined functions that format nested parts of the content. They each have common defaults, so often they do not need to be set manually. An example is `mkSectionName ? (name: libStr.escape [ "[" "]" ] name)` from the `INI` generator. It receives the name of a section and sanitizes it. The default `mkSectionName` escapes `[` and `]` with a backslash.
Generators can be fine-tuned to produce exactly the file format required by your application/service. One example is an INI-file format which uses `: ` as separator, the strings `"yes"`/`"no"` as boolean values and requires all string values to be quoted:
```nix
with lib;
let
customToINI = generators.toINI {
# specifies how to format a key/value pair
mkKeyValue = generators.mkKeyValueDefault {
# specifies the generated string for a subset of nix values
mkValueString = v:
if v == true then ''"yes"''
else if v == false then ''"no"''
else if isString v then ''"${v}"''
# and delegats all other values to the default generator
else generators.mkValueStringDefault {} v;
} ":";
};
# the INI file can now be given as plain old nix values
in customToINI {
main = {
pushinfo = true;
autopush = false;
host = "localhost";
port = 42;
};
mergetool = {
merge = "diff3";
};
}
```
This will produce the following INI file as nix string:
```INI
[main]
autopush:"no"
host:"localhost"
port:42
pushinfo:"yes"
str\:ange:"very::strange"
[mergetool]
merge:"diff3"
```
::: {.note}
Nix store paths can be converted to strings by enclosing a derivation attribute like so: `"${drv}"`.
:::
Detailed documentation for each generator can be found in `lib/generators.nix`.

View File

@@ -1,30 +0,0 @@
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="sec-functions-library">
<title>Nixpkgs Library Functions</title>
<para>
Nixpkgs provides a standard library at <varname>pkgs.lib</varname>, or through <code>import &lt;nixpkgs/lib&gt;</code>.
</para>
<xi:include href="./library/asserts.xml" />
<xi:include href="./library/attrsets.xml" />
<!-- These docs are generated via nixdoc. To add another generated
library function file to this list, the file
`lib-function-docs.nix` must also be updated. -->
<xi:include href="./library/generated/strings.xml" />
<xi:include href="./library/generated/trivial.xml" />
<xi:include href="./library/generated/lists.xml" />
<xi:include href="./library/generated/debug.xml" />
<xi:include href="./library/generated/options.xml" />
<xi:include href="./library/generated/sources.xml" />
</section>

View File

@@ -1,112 +0,0 @@
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="sec-functions-library-asserts">
<title>Assert functions</title>
<section xml:id="function-library-lib.asserts.assertMsg">
<title><function>lib.asserts.assertMsg</function></title>
<subtitle><literal>assertMsg :: Bool -> String -> Bool</literal>
</subtitle>
<xi:include href="./locations.xml" xpointer="lib.asserts.assertMsg" />
<para>
Print a trace message if <literal>pred</literal> is false.
</para>
<para>
Intended to be used to augment asserts with helpful error messages.
</para>
<variablelist>
<varlistentry>
<term>
<varname>pred</varname>
</term>
<listitem>
<para>
Condition under which the <varname>msg</varname> should <emphasis>not</emphasis> be printed.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<varname>msg</varname>
</term>
<listitem>
<para>
Message to print.
</para>
</listitem>
</varlistentry>
</variablelist>
<example xml:id="function-library-lib.asserts.assertMsg-example-false">
<title>Printing when the predicate is false</title>
<programlisting><![CDATA[
assert lib.asserts.assertMsg ("foo" == "bar") "foo is not bar, silly"
stderr> trace: foo is not bar, silly
stderr> assert failed
]]></programlisting>
</example>
</section>
<section xml:id="function-library-lib.asserts.assertOneOf">
<title><function>lib.asserts.assertOneOf</function></title>
<subtitle><literal>assertOneOf :: String -> String ->
StringList -> Bool</literal>
</subtitle>
<xi:include href="./locations.xml" xpointer="lib.asserts.assertOneOf" />
<para>
Specialized <function>asserts.assertMsg</function> for checking if <varname>val</varname> is one of the elements of <varname>xs</varname>. Useful for checking enums.
</para>
<variablelist>
<varlistentry>
<term>
<varname>name</varname>
</term>
<listitem>
<para>
The name of the variable the user entered <varname>val</varname> into, for inclusion in the error message.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<varname>val</varname>
</term>
<listitem>
<para>
The value of what the user provided, to be compared against the values in <varname>xs</varname>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<varname>xs</varname>
</term>
<listitem>
<para>
The list of valid values.
</para>
</listitem>
</varlistentry>
</variablelist>
<example xml:id="function-library-lib.asserts.assertOneOf-example">
<title>Ensuring a user provided a possible value</title>
<programlisting><![CDATA[
let sslLibrary = "bearssl";
in lib.asserts.assertOneOf "sslLibrary" sslLibrary [ "openssl" "libressl" ];
=> false
stderr> trace: sslLibrary must be one of "openssl", "libressl", but is: "bearssl"
]]></programlisting>
</example>
</section>
</section>

File diff suppressed because it is too large Load Diff

View File

@@ -1,49 +0,0 @@
# pkgs.nix-gitignore {#sec-pkgs-nix-gitignore}
`pkgs.nix-gitignore` is a function that acts similarly to `builtins.filterSource` but also allows filtering with the help of the gitignore format.
## Usage {#sec-pkgs-nix-gitignore-usage}
`pkgs.nix-gitignore` exports a number of functions, but you\'ll most likely need either `gitignoreSource` or `gitignoreSourcePure`. As their first argument, they both accept either 1. a file with gitignore lines or 2. a string with gitignore lines, or 3. a list of either of the two. They will be concatenated into a single big string.
```nix
{ pkgs ? import <nixpkgs> {} }:
nix-gitignore.gitignoreSource [] ./source
# Simplest version
nix-gitignore.gitignoreSource "supplemental-ignores\n" ./source
# This one reads the ./source/.gitignore and concats the auxiliary ignores
nix-gitignore.gitignoreSourcePure "ignore-this\nignore-that\n" ./source
# Use this string as gitignore, don't read ./source/.gitignore.
nix-gitignore.gitignoreSourcePure ["ignore-this\nignore-that\n", ~/.gitignore] ./source
# It also accepts a list (of strings and paths) that will be concatenated
# once the paths are turned to strings via readFile.
```
These functions are derived from the `Filter` functions by setting the first filter argument to `(_: _: true)`:
```nix
gitignoreSourcePure = gitignoreFilterSourcePure (_: _: true);
gitignoreSource = gitignoreFilterSource (_: _: true);
```
Those filter functions accept the same arguments the `builtins.filterSource` function would pass to its filters, thus `fn: gitignoreFilterSourcePure fn ""` should be extensionally equivalent to `filterSource`. The file is blacklisted if it\'s blacklisted by either your filter or the gitignoreFilter.
If you want to make your own filter from scratch, you may use
```nix
gitignoreFilter = ign: root: filterPattern (gitignoreToPatterns ign) root;
```
## gitignore files in subdirectories {#sec-pkgs-nix-gitignore-usage-recursive}
If you wish to use a filter that would search for .gitignore files in subdirectories, just like git does by default, use this function:
```nix
gitignoreFilterRecursiveSource = filter: patterns: root:
# OR
gitignoreRecursiveSource = gitignoreFilterSourcePure (_: _: true);
```

View File

@@ -1,17 +0,0 @@
# prefer-remote-fetch overlay {#sec-prefer-remote-fetch}
`prefer-remote-fetch` is an overlay that download sources on remote builder. This is useful when the evaluating machine has a slow upload while the builder can fetch faster directly from the source. To use it, put the following snippet as a new overlay:
```nix
self: super:
(super.prefer-remote-fetch self super)
```
A full configuration example for that sets the overlay up for your own account, could look like this
```ShellSession
$ mkdir ~/.config/nixpkgs/overlays/
$ cat > ~/.config/nixpkgs/overlays/prefer-remote-fetch.nix <<EOF
self: super: super.prefer-remote-fetch self super
EOF
```

View File

@@ -1,10 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="chap-hooks">
<title>Hooks reference</title>
<para>
Nixpkgs has several hook packages that augment the stdenv phases.
</para>
<xi:include href="./postgresql-test-hook.section.xml" />
</chapter>

View File

@@ -1,59 +0,0 @@
# `postgresqlTestHook` {#sec-postgresqlTestHook}
This hook starts a PostgreSQL server during the `checkPhase`. Example:
```nix
{ stdenv, postgresql, postgresqlTestHook }:
stdenv.mkDerivation {
# ...
checkInputs = [
postgresql
postgresqlTestHook
];
}
```
If you use a custom `checkPhase`, remember to add the `runHook` calls:
```nix
checkPhase ''
runHook preCheck
# ... your tests
runHook postCheck
''
```
## Variables {#sec-postgresqlTestHook-variables}
The hook logic will read a number of variables and set them to a default value if unset or empty.
Exported variables:
- `PGDATA`: location of server files.
- `PGHOST`: location of UNIX domain socket directory; the default `host` in a connection string.
- `PGUSER`: user to create / log in with, default: `test_user`.
- `PGDATABASE`: database name, default: `test_db`.
Bash-only variables:
- `postgresqlTestUserOptions`: SQL options to use when creating the `$PGUSER` role, default: `LOGIN`.
- `postgresqlTestSetupSQL`: SQL commands to run as database administrator after startup, default: statements that create `$PGUSER` and `$PGDATABASE`.
- `postgresqlTestSetupCommands`: bash commands to run after database start, defaults to running `$postgresqlTestSetupSQL` as database administrator.
- `postgresqlEnableTCP`: set to `1` to enable TCP listening. Flaky; not recommended.
- `postgresqlStartCommands`: defaults to `pg_ctl start`.
## TCP and the Nix sandbox {#sec-postgresqlTestHook-tcp}
`postgresqlEnableTCP` relies on network sandboxing, which is not available on macOS and some custom Nix installations, resulting in flaky tests.
For this reason, it is disabled by default.
The preferred solution is to make the test suite use a UNIX domain socket connection. This is the default behavior when no `host` connection parameter is provided.
Some test suites hardcode a value for `host` though, so a patch may be required. If you can upstream the patch, you can make `host` default to the `PGHOST` environment variable when set. Otherwise, you can patch it locally to omit the `host` connection string parameter altogether.
::: {.note}
The error `libpq: failed (could not receive data from server: Connection refused` is generally an indication that the test suite is trying to connect through TCP.
:::

21
doc/introduction.xml Normal file
View File

@@ -0,0 +1,21 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-introduction">
<title>Introduction</title>
<para>This manual tells you how to write packages for the Nix Packages
collection (Nixpkgs). Thus its for packagers and developers who want
to add packages to Nixpkgs. End users are kindly referred to the
<link xlink:href="http://hydra.nixos.org/job/nix/trunk/tarball/latest/download-by-type/doc/manual">Nix
manual</link>.</para>
<para>This manual does not describe the syntax and semantics of the
Nix expression language, which are given in the Nix manual in the
<link
xlink:href="http://hydra.nixos.org/job/nix/trunk/tarball/latest/download-by-type/doc/manual/#chap-writing-nix-expressions">chapter
on writing Nix expressions</link>. It only describes the facilities
provided by Nixpkgs to make writing packages easier, such as the
standard build environment (<literal>stdenv</literal>).</para>
</chapter>

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