Merge remote-tracking branch 'origin/master' into haskell-updates
This commit is contained in:
commit
f75fe9394f
4
.github/workflows/merge-staging.yml
vendored
4
.github/workflows/merge-staging.yml
vendored
|
@ -14,6 +14,7 @@ jobs:
|
|||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Merge master into staging-next
|
||||
id: staging_next
|
||||
uses: devmasx/merge-branch@v1.3.1
|
||||
with:
|
||||
type: now
|
||||
|
@ -22,6 +23,7 @@ jobs:
|
|||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Merge staging-next into staging
|
||||
id: staging
|
||||
uses: devmasx/merge-branch@v1.3.1
|
||||
with:
|
||||
type: now
|
||||
|
@ -35,5 +37,5 @@ jobs:
|
|||
with:
|
||||
issue-number: 105153
|
||||
body: |
|
||||
An automatic merge [failed](https://github.com/NixOS/nixpkgs/actions/runs/${{ github.run_id }}).
|
||||
An automatic merge${{ (steps.staging_next.outcome == 'failure' && ' from master to staging-next') || ((steps.staging.outcome == 'failure' && ' from staging-next to staging') || '') }} [failed](https://github.com/NixOS/nixpkgs/actions/runs/${{ github.run_id }}).
|
||||
|
||||
|
|
|
@ -1,15 +1,17 @@
|
|||
# pkgs.mkShell {#sec-pkgs-mkShell}
|
||||
|
||||
`pkgs.mkShell` is a special kind of derivation that is only useful when using it combined with `nix-shell`. It will in fact fail to instantiate when invoked with `nix-build`.
|
||||
`pkgs.mkShell` is a special kind of derivation that is only useful when using
|
||||
it combined with `nix-shell`. It will in fact fail to instantiate when invoked
|
||||
with `nix-build`.
|
||||
|
||||
## Usage {#sec-pkgs-mkShell-usage}
|
||||
|
||||
```nix
|
||||
{ pkgs ? import <nixpkgs> {} }:
|
||||
pkgs.mkShell {
|
||||
# this will make all the build inputs from hello and gnutar
|
||||
# available to the shell environment
|
||||
# specify which packages to add to the shell environment
|
||||
packages = [ pkgs.gnumake ];
|
||||
# add all the dependencies, of the given packages, to the shell environment
|
||||
inputsFrom = with pkgs; [ hello gnutar ];
|
||||
buildInputs = [ pkgs.gnumake ];
|
||||
}
|
||||
```
|
||||
|
|
432
doc/languages-frameworks/dhall.section.md
Normal file
432
doc/languages-frameworks/dhall.section.md
Normal file
|
@ -0,0 +1,432 @@
|
|||
# Dhall {#sec-language-dhall}
|
||||
|
||||
The Nixpkgs support for Dhall assumes some familiarity with Dhall's language
|
||||
support for importing Dhall expressions, which is documented here:
|
||||
|
||||
* [`dhall-lang.org` - Installing packages](https://docs.dhall-lang.org/tutorials/Language-Tour.html#installing-packages)
|
||||
|
||||
## Remote imports
|
||||
|
||||
Nixpkgs bypasses Dhall's support for remote imports using Dhall's
|
||||
semantic integrity checks. Specifically, any Dhall import can be protected by
|
||||
an integrity check like:
|
||||
|
||||
```dhall
|
||||
https://prelude.dhall-lang.org/v20.1.0/package.dhall
|
||||
sha256:26b0ef498663d269e4dc6a82b0ee289ec565d683ef4c00d0ebdd25333a5a3c98
|
||||
```
|
||||
|
||||
… and if the import is cached then the interpreter will load the import from
|
||||
cache instead of fetching the URL.
|
||||
|
||||
Nixpkgs uses this trick to add all of a Dhall expression's dependencies into the
|
||||
cache so that the Dhall interpreter never needs to resolve any remote URLs. In
|
||||
fact, Nixpkgs uses a Dhall interpreter with remote imports disabled when
|
||||
packaging Dhall expressions to enforce that the interpreter never resolves a
|
||||
remote import. This means that Nixpkgs only supports building Dhall expressions
|
||||
if all of their remote imports are protected by semantic integrity checks.
|
||||
|
||||
Instead of remote imports, Nixpkgs uses Nix to fetch remote Dhall code. For
|
||||
example, the Prelude Dhall package uses `pkgs.fetchFromGitHub` to fetch the
|
||||
`dhall-lang` repository containing the Prelude. Relying exclusively on Nix
|
||||
to fetch Dhall code ensures that Dhall packages built using Nix remain pure and
|
||||
also behave well when built within a sandbox.
|
||||
|
||||
## Packaging a Dhall expression from scratch
|
||||
|
||||
We can illustrate how Nixpkgs integrates Dhall by beginning from the following
|
||||
trivial Dhall expression with one dependency (the Prelude):
|
||||
|
||||
```dhall
|
||||
-- ./true.dhall
|
||||
|
||||
let Prelude = https://prelude.dhall-lang.org/v20.1.0/package.dhall
|
||||
|
||||
in Prelude.Bool.not False
|
||||
```
|
||||
|
||||
As written, this expression cannot be built using Nixpkgs because the
|
||||
expression does not protect the Prelude import with a semantic integrity
|
||||
check, so the first step is to freeze the expression using `dhall freeze`,
|
||||
like this:
|
||||
|
||||
```bash
|
||||
$ dhall freeze --inplace ./true.dhall
|
||||
```
|
||||
|
||||
… which gives us:
|
||||
|
||||
```dhall
|
||||
-- ./true.dhall
|
||||
|
||||
let Prelude =
|
||||
https://prelude.dhall-lang.org/v20.1.0/package.dhall
|
||||
sha256:26b0ef498663d269e4dc6a82b0ee289ec565d683ef4c00d0ebdd25333a5a3c98
|
||||
|
||||
in Prelude.Bool.not False
|
||||
```
|
||||
|
||||
To package that expression, we create a `./true.nix` file containing the
|
||||
following specification for the Dhall package:
|
||||
|
||||
```nix
|
||||
# ./true.nix
|
||||
|
||||
{ buildDhallPackage, Prelude }:
|
||||
|
||||
buildDhallPackage {
|
||||
name = "true";
|
||||
code = ./true.dhall;
|
||||
dependencies = [ Prelude ];
|
||||
source = true;
|
||||
}
|
||||
```
|
||||
|
||||
… and we complete the build by incorporating that Dhall package into the
|
||||
`pkgs.dhallPackages` hierarchy using an overlay, like this:
|
||||
|
||||
```nix
|
||||
# ./example.nix
|
||||
|
||||
let
|
||||
nixpkgs = builtins.fetchTarball {
|
||||
url = "https://github.com/NixOS/nixpkgs/archive/94b2848559b12a8ed1fe433084686b2a81123c99.tar.gz";
|
||||
sha256 = "1pbl4c2dsaz2lximgd31m96jwbps6apn3anx8cvvhk1gl9rkg107";
|
||||
};
|
||||
|
||||
dhallOverlay = self: super: {
|
||||
true = self.callPackage ./true.nix { };
|
||||
};
|
||||
|
||||
overlay = self: super: {
|
||||
dhallPackages = super.dhallPackages.override (old: {
|
||||
overrides =
|
||||
self.lib.composeExtensions (old.overrides or (_: _: {})) dhallOverlay;
|
||||
});
|
||||
};
|
||||
|
||||
pkgs = import nixpkgs { config = {}; overlays = [ overlay ]; };
|
||||
|
||||
in
|
||||
pkgs
|
||||
```
|
||||
|
||||
… which we can then build using this command:
|
||||
|
||||
```bash
|
||||
$ nix build --file ./example.nix dhallPackages.true
|
||||
```
|
||||
|
||||
## Contents of a Dhall package
|
||||
|
||||
The above package produces the following directory tree:
|
||||
|
||||
```bash
|
||||
$ tree -a ./result
|
||||
result
|
||||
├── .cache
|
||||
│ └── dhall
|
||||
│ └── 122027abdeddfe8503496adeb623466caa47da5f63abd2bc6fa19f6cfcb73ecfed70
|
||||
├── binary.dhall
|
||||
└── source.dhall
|
||||
```
|
||||
|
||||
… where:
|
||||
|
||||
* `source.dhall` contains the result of interpreting our Dhall package:
|
||||
|
||||
```bash
|
||||
$ cat ./result/source.dhall
|
||||
True
|
||||
```
|
||||
|
||||
* The `.cache` subdirectory contains one binary cache product encoding the
|
||||
same result as `source.dhall`:
|
||||
|
||||
```bash
|
||||
$ dhall decode < ./result/.cache/dhall/122027abdeddfe8503496adeb623466caa47da5f63abd2bc6fa19f6cfcb73ecfed70
|
||||
True
|
||||
```
|
||||
|
||||
* `binary.dhall` contains a Dhall expression which handles fetching and decoding
|
||||
the same cache product:
|
||||
|
||||
```bash
|
||||
$ cat ./result/binary.dhall
|
||||
missing sha256:27abdeddfe8503496adeb623466caa47da5f63abd2bc6fa19f6cfcb73ecfed70
|
||||
$ cp -r ./result/.cache .cache
|
||||
|
||||
$ chmod -R u+w .cache
|
||||
|
||||
$ XDG_CACHE_HOME=.cache dhall --file ./result/binary.dhall
|
||||
True
|
||||
```
|
||||
|
||||
The `source.dhall` file is only present for packages that specify
|
||||
`source = true;`. By default, Dhall packages omit the `source.dhall` in order
|
||||
to conserve disk space when they are used exclusively as dependencies. For
|
||||
example, if we build the Prelude package it will only contain the binary
|
||||
encoding of the expression:
|
||||
|
||||
```bash
|
||||
$ nix build --file ./example.nix dhallPackages.Prelude
|
||||
|
||||
$ tree -a result
|
||||
result
|
||||
├── .cache
|
||||
│ └── dhall
|
||||
│ └── 122026b0ef498663d269e4dc6a82b0ee289ec565d683ef4c00d0ebdd25333a5a3c98
|
||||
└── binary.dhall
|
||||
|
||||
2 directories, 2 files
|
||||
```
|
||||
|
||||
Typically, you only specify `source = true;` for the top-level Dhall expression
|
||||
of interest (such as our example `true.nix` Dhall package). However, if you
|
||||
wish to specify `source = true` for all Dhall packages, then you can amend the
|
||||
Dhall overlay like this:
|
||||
|
||||
```nix
|
||||
dhallOverrides = self: super: {
|
||||
# Enable source for all Dhall packages
|
||||
buildDhallPackage =
|
||||
args: super.buildDhallPackage (args // { source = true; });
|
||||
|
||||
true = self.callPackage ./true.nix { };
|
||||
};
|
||||
```
|
||||
|
||||
… and now the Prelude will contain the fully decoded result of interpreting
|
||||
the Prelude:
|
||||
|
||||
```bash
|
||||
$ nix build --file ./example.nix dhallPackages.Prelude
|
||||
|
||||
$ tree -a result
|
||||
result
|
||||
├── .cache
|
||||
│ └── dhall
|
||||
│ └── 122026b0ef498663d269e4dc6a82b0ee289ec565d683ef4c00d0ebdd25333a5a3c98
|
||||
├── binary.dhall
|
||||
└── source.dhall
|
||||
|
||||
$ cat ./result/source.dhall
|
||||
{ Bool =
|
||||
{ and =
|
||||
\(_ : List Bool) ->
|
||||
List/fold Bool _ Bool (\(_ : Bool) -> \(_ : Bool) -> _@1 && _) True
|
||||
, build = \(_ : Type -> _ -> _@1 -> _@2) -> _ Bool True False
|
||||
, even =
|
||||
\(_ : List Bool) ->
|
||||
List/fold Bool _ Bool (\(_ : Bool) -> \(_ : Bool) -> _@1 == _) True
|
||||
, fold =
|
||||
\(_ : Bool) ->
|
||||
…
|
||||
```
|
||||
|
||||
## Packaging functions
|
||||
|
||||
We already saw an example of using `buildDhallPackage` to create a Dhall
|
||||
package from a single file, but most Dhall packages consist of more than one
|
||||
file and there are two derived utilities that you may find more useful when
|
||||
packaging multiple files:
|
||||
|
||||
* `buildDhallDirectoryPackage` - build a Dhall package from a local directory
|
||||
|
||||
* `buildDhallGitHubPackage` - build a Dhall package from a GitHub repository
|
||||
|
||||
The `buildDhallPackage` is the lowest-level function and accepts the following
|
||||
arguments:
|
||||
|
||||
* `name`: The name of the derivation
|
||||
|
||||
* `dependencies`: Dhall dependencies to build and cache ahead of time
|
||||
|
||||
* `code`: The top-level expression to build for this package
|
||||
|
||||
Note that the `code` field accepts an arbitrary Dhall expression. You're
|
||||
not limited to just a file.
|
||||
|
||||
* `source`: Set to `true` to include the decoded result as `source.dhall` in the
|
||||
build product, at the expense of requiring more disk space
|
||||
|
||||
* `documentationRoot`: Set to the root directory of the package if you want
|
||||
`dhall-docs` to generate documentation underneath the `docs` subdirectory of
|
||||
the build product
|
||||
|
||||
The `buildDhallDirectoryPackage` is a higher-level function implemented in terms
|
||||
of `buildDhallPackage` that accepts the following arguments:
|
||||
|
||||
* `name`: Same as `buildDhallPackage`
|
||||
|
||||
* `dependencies`: Same as `buildDhallPackage`
|
||||
|
||||
* `source`: Same as `buildDhallPackage`
|
||||
|
||||
* `src`: The directory containing Dhall code that you want to turn into a Dhall
|
||||
package
|
||||
|
||||
* `file`: The top-level file (`package.dhall` by default) that is the entrypoint
|
||||
to the rest of the package
|
||||
|
||||
* `document`: Set to `true` to generate documentation for the package
|
||||
|
||||
The `buildDhallGitHubPackage` is another higher-level function implemented in
|
||||
terms of `buildDhallPackage` that accepts the following arguments:
|
||||
|
||||
* `name`: Same as `buildDhallPackage`
|
||||
|
||||
* `dependencies`: Same as `buildDhallPackage`
|
||||
|
||||
* `source`: Same as `buildDhallPackage`
|
||||
|
||||
* `owner`: The owner of the repository
|
||||
|
||||
* `repo`: The repository name
|
||||
|
||||
* `rev`: The desired revision (or branch, or tag)
|
||||
|
||||
* `directory`: The subdirectory of the Git repository to package (if a
|
||||
directory other than the root of the repository)
|
||||
|
||||
* `file`: The top-level file (`${directory}/package.dhall` by default) that is
|
||||
the entrypoint to the rest of the package
|
||||
|
||||
* `document`: Set to `true` to generate documentation for the package
|
||||
|
||||
Additionally, `buildDhallGitHubPackage` accepts the same arguments as
|
||||
`fetchFromGitHub`, such as `sha256` or `fetchSubmodules`.
|
||||
|
||||
## `dhall-to-nixpkgs`
|
||||
|
||||
You can use the `dhall-to-nixpkgs` command-line utility to automate
|
||||
packaging Dhall code. For example:
|
||||
|
||||
```bash
|
||||
$ nix-env --install --attr haskellPackages.dhall-nixpkgs
|
||||
|
||||
$ nix-env --install --attr nix-prefetch-git # Used by dhall-to-nixpkgs
|
||||
|
||||
$ dhall-to-nixpkgs github https://github.com/Gabriel439/dhall-semver.git
|
||||
{ buildDhallGitHubPackage, Prelude }:
|
||||
buildDhallGitHubPackage {
|
||||
name = "dhall-semver";
|
||||
githubBase = "github.com";
|
||||
owner = "Gabriel439";
|
||||
repo = "dhall-semver";
|
||||
rev = "2d44ae605302ce5dc6c657a1216887fbb96392a4";
|
||||
fetchSubmodules = false;
|
||||
sha256 = "0y8shvp8srzbjjpmnsvz9c12ciihnx1szs0yzyi9ashmrjvd0jcz";
|
||||
directory = "";
|
||||
file = "package.dhall";
|
||||
source = false;
|
||||
document = false;
|
||||
dependencies = [ (Prelude.overridePackage { file = "package.dhall"; }) ];
|
||||
}
|
||||
```
|
||||
|
||||
The utility takes care of automatically detecting remote imports and converting
|
||||
them to package dependencies. You can also use the utility on local
|
||||
Dhall directories, too:
|
||||
|
||||
```bash
|
||||
$ dhall-to-nixpkgs directory ~/proj/dhall-semver
|
||||
{ buildDhallDirectoryPackage, Prelude }:
|
||||
buildDhallDirectoryPackage {
|
||||
name = "proj";
|
||||
src = /Users/gabriel/proj/dhall-semver;
|
||||
file = "package.dhall";
|
||||
source = false;
|
||||
document = false;
|
||||
dependencies = [ (Prelude.overridePackage { file = "package.dhall"; }) ];
|
||||
}
|
||||
```
|
||||
|
||||
## Overriding dependency versions
|
||||
|
||||
Suppose that we change our `true.dhall` example expression to depend on an older
|
||||
version of the Prelude (19.0.0):
|
||||
|
||||
```dhall
|
||||
-- ./true.dhall
|
||||
|
||||
let Prelude =
|
||||
https://prelude.dhall-lang.org/v19.0.0/package.dhall
|
||||
sha256:eb693342eb769f782174157eba9b5924cf8ac6793897fc36a31ccbd6f56dafe2
|
||||
|
||||
in Prelude.Bool.not False
|
||||
```
|
||||
|
||||
If we try to rebuild that expression the build will fail:
|
||||
|
||||
```
|
||||
$ nix build --file ./example.nix dhallPackages.true
|
||||
builder for '/nix/store/0f1hla7ff1wiaqyk1r2ky4wnhnw114fi-true.drv' failed with exit code 1; last 10 log lines:
|
||||
|
||||
Dhall was compiled without the 'with-http' flag.
|
||||
|
||||
The requested URL was: https://prelude.dhall-lang.org/v19.0.0/package.dhall
|
||||
|
||||
|
||||
4│ https://prelude.dhall-lang.org/v19.0.0/package.dhall
|
||||
5│ sha256:eb693342eb769f782174157eba9b5924cf8ac6793897fc36a31ccbd6f56dafe2
|
||||
|
||||
/nix/store/rsab4y99h14912h4zplqx2iizr5n4rc2-true.dhall:4:7
|
||||
[1 built (1 failed), 0.0 MiB DL]
|
||||
error: build of '/nix/store/0f1hla7ff1wiaqyk1r2ky4wnhnw114fi-true.drv' failed
|
||||
```
|
||||
|
||||
… because the default Prelude selected by Nixpkgs revision
|
||||
`94b2848559b12a8ed1fe433084686b2a81123c99is` is version 20.1.0, which doesn't
|
||||
have the same integrity check as version 19.0.0. This means that version
|
||||
19.0.0 is not cached and the interpreter is not allowed to fall back to
|
||||
importing the URL.
|
||||
|
||||
However, we can override the default Prelude version by using `dhall-to-nixpkgs`
|
||||
to create a Dhall package for our desired Prelude:
|
||||
|
||||
```bash
|
||||
$ dhall-to-nixpkgs github https://github.com/dhall-lang/dhall-lang.git \
|
||||
--name Prelude \
|
||||
--directory Prelude \
|
||||
--rev v19.0.0 \
|
||||
> Prelude.nix
|
||||
```
|
||||
|
||||
… and then referencing that package in our Dhall overlay, by either overriding
|
||||
the Prelude globally for all packages, like this:
|
||||
|
||||
```bash
|
||||
dhallOverrides = self: super: {
|
||||
true = self.callPackage ./true.nix { };
|
||||
|
||||
Prelude = self.callPackage ./Prelude.nix { };
|
||||
};
|
||||
```
|
||||
|
||||
… or selectively overriding the Prelude dependency for just the `true` package,
|
||||
like this:
|
||||
|
||||
```bash
|
||||
dhallOverrides = self: super: {
|
||||
true = self.callPackage ./true.nix {
|
||||
Prelude = self.callPackage ./Prelude.nix { };
|
||||
};
|
||||
};
|
||||
```
|
||||
|
||||
## Overrides
|
||||
|
||||
You can override any of the arguments to `buildDhallGitHubPackage` or
|
||||
`buildDhallDirectoryPackage` using the `overridePackage` attribute of a package.
|
||||
For example, suppose we wanted to selectively enable `source = true` just for the Prelude. We can do that like this:
|
||||
|
||||
```nix
|
||||
dhallOverrides = self: super: {
|
||||
Prelude = super.Prelude.overridePackage { source = true; };
|
||||
|
||||
…
|
||||
};
|
||||
```
|
||||
|
||||
[semantic-integrity-checks]: https://docs.dhall-lang.org/tutorials/Language-Tour.html#installing-packages
|
|
@ -10,7 +10,7 @@ with import <nixpkgs> {};
|
|||
|
||||
mkShell {
|
||||
name = "dotnet-env";
|
||||
buildInputs = [
|
||||
packages = [
|
||||
dotnet-sdk_3
|
||||
];
|
||||
}
|
||||
|
@ -25,7 +25,7 @@ with import <nixpkgs> {};
|
|||
|
||||
mkShell {
|
||||
name = "dotnet-env";
|
||||
buildInputs = [
|
||||
packages = [
|
||||
(with dotnetCorePackages; combinePackages [
|
||||
sdk_3_1
|
||||
sdk_3_0
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
<xi:include href="bower.section.xml" />
|
||||
<xi:include href="coq.section.xml" />
|
||||
<xi:include href="crystal.section.xml" />
|
||||
<xi:include href="dhall.section.xml" />
|
||||
<xi:include href="emscripten.section.xml" />
|
||||
<xi:include href="gnome.section.xml" />
|
||||
<xi:include href="go.section.xml" />
|
||||
|
|
|
@ -245,7 +245,7 @@ let
|
|||
ps.toolz
|
||||
]);
|
||||
in mkShell {
|
||||
buildInputs = [
|
||||
packages = [
|
||||
pythonEnv
|
||||
|
||||
black
|
||||
|
|
|
@ -106,7 +106,7 @@ let
|
|||
name = "gems-for-some-project";
|
||||
gemdir = ./.;
|
||||
};
|
||||
in mkShell { buildInputs = [ gems gems.wrappedRuby ]; }
|
||||
in mkShell { packages = [ gems gems.wrappedRuby ]; }
|
||||
```
|
||||
|
||||
With this file in your directory, you can run `nix-shell` to build and use the gems. The important parts here are `bundlerEnv` and `wrappedRuby`.
|
||||
|
|
|
@ -121,15 +121,20 @@ rec {
|
|||
js = { bits = 32; significantByte = littleEndian; family = "js"; };
|
||||
};
|
||||
|
||||
# Determine where two CPUs are compatible with each other. That is,
|
||||
# can we run code built for system b on system a? For that to
|
||||
# happen, then the set of all possible possible programs that system
|
||||
# b accepts must be a subset of the set of all programs that system
|
||||
# a accepts. This compatibility relation forms a category where each
|
||||
# CPU is an object and each arrow from a to b represents
|
||||
# compatibility. CPUs with multiple modes of Endianness are
|
||||
# isomorphic while all CPUs are endomorphic because any program
|
||||
# built for a CPU can run on that CPU.
|
||||
# Determine when two CPUs are compatible with each other. That is,
|
||||
# can code built for system B run on system A? For that to happen,
|
||||
# the programs that system B accepts must be a subset of the
|
||||
# programs that system A accepts.
|
||||
#
|
||||
# We have the following properties of the compatibility relation,
|
||||
# which must be preserved when adding compatibility information for
|
||||
# additional CPUs.
|
||||
# - (reflexivity)
|
||||
# Every CPU is compatible with itself.
|
||||
# - (transitivity)
|
||||
# If A is compatible with B and B is compatible with C then A is compatible with C.
|
||||
# - (compatible under multiple endianness)
|
||||
# CPUs with multiple modes of endianness are pairwise compatible.
|
||||
isCompatible = a: b: with cpuTypes; lib.any lib.id [
|
||||
# x86
|
||||
(b == i386 && isCompatible a i486)
|
||||
|
|
|
@ -2,8 +2,11 @@
|
|||
}:
|
||||
with nixpkgs;
|
||||
mkShell {
|
||||
buildInputs = [
|
||||
bash luarocks-nix nix-prefetch-scripts parallel
|
||||
packages = [
|
||||
bash
|
||||
luarocks-nix
|
||||
nix-prefetch-scripts
|
||||
parallel
|
||||
];
|
||||
LUAROCKS_NIXPKGS_PATH = toString nixpkgs.path;
|
||||
}
|
||||
|
|
|
@ -78,7 +78,7 @@
|
|||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<link xlink:href="https://kodi.tv/">Kodi</link> has been updated to version 19.0 "Matrix". See
|
||||
<link xlink:href="https://kodi.tv/">Kodi</link> has been updated to version 19.1 "Matrix". See
|
||||
the <link xlink:href="https://kodi.tv/article/kodi-190-matrix-release">announcement</link> for
|
||||
further details.
|
||||
</para>
|
||||
|
@ -715,6 +715,20 @@ environment.systemPackages = [
|
|||
The <package>yadm</package> dotfile manager has been updated from 2.x to 3.x, which has new (XDG) default locations for some data/state files. Most yadm commands will fail and print a legacy path warning (which describes how to upgrade/migrate your repository). If you have scripts, daemons, scheduled jobs, shell profiles, etc. that invoke yadm, expect them to fail or misbehave until you perform this migration and prepare accordingly.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
Instead of determining <option>services.radicale.package</option>
|
||||
automatically based on <option>system.stateVersion</option>, the latest
|
||||
version is always used because old versions are not officially supported.
|
||||
</para>
|
||||
<para>
|
||||
Furthermore, Radicale's systemd unit was hardened which might break some
|
||||
deployments. In particular, a non-default
|
||||
<literal>filesystem_folder</literal> has to be added to
|
||||
<option>systemd.services.radicale.serviceConfig.ReadWritePaths</option> if
|
||||
the deprecated <option>services.radicale.config</option> is used.
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
|
||||
|
|
|
@ -4,5 +4,5 @@ in
|
|||
pkgs.mkShell {
|
||||
name = "nixos-manual";
|
||||
|
||||
buildInputs = with pkgs; [ xmlformat jing xmloscopy ruby ];
|
||||
packages = with pkgs; [ xmlformat jing xmloscopy ruby ];
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
x86_64-linux = "/nix/store/iwfs2bfcy7lqwhri94p2i6jc87ih55zk-nix-2.3.10";
|
||||
i686-linux = "/nix/store/a3ccfvy9i5n418d5v0bir330kbcz3vj8-nix-2.3.10";
|
||||
aarch64-linux = "/nix/store/bh5g6cv7bv35iz853d3xv2sphn51ybmb-nix-2.3.10";
|
||||
x86_64-darwin = "/nix/store/8c98r6zlwn2d40qm7jnnrr2rdlqviszr-nix-2.3.10";
|
||||
x86_64-linux = "/nix/store/d1ppfhjhdwcsb4npfzyifv5z8i00fzsk-nix-2.3.11";
|
||||
i686-linux = "/nix/store/c6ikndcrzwpfn2sb5b9xb1f17p9b8iga-nix-2.3.11";
|
||||
aarch64-linux = "/nix/store/fb0lfrn0m8s197d264jzd64vhz9c8zbx-nix-2.3.11";
|
||||
x86_64-darwin = "/nix/store/qvb86ffv08q3r66qbd6nqifz425lyyhf-nix-2.3.11";
|
||||
}
|
||||
|
|
|
@ -37,6 +37,9 @@ in
|
|||
# drives.
|
||||
"uas"
|
||||
|
||||
# SD cards.
|
||||
"sdhci_pci"
|
||||
|
||||
# Firewire support. Not tested.
|
||||
"ohci1394" "sbp2"
|
||||
|
||||
|
|
|
@ -31,6 +31,7 @@ let
|
|||
extraOptions = cfg.extraOptions;
|
||||
withBaseWrapper = cfg.wrapperFeatures.base;
|
||||
withGtkWrapper = cfg.wrapperFeatures.gtk;
|
||||
isNixOS = true;
|
||||
};
|
||||
in {
|
||||
options.programs.sway = {
|
||||
|
@ -38,9 +39,8 @@ in {
|
|||
Sway, the i3-compatible tiling Wayland compositor. You can manually launch
|
||||
Sway by executing "exec sway" on a TTY. Copy /etc/sway/config to
|
||||
~/.config/sway/config to modify the default configuration. See
|
||||
https://github.com/swaywm/sway/wiki and "man 5 sway" for more information.
|
||||
Please have a look at the "extraSessionCommands" example for running
|
||||
programs natively under Wayland'';
|
||||
<link xlink:href="https://github.com/swaywm/sway/wiki" /> and
|
||||
"man 5 sway" for more information'';
|
||||
|
||||
wrapperFeatures = mkOption {
|
||||
type = wrapperOptions;
|
||||
|
@ -55,16 +55,20 @@ in {
|
|||
type = types.lines;
|
||||
default = "";
|
||||
example = ''
|
||||
# SDL:
|
||||
export SDL_VIDEODRIVER=wayland
|
||||
# needs qt5.qtwayland in systemPackages
|
||||
export QT_QPA_PLATFORM=wayland
|
||||
# QT (needs qt5.qtwayland in systemPackages):
|
||||
export QT_QPA_PLATFORM=wayland-egl
|
||||
export QT_WAYLAND_DISABLE_WINDOWDECORATION="1"
|
||||
# Fix for some Java AWT applications (e.g. Android Studio),
|
||||
# use this if they aren't displayed properly:
|
||||
export _JAVA_AWT_WM_NONREPARENTING=1
|
||||
'';
|
||||
description = ''
|
||||
Shell commands executed just before Sway is started.
|
||||
Shell commands executed just before Sway is started. See
|
||||
<link xlink:href="https://github.com/swaywm/sway/wiki/Running-programs-natively-under-wayland" />
|
||||
and <link xlink:href="https://github.com/swaywm/wlroots/blob/master/docs/env_vars.md" />
|
||||
for some useful environment variables.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -94,13 +98,15 @@ in {
|
|||
'';
|
||||
example = literalExample ''
|
||||
with pkgs; [
|
||||
xwayland
|
||||
i3status i3status-rust
|
||||
termite rofi light
|
||||
]
|
||||
'';
|
||||
description = ''
|
||||
Extra packages to be installed system wide.
|
||||
Extra packages to be installed system wide. See
|
||||
<link xlink:href="https://github.com/swaywm/sway/wiki/Useful-add-ons-for-sway" /> and
|
||||
<link xlink:href="https://github.com/swaywm/sway/wiki/i3-Migration-Guide#common-x11-apps-used-on-i3-with-wayland-alternatives" />
|
||||
for a list of useful software.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -120,8 +126,11 @@ in {
|
|||
systemPackages = [ swayPackage ] ++ cfg.extraPackages;
|
||||
etc = {
|
||||
"sway/config".source = mkOptionDefault "${swayPackage}/etc/sway/config";
|
||||
#"sway/security.d".source = mkOptionDefault "${swayPackage}/etc/sway/security.d/";
|
||||
#"sway/config.d".source = mkOptionDefault "${swayPackage}/etc/sway/config.d/";
|
||||
"sway/config.d/nixos.conf".source = pkgs.writeText "nixos.conf" ''
|
||||
# Import the most important environment variables into the D-Bus and systemd
|
||||
# user environments (e.g. required for screen sharing and Pinentry prompts):
|
||||
exec dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK XDG_CURRENT_DESKTOP
|
||||
'';
|
||||
};
|
||||
};
|
||||
security.pam.services.swaylock = {};
|
||||
|
@ -131,6 +140,8 @@ in {
|
|||
# To make a Sway session available if a display manager like SDDM is enabled:
|
||||
services.xserver.displayManager.sessionPackages = [ swayPackage ];
|
||||
programs.xwayland.enable = mkDefault true;
|
||||
# For screen sharing (this option only has an effect with xdg.portal.enable):
|
||||
xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-wlr ];
|
||||
};
|
||||
|
||||
meta.maintainers = with lib.maintainers; [ gnidorah primeos colemickens ];
|
||||
|
|
|
@ -35,10 +35,10 @@ let
|
|||
auto_pause = true;
|
||||
only_admins_can_pause_the_game = true;
|
||||
autosave_only_on_server = true;
|
||||
admins = [];
|
||||
non_blocking_saving = cfg.nonBlockingSaving;
|
||||
} // cfg.extraSettings;
|
||||
serverSettingsFile = pkgs.writeText "server-settings.json" (builtins.toJSON (filterAttrsRecursive (n: v: v != null) serverSettings));
|
||||
serverAdminsFile = pkgs.writeText "server-adminlist.json" (builtins.toJSON cfg.admins);
|
||||
modDir = pkgs.factorio-utils.mkModDirDrv cfg.mods;
|
||||
in
|
||||
{
|
||||
|
@ -52,6 +52,16 @@ in
|
|||
The port to which the service should bind.
|
||||
'';
|
||||
};
|
||||
|
||||
admins = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [];
|
||||
example = [ "username" ];
|
||||
description = ''
|
||||
List of player names which will be admin.
|
||||
'';
|
||||
};
|
||||
|
||||
openFirewall = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
|
@ -234,6 +244,7 @@ in
|
|||
"--start-server=${mkSavePath cfg.saveName}"
|
||||
"--server-settings=${serverSettingsFile}"
|
||||
(optionalString (cfg.mods != []) "--mod-directory=${modDir}")
|
||||
(optionalString (cfg.admins != []) "--server-adminlist=${serverAdminsFile}")
|
||||
];
|
||||
|
||||
# Sandboxing
|
||||
|
|
|
@ -34,6 +34,7 @@ let
|
|||
"fritzbox"
|
||||
"json"
|
||||
"jitsi"
|
||||
"kea"
|
||||
"keylight"
|
||||
"knot"
|
||||
"lnd"
|
||||
|
|
|
@ -41,12 +41,12 @@ in
|
|||
serviceConfig = {
|
||||
ExecStart = ''
|
||||
${pkgs.prometheus-bind-exporter}/bin/bind_exporter \
|
||||
-web.listen-address ${cfg.listenAddress}:${toString cfg.port} \
|
||||
-bind.pid-file /var/run/named/named.pid \
|
||||
-bind.timeout ${toString cfg.bindTimeout} \
|
||||
-bind.stats-url ${cfg.bindURI} \
|
||||
-bind.stats-version ${cfg.bindVersion} \
|
||||
-bind.stats-groups ${concatStringsSep "," cfg.bindGroups} \
|
||||
--web.listen-address ${cfg.listenAddress}:${toString cfg.port} \
|
||||
--bind.pid-file /var/run/named/named.pid \
|
||||
--bind.timeout ${toString cfg.bindTimeout} \
|
||||
--bind.stats-url ${cfg.bindURI} \
|
||||
--bind.stats-version ${cfg.bindVersion} \
|
||||
--bind.stats-groups ${concatStringsSep "," cfg.bindGroups} \
|
||||
${concatStringsSep " \\\n " cfg.extraFlags}
|
||||
'';
|
||||
};
|
||||
|
|
|
@ -41,11 +41,11 @@ in
|
|||
};
|
||||
|
||||
logFormat = mkOption {
|
||||
type = types.str;
|
||||
default = "logger:stderr";
|
||||
example = "logger:syslog?appname=bob&local=7 or logger:stdout?json=true";
|
||||
type = types.enum [ "logfmt" "json" ];
|
||||
default = "logfmt";
|
||||
example = "json";
|
||||
description = ''
|
||||
Set the log target and format.
|
||||
Set the log format.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -59,16 +59,16 @@ in
|
|||
};
|
||||
serviceOpts = let
|
||||
collectSettingsArgs = if (cfg.collectdBinary.enable) then ''
|
||||
-collectd.listen-address ${cfg.collectdBinary.listenAddress}:${toString cfg.collectdBinary.port} \
|
||||
-collectd.security-level ${cfg.collectdBinary.securityLevel} \
|
||||
--collectd.listen-address ${cfg.collectdBinary.listenAddress}:${toString cfg.collectdBinary.port} \
|
||||
--collectd.security-level ${cfg.collectdBinary.securityLevel} \
|
||||
'' else "";
|
||||
in {
|
||||
serviceConfig = {
|
||||
ExecStart = ''
|
||||
${pkgs.prometheus-collectd-exporter}/bin/collectd_exporter \
|
||||
-log.format ${escapeShellArg cfg.logFormat} \
|
||||
-log.level ${cfg.logLevel} \
|
||||
-web.listen-address ${cfg.listenAddress}:${toString cfg.port} \
|
||||
--log.format ${escapeShellArg cfg.logFormat} \
|
||||
--log.level ${cfg.logLevel} \
|
||||
--web.listen-address ${cfg.listenAddress}:${toString cfg.port} \
|
||||
${collectSettingsArgs} \
|
||||
${concatStringsSep " \\\n " cfg.extraFlags}
|
||||
'';
|
||||
|
|
|
@ -0,0 +1,38 @@
|
|||
{ config
|
||||
, lib
|
||||
, pkgs
|
||||
, options
|
||||
}:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.services.prometheus.exporters.kea;
|
||||
in {
|
||||
port = 9547;
|
||||
extraOpts = {
|
||||
controlSocketPaths = mkOption {
|
||||
type = types.listOf types.str;
|
||||
example = literalExample ''
|
||||
[
|
||||
"/run/kea/kea-dhcp4.socket"
|
||||
"/run/kea/kea-dhcp6.socket"
|
||||
]
|
||||
'';
|
||||
description = ''
|
||||
Paths to kea control sockets
|
||||
'';
|
||||
};
|
||||
};
|
||||
serviceOpts = {
|
||||
serviceConfig = {
|
||||
ExecStart = ''
|
||||
${pkgs.prometheus-kea-exporter}/bin/kea-exporter \
|
||||
--address ${cfg.listenAddress} \
|
||||
--port ${toString cfg.port} \
|
||||
${concatStringsSep " \\n" cfg.controlSocketPaths}
|
||||
'';
|
||||
SupplementaryGroups = [ "kea" ];
|
||||
};
|
||||
};
|
||||
}
|
|
@ -13,7 +13,7 @@ let
|
|||
generateConfig = extraLabels: {
|
||||
metrics = (map (path: {
|
||||
name = "rspamd_${replaceStrings [ "." " " ] [ "_" "_" ] path}";
|
||||
path = "$.${path}";
|
||||
path = "{ .${path} }";
|
||||
labels = extraLabels;
|
||||
}) [
|
||||
"actions.'add header'"
|
||||
|
|
|
@ -3,56 +3,103 @@
|
|||
with lib;
|
||||
|
||||
let
|
||||
|
||||
cfg = config.services.radicale;
|
||||
|
||||
confFile = pkgs.writeText "radicale.conf" cfg.config;
|
||||
|
||||
defaultPackage = if versionAtLeast config.system.stateVersion "20.09" then {
|
||||
pkg = pkgs.radicale3;
|
||||
text = "pkgs.radicale3";
|
||||
} else if versionAtLeast config.system.stateVersion "17.09" then {
|
||||
pkg = pkgs.radicale2;
|
||||
text = "pkgs.radicale2";
|
||||
} else {
|
||||
pkg = pkgs.radicale1;
|
||||
text = "pkgs.radicale1";
|
||||
format = pkgs.formats.ini {
|
||||
listToValue = concatMapStringsSep ", " (generators.mkValueStringDefault { });
|
||||
};
|
||||
in
|
||||
|
||||
{
|
||||
pkg = if isNull cfg.package then
|
||||
pkgs.radicale
|
||||
else
|
||||
cfg.package;
|
||||
|
||||
options = {
|
||||
services.radicale.enable = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = ''
|
||||
Enable Radicale CalDAV and CardDAV server.
|
||||
'';
|
||||
confFile = if cfg.settings == { } then
|
||||
pkgs.writeText "radicale.conf" cfg.config
|
||||
else
|
||||
format.generate "radicale.conf" cfg.settings;
|
||||
|
||||
rightsFile = format.generate "radicale.rights" cfg.rights;
|
||||
|
||||
bindLocalhost = cfg.settings != { } && !hasAttrByPath [ "server" "hosts" ] cfg.settings;
|
||||
|
||||
in {
|
||||
options.services.radicale = {
|
||||
enable = mkEnableOption "Radicale CalDAV and CardDAV server";
|
||||
|
||||
package = mkOption {
|
||||
description = "Radicale package to use.";
|
||||
# Default cannot be pkgs.radicale because non-null values suppress
|
||||
# warnings about incompatible configuration and storage formats.
|
||||
type = with types; nullOr package // { inherit (package) description; };
|
||||
default = null;
|
||||
defaultText = "pkgs.radicale";
|
||||
};
|
||||
|
||||
services.radicale.package = mkOption {
|
||||
type = types.package;
|
||||
default = defaultPackage.pkg;
|
||||
defaultText = defaultPackage.text;
|
||||
description = ''
|
||||
Radicale package to use. This defaults to version 1.x if
|
||||
<literal>system.stateVersion < 17.09</literal>, version 2.x if
|
||||
<literal>17.09 ≤ system.stateVersion < 20.09</literal>, and
|
||||
version 3.x otherwise.
|
||||
'';
|
||||
};
|
||||
|
||||
services.radicale.config = mkOption {
|
||||
config = mkOption {
|
||||
type = types.str;
|
||||
default = "";
|
||||
description = ''
|
||||
Radicale configuration, this will set the service
|
||||
configuration file.
|
||||
This option is mutually exclusive with <option>settings</option>.
|
||||
This option is deprecated. Use <option>settings</option> instead.
|
||||
'';
|
||||
};
|
||||
|
||||
services.radicale.extraArgs = mkOption {
|
||||
settings = mkOption {
|
||||
type = format.type;
|
||||
default = { };
|
||||
description = ''
|
||||
Configuration for Radicale. See
|
||||
<link xlink:href="https://radicale.org/3.0.html#documentation/configuration" />.
|
||||
This option is mutually exclusive with <option>config</option>.
|
||||
'';
|
||||
example = literalExample ''
|
||||
server = {
|
||||
hosts = [ "0.0.0.0:5232" "[::]:5232" ];
|
||||
};
|
||||
auth = {
|
||||
type = "htpasswd";
|
||||
htpasswd_filename = "/etc/radicale/users";
|
||||
htpasswd_encryption = "bcrypt";
|
||||
};
|
||||
storage = {
|
||||
filesystem_folder = "/var/lib/radicale/collections";
|
||||
};
|
||||
'';
|
||||
};
|
||||
|
||||
rights = mkOption {
|
||||
type = format.type;
|
||||
description = ''
|
||||
Configuration for Radicale's rights file. See
|
||||
<link xlink:href="https://radicale.org/3.0.html#documentation/authentication-and-rights" />.
|
||||
This option only works in conjunction with <option>settings</option>.
|
||||
Setting this will also set <option>settings.rights.type</option> and
|
||||
<option>settings.rights.file</option> to approriate values.
|
||||
'';
|
||||
default = { };
|
||||
example = literalExample ''
|
||||
root = {
|
||||
user = ".+";
|
||||
collection = "";
|
||||
permissions = "R";
|
||||
};
|
||||
principal = {
|
||||
user = ".+";
|
||||
collection = "{user}";
|
||||
permissions = "RW";
|
||||
};
|
||||
calendars = {
|
||||
user = ".+";
|
||||
collection = "{user}/[^/]+";
|
||||
permissions = "rw";
|
||||
};
|
||||
'';
|
||||
};
|
||||
|
||||
extraArgs = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [];
|
||||
description = "Extra arguments passed to the Radicale daemon.";
|
||||
|
@ -60,33 +107,94 @@ in
|
|||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
environment.systemPackages = [ cfg.package ];
|
||||
assertions = [
|
||||
{
|
||||
assertion = cfg.settings == { } || cfg.config == "";
|
||||
message = ''
|
||||
The options services.radicale.config and services.radicale.settings
|
||||
are mutually exclusive.
|
||||
'';
|
||||
}
|
||||
];
|
||||
|
||||
users.users.radicale =
|
||||
{ uid = config.ids.uids.radicale;
|
||||
description = "radicale user";
|
||||
home = "/var/lib/radicale";
|
||||
createHome = true;
|
||||
};
|
||||
warnings = optional (isNull cfg.package && versionOlder config.system.stateVersion "17.09") ''
|
||||
The configuration and storage formats of your existing Radicale
|
||||
installation might be incompatible with the newest version.
|
||||
For upgrade instructions see
|
||||
https://radicale.org/2.1.html#documentation/migration-from-1xx-to-2xx.
|
||||
Set services.radicale.package to suppress this warning.
|
||||
'' ++ optional (isNull cfg.package && versionOlder config.system.stateVersion "20.09") ''
|
||||
The configuration format of your existing Radicale installation might be
|
||||
incompatible with the newest version. For upgrade instructions see
|
||||
https://github.com/Kozea/Radicale/blob/3.0.6/NEWS.md#upgrade-checklist.
|
||||
Set services.radicale.package to suppress this warning.
|
||||
'' ++ optional (cfg.config != "") ''
|
||||
The option services.radicale.config is deprecated.
|
||||
Use services.radicale.settings instead.
|
||||
'';
|
||||
|
||||
users.groups.radicale =
|
||||
{ gid = config.ids.gids.radicale; };
|
||||
services.radicale.settings.rights = mkIf (cfg.rights != { }) {
|
||||
type = "from_file";
|
||||
file = toString rightsFile;
|
||||
};
|
||||
|
||||
environment.systemPackages = [ pkg ];
|
||||
|
||||
users.users.radicale.uid = config.ids.uids.radicale;
|
||||
|
||||
users.groups.radicale.gid = config.ids.gids.radicale;
|
||||
|
||||
systemd.services.radicale = {
|
||||
description = "A Simple Calendar and Contact Server";
|
||||
after = [ "network.target" ];
|
||||
requires = [ "network.target" ];
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig = {
|
||||
ExecStart = concatStringsSep " " ([
|
||||
"${cfg.package}/bin/radicale" "-C" confFile
|
||||
"${pkg}/bin/radicale" "-C" confFile
|
||||
] ++ (
|
||||
map escapeShellArg cfg.extraArgs
|
||||
));
|
||||
User = "radicale";
|
||||
Group = "radicale";
|
||||
StateDirectory = "radicale/collections";
|
||||
StateDirectoryMode = "0750";
|
||||
# Hardening
|
||||
CapabilityBoundingSet = [ "" ];
|
||||
DeviceAllow = [ "/dev/stdin" ];
|
||||
DevicePolicy = "strict";
|
||||
IPAddressAllow = mkIf bindLocalhost "localhost";
|
||||
IPAddressDeny = mkIf bindLocalhost "any";
|
||||
LockPersonality = true;
|
||||
MemoryDenyWriteExecute = true;
|
||||
NoNewPrivileges = true;
|
||||
PrivateDevices = true;
|
||||
PrivateTmp = true;
|
||||
PrivateUsers = true;
|
||||
ProcSubset = "pid";
|
||||
ProtectClock = true;
|
||||
ProtectControlGroups = true;
|
||||
ProtectHome = true;
|
||||
ProtectHostname = true;
|
||||
ProtectKernelLogs = true;
|
||||
ProtectKernelModules = true;
|
||||
ProtectKernelTunables = true;
|
||||
ProtectProc = "invisible";
|
||||
ProtectSystem = "strict";
|
||||
ReadWritePaths = lib.optional
|
||||
(hasAttrByPath [ "storage" "filesystem_folder" ] cfg.settings)
|
||||
cfg.settings.storage.filesystem_folder;
|
||||
RemoveIPC = true;
|
||||
RestrictAddressFamilies = [ "AF_INET" "AF_INET6" ];
|
||||
RestrictNamespaces = true;
|
||||
RestrictRealtime = true;
|
||||
RestrictSUIDSGID = true;
|
||||
SystemCallArchitectures = "native";
|
||||
SystemCallFilter = [ "@system-service" "~@privileged" "~@resources" ];
|
||||
UMask = "0027";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
meta.maintainers = with lib.maintainers; [ aneeshusa infinisil ];
|
||||
meta.maintainers = with lib.maintainers; [ aneeshusa infinisil dotlambda ];
|
||||
}
|
||||
|
|
|
@ -15,11 +15,9 @@ let
|
|||
apachectl = pkgs.runCommand "apachectl" { meta.priority = -1; } ''
|
||||
mkdir -p $out/bin
|
||||
cp ${pkg}/bin/apachectl $out/bin/apachectl
|
||||
sed -i $out/bin/apachectl -e 's|$HTTPD -t|$HTTPD -t -f ${httpdConf}|'
|
||||
sed -i $out/bin/apachectl -e 's|$HTTPD -t|$HTTPD -t -f /etc/httpd/httpd.conf|'
|
||||
'';
|
||||
|
||||
httpdConf = cfg.configFile;
|
||||
|
||||
php = cfg.phpPackage.override { apacheHttpd = pkg; };
|
||||
|
||||
phpModuleName = let
|
||||
|
@ -682,6 +680,8 @@ in
|
|||
}) (filter (hostOpts: hostOpts.useACMEHost == null) acmeEnabledVhosts);
|
||||
in listToAttrs acmePairs;
|
||||
|
||||
# httpd requires a stable path to the configuration file for reloads
|
||||
environment.etc."httpd/httpd.conf".source = cfg.configFile;
|
||||
environment.systemPackages = [
|
||||
apachectl
|
||||
pkg
|
||||
|
@ -753,6 +753,7 @@ in
|
|||
wants = concatLists (map (certName: [ "acme-finished-${certName}.target" ]) dependentCertNames);
|
||||
after = [ "network.target" ] ++ map (certName: "acme-selfsigned-${certName}.service") dependentCertNames;
|
||||
before = map (certName: "acme-${certName}.service") dependentCertNames;
|
||||
restartTriggers = [ cfg.configFile ];
|
||||
|
||||
path = [ pkg pkgs.coreutils pkgs.gnugrep ];
|
||||
|
||||
|
@ -771,9 +772,9 @@ in
|
|||
'';
|
||||
|
||||
serviceConfig = {
|
||||
ExecStart = "@${pkg}/bin/httpd httpd -f ${httpdConf}";
|
||||
ExecStop = "${pkg}/bin/httpd -f ${httpdConf} -k graceful-stop";
|
||||
ExecReload = "${pkg}/bin/httpd -f ${httpdConf} -k graceful";
|
||||
ExecStart = "@${pkg}/bin/httpd httpd -f /etc/httpd/httpd.conf";
|
||||
ExecStop = "${pkg}/bin/httpd -f /etc/httpd/httpd.conf -k graceful-stop";
|
||||
ExecReload = "${pkg}/bin/httpd -f /etc/httpd/httpd.conf -k graceful";
|
||||
User = cfg.user;
|
||||
Group = cfg.group;
|
||||
Type = "forking";
|
||||
|
@ -800,6 +801,7 @@ in
|
|||
# certs are updated _after_ config has been reloaded.
|
||||
before = sslTargets;
|
||||
after = sslServices;
|
||||
restartTriggers = [ cfg.configFile ];
|
||||
# Block reloading if not all certs exist yet.
|
||||
# Happens when config changes add new vhosts/certs.
|
||||
unitConfig.ConditionPathExists = map (certName: certs.${certName}.directory + "/fullchain.pem") dependentCertNames;
|
||||
|
@ -807,7 +809,7 @@ in
|
|||
Type = "oneshot";
|
||||
TimeoutSec = 60;
|
||||
ExecCondition = "/run/current-system/systemd/bin/systemctl -q is-active httpd.service";
|
||||
ExecStartPre = "${pkg}/bin/httpd -f ${httpdConf} -t";
|
||||
ExecStartPre = "${pkg}/bin/httpd -f /etc/httpd/httpd.conf -t";
|
||||
ExecStart = "/run/current-system/systemd/bin/systemctl reload httpd.service";
|
||||
};
|
||||
};
|
||||
|
|
|
@ -103,6 +103,7 @@ in
|
|||
readOnly = true;
|
||||
type = types.package;
|
||||
default = if config.boot.zfs.enableUnstable then pkgs.zfsUnstable else pkgs.zfs;
|
||||
defaultText = "if config.boot.zfs.enableUnstable then pkgs.zfsUnstable else pkgs.zfs";
|
||||
description = "Configured ZFS userland tools package.";
|
||||
};
|
||||
|
||||
|
|
|
@ -151,8 +151,8 @@ in
|
|||
config = mkIf cfg.enable (mkMerge [{
|
||||
boot.kernelModules = [ "bridge" "veth" ];
|
||||
boot.kernel.sysctl = {
|
||||
"net.ipv4.conf.all.forwarding" = mkOverride 99 true;
|
||||
"net.ipv4.conf.default.forwarding" = mkOverride 99 true;
|
||||
"net.ipv4.conf.all.forwarding" = mkOverride 98 true;
|
||||
"net.ipv4.conf.default.forwarding" = mkOverride 98 true;
|
||||
};
|
||||
environment.systemPackages = [ cfg.package ]
|
||||
++ optional cfg.enableNvidia pkgs.nvidia-docker;
|
||||
|
|
|
@ -90,6 +90,7 @@ in
|
|||
custom-ca = handleTest ./custom-ca.nix {};
|
||||
croc = handleTest ./croc.nix {};
|
||||
deluge = handleTest ./deluge.nix {};
|
||||
dendrite = handleTest ./dendrite.nix {};
|
||||
dhparams = handleTest ./dhparams.nix {};
|
||||
discourse = handleTest ./discourse.nix {};
|
||||
dnscrypt-proxy2 = handleTestOn ["x86_64-linux"] ./dnscrypt-proxy2.nix {};
|
||||
|
|
99
nixos/tests/dendrite.nix
Normal file
99
nixos/tests/dendrite.nix
Normal file
|
@ -0,0 +1,99 @@
|
|||
import ./make-test-python.nix (
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
homeserverUrl = "http://homeserver:8008";
|
||||
|
||||
private_key = pkgs.runCommand "matrix_key.pem" {
|
||||
buildInputs = [ pkgs.dendrite ];
|
||||
} "generate-keys --private-key $out";
|
||||
in
|
||||
{
|
||||
name = "dendrite";
|
||||
meta = with pkgs.lib; {
|
||||
maintainers = teams.matrix.members;
|
||||
};
|
||||
|
||||
nodes = {
|
||||
homeserver = { pkgs, ... }: {
|
||||
services.dendrite = {
|
||||
enable = true;
|
||||
settings = {
|
||||
global.server_name = "test-dendrite-server.com";
|
||||
global.private_key = private_key;
|
||||
client_api.registration_disabled = false;
|
||||
};
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [ 8008 ];
|
||||
};
|
||||
|
||||
client = { pkgs, ... }: {
|
||||
environment.systemPackages = [
|
||||
(
|
||||
pkgs.writers.writePython3Bin "do_test"
|
||||
{ libraries = [ pkgs.python3Packages.matrix-nio ]; } ''
|
||||
import asyncio
|
||||
|
||||
from nio import AsyncClient
|
||||
|
||||
|
||||
async def main() -> None:
|
||||
# Connect to dendrite
|
||||
client = AsyncClient("http://homeserver:8008", "alice")
|
||||
|
||||
# Register as user alice
|
||||
response = await client.register("alice", "my-secret-password")
|
||||
|
||||
# Log in as user alice
|
||||
response = await client.login("my-secret-password")
|
||||
|
||||
# Create a new room
|
||||
response = await client.room_create(federate=False)
|
||||
room_id = response.room_id
|
||||
|
||||
# Join the room
|
||||
response = await client.join(room_id)
|
||||
|
||||
# Send a message to the room
|
||||
response = await client.room_send(
|
||||
room_id=room_id,
|
||||
message_type="m.room.message",
|
||||
content={
|
||||
"msgtype": "m.text",
|
||||
"body": "Hello world!"
|
||||
}
|
||||
)
|
||||
|
||||
# Sync responses
|
||||
response = await client.sync(timeout=30000)
|
||||
|
||||
# Check the message was received by dendrite
|
||||
last_message = response.rooms.join[room_id].timeline.events[-1].body
|
||||
assert last_message == "Hello world!"
|
||||
|
||||
# Leave the room
|
||||
response = await client.room_leave(room_id)
|
||||
|
||||
# Close the client
|
||||
await client.close()
|
||||
|
||||
asyncio.get_event_loop().run_until_complete(main())
|
||||
''
|
||||
)
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
start_all()
|
||||
|
||||
with subtest("start the homeserver"):
|
||||
homeserver.wait_for_unit("dendrite.service")
|
||||
homeserver.wait_for_open_port(8008)
|
||||
|
||||
with subtest("ensure messages can be exchanged"):
|
||||
client.succeed("do_test")
|
||||
'';
|
||||
|
||||
}
|
||||
)
|
|
@ -302,7 +302,7 @@ let
|
|||
url = "http://localhost";
|
||||
configFile = pkgs.writeText "json-exporter-conf.json" (builtins.toJSON {
|
||||
metrics = [
|
||||
{ name = "json_test_metric"; path = "$.test"; }
|
||||
{ name = "json_test_metric"; path = "{ .test }"; }
|
||||
];
|
||||
});
|
||||
};
|
||||
|
@ -326,6 +326,57 @@ let
|
|||
'';
|
||||
};
|
||||
|
||||
kea = {
|
||||
exporterConfig = {
|
||||
enable = true;
|
||||
controlSocketPaths = [
|
||||
"/run/kea/kea-dhcp6.sock"
|
||||
];
|
||||
};
|
||||
metricProvider = {
|
||||
users.users.kea = {
|
||||
isSystemUser = true;
|
||||
};
|
||||
users.groups.kea = {};
|
||||
|
||||
systemd.services.prometheus-kea-exporter.after = [ "kea-dhcp6.service" ];
|
||||
|
||||
systemd.services.kea-dhcp6 = let
|
||||
configFile = pkgs.writeText "kea-dhcp6.conf" (builtins.toJSON {
|
||||
Dhcp6 = {
|
||||
"control-socket" = {
|
||||
"socket-type" = "unix";
|
||||
"socket-name" = "/run/kea/kea-dhcp6.sock";
|
||||
};
|
||||
};
|
||||
});
|
||||
in
|
||||
{
|
||||
after = [ "network.target" ];
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
|
||||
serviceConfig = {
|
||||
DynamicUser = false;
|
||||
User = "kea";
|
||||
Group = "kea";
|
||||
ExecStart = "${pkgs.kea}/bin/kea-dhcp6 -c ${configFile}";
|
||||
StateDirectory = "kea";
|
||||
RuntimeDirectory = "kea";
|
||||
UMask = "0007";
|
||||
};
|
||||
};
|
||||
};
|
||||
exporterTest = ''
|
||||
wait_for_unit("kea-dhcp6.service")
|
||||
wait_for_file("/run/kea/kea-dhcp6.sock")
|
||||
wait_for_unit("prometheus-kea-exporter.service")
|
||||
wait_for_open_port(9547)
|
||||
succeed(
|
||||
"curl --fail localhost:9547/metrics | grep 'packets_received_total'"
|
||||
)
|
||||
'';
|
||||
};
|
||||
|
||||
knot = {
|
||||
exporterConfig = {
|
||||
enable = true;
|
||||
|
@ -406,8 +457,8 @@ let
|
|||
};
|
||||
metricProvider = {
|
||||
systemd.services.prometheus-lnd-exporter.serviceConfig.DynamicUser = false;
|
||||
services.bitcoind.enable = true;
|
||||
services.bitcoind.extraConfig = ''
|
||||
services.bitcoind.main.enable = true;
|
||||
services.bitcoind.main.extraConfig = ''
|
||||
rpcauth=bitcoinrpc:e8fe33f797e698ac258c16c8d7aadfbe$872bdb8f4d787367c26bcfd75e6c23c4f19d44a69f5d1ad329e5adf3f82710f7
|
||||
bitcoind.zmqpubrawblock=tcp://127.0.0.1:28332
|
||||
bitcoind.zmqpubrawtx=tcp://127.0.0.1:28333
|
||||
|
@ -1021,7 +1072,7 @@ let
|
|||
# Note: this does not connect the test environment to the Tor network.
|
||||
# Client, relay, bridge or exit connectivity are disabled by default.
|
||||
services.tor.enable = true;
|
||||
services.tor.controlPort = 9051;
|
||||
services.tor.settings.ControlPort = 9051;
|
||||
};
|
||||
exporterTest = ''
|
||||
wait_for_unit("tor.service")
|
||||
|
|
|
@ -1,140 +1,95 @@
|
|||
import ./make-test-python.nix ({ lib, pkgs, ... }:
|
||||
|
||||
let
|
||||
user = "someuser";
|
||||
password = "some_password";
|
||||
port = builtins.toString 5232;
|
||||
port = "5232";
|
||||
filesystem_folder = "/data/radicale";
|
||||
|
||||
common = { pkgs, ... }: {
|
||||
cli = "${pkgs.calendar-cli}/bin/calendar-cli --caldav-user ${user} --caldav-pass ${password}";
|
||||
in {
|
||||
name = "radicale3";
|
||||
meta.maintainers = with lib.maintainers; [ dotlambda ];
|
||||
|
||||
machine = { pkgs, ... }: {
|
||||
services.radicale = {
|
||||
enable = true;
|
||||
config = ''
|
||||
[auth]
|
||||
type = htpasswd
|
||||
htpasswd_filename = /etc/radicale/htpasswd
|
||||
htpasswd_encryption = bcrypt
|
||||
|
||||
[storage]
|
||||
filesystem_folder = /tmp/collections
|
||||
'';
|
||||
settings = {
|
||||
auth = {
|
||||
type = "htpasswd";
|
||||
htpasswd_filename = "/etc/radicale/users";
|
||||
htpasswd_encryption = "bcrypt";
|
||||
};
|
||||
storage = {
|
||||
inherit filesystem_folder;
|
||||
hook = "git add -A && (git diff --cached --quiet || git commit -m 'Changes by '%(user)s)";
|
||||
};
|
||||
logging.level = "info";
|
||||
};
|
||||
rights = {
|
||||
principal = {
|
||||
user = ".+";
|
||||
collection = "{user}";
|
||||
permissions = "RW";
|
||||
};
|
||||
calendars = {
|
||||
user = ".+";
|
||||
collection = "{user}/[^/]+";
|
||||
permissions = "rw";
|
||||
};
|
||||
};
|
||||
};
|
||||
systemd.services.radicale.path = [ pkgs.git ];
|
||||
environment.systemPackages = [ pkgs.git ];
|
||||
systemd.tmpfiles.rules = [ "d ${filesystem_folder} 0750 radicale radicale -" ];
|
||||
# WARNING: DON'T DO THIS IN PRODUCTION!
|
||||
# This puts unhashed secrets directly into the Nix store for ease of testing.
|
||||
environment.etc."radicale/htpasswd".source = pkgs.runCommand "htpasswd" {} ''
|
||||
environment.etc."radicale/users".source = pkgs.runCommand "htpasswd" {} ''
|
||||
${pkgs.apacheHttpd}/bin/htpasswd -bcB "$out" ${user} ${password}
|
||||
'';
|
||||
};
|
||||
testScript = ''
|
||||
machine.wait_for_unit("radicale.service")
|
||||
machine.wait_for_open_port(${port})
|
||||
|
||||
in
|
||||
machine.succeed("sudo -u radicale git -C ${filesystem_folder} init")
|
||||
machine.succeed(
|
||||
"sudo -u radicale git -C ${filesystem_folder} config --local user.email radicale@example.com"
|
||||
)
|
||||
machine.succeed(
|
||||
"sudo -u radicale git -C ${filesystem_folder} config --local user.name radicale"
|
||||
)
|
||||
|
||||
import ./make-test-python.nix ({ lib, ... }@args: {
|
||||
name = "radicale";
|
||||
meta.maintainers = with lib.maintainers; [ aneeshusa infinisil ];
|
||||
with subtest("Test calendar and event creation"):
|
||||
machine.succeed(
|
||||
"${cli} --caldav-url http://localhost:${port}/${user} calendar create cal"
|
||||
)
|
||||
machine.succeed("test -d ${filesystem_folder}/collection-root/${user}/cal")
|
||||
machine.succeed('test -z "$(ls ${filesystem_folder}/collection-root/${user}/cal)"')
|
||||
machine.succeed(
|
||||
"${cli} --caldav-url http://localhost:${port}/${user}/cal calendar add 2021-04-23 testevent"
|
||||
)
|
||||
machine.succeed('test -n "$(ls ${filesystem_folder}/collection-root/${user}/cal)"')
|
||||
(status, stdout) = machine.execute(
|
||||
"sudo -u radicale git -C ${filesystem_folder} log --format=oneline | wc -l"
|
||||
)
|
||||
assert status == 0, "git log failed"
|
||||
assert stdout == "3\n", "there should be exactly 3 commits"
|
||||
|
||||
nodes = rec {
|
||||
radicale = radicale1; # Make the test script read more nicely
|
||||
radicale1 = lib.recursiveUpdate (common args) {
|
||||
nixpkgs.overlays = [
|
||||
(self: super: {
|
||||
radicale1 = super.radicale1.overrideAttrs (oldAttrs: {
|
||||
propagatedBuildInputs = with self.pythonPackages;
|
||||
(oldAttrs.propagatedBuildInputs or []) ++ [ passlib ];
|
||||
});
|
||||
})
|
||||
];
|
||||
system.stateVersion = "17.03";
|
||||
};
|
||||
radicale1_export = lib.recursiveUpdate radicale1 {
|
||||
services.radicale.extraArgs = [
|
||||
"--export-storage" "/tmp/collections-new"
|
||||
];
|
||||
system.stateVersion = "17.03";
|
||||
};
|
||||
radicale2_verify = lib.recursiveUpdate radicale2 {
|
||||
services.radicale.extraArgs = [ "--debug" "--verify-storage" ];
|
||||
system.stateVersion = "17.09";
|
||||
};
|
||||
radicale2 = lib.recursiveUpdate (common args) {
|
||||
system.stateVersion = "17.09";
|
||||
};
|
||||
radicale3 = lib.recursiveUpdate (common args) {
|
||||
system.stateVersion = "20.09";
|
||||
};
|
||||
};
|
||||
with subtest("Test rights file"):
|
||||
machine.fail(
|
||||
"${cli} --caldav-url http://localhost:${port}/${user} calendar create sub/cal"
|
||||
)
|
||||
machine.fail(
|
||||
"${cli} --caldav-url http://localhost:${port}/otheruser calendar create cal"
|
||||
)
|
||||
|
||||
# This tests whether the web interface is accessible to an authenticated user
|
||||
testScript = { nodes }: let
|
||||
switchToConfig = nodeName: let
|
||||
newSystem = nodes.${nodeName}.config.system.build.toplevel;
|
||||
in "${newSystem}/bin/switch-to-configuration test";
|
||||
in ''
|
||||
with subtest("Check Radicale 1 functionality"):
|
||||
radicale.succeed(
|
||||
"${switchToConfig "radicale1"} >&2"
|
||||
)
|
||||
radicale.wait_for_unit("radicale.service")
|
||||
radicale.wait_for_open_port(${port})
|
||||
radicale.succeed(
|
||||
"curl --fail http://${user}:${password}@localhost:${port}/someuser/calendar.ics/"
|
||||
)
|
||||
with subtest("Test web interface"):
|
||||
machine.succeed("curl --fail http://${user}:${password}@localhost:${port}/.web/")
|
||||
|
||||
with subtest("Export data in Radicale 2 format"):
|
||||
radicale.succeed("systemctl stop radicale")
|
||||
radicale.succeed("ls -al /tmp/collections")
|
||||
radicale.fail("ls -al /tmp/collections-new")
|
||||
|
||||
with subtest("Radicale exits immediately after exporting storage"):
|
||||
radicale.succeed(
|
||||
"${switchToConfig "radicale1_export"} >&2"
|
||||
)
|
||||
radicale.wait_until_fails("systemctl status radicale")
|
||||
radicale.succeed("ls -al /tmp/collections")
|
||||
radicale.succeed("ls -al /tmp/collections-new")
|
||||
|
||||
with subtest("Verify data in Radicale 2 format"):
|
||||
radicale.succeed("rm -r /tmp/collections/${user}")
|
||||
radicale.succeed("mv /tmp/collections-new/collection-root /tmp/collections")
|
||||
radicale.succeed(
|
||||
"${switchToConfig "radicale2_verify"} >&2"
|
||||
)
|
||||
radicale.wait_until_fails("systemctl status radicale")
|
||||
|
||||
(retcode, logs) = radicale.execute("journalctl -u radicale -n 10")
|
||||
assert (
|
||||
retcode == 0 and "Verifying storage" in logs
|
||||
), "Radicale 2 didn't verify storage"
|
||||
assert (
|
||||
"failed" not in logs and "exception" not in logs
|
||||
), "storage verification failed"
|
||||
|
||||
with subtest("Check Radicale 2 functionality"):
|
||||
radicale.succeed(
|
||||
"${switchToConfig "radicale2"} >&2"
|
||||
)
|
||||
radicale.wait_for_unit("radicale.service")
|
||||
radicale.wait_for_open_port(${port})
|
||||
|
||||
(retcode, output) = radicale.execute(
|
||||
"curl --fail http://${user}:${password}@localhost:${port}/someuser/calendar.ics/"
|
||||
)
|
||||
assert (
|
||||
retcode == 0 and "VCALENDAR" in output
|
||||
), "Could not read calendar from Radicale 2"
|
||||
|
||||
radicale.succeed("curl --fail http://${user}:${password}@localhost:${port}/.web/")
|
||||
|
||||
with subtest("Check Radicale 3 functionality"):
|
||||
radicale.succeed(
|
||||
"${switchToConfig "radicale3"} >&2"
|
||||
)
|
||||
radicale.wait_for_unit("radicale.service")
|
||||
radicale.wait_for_open_port(${port})
|
||||
|
||||
(retcode, output) = radicale.execute(
|
||||
"curl --fail http://${user}:${password}@localhost:${port}/someuser/calendar.ics/"
|
||||
)
|
||||
assert (
|
||||
retcode == 0 and "VCALENDAR" in output
|
||||
), "Could not read calendar from Radicale 3"
|
||||
|
||||
radicale.succeed("curl --fail http://${user}:${password}@localhost:${port}/.web/")
|
||||
'';
|
||||
with subtest("Test security"):
|
||||
output = machine.succeed("systemd-analyze security radicale.service")
|
||||
machine.log(output)
|
||||
assert output[-9:-1] == "SAFE :-}"
|
||||
'';
|
||||
})
|
||||
|
|
|
@ -3,7 +3,7 @@ import ./make-test-python.nix ({ pkgs, ...} :
|
|||
{
|
||||
name = "signal-desktop";
|
||||
meta = with pkgs.lib.maintainers; {
|
||||
maintainers = [ flokli ];
|
||||
maintainers = [ flokli primeos ];
|
||||
};
|
||||
|
||||
machine = { ... }:
|
||||
|
@ -16,7 +16,7 @@ import ./make-test-python.nix ({ pkgs, ...} :
|
|||
|
||||
services.xserver.enable = true;
|
||||
test-support.displayManager.auto.user = "alice";
|
||||
environment.systemPackages = [ pkgs.signal-desktop ];
|
||||
environment.systemPackages = with pkgs; [ signal-desktop file ];
|
||||
virtualisation.memorySize = 1024;
|
||||
};
|
||||
|
||||
|
@ -39,5 +39,17 @@ import ./make-test-python.nix ({ pkgs, ...} :
|
|||
machine.wait_for_text("Signal")
|
||||
machine.wait_for_text("File Edit View Window Help")
|
||||
machine.screenshot("signal_desktop")
|
||||
|
||||
# Test if the database is encrypted to prevent these issues:
|
||||
# - https://github.com/NixOS/nixpkgs/issues/108772
|
||||
# - https://github.com/NixOS/nixpkgs/pull/117555
|
||||
print(machine.succeed("su - alice -c 'file ~/.config/Signal/sql/db.sqlite'"))
|
||||
# TODO: The DB should be encrypted and the following should be machine.fail
|
||||
# instead of machine.succeed but the DB is currently unencrypted and we
|
||||
# want to notice if this isn't the case anymore as the transition to a
|
||||
# encrypted DB can cause data loss!:
|
||||
machine.succeed(
|
||||
"su - alice -c 'file ~/.config/Signal/sql/db.sqlite' | grep -i sqlite"
|
||||
)
|
||||
'';
|
||||
})
|
||||
|
|
|
@ -38,6 +38,9 @@ import ./make-test-python.nix ({ pkgs, lib, ...} :
|
|||
|
||||
programs.sway.enable = true;
|
||||
|
||||
# To test pinentry via gpg-agent:
|
||||
programs.gnupg.agent.enable = true;
|
||||
|
||||
virtualisation.memorySize = 1024;
|
||||
# Need to switch to a different VGA card / GPU driver than the default one (std) so that Sway can launch:
|
||||
virtualisation.qemu.options = [ "-vga virtio" ];
|
||||
|
@ -80,6 +83,17 @@ import ./make-test-python.nix ({ pkgs, lib, ...} :
|
|||
machine.send_key("alt-shift-q")
|
||||
machine.wait_until_fails("pgrep alacritty")
|
||||
|
||||
# Test gpg-agent starting pinentry-gnome3 via D-Bus (tests if
|
||||
# $WAYLAND_DISPLAY is correctly imported into the D-Bus user env):
|
||||
machine.succeed(
|
||||
"su - alice -c 'swaymsg -- exec gpg --no-tty --yes --quick-generate-key test'"
|
||||
)
|
||||
machine.wait_until_succeeds("pgrep --exact gpg")
|
||||
machine.wait_for_text("Passphrase")
|
||||
machine.screenshot("gpg_pinentry")
|
||||
machine.send_key("alt-shift-q")
|
||||
machine.wait_until_fails("pgrep --exact gpg")
|
||||
|
||||
# Test swaynag:
|
||||
machine.send_key("alt-shift-e")
|
||||
machine.wait_for_text("You pressed the exit shortcut.")
|
||||
|
|
|
@ -82,10 +82,6 @@ mkDerivation rec {
|
|||
util-linux
|
||||
];
|
||||
|
||||
cmakeFlags = [
|
||||
"-DUSE_SYSTEM_TAGLIB=ON"
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
qtWrapperArgs+=(--prefix GST_PLUGIN_SYSTEM_PATH_1_0 : "$GST_PLUGIN_SYSTEM_PATH_1_0")
|
||||
'';
|
||||
|
|
|
@ -2,11 +2,11 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "ergo";
|
||||
version = "4.0.9";
|
||||
version = "4.0.10";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/ergoplatform/ergo/releases/download/v${version}/ergo-${version}.jar";
|
||||
sha256 = "sha256-FstAKUZVKW9U6QTqqCEDybvbBl+0H9qVHqFMPubdDpk=";
|
||||
sha256 = "sha256-o3+yL81WO5/UGh0gl4MOewPHTDch/Vij8mzZWOlEkjg=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ lib, fetchFromGitHub, rustPlatform }:
|
||||
{ lib, stdenv, fetchFromGitHub, rustPlatform, libiconv }:
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "ethabi";
|
||||
|
@ -15,6 +15,8 @@ rustPlatform.buildRustPackage rec {
|
|||
|
||||
cargoPatches = [ ./add-Cargo-lock.patch ];
|
||||
|
||||
buildInputs = lib.optional stdenv.isDarwin libiconv;
|
||||
|
||||
meta = with lib; {
|
||||
description = "Ethereum function call encoding (ABI) utility";
|
||||
homepage = "https://github.com/rust-ethereum/ethabi";
|
||||
|
|
|
@ -7,16 +7,16 @@
|
|||
}:
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "polkadot";
|
||||
version = "0.9.0";
|
||||
version = "0.9.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "paritytech";
|
||||
repo = "polkadot";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-Y52VFTjRFyC38ZNt6NMtVRA2pn6Y4B/NC4EEuDvIFQQ=";
|
||||
sha256 = "sha256-Ryo7Ln9nh6rlla4jnhSgqiIqHciGBTDxAjuRzE7BhDs=";
|
||||
};
|
||||
|
||||
cargoSha256 = "sha256-0GrExza6uPF/eFWrXlM4MpCD7TMk2y+uEc5SDj/UQkg=";
|
||||
cargoSha256 = "sha256-PpFphsSfVTENp1TsnQRuAqKK0hcqFLXp/tDrVSz5mIQ=";
|
||||
|
||||
nativeBuildInputs = [ clang ];
|
||||
|
||||
|
|
|
@ -655,10 +655,10 @@
|
|||
elpaBuild {
|
||||
pname = "corfu";
|
||||
ename = "corfu";
|
||||
version = "0.4";
|
||||
version = "0.6";
|
||||
src = fetchurl {
|
||||
url = "https://elpa.gnu.org/packages/corfu-0.4.tar";
|
||||
sha256 = "0yaspx58w02n3liqy5i4lm6lk5f1fm6v5lfrzp7xaqnngq1f4gbj";
|
||||
url = "https://elpa.gnu.org/packages/corfu-0.6.tar";
|
||||
sha256 = "0zl769l3mmy4b0pj70dwjllq0224r2w4l45xvaqbj75qfqclj6cj";
|
||||
};
|
||||
packageRequires = [ emacs ];
|
||||
meta = {
|
||||
|
@ -1045,10 +1045,10 @@
|
|||
elpaBuild {
|
||||
pname = "eev";
|
||||
ename = "eev";
|
||||
version = "20210102";
|
||||
version = "20210512";
|
||||
src = fetchurl {
|
||||
url = "https://elpa.gnu.org/packages/eev-20210102.tar";
|
||||
sha256 = "14vpgcncmzzbv8v78v221hdhigvk00vqiizwd8dy0b7hqz6gl0rq";
|
||||
url = "https://elpa.gnu.org/packages/eev-20210512.tar";
|
||||
sha256 = "0dj49lpqv5vsx02h8mla8cmv5cr5f2qbz74f9dn8q4adpzxsajin";
|
||||
};
|
||||
packageRequires = [ emacs ];
|
||||
meta = {
|
||||
|
@ -1148,10 +1148,10 @@
|
|||
elpaBuild {
|
||||
pname = "elisp-benchmarks";
|
||||
ename = "elisp-benchmarks";
|
||||
version = "1.11";
|
||||
version = "1.12";
|
||||
src = fetchurl {
|
||||
url = "https://elpa.gnu.org/packages/elisp-benchmarks-1.11.tar";
|
||||
sha256 = "0s1mpapvcivy25zbhw6ghpg0ym23vb4dsrz876rl4z2rfyckxral";
|
||||
url = "https://elpa.gnu.org/packages/elisp-benchmarks-1.12.tar";
|
||||
sha256 = "0jzpzif4vrjg5hl0hxg4aqvi6nv56cxa1w0amnkgcz4hsscxkvwm";
|
||||
};
|
||||
packageRequires = [];
|
||||
meta = {
|
||||
|
@ -1159,16 +1159,21 @@
|
|||
license = lib.licenses.free;
|
||||
};
|
||||
}) {};
|
||||
emms = callPackage ({ cl-lib ? null, elpaBuild, fetchurl, lib, seq }:
|
||||
emms = callPackage ({ cl-lib ? null
|
||||
, elpaBuild
|
||||
, fetchurl
|
||||
, lib
|
||||
, nadvice
|
||||
, seq }:
|
||||
elpaBuild {
|
||||
pname = "emms";
|
||||
ename = "emms";
|
||||
version = "7.1";
|
||||
version = "7.2";
|
||||
src = fetchurl {
|
||||
url = "https://elpa.gnu.org/packages/emms-7.1.tar";
|
||||
sha256 = "1dng8dy0w0wsdvvnjnrllwv5a8wq3kj20jik994b7prdx5dn6y52";
|
||||
url = "https://elpa.gnu.org/packages/emms-7.2.tar";
|
||||
sha256 = "11vqqh9rnzibsfw7wx62rgzl8i8ldpf0hv1sj43nhl5c6dlc8d5z";
|
||||
};
|
||||
packageRequires = [ cl-lib seq ];
|
||||
packageRequires = [ cl-lib nadvice seq ];
|
||||
meta = {
|
||||
homepage = "https://elpa.gnu.org/packages/emms.html";
|
||||
license = lib.licenses.free;
|
||||
|
@ -2824,10 +2829,10 @@
|
|||
elpaBuild {
|
||||
pname = "pyim";
|
||||
ename = "pyim";
|
||||
version = "3.7.1";
|
||||
version = "3.7.5";
|
||||
src = fetchurl {
|
||||
url = "https://elpa.gnu.org/packages/pyim-3.7.1.tar";
|
||||
sha256 = "0k73f1qdl51qshnvycjassdh70id5gp5qi5wz7k4zyl8pbampiyd";
|
||||
url = "https://elpa.gnu.org/packages/pyim-3.7.5.tar";
|
||||
sha256 = "09f34wgzckbxgr5xvaqrj0wdcmnfsb31a6m460f5g0acys20ams5";
|
||||
};
|
||||
packageRequires = [ async emacs xr ];
|
||||
meta = {
|
||||
|
@ -3950,10 +3955,10 @@
|
|||
elpaBuild {
|
||||
pname = "vertico";
|
||||
ename = "vertico";
|
||||
version = "0.6";
|
||||
version = "0.8";
|
||||
src = fetchurl {
|
||||
url = "https://elpa.gnu.org/packages/vertico-0.6.tar";
|
||||
sha256 = "19f6ffljraikz83nc2y9q83zjc4cfyzn9rnwm18lwh6sjsydz6kk";
|
||||
url = "https://elpa.gnu.org/packages/vertico-0.8.tar";
|
||||
sha256 = "1cdq49csd57vqhrs1nbif79yw4s8c0p2i2ww5n5znzj7rnxwpva4";
|
||||
};
|
||||
packageRequires = [ emacs ];
|
||||
meta = {
|
||||
|
|
|
@ -7,10 +7,10 @@ let
|
|||
rev = "860da04ca91cbb69c9b881a54248d16bdaaf9923";
|
||||
sha256 = "1r3xmyk9rfgx7ln69dk8mgbnh3awcalm3r1c5ia2shlsrymvv1df";
|
||||
};
|
||||
in
|
||||
pkgs.mkShell {
|
||||
|
||||
in pkgs.mkShell {
|
||||
|
||||
buildInputs = [
|
||||
packages = [
|
||||
pkgs.bash
|
||||
];
|
||||
|
||||
|
|
|
@ -4,10 +4,10 @@
|
|||
elpaBuild {
|
||||
pname = "org";
|
||||
ename = "org";
|
||||
version = "20210503";
|
||||
version = "20210510";
|
||||
src = fetchurl {
|
||||
url = "https://orgmode.org/elpa/org-20210503.tar";
|
||||
sha256 = "0j9p834c67qzxbxz8s1n8l5blylrpb3jh9wywphlb6jgbgl0mw09";
|
||||
url = "https://orgmode.org/elpa/org-20210510.tar";
|
||||
sha256 = "015c68pk52vksar7kpyb0nkcyjihlczmpq4h5vdv8xayas2qlzc7";
|
||||
};
|
||||
packageRequires = [];
|
||||
meta = {
|
||||
|
@ -19,10 +19,10 @@
|
|||
elpaBuild {
|
||||
pname = "org-plus-contrib";
|
||||
ename = "org-plus-contrib";
|
||||
version = "20210503";
|
||||
version = "20210510";
|
||||
src = fetchurl {
|
||||
url = "https://orgmode.org/elpa/org-plus-contrib-20210503.tar";
|
||||
sha256 = "0k0wmnx2g919h3s9ynv1cvdlyxvydglslamlwph4xng4kzcr5lrk";
|
||||
url = "https://orgmode.org/elpa/org-plus-contrib-20210510.tar";
|
||||
sha256 = "0pdwjnpcsk75jv4qs8n4xia6vspwn6dndbdx9z7kq5vqz7w4ykmw";
|
||||
};
|
||||
packageRequires = [];
|
||||
meta = {
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
|
|||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/sunrise-commander/sunrise-commander/";
|
||||
description = "Two-pane file manager for Emacs based on Dired and inspired by MC";
|
||||
description = "Orthodox (two-pane) file manager for Emacs";
|
||||
license = licenses.gpl3Plus;
|
||||
maintainers = [ maintainers.AndersonTorres ];
|
||||
platforms = platforms.all;
|
||||
|
|
|
@ -29,7 +29,7 @@ let
|
|||
in [ promise semaphore ]);
|
||||
|
||||
in pkgs.mkShell {
|
||||
buildInputs = [
|
||||
packages = [
|
||||
pkgs.git
|
||||
pkgs.nix
|
||||
pkgs.bash
|
||||
|
|
3292
pkgs/applications/editors/neovim/neovide/Cargo.lock
generated
Normal file
3292
pkgs/applications/editors/neovim/neovide/Cargo.lock
generated
Normal file
File diff suppressed because it is too large
Load diff
115
pkgs/applications/editors/neovim/neovide/default.nix
Normal file
115
pkgs/applications/editors/neovim/neovide/default.nix
Normal file
|
@ -0,0 +1,115 @@
|
|||
{ rustPlatform
|
||||
, runCommand
|
||||
, lib
|
||||
, fetchFromGitHub
|
||||
, fetchgit
|
||||
, makeWrapper
|
||||
, pkg-config
|
||||
, python2
|
||||
, expat
|
||||
, openssl
|
||||
, SDL2
|
||||
, vulkan-loader
|
||||
, fontconfig
|
||||
, ninja
|
||||
, gn
|
||||
, llvmPackages
|
||||
, makeFontsConf
|
||||
}:
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "neovide";
|
||||
version = "20210515";
|
||||
|
||||
src =
|
||||
let
|
||||
repo = fetchFromGitHub {
|
||||
owner = "Kethku";
|
||||
repo = "neovide";
|
||||
rev = "0b976c3d28bbd24e6c83a2efc077aa96dde1e9eb";
|
||||
sha256 = "sha256-asaOxcAenKdy/yJvch3HFfgnrBnQagL02UpWYnz7sa8=";
|
||||
};
|
||||
in
|
||||
runCommand "source" { } ''
|
||||
cp -R ${repo} $out
|
||||
chmod -R +w $out
|
||||
# Reasons for patching Cargo.toml:
|
||||
# - I got neovide built with latest compatible skia-save version 0.35.1
|
||||
# and I did not try to get it with 0.32.1 working. Changing the skia
|
||||
# version is time consuming, because of manual dependecy tracking and
|
||||
# long compilation runs.
|
||||
sed -i $out/Cargo.toml \
|
||||
-e '/skia-safe/s;0.32.1;0.35.1;'
|
||||
cp ${./Cargo.lock} $out/Cargo.lock
|
||||
'';
|
||||
|
||||
cargoSha256 = "sha256-XMPRM3BAfCleS0LXQv03A3lQhlUhAP8/9PdVbAUnfG0=";
|
||||
|
||||
SKIA_OFFLINE_SOURCE_DIR =
|
||||
let
|
||||
repo = fetchFromGitHub {
|
||||
owner = "rust-skia";
|
||||
repo = "skia";
|
||||
# see rust-skia/Cargo.toml#package.metadata skia
|
||||
rev = "m86-0.35.0";
|
||||
sha256 = "sha256-uTSgtiEkbE9e08zYOkRZyiHkwOLr/FbBYkr2d+NZ8J0=";
|
||||
};
|
||||
# The externals for skia are taken from skia/DEPS
|
||||
externals = lib.mapAttrs (n: v: fetchgit v) (lib.importJSON ./skia-externals.json);
|
||||
in
|
||||
runCommand "source" { } (''
|
||||
cp -R ${repo} $out
|
||||
chmod -R +w $out
|
||||
|
||||
mkdir -p $out/third_party/externals
|
||||
cd $out/third_party/externals
|
||||
'' + (builtins.concatStringsSep "\n" (lib.mapAttrsToList (name: value: "cp -ra ${value} ${name}") externals)));
|
||||
|
||||
SKIA_OFFLINE_NINJA_COMMAND = "${ninja}/bin/ninja";
|
||||
SKIA_OFFLINE_GN_COMMAND = "${gn}/bin/gn";
|
||||
LIBCLANG_PATH = "${llvmPackages.libclang}/lib";
|
||||
|
||||
# test needs a valid fontconfig file
|
||||
FONTCONFIG_FILE = makeFontsConf { fontDirectories = [ ]; };
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
makeWrapper
|
||||
python2 # skia-bindings
|
||||
llvmPackages.clang # skia
|
||||
];
|
||||
|
||||
# All tests passes but at the end cargo prints for unknown reason:
|
||||
# error: test failed, to rerun pass '--bin neovide'
|
||||
# Increasing the loglevel did not help. In a nix-shell environment
|
||||
# the failure do not occure.
|
||||
doCheck = false;
|
||||
|
||||
buildInputs = [
|
||||
expat
|
||||
openssl
|
||||
SDL2
|
||||
fontconfig
|
||||
];
|
||||
|
||||
postFixup = ''
|
||||
wrapProgram $out/bin/neovide \
|
||||
--prefix LD_LIBRARY_PATH : ${vulkan-loader}/lib
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
for n in 16x16 32x32 48x48 256x256; do
|
||||
install -m444 -D "assets/neovide-$n.png" \
|
||||
"$out/share/icons/hicolor/$n/apps/neovide.png"
|
||||
done
|
||||
install -m444 -Dt $out/share/icons/hicolor/scalable/apps assets/neovide.svg
|
||||
install -m444 -Dt $out/share/applications assets/neovide.desktop
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "This is a simple graphical user interface for Neovim.";
|
||||
homepage = "https://github.com/Kethku/neovide";
|
||||
license = with licenses; [ mit ];
|
||||
maintainers = with maintainers; [ ck3d ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
37
pkgs/applications/editors/neovim/neovide/skia-externals.json
Normal file
37
pkgs/applications/editors/neovim/neovide/skia-externals.json
Normal file
|
@ -0,0 +1,37 @@
|
|||
{
|
||||
"expat": {
|
||||
"url": "https://chromium.googlesource.com/external/github.com/libexpat/libexpat.git",
|
||||
"rev": "e976867fb57a0cd87e3b0fe05d59e0ed63c6febb",
|
||||
"sha256": "sha256-akSh/Vo7s7m/7qePamGA7oiHEHT3D6JhCFMc27CgDFI="
|
||||
},
|
||||
"libjpeg-turbo": {
|
||||
"url": "https://chromium.googlesource.com/chromium/deps/libjpeg_turbo.git",
|
||||
"rev": "64fc43d52351ed52143208ce6a656c03db56462b",
|
||||
"sha256": "sha256-rk22wE83hxKbtZLhGwUIF4J816jHvWovgICdrKZi2Ig="
|
||||
},
|
||||
"icu": {
|
||||
"url": "https://chromium.googlesource.com/chromium/deps/icu.git",
|
||||
"rev": "dbd3825b31041d782c5b504c59dcfb5ac7dda08c",
|
||||
"sha256": "sha256-voMH+TdNx3dBHeH5Oky5OYmmLGJ2u+WrMrmAkjXJRTE="
|
||||
},
|
||||
"zlib": {
|
||||
"url": "https://chromium.googlesource.com/chromium/src/third_party/zlib",
|
||||
"rev": "eaf99a4e2009b0e5759e6070ad1760ac1dd75461",
|
||||
"sha256": "sha256-B4PgeSVBU/MSkPkXTu9jPIa37dNJPm2HpmiVf6XuOGE="
|
||||
},
|
||||
"harfbuzz": {
|
||||
"url": "https://chromium.googlesource.com/external/github.com/harfbuzz/harfbuzz.git",
|
||||
"rev": "3a74ee528255cc027d84b204a87b5c25e47bff79",
|
||||
"sha256": "sha256-/4UdoUj0bxj6+EfNE8ofjtWOn2VkseEfvdFah5rwwBM="
|
||||
},
|
||||
"libpng": {
|
||||
"url": "https://skia.googlesource.com/third_party/libpng.git",
|
||||
"rev": "386707c6d19b974ca2e3db7f5c61873813c6fe44",
|
||||
"sha256": "sha256-67kf5MBsnBBi0bOfX/RKL52xpaCWm/ampltAI+EeQ+c="
|
||||
},
|
||||
"libgifcodec": {
|
||||
"url": "https://skia.googlesource.com/libgifcodec",
|
||||
"rev": "d06d2a6d42baf6c0c91cacc28df2542a911d05fe",
|
||||
"sha256": "sha256-ke1X5iyj2ah2NqGVdFv8GuoRAzXg1aCeTdZwUM8wvCI="
|
||||
}
|
||||
}
|
|
@ -13,10 +13,10 @@ let
|
|||
archive_fmt = if system == "x86_64-darwin" then "zip" else "tar.gz";
|
||||
|
||||
sha256 = {
|
||||
x86_64-linux = "0l4lx5h2daw9c5vl4kz6sq2i58b45xy4948x4q0wnwbqdqlqc9s4";
|
||||
x86_64-darwin = "0qqgs7vns52bz9xkys822sjjkvyq4l20iipz6sx5kinxg6h04jyy";
|
||||
aarch64-linux = "1gnh5kk4r0kfik9yfvvcbavhws4n8kn89kyl2qzpa2ryy52kk81j";
|
||||
armv7l-linux = "0zz5fn9nxq58i3svhgc25s6fdz7i3rxc0naflyx1jzmpzipp4v6n";
|
||||
x86_64-linux = "08qrag9nzmngzzvs2cgbmc4zzxlb9kwn183v8caj6dvcrjvfqgbv";
|
||||
x86_64-darwin = "0rlyr08lla3xadlh373xqcks8a9akk3x2cmakgn17q2b16988fmq";
|
||||
aarch64-linux = "1m277940xsasqac4i88s05xrqsab99jhl3ka0zzfbixrgr2dj8q1";
|
||||
armv7l-linux = "1qm4cggjj50vdnrx848x810gz3ahh0hndra22lsvcjdbsw8g35rk";
|
||||
}.${system};
|
||||
in
|
||||
callPackage ./generic.nix rec {
|
||||
|
@ -25,7 +25,7 @@ in
|
|||
|
||||
# Please backport all compatible updates to the stable release.
|
||||
# This is important for the extension ecosystem.
|
||||
version = "1.56.1";
|
||||
version = "1.56.2";
|
||||
pname = "vscode";
|
||||
|
||||
executableName = "code" + lib.optionalString isInsiders "-insiders";
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{ lib, stdenv, fetchFromGitHub, pkg-config, libtool
|
||||
, bzip2, zlib, libX11, libXext, libXt, fontconfig, freetype, ghostscript, libjpeg, djvulibre
|
||||
, lcms2, openexr, libpng, librsvg, libtiff, libxml2, openjpeg, libwebp, fftw, libheif, libde265
|
||||
, ApplicationServices
|
||||
, ApplicationServices, Foundation
|
||||
}:
|
||||
|
||||
let
|
||||
|
@ -50,7 +50,8 @@ stdenv.mkDerivation rec {
|
|||
]
|
||||
++ lib.optionals (!stdenv.hostPlatform.isMinGW)
|
||||
[ openexr librsvg openjpeg ]
|
||||
++ lib.optional stdenv.isDarwin ApplicationServices;
|
||||
++ lib.optionals stdenv.isDarwin
|
||||
[ ApplicationServices Foundation ];
|
||||
|
||||
propagatedBuildInputs =
|
||||
[ bzip2 freetype libjpeg lcms2 fftw ]
|
||||
|
|
|
@ -9,11 +9,13 @@ stdenv.mkDerivation rec {
|
|||
sha256 = "0ihwrx4gspj8l7fc8vxch6dpjrw1lvv9z3c19f0wxnmnxhv1cjvs";
|
||||
};
|
||||
|
||||
NIX_CFLAGS_COMPILE = builtins.toString [
|
||||
"-Wno-error=format-truncation"
|
||||
"-Wno-error=deprecated-declarations"
|
||||
"-Wno-error=stringop-overflow"
|
||||
];
|
||||
NIX_CFLAGS_COMPILE = builtins.toString (
|
||||
[ "-Wno-error=deprecated-declarations" ]
|
||||
++ lib.optionals (!stdenv.cc.isClang) [
|
||||
"-Wno-error=format-truncation"
|
||||
"-Wno-error=stringop-overflow"
|
||||
]
|
||||
);
|
||||
|
||||
buildInputs = [ openssl ];
|
||||
|
||||
|
|
|
@ -2,11 +2,11 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gpsprune";
|
||||
version = "20.3";
|
||||
version = "20.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://activityworkshop.net/software/gpsprune/gpsprune_${version}.jar";
|
||||
sha256 = "sha256-hmAksLPQxzB4O+ET+O/pmL/J4FG4+Dt0ulSsgjBWKxw=";
|
||||
sha256 = "sha256-ZTYkKyu0/axf2uLUmQHRW/2bQ6p2zK7xBF66ozbPS2c=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
|
|
@ -2,10 +2,10 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gremlin-console";
|
||||
version = "3.4.10";
|
||||
version = "3.5.0";
|
||||
src = fetchzip {
|
||||
url = "http://www-eu.apache.org/dist/tinkerpop/${version}/apache-tinkerpop-gremlin-console-${version}-bin.zip";
|
||||
sha256 = "sha256-4/EcVjIc+8OMkll8OxE5oXiqk+w9k1Nv9ld8N7oFFp0=";
|
||||
url = "https://downloads.apache.org/tinkerpop/${version}/apache-tinkerpop-gremlin-console-${version}-bin.zip";
|
||||
sha256 = "sha256-aVhDbOYhgYaWjttGjJvBKbov7OGWh2/llBTePFPGXDM=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
|
|
@ -1,46 +1,59 @@
|
|||
{ fetchFromGitHub, lib, gobject-introspection, gtk3, python3Packages }:
|
||||
# Although we copy in the udev rules here, you probably just want to use logitech-udev-rules instead of
|
||||
# adding this to services.udev.packages on NixOS
|
||||
|
||||
# Although we copy in the udev rules here, you probably just want to use
|
||||
# logitech-udev-rules instead of adding this to services.udev.packages on NixOS
|
||||
python3Packages.buildPythonApplication rec {
|
||||
pname = "solaar";
|
||||
version = "1.0.2";
|
||||
version = "1.0.5";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "pwr-Solaar";
|
||||
repo = "Solaar";
|
||||
rev = version;
|
||||
sha256 = "0k5z9dap6rawiafkg1x7zjx51ala7wra6j6lvc2nn0y8r79yp7a9";
|
||||
sha256 = "sha256-k87DqIkvy5CVEsHT82ZArSM2JBi5sYdSCPfP4KjI850=";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = with python3Packages; [ gobject-introspection gtk3 pygobject3 pyudev ];
|
||||
propagatedBuildInputs = with python3Packages; [
|
||||
gobject-introspection
|
||||
gtk3
|
||||
psutil
|
||||
pygobject3
|
||||
pyudev
|
||||
pyyaml
|
||||
xlib
|
||||
];
|
||||
|
||||
makeWrapperArgs = [
|
||||
"--prefix PYTHONPATH : $PYTHONPATH"
|
||||
"--prefix GI_TYPELIB_PATH : $GI_TYPELIB_PATH"
|
||||
];
|
||||
|
||||
# the -cli symlink is just to maintain compabilility with older versions where
|
||||
# there was a difference between the GUI and CLI versions.
|
||||
postInstall = ''
|
||||
wrapProgram "$out/bin/solaar" \
|
||||
--prefix PYTHONPATH : "$PYTHONPATH" \
|
||||
--prefix GI_TYPELIB_PATH : "$GI_TYPELIB_PATH"
|
||||
wrapProgram "$out/bin/solaar-cli" \
|
||||
--prefix PYTHONPATH : "$PYTHONPATH" \
|
||||
--prefix GI_TYPELIB_PATH : "$GI_TYPELIB_PATH"
|
||||
ln -s $out/bin/solaar $out/bin/solaar-cli
|
||||
|
||||
install -Dm644 -t $out/etc/udev/rules.d rules.d/*.rules
|
||||
install -Dm444 -t $out/etc/udev/rules.d rules.d/*.rules
|
||||
'';
|
||||
|
||||
enableParallelBuilding = true;
|
||||
# No tests
|
||||
doCheck = false;
|
||||
|
||||
meta = with lib; {
|
||||
description = "Linux devices manager for the Logitech Unifying Receiver";
|
||||
longDescription = ''
|
||||
Solaar is a Linux device manager for Logitech’s Unifying Receiver
|
||||
peripherals. It is able to pair/unpair devices to the receiver, and for
|
||||
most devices read battery status.
|
||||
Solaar is a Linux manager for many Logitech keyboards, mice, and trackpads that
|
||||
connect wirelessly to a USB Unifying, Lightspeed, or Nano receiver, connect
|
||||
directly via a USB cable, or connect via Bluetooth. Solaar does not work with
|
||||
peripherals from other companies.
|
||||
|
||||
It comes in two flavors, command-line and GUI. Both are able to list the
|
||||
devices paired to a Unifying Receiver, show detailed info for each
|
||||
device, and also pair/unpair supported devices with the receiver.
|
||||
Solaar can be used as a GUI application or via its command-line interface.
|
||||
|
||||
To be able to use it, make sure you have access to /dev/hidraw* files.
|
||||
This tool requires either to be run with root/sudo or alternatively to have the udev rules files installed. On NixOS this can be achieved by setting `hardware.logitech.wireless.enable`.
|
||||
'';
|
||||
license = licenses.gpl2;
|
||||
homepage = "https://pwr-solaar.github.io/Solaar/";
|
||||
platforms = platforms.linux;
|
||||
license = licenses.gpl2Only;
|
||||
maintainers = with maintainers; [ spinus ysndr ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -7,16 +7,16 @@
|
|||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "stork";
|
||||
version = "1.2.0";
|
||||
version = "1.2.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "jameslittle230";
|
||||
repo = "stork";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-gPrXeS7XT38Dil/EBwmeKIJrmPlEK+hmiyHi4p28tl0=";
|
||||
sha256 = "sha256-rox8X+lYiiCXO66JemW+R2I6y/IxdK6qpaiFXYoL6nY=";
|
||||
};
|
||||
|
||||
cargoSha256 = "sha256-9YKCtryb9mTPz9iWE7Iuk2SKgV0knWRbaouF+1DCjv8=";
|
||||
cargoSha256 = "sha256-ujmBAld6DCc1l+yUu9qhRF8pS5HoIlstcdPTeTAyyXs=";
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
|
|
|
@ -1,19 +1,17 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, fetchsvn
|
||||
, makeWrapper
|
||||
, makeDesktopItem
|
||||
# sweethome3d 6.4.2 does not yet build with jdk 9 and later.
|
||||
# this is fixed on trunk (7699?) but let's build with jdk8 until then.
|
||||
# sweethome3d 6.5.2 does not yet fully build&run with jdk 9 and later?
|
||||
, jdk8
|
||||
# it can run on the latest stable jre fine though
|
||||
, jre
|
||||
, jre8
|
||||
, ant
|
||||
, gtk3
|
||||
, gsettings-desktop-schemas
|
||||
, p7zip
|
||||
, libXxf86vm
|
||||
, unzip
|
||||
}:
|
||||
|
||||
let
|
||||
|
@ -49,7 +47,7 @@ let
|
|||
patchelf --set-rpath ${libXxf86vm}/lib lib/java3d-1.6/linux/i586/libnativewindow_x11.so
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
nativeBuildInputs = [ makeWrapper unzip ];
|
||||
buildInputs = [ ant jdk8 p7zip gtk3 gsettings-desktop-schemas ];
|
||||
|
||||
buildPhase = ''
|
||||
|
@ -77,7 +75,7 @@ let
|
|||
# without it a "Profiles [GL4bc, GL3bc, GL2, GLES1] not available on device null"
|
||||
# exception is thrown on startup.
|
||||
# https://discourse.nixos.org/t/glx-not-recognised-after-mesa-update/6753
|
||||
makeWrapper ${jre}/bin/java $out/bin/$exec \
|
||||
makeWrapper ${jre8}/bin/java $out/bin/$exec \
|
||||
--set MESA_GL_VERSION_OVERRIDE 2.1 \
|
||||
--prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:${gtk3.out}/share:${gsettings-desktop-schemas}/share:$out/share:$GSETTINGS_SCHEMAS_PATH" \
|
||||
--add-flags "-Dsun.java2d.opengl=true -jar $out/share/java/${module}-${version}.jar -cp $out/share/java/Furniture.jar:$out/share/java/Textures.jar:$out/share/java/Help.jar -d${toString stdenv.hostPlatform.parsed.cpu.bits}"
|
||||
|
@ -102,14 +100,13 @@ in {
|
|||
|
||||
application = mkSweetHome3D rec {
|
||||
pname = lib.toLower module + "-application";
|
||||
version = "6.4.2";
|
||||
version = "6.5.2";
|
||||
module = "SweetHome3D";
|
||||
description = "Design and visualize your future home";
|
||||
license = lib.licenses.gpl2Plus;
|
||||
src = fetchsvn {
|
||||
url = "https://svn.code.sf.net/p/sweethome3d/code/tags/V_" + d2u version + "/SweetHome3D/";
|
||||
sha256 = "13rczayakwb5246hqnp8lnw61p0p7ywr2294bnlp4zwsrz1in9z4";
|
||||
rev = "7504";
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/sweethome3d/${module}-${version}-src.zip";
|
||||
sha256 = "1j0xm2vmcxxjmf12k8rfnisq9hd7hqaiyxrfbrbjxis9iq3kycp3";
|
||||
};
|
||||
desktopName = "Sweet Home 3D";
|
||||
icons = {
|
||||
|
|
|
@ -1,17 +1,17 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchcvs
|
||||
, fetchurl
|
||||
, makeWrapper
|
||||
, makeDesktopItem
|
||||
# sweethome3d 6.4.2 does not yet build with jdk 9 and later.
|
||||
# this is fixed on trunk (7699?) but let's build with jdk8 until then.
|
||||
# sweethome3d 6.5.2 does not yet fully build&run with jdk 9 and later?
|
||||
, jdk8
|
||||
# it can run on the latest stable jre fine though
|
||||
, jre
|
||||
, jre8
|
||||
, ant
|
||||
, gtk3
|
||||
, gsettings-desktop-schemas
|
||||
, sweethome3dApp }:
|
||||
, sweethome3dApp
|
||||
, unzip
|
||||
}:
|
||||
|
||||
let
|
||||
|
||||
|
@ -20,6 +20,14 @@ let
|
|||
+ removeSuffix "libraryeditor" (toLower m)
|
||||
+ "-editor";
|
||||
|
||||
applicationSrc = stdenv.mkDerivation {
|
||||
name = "application-src";
|
||||
src = sweethome3dApp.src;
|
||||
nativeBuildInputs = [ unzip ];
|
||||
buildPhase = "";
|
||||
installPhase = "cp -r . $out";
|
||||
};
|
||||
|
||||
mkEditorProject =
|
||||
{ pname, module, version, src, license, description, desktopName }:
|
||||
|
||||
|
@ -35,18 +43,18 @@ let
|
|||
categories = "Graphics;2DGraphics;3DGraphics;";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
buildInputs = [ ant jre jdk8 gtk3 gsettings-desktop-schemas ];
|
||||
nativeBuildInputs = [ makeWrapper unzip ];
|
||||
buildInputs = [ ant jre8 jdk8 gtk3 gsettings-desktop-schemas ];
|
||||
|
||||
postPatch = ''
|
||||
sed -i -e 's,../SweetHome3D,${application.src},g' build.xml
|
||||
sed -i -e 's,../SweetHome3D,${applicationSrc},g' build.xml
|
||||
sed -i -e 's,lib/macosx/java3d-1.6/jogl-all.jar,lib/java3d-1.6/jogl-all.jar,g' build.xml
|
||||
'';
|
||||
|
||||
buildPhase = ''
|
||||
runHook preBuild
|
||||
|
||||
ant -lib ${application.src}/libtest -lib ${application.src}/lib -lib ${jdk8}/lib
|
||||
ant -lib ${applicationSrc}/libtest -lib ${applicationSrc}/lib -lib ${jdk8}/lib
|
||||
|
||||
runHook postBuild
|
||||
'';
|
||||
|
@ -56,7 +64,7 @@ let
|
|||
mkdir -p $out/share/{java,applications}
|
||||
cp ${module}-${version}.jar $out/share/java/.
|
||||
cp "${editorItem}/share/applications/"* $out/share/applications
|
||||
makeWrapper ${jre}/bin/java $out/bin/$exec \
|
||||
makeWrapper ${jre8}/bin/java $out/bin/$exec \
|
||||
--prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:${gtk3.out}/share:${gsettings-desktop-schemas}/share:$out/share:$GSETTINGS_SCHEMAS_PATH" \
|
||||
--add-flags "-jar $out/share/java/${module}-${version}.jar -d${toString stdenv.hostPlatform.parsed.cpu.bits}"
|
||||
'';
|
||||
|
@ -78,31 +86,27 @@ let
|
|||
in {
|
||||
|
||||
textures-editor = mkEditorProject rec {
|
||||
version = "1.5";
|
||||
version = "1.7";
|
||||
module = "TexturesLibraryEditor";
|
||||
pname = module;
|
||||
description = "Easily create SH3T files and edit the properties of the texture images it contain";
|
||||
license = lib.licenses.gpl2Plus;
|
||||
src = fetchcvs {
|
||||
cvsRoot = ":pserver:anonymous@sweethome3d.cvs.sourceforge.net:/cvsroot/sweethome3d";
|
||||
sha256 = "15wxdns3hc8yq362x0rj53bcxran2iynxznfcb9js85psd94zq7h";
|
||||
module = module;
|
||||
tag = "V_" + d2u version;
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/sweethome3d/${module}-${version}-src.zip";
|
||||
sha256 = "03vb9y645qzffxxdhgbjb0d98k3lafxckg2vh2s86j62b6357d0h";
|
||||
};
|
||||
desktopName = "Sweet Home 3D - Textures Library Editor";
|
||||
};
|
||||
|
||||
furniture-editor = mkEditorProject rec {
|
||||
version = "1.19";
|
||||
version = "1.27";
|
||||
module = "FurnitureLibraryEditor";
|
||||
pname = module;
|
||||
description = "Quickly create SH3F files and edit the properties of the 3D models it contain";
|
||||
license = lib.licenses.gpl2;
|
||||
src = fetchcvs {
|
||||
cvsRoot = ":pserver:anonymous@sweethome3d.cvs.sourceforge.net:/cvsroot/sweethome3d";
|
||||
sha256 = "0rr4nqil1mngak3ds5vz7f1whrgcgzpk6fb0qcr5ljms0jx0ylvs";
|
||||
module = module;
|
||||
tag = "V_" + d2u version;
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/sweethome3d/${module}-${version}-src.zip";
|
||||
sha256 = "1zxbcn9awgax8lalzkc05f5yfwbgnrayc17fkyv5i19j4qb3r2a0";
|
||||
};
|
||||
desktopName = "Sweet Home 3D - Furniture Library Editor";
|
||||
};
|
||||
|
|
|
@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
|
|||
] ++ optional stdenv.isLinux libseccomp
|
||||
++ optional stdenv.isDarwin gtk-mac-integration;
|
||||
|
||||
doCheck = true;
|
||||
doCheck = !stdenv.isDarwin;
|
||||
|
||||
meta = {
|
||||
homepage = "https://git.pwmt.org/pwmt/zathura";
|
||||
|
|
|
@ -90,11 +90,11 @@ in
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "brave";
|
||||
version = "1.24.82";
|
||||
version = "1.24.85";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/brave/brave-browser/releases/download/v${version}/brave-browser_${version}_amd64.deb";
|
||||
sha256 = "iWUJ5yLWWQvg510Atf+Pd9ya/1NnMNW2Sp/RVFn4PCc=";
|
||||
sha256 = "jE9INGYz78Vyvps4ESimtH1rL4GdboAUtMx1p31XQGk=";
|
||||
};
|
||||
|
||||
dontConfigure = true;
|
||||
|
|
|
@ -44,9 +44,9 @@
|
|||
}
|
||||
},
|
||||
"ungoogled-chromium": {
|
||||
"version": "90.0.4430.93",
|
||||
"sha256": "0zimr975vp0v12zz1nqjwag3f0q147wrmdhpzgi4yf089rgwfbjk",
|
||||
"sha256bin64": "1vifcrrfv69i0q7qnnml43xr0c20bi22hfw6lygq3k2x70zdzgl6",
|
||||
"version": "90.0.4430.212",
|
||||
"sha256": "17nmhrkl81qqvzbh861k2mmifncx4wg1mv1fmn52f8gzn461vqdb",
|
||||
"sha256bin64": "1y33c5829s22yfj0qmsj8fpcxnjhcm3fsxz7744csfsa9cy4fjr7",
|
||||
"deps": {
|
||||
"gn": {
|
||||
"version": "2021-02-09",
|
||||
|
@ -55,8 +55,8 @@
|
|||
"sha256": "1941bzg37c4dpsk3sh6ga3696gpq6vjzpcw9rsnf6kdr9mcgdxvn"
|
||||
},
|
||||
"ungoogled-patches": {
|
||||
"rev": "90.0.4430.93-1",
|
||||
"sha256": "11adnd96iwkkri3yyzvxsq43gqsc12fvd87rvqqflj0irrdk98a0"
|
||||
"rev": "90.0.4430.212-1",
|
||||
"sha256": "05jh05a4g50ws7pr18dl5pwi95knygh6xywp7kyydir7wy1pbin8"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "cloudflared";
|
||||
version = "2021.3.3";
|
||||
version = "2021.5.6";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "cloudflare";
|
||||
repo = "cloudflared";
|
||||
rev = version;
|
||||
sha256 = "sha256-St2WBdy76OVFlYoY1RGwQj1WsUpPtsL7yX1MFwztKgs=";
|
||||
sha256 = "sha256-CwwdU5phnJGcSVXCoea3jZoSa9uoABJKL/Z1BsYUY1g=";
|
||||
};
|
||||
|
||||
vendorSha256 = null;
|
||||
|
|
|
@ -19,13 +19,13 @@ let
|
|||
in
|
||||
buildGoModule rec {
|
||||
pname = "argo";
|
||||
version = "3.0.2";
|
||||
version = "3.0.3";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "argoproj";
|
||||
repo = "argo";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-+LuBz58hTzi/hGwqX/0VMNYn/+SRYgnNefn3B3i7eEs=";
|
||||
sha256 = "sha256-6w0FwVmzICsjWH7lE2ZnIhictNFTpo8pQ2Wvsyn925A=";
|
||||
};
|
||||
|
||||
vendorSha256 = "sha256-YjVAoMyGKMHLGEPeOOkCKCzeWFiUsXfJIKcw5GYoljg=";
|
||||
|
|
|
@ -20,13 +20,13 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "kubernetes";
|
||||
version = "1.21.0";
|
||||
version = "1.21.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "kubernetes";
|
||||
repo = "kubernetes";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-5IUcKVbHxL5qb7M087sZSsd50t5zSaeWATnyLHkVsRU=";
|
||||
sha256 = "sha256-gJjCw28SqU49kIiRH+MZgeYN4VBgKVEaRPr5A/2c5Pc=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ removeReferencesTo makeWrapper which go rsync installShellFiles ];
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ lib, stdenv
|
||||
{ lib
|
||||
, stdenv
|
||||
, buildGoModule
|
||||
, fetchFromGitHub
|
||||
, go-bindata
|
||||
|
@ -11,9 +12,9 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "minikube";
|
||||
version = "1.19.0";
|
||||
version = "1.20.0";
|
||||
|
||||
vendorSha256 = "sha256-WGW2uz3YJIUjLsYQ6rXNvgJGLrZSIkEEk07llLzMVXA=";
|
||||
vendorSha256 = "sha256-ncgf2C4PZMoVMZIMDn9LwP2EDqg7T/WbUPRd/SqGGnU=";
|
||||
|
||||
doCheck = false;
|
||||
|
||||
|
@ -21,7 +22,7 @@ buildGoModule rec {
|
|||
owner = "kubernetes";
|
||||
repo = "minikube";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-F+nPSWX9gs/hvOR6g8MW4b+JW+w3ScDaaF/FLHbLspY=";
|
||||
sha256 = "sha256-TnvbO8OLjnI5WGy3QR4OZbesOBat2VsL7ElCnj2Tkmk=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ go-bindata installShellFiles pkg-config which ];
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{ pkgs ? import <nixpkgs> {} }:
|
||||
{ pkgs ? import <nixpkgs> { } }:
|
||||
|
||||
pkgs.mkShell {
|
||||
buildInputs = [
|
||||
packages = [
|
||||
pkgs.poetry2nix.cli
|
||||
pkgs.pkg-config
|
||||
pkgs.libvirt
|
||||
|
|
|
@ -6,6 +6,6 @@
|
|||
|
||||
callPackage ./generic.nix {
|
||||
inherit buildGoPackage nvidia_x11 nvidiaGpuSupport;
|
||||
version = "0.12.10";
|
||||
sha256 = "12hlzjkay7y1502nmfvq2qkhp9pq7vp4zxypawnh98qvxbzv149l";
|
||||
version = "0.12.12";
|
||||
sha256 = "0hz5fsqv8jh22zhs0r1yk0c4qf4sf11hmqg4db91kp2xrq72a0qg";
|
||||
}
|
||||
|
|
|
@ -6,6 +6,6 @@
|
|||
|
||||
callPackage ./generic.nix {
|
||||
inherit buildGoPackage nvidia_x11 nvidiaGpuSupport;
|
||||
version = "1.0.4";
|
||||
sha256 = "0znaxz9mzbqb59p6rwa5h89m344m2ci39jsx8dfh1v5fc17r0fcq";
|
||||
version = "1.0.5";
|
||||
sha256 = "06l56fi4fhplvl8v0i88q18yh1hwwd12fngnrflb91janbyk6p4l";
|
||||
}
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "terragrunt";
|
||||
version = "0.29.1";
|
||||
version = "0.29.2";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "gruntwork-io";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-fr33DRFZrUZQELYMf8z5ShOZobwylgoiW+yi6qdtFP4=";
|
||||
sha256 = "sha256-e4DwMphX8I37MShMt5nnoizfL919mJaFCkDGNeGXHbQ=";
|
||||
};
|
||||
|
||||
vendorSha256 = "sha256-qlSCQtiGHmlk3DyETMoQbbSYhuUSZTsvAnBKuDJI8x8=";
|
||||
|
|
|
@ -2,10 +2,10 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "davmail";
|
||||
version = "5.4.0";
|
||||
version = "5.5.1";
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/${pname}/${version}/${pname}-${version}-3135.zip";
|
||||
sha256 = "05n2j5canh046744arvni6yfdsandvjkld93w3p7rg116jrh19gq";
|
||||
url = "mirror://sourceforge/${pname}/${version}/${pname}-${version}-3299.zip";
|
||||
sha256 = "sha256-NN/TUOcUIifNzrJnZmtYhs6UVktjlfoOYJjYaMEQpI4=";
|
||||
};
|
||||
|
||||
sourceRoot = ".";
|
||||
|
@ -13,11 +13,13 @@ stdenv.mkDerivation rec {
|
|||
nativeBuildInputs = [ makeWrapper unzip ];
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
mkdir -p $out/share/davmail
|
||||
cp -vR ./* $out/share/davmail
|
||||
makeWrapper $out/share/davmail/davmail $out/bin/davmail \
|
||||
--prefix PATH : ${jre}/bin \
|
||||
--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ glib gtk2 libXtst ]}
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
|
@ -25,6 +27,6 @@ stdenv.mkDerivation rec {
|
|||
description = "A Java application which presents a Microsoft Exchange server as local CALDAV, IMAP and SMTP servers";
|
||||
maintainers = [ maintainers.hinton ];
|
||||
platforms = platforms.all;
|
||||
license = licenses.gpl2;
|
||||
license = licenses.gpl2Plus;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -2,16 +2,16 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "dnscontrol";
|
||||
version = "3.8.1";
|
||||
version = "3.9.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "StackExchange";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-x002p7wPKbcmr4uE04mgKBagHQV/maEo99Y2Jr7xgK4=";
|
||||
sha256 = "sha256-9lIjQaMYy0FGMkR29Es3BMIAcn+jQYudyFJHwezlXKM=";
|
||||
};
|
||||
|
||||
vendorSha256 = "sha256-lR5+xVi/ROOFoRWyK0h/8uiSP/joQ9Zr9kMaQ+sWNhM=";
|
||||
vendorSha256 = "sha256-thvbqDhLdY+g/byFHJ9Tdiw8WYRccu4X1Rb0pdhE34E=";
|
||||
|
||||
subPackages = [ "." ];
|
||||
|
||||
|
|
|
@ -20,19 +20,19 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "newsflash";
|
||||
version = "1.4.0";
|
||||
version = "1.4.1";
|
||||
|
||||
src = fetchFromGitLab {
|
||||
owner = "news-flash";
|
||||
repo = "news_flash_gtk";
|
||||
rev = version;
|
||||
hash = "sha256-EInI5Unaz9m8/gJ7vAzJVyMynJGq0KZh12dNK8r1wnY=";
|
||||
hash = "sha256-pskmvztKOwutXRHVnW5u68/0DAuV9Gb+Ovp2JbXiMYo=";
|
||||
};
|
||||
|
||||
cargoDeps = rustPlatform.fetchCargoTarball {
|
||||
inherit src;
|
||||
name = "${pname}-${version}";
|
||||
hash = "sha256-xrWZhjfYnO6M3LMTP6l3+oZOusvUWuRBDesIlsiEJ6s=";
|
||||
hash = "sha256-qq8cZplt5YWUwsXUShMDhQm3RGH2kCEBk64x6bOa50E=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
|
|
|
@ -5,12 +5,12 @@
|
|||
|
||||
let
|
||||
pname = "zulip";
|
||||
version = "5.6.0";
|
||||
version = "5.7.0";
|
||||
name = "${pname}-${version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/zulip/zulip-desktop/releases/download/v${version}/Zulip-${version}-x86_64.AppImage";
|
||||
sha256 = "19sdmkxxzaidb89m8k56p94hq2yaxwn9islzrzwb86f50hlrq46w";
|
||||
sha256 = "0yfr0n84p3jp8mnnqww2dqpcj9gd7rwpygpq4v10rmrnli18qygw";
|
||||
name="${pname}-${version}.AppImage";
|
||||
};
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ mkDerivation, lib, fetchFromGitHub, pkg-config, cmake, qtbase, qttools
|
||||
{ mkDerivation, lib, fetchFromGitHub, fetchpatch, pkg-config, cmake, qtbase, qttools
|
||||
, seafile-shared, jansson, libsearpc
|
||||
, withShibboleth ? true, qtwebengine }:
|
||||
|
||||
|
@ -13,6 +13,15 @@ mkDerivation rec {
|
|||
sha256 = "2vV+6ZXjVg81JVLfWeD0UK+RdmpBxBU2Ozx790WFSyw=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Fix compilation failure with "error: template with C linkage", fixes #122505
|
||||
(fetchpatch {
|
||||
url = "https://aur.archlinux.org/cgit/aur.git/plain/fix_build_with_glib2.diff?h=seafile-client&id=7be253aaa2bdb6771721f45aa08bc875c8001c5a";
|
||||
name = "fix_build_with_glib2.diff";
|
||||
sha256 = "0hl7rcqfr8k62c1pr133bp3j63b905izaaggmgvr1af4jibal05v";
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ pkg-config cmake ];
|
||||
buildInputs = [ qtbase qttools seafile-shared jansson libsearpc ]
|
||||
++ lib.optional withShibboleth qtwebengine;
|
||||
|
@ -29,6 +38,6 @@ mkDerivation rec {
|
|||
description = "Desktop client for Seafile, the Next-generation Open Source Cloud Storage";
|
||||
license = licenses.asl20;
|
||||
platforms = platforms.linux;
|
||||
maintainers = with maintainers; [ ];
|
||||
maintainers = with maintainers; [ eduardosm ];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
, unwrapped
|
||||
# If it's a minimal build, we don't want to wrap it with lndir and
|
||||
# wrapProgram..
|
||||
, wrap ? true
|
||||
, doWrap ? true
|
||||
# For the wrapper
|
||||
, makeWrapper
|
||||
# For lndir
|
||||
|
@ -138,7 +138,7 @@ let
|
|||
;
|
||||
pkgs = packages;
|
||||
};
|
||||
self = if wrap then
|
||||
self = if doWrap then
|
||||
stdenv.mkDerivation {
|
||||
inherit name passthru;
|
||||
buildInputs = [
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{ lib, stdenv, fetchFromGitLab, pkg-config, meson, ninja, wrapGAppsHook
|
||||
{ lib, stdenv, fetchFromGitLab, fetchpatch, pkg-config, meson, ninja
|
||||
, git, criterion, gtk3, libconfig, gnuplot, opencv, json-glib
|
||||
, fftwFloat, cfitsio, gsl, exiv2, librtprocess, wcslib, ffmpeg
|
||||
, libraw, libtiff, libpng, libjpeg, libheif, ffms
|
||||
, libraw, libtiff, libpng, libjpeg, libheif, ffms, wrapGAppsHook
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
@ -15,6 +15,14 @@ stdenv.mkDerivation rec {
|
|||
sha256 = "0h3slgpj6zdc0rwmyr9zb0vgf53283hpwb7h26skdswmggsk90i5";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Backport fix for broken build on glib-2.68
|
||||
(fetchpatch {
|
||||
url = "https://gitlab.com/free-astro/siril/-/commit/d319fceca5b00f156e1c5e3512d3ac1f41beb16a.diff";
|
||||
sha256 = "00lq9wq8z48ly3hmkgzfqbdjaxr0hzyl2qwbj45bdnxfwqragh5m";
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
meson ninja pkg-config git criterion wrapGAppsHook
|
||||
];
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "bowtie2";
|
||||
version = "2.4.2";
|
||||
version = "2.4.3";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "BenLangmead";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "11apzq7l1lk3yxw97g9dfr0gwnvfh58x6apifcblgd66gbip3y1y";
|
||||
sha256 = "sha256-uEKTB8935YY6lpXv2tJBQ1hrRk63vALLQb6SUXsVyhQ=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ lib, stdenv, fetchFromGitHub, makeWrapper, zlib, perl, perlPackages }:
|
||||
{ lib, stdenv, fetchFromGitHub, makeWrapper, zlib, perl, perlPackages, openmp }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "4.8.1";
|
||||
|
@ -14,8 +14,12 @@ stdenv.mkDerivation rec {
|
|||
propagatedBuildInputs = [ perl perlPackages.TextNSP perlPackages.PerlMagick ];
|
||||
|
||||
nativeBuildInputs = [ zlib makeWrapper ];
|
||||
buildInputs = lib.optional stdenv.cc.isClang openmp;
|
||||
|
||||
makeFlags = [ "PREFIX=$(out)/bin" ];
|
||||
makeFlags = [
|
||||
"CC=${stdenv.cc.targetPrefix}c++" # remove once https://github.com/weizhongli/cdhit/pull/114 is merged
|
||||
"PREFIX=$(out)/bin"
|
||||
];
|
||||
|
||||
preInstall = "mkdir -p $out/bin";
|
||||
|
||||
|
|
|
@ -15,84 +15,124 @@
|
|||
, boost
|
||||
, pkg-config
|
||||
, doxygen
|
||||
, graphviz
|
||||
, pcre
|
||||
, libpthreadstubs
|
||||
, libXdmcp
|
||||
, lndir
|
||||
|
||||
, util-linux
|
||||
, libselinux
|
||||
, libsepol
|
||||
, libthai
|
||||
, libdatrie
|
||||
, libxkbcommon
|
||||
, epoxy
|
||||
, dbus
|
||||
, at-spi2-core
|
||||
, libXtst
|
||||
|
||||
, swig
|
||||
, python
|
||||
, wxPython
|
||||
, opencascade
|
||||
, opencascade-occt
|
||||
, libngspice
|
||||
, valgrind
|
||||
|
||||
, stable
|
||||
, baseName
|
||||
, kicadSrc
|
||||
, kicadVersion
|
||||
, i18n
|
||||
, withOCE
|
||||
, opencascade
|
||||
, withOCC
|
||||
, opencascade-occt
|
||||
, withNgspice
|
||||
, libngspice
|
||||
, withScripting
|
||||
, swig
|
||||
, python
|
||||
, wxPython
|
||||
, debug
|
||||
, valgrind
|
||||
, sanitizeAddress
|
||||
, sanitizeThreads
|
||||
, withI18n
|
||||
, gtk3
|
||||
}:
|
||||
|
||||
assert lib.asserts.assertMsg (!(withOCE && stdenv.isAarch64)) "OCE fails a test on Aarch64";
|
||||
assert lib.asserts.assertMsg (!(withOCC && withOCE))
|
||||
"Only one of OCC and OCE may be enabled";
|
||||
assert lib.assertMsg (!(stable && (sanitizeAddress || sanitizeThreads)))
|
||||
"Only kicad-unstable(-small) supports address/thread sanitation";
|
||||
assert lib.assertMsg (!(sanitizeAddress && sanitizeThreads))
|
||||
"'sanitizeAddress' and 'sanitizeThreads' are mutually exclusive, use one.";
|
||||
let
|
||||
inherit (lib) optional optionals;
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "kicad-base";
|
||||
version = kicadVersion;
|
||||
version = if (stable) then kicadVersion else builtins.substring 0 10 src.rev;
|
||||
|
||||
src = kicadSrc;
|
||||
|
||||
# tagged releases don't have "unknown"
|
||||
# kicad nightlies use git describe --dirty
|
||||
# nix removes .git, so its approximated here
|
||||
# "-1" appended to indicate we're adding a patch
|
||||
postPatch = ''
|
||||
substituteInPlace CMakeModules/KiCadVersion.cmake \
|
||||
--replace "unknown" "${builtins.substring 0 10 src.rev}-1" \
|
||||
--replace "${version}" "${version}-1"
|
||||
--replace "unknown" "${builtins.substring 0 10 src.rev}" \
|
||||
'';
|
||||
|
||||
makeFlags = optional (debug) [ "CFLAGS+=-Og" "CFLAGS+=-ggdb" ];
|
||||
makeFlags = optionals (debug) [ "CFLAGS+=-Og" "CFLAGS+=-ggdb" ];
|
||||
|
||||
cmakeFlags =
|
||||
optionals (withScripting) [
|
||||
"-DKICAD_SCRIPTING=ON"
|
||||
"-DKICAD_SCRIPTING_MODULES=ON"
|
||||
"-DKICAD_SCRIPTING_PYTHON3=ON"
|
||||
"-DKICAD_SCRIPTING_WXPYTHON_PHOENIX=ON"
|
||||
]
|
||||
++ optional (!withScripting)
|
||||
"-DKICAD_SCRIPTING=OFF"
|
||||
++ optional (withNgspice) "-DKICAD_SPICE=ON"
|
||||
++ optional (!withOCE) "-DKICAD_USE_OCE=OFF"
|
||||
++ optional (!withOCC) "-DKICAD_USE_OCC=OFF"
|
||||
++ optionals (withOCE) [
|
||||
"-DKICAD_USE_OCE=ON"
|
||||
"-DOCE_DIR=${opencascade}"
|
||||
]
|
||||
++ optionals (withOCC) [
|
||||
"-DKICAD_USE_OCC=ON"
|
||||
"-DOCC_INCLUDE_DIR=${opencascade-occt}/include/opencascade"
|
||||
]
|
||||
++ optionals (debug) [
|
||||
"-DCMAKE_BUILD_TYPE=Debug"
|
||||
"-DKICAD_STDLIB_DEBUG=ON"
|
||||
"-DKICAD_USE_VALGRIND=ON"
|
||||
]
|
||||
;
|
||||
cmakeFlags = optionals (withScripting) [
|
||||
"-DKICAD_SCRIPTING=ON"
|
||||
"-DKICAD_SCRIPTING_MODULES=ON"
|
||||
"-DKICAD_SCRIPTING_PYTHON3=ON"
|
||||
"-DKICAD_SCRIPTING_WXPYTHON_PHOENIX=ON"
|
||||
]
|
||||
++ optional (!withScripting)
|
||||
"-DKICAD_SCRIPTING=OFF"
|
||||
++ optional (withNgspice) "-DKICAD_SPICE=ON"
|
||||
++ optional (!withOCE) "-DKICAD_USE_OCE=OFF"
|
||||
++ optional (!withOCC) "-DKICAD_USE_OCC=OFF"
|
||||
++ optionals (withOCE) [
|
||||
"-DKICAD_USE_OCE=ON"
|
||||
"-DOCE_DIR=${opencascade}"
|
||||
]
|
||||
++ optionals (withOCC) [
|
||||
"-DKICAD_USE_OCC=ON"
|
||||
"-DOCC_INCLUDE_DIR=${opencascade-occt}/include/opencascade"
|
||||
]
|
||||
++ optionals (debug) [
|
||||
"-DCMAKE_BUILD_TYPE=Debug"
|
||||
"-DKICAD_STDLIB_DEBUG=ON"
|
||||
"-DKICAD_USE_VALGRIND=ON"
|
||||
]
|
||||
++ optionals (sanitizeAddress) [
|
||||
"-DKICAD_SANITIZE_ADDRESS=ON"
|
||||
]
|
||||
++ optionals (sanitizeThreads) [
|
||||
"-DKICAD_SANITIZE_THREADS=ON"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake doxygen pkg-config lndir ];
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
doxygen
|
||||
graphviz
|
||||
pkg-config
|
||||
lndir
|
||||
]
|
||||
# wanted by configuration on linux, doesn't seem to affect performance
|
||||
# no effect on closure size
|
||||
++ optionals (stdenv.isLinux) [
|
||||
util-linux
|
||||
libselinux
|
||||
libsepol
|
||||
libthai
|
||||
libdatrie
|
||||
libxkbcommon
|
||||
epoxy
|
||||
dbus.daemon
|
||||
at-spi2-core
|
||||
libXtst
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
libGLU
|
||||
|
@ -100,6 +140,7 @@ stdenv.mkDerivation rec {
|
|||
zlib
|
||||
libX11
|
||||
wxGTK
|
||||
wxGTK.gtk
|
||||
pcre
|
||||
libXdmcp
|
||||
gettext
|
||||
|
@ -110,7 +151,6 @@ stdenv.mkDerivation rec {
|
|||
curl
|
||||
openssl
|
||||
boost
|
||||
gtk3
|
||||
]
|
||||
++ optionals (withScripting) [ swig python wxPython ]
|
||||
++ optional (withNgspice) libngspice
|
||||
|
|
|
@ -25,6 +25,8 @@
|
|||
, withScripting ? true
|
||||
, python3
|
||||
, debug ? false
|
||||
, sanitizeAddress ? false
|
||||
, sanitizeThreads ? false
|
||||
, with3d ? true
|
||||
, withI18n ? true
|
||||
, srcs ? { }
|
||||
|
@ -146,28 +148,28 @@ let
|
|||
};
|
||||
|
||||
python = python3;
|
||||
wxPython = python.pkgs.wxPython_4_0;
|
||||
wxPython = if (stable)
|
||||
then python.pkgs.wxPython_4_0
|
||||
else python.pkgs.wxPython_4_1;
|
||||
|
||||
inherit (lib) concatStringsSep flatten optionalString optionals;
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
|
||||
# Common libraries, referenced during runtime, via the wrapper.
|
||||
passthru.libraries = callPackages ./libraries.nix { inherit libSrc libVersion; };
|
||||
passthru.i18n = callPackage ./i18n.nix {
|
||||
src = i18nSrc;
|
||||
version = i18nVersion;
|
||||
};
|
||||
passthru.libraries = callPackages ./libraries.nix { inherit libSrc; };
|
||||
passthru.i18n = callPackage ./i18n.nix { src = i18nSrc; };
|
||||
base = callPackage ./base.nix {
|
||||
inherit stable baseName;
|
||||
inherit kicadSrc kicadVersion;
|
||||
inherit (passthru) i18n;
|
||||
inherit wxGTK python wxPython;
|
||||
inherit debug withI18n withOCC withOCE withNgspice withScripting;
|
||||
inherit withI18n withOCC withOCE withNgspice withScripting;
|
||||
inherit debug sanitizeAddress sanitizeThreads;
|
||||
};
|
||||
|
||||
inherit pname;
|
||||
version = kicadVersion;
|
||||
version = if (stable) then kicadVersion else builtins.substring 0 10 src.src.rev;
|
||||
|
||||
src = base;
|
||||
dontUnpack = true;
|
||||
|
@ -193,14 +195,31 @@ stdenv.mkDerivation rec {
|
|||
# wrapGAppsHook did these two as well, no idea if it matters...
|
||||
"--prefix XDG_DATA_DIRS : ${cups}/share"
|
||||
"--prefix GIO_EXTRA_MODULES : ${dconf}/lib/gio/modules"
|
||||
|
||||
# required to open a bug report link in firefox-wayland
|
||||
"--set-default MOZ_DBUS_REMOTE 1"
|
||||
]
|
||||
++ optionals (stable)
|
||||
[
|
||||
"--set-default KISYSMOD ${footprints}/share/kicad/modules"
|
||||
"--set-default KICAD_SYMBOL_DIR ${symbols}/share/kicad/library"
|
||||
"--set-default KICAD_TEMPLATE_DIR ${templates}/share/kicad/template"
|
||||
"--prefix KICAD_TEMPLATE_DIR : ${symbols}/share/kicad/template"
|
||||
"--prefix KICAD_TEMPLATE_DIR : ${footprints}/share/kicad/template"
|
||||
]
|
||||
++ optionals (with3d) [ "--set-default KISYS3DMOD ${packages3d}/share/kicad/modules/packages3d" ]
|
||||
++ optionals (stable && with3d) [ "--set-default KISYS3DMOD ${packages3d}/share/kicad/modules/packages3d" ]
|
||||
++ optionals (!stable)
|
||||
[
|
||||
"--set-default KICAD6_FOOTPRINT_DIR ${footprints}/share/kicad/modules"
|
||||
"--set-default KICAD6_SYMBOL_DIR ${symbols}/share/kicad/library"
|
||||
"--set-default KICAD6_TEMPLATE_DIR ${templates}/share/kicad/template"
|
||||
"--prefix KICAD6_TEMPLATE_DIR : ${symbols}/share/kicad/template"
|
||||
"--prefix KICAD6_TEMPLATE_DIR : ${footprints}/share/kicad/template"
|
||||
]
|
||||
++ optionals (!stable && with3d)
|
||||
[
|
||||
"--set-default KISYS3DMOD ${packages3d}/share/kicad/3dmodels"
|
||||
"--set-default KICAD6_3DMODEL_DIR ${packages3d}/share/kicad/3dmodels"
|
||||
]
|
||||
++ optionals (withNgspice) [ "--prefix LD_LIBRARY_PATH : ${libngspice}/lib" ]
|
||||
|
||||
# infinisil's workaround for #39493
|
||||
|
@ -238,6 +257,7 @@ stdenv.mkDerivation rec {
|
|||
postInstall = ''
|
||||
mkdir -p $out/share
|
||||
ln -s ${base}/share/applications $out/share/applications
|
||||
ln -s ${base}/share/metainfo $out/share/metainfo
|
||||
ln -s ${base}/share/icons $out/share/icons
|
||||
ln -s ${base}/share/mime $out/share/mime
|
||||
'';
|
||||
|
@ -260,8 +280,7 @@ stdenv.mkDerivation rec {
|
|||
The Programs handle Schematic Capture, and PCB Layout with Gerber output.
|
||||
'';
|
||||
license = lib.licenses.gpl3Plus;
|
||||
# berce seems inactive...
|
||||
maintainers = with lib.maintainers; [ evils kiwi berce ];
|
||||
maintainers = with lib.maintainers; [ evils kiwi ];
|
||||
# kicad is cross platform
|
||||
platforms = lib.platforms.all;
|
||||
# despite that, nipkgs' wxGTK for darwin is "wxmac"
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
, cmake
|
||||
, gettext
|
||||
, src
|
||||
, version
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
inherit src version;
|
||||
inherit src;
|
||||
|
||||
pname = "kicad-i18n";
|
||||
version = builtins.substring 0 10 src.rev;
|
||||
|
||||
nativeBuildInputs = [ cmake gettext ];
|
||||
meta = with lib; {
|
||||
|
|
|
@ -2,13 +2,12 @@
|
|||
, cmake
|
||||
, gettext
|
||||
, libSrc
|
||||
, libVersion
|
||||
}:
|
||||
let
|
||||
mkLib = name:
|
||||
stdenv.mkDerivation {
|
||||
pname = "kicad-${name}";
|
||||
version = libVersion;
|
||||
version = builtins.substring 0 10 (libSrc name).rev;
|
||||
|
||||
src = libSrc name;
|
||||
|
||||
|
|
|
@ -3,17 +3,17 @@
|
|||
{
|
||||
"kicad" = {
|
||||
kicadVersion = {
|
||||
version = "5.1.9";
|
||||
version = "5.1.10";
|
||||
src = {
|
||||
rev = "73d0e3b20dec05c4350efa5b69916eb29a7bfcb5";
|
||||
sha256 = "1cqh3bc9y140hbryfk9qavs2y3lj5sm9q0qjxcf4mm472afzckky";
|
||||
rev = "88a1d61d58fdd62149bd1e00984e01540148ca1b";
|
||||
sha256 = "10ix560bqy0lprnik1bprxw9ix4g8w2ipvyikx551ak9ryvgwjcc";
|
||||
};
|
||||
};
|
||||
libVersion = {
|
||||
version = "5.1.9";
|
||||
version = "5.1.10";
|
||||
libSources = {
|
||||
i18n.rev = "04f3231f60d55400cb81564b2cd465a57d5192d5";
|
||||
i18n.sha256 = "04jq1dcag6i2ljjfqrib65mn4wg4c4nmi7i946l3bywc0rkqsx1f";
|
||||
i18n.rev = "f081afe79be4660d5c49a9d674e3cb666d76d4d0";
|
||||
i18n.sha256 = "0y51l0r62cnxkvpc21732p3cx7pjvaqjih8193502hlv9kv1j9p6";
|
||||
symbols.rev = "6dec5004b6a2679c19d4857bda2f90c5ab3a5726";
|
||||
symbols.sha256 = "0n25rq32jwyigfw26faqraillwv6zbi2ywy26dkz5zqlf5xp56ad";
|
||||
templates.rev = "1ccbaf3704e8ff4030d0915f71e051af621ef7d7";
|
||||
|
@ -27,23 +27,23 @@
|
|||
};
|
||||
"kicad-unstable" = {
|
||||
kicadVersion = {
|
||||
version = "2020-12-23";
|
||||
version = "2021-05-13";
|
||||
src = {
|
||||
rev = "912657dd238ad78cfc5d9d5e426ea850d5554fb3";
|
||||
sha256 = "1p5kr4d4zpajwdmya1f351y1ix8qmvsx1hrnvhzh7yc3g72kgxah";
|
||||
rev = "8513ca974c28d76d9f74a7dc96601d98e66e87fd";
|
||||
sha256 = "1xlj6jwzwxsa14djqhj0csziii21mr9czvdj6fxqp6px84cifjsh";
|
||||
};
|
||||
};
|
||||
libVersion = {
|
||||
version = "2020-12-23";
|
||||
version = "2021-05-13";
|
||||
libSources = {
|
||||
i18n.rev = "e89d9a89bec59199c1ade56ee2556591412ab7b0";
|
||||
i18n.sha256 = "04zaqyhj3qr4ymyd3k5vjpcna64j8klpsygcgjcv29s3rdi8glfl";
|
||||
symbols.rev = "e538abb015b4f289910a6f26b2f1b9cb8bf2efdb";
|
||||
symbols.sha256 = "117y4cm46anlrnw6y6mdjgl1a5gab6h6m7cwx3q7qb284m9bs5gi";
|
||||
templates.rev = "32a4f6fab863976fdcfa232e3e08fdcf3323a954";
|
||||
templates.sha256 = "13r94dghrh9slpj7nkzv0zqv5hk49s6pxm4q5ndqx0y8037ivmhk";
|
||||
footprints.rev = "15ffd67e01257d4d8134dbd6708cb58977eeccbe";
|
||||
footprints.sha256 = "1ad5k3wh2zqfibrar7pd3g363jk2q51dvraxnq3zlxa2x4znh7mw";
|
||||
symbols.rev = "32de73ea01347a005790119eb4102c550815685c";
|
||||
symbols.sha256 = "0gj10v06rkxlxngc40d1sfmlcagy5p7jfxid0lch4w0wxfjmks7z";
|
||||
templates.rev = "073d1941c428242a563dcb5301ff5c7479fe9c71";
|
||||
templates.sha256 = "14p06m2zvlzzz2w74y83f2zml7mgv5dhy2nyfkpblanxawrzxv1x";
|
||||
footprints.rev = "8fa36dfa3423d8777472e3475c1c2b0b2069624f";
|
||||
footprints.sha256 = "138xfkr0prxw2djkwc1m4mlp9km99v12sivbqhm1jkq5yxngdbin";
|
||||
packages3d.rev = "d8b7e8c56d535f4d7e46373bf24c754a8403da1f";
|
||||
packages3d.sha256 = "0dh8ixg0w43wzj5h3164dz6l1vl4llwxhi3qcdgj1lgvrs28aywd";
|
||||
};
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ mkDerivation, lib, fetchurl, pkg-config, cmake, glib, boost, libsigrok
|
||||
{ mkDerivation, lib, fetchurl, fetchpatch, pkg-config, cmake, glib, boost, libsigrok
|
||||
, libsigrokdecode, libserialport, libzip, udev, libusb1, libftdi1, glibmm
|
||||
, pcre, librevisa, python3, qtbase, qtsvg
|
||||
}:
|
||||
|
@ -20,6 +20,15 @@ mkDerivation rec {
|
|||
qtbase qtsvg
|
||||
];
|
||||
|
||||
patches = [
|
||||
# Allow building with glib 2.68
|
||||
# PR at https://github.com/sigrokproject/pulseview/pull/39
|
||||
(fetchpatch {
|
||||
url = "https://github.com/sigrokproject/pulseview/commit/fb89dd11f2a4a08b73c498869789e38677181a8d.patch";
|
||||
sha256 = "07ifsis9jlc0jjp2d11f7hvw9kaxcbk0a57h2m4xsv1d7vzl9yfh";
|
||||
})
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Qt-based LA/scope/MSO GUI for sigrok (a signal analysis software suite)";
|
||||
homepage = "https://sigrok.org/";
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{ stdenv, lib, runCommand, patchelf, makeWrapper, pkg-config, curl
|
||||
, openssl, gmp, zlib, fetchFromGitHub, rustPlatform }:
|
||||
, openssl, gmp, zlib, fetchFromGitHub, rustPlatform, libiconv }:
|
||||
|
||||
let
|
||||
libPath = lib.makeLibraryPath [ gmp ];
|
||||
|
@ -21,7 +21,8 @@ rustPlatform.buildRustPackage rec {
|
|||
nativeBuildInputs = [ pkg-config makeWrapper ];
|
||||
|
||||
OPENSSL_NO_VENDOR = 1;
|
||||
buildInputs = [ curl zlib openssl ];
|
||||
buildInputs = [ curl zlib openssl ]
|
||||
++ lib.optional stdenv.isDarwin libiconv;
|
||||
|
||||
cargoBuildFlags = [ "--features no-self-update" ];
|
||||
|
||||
|
|
|
@ -3,11 +3,11 @@
|
|||
|
||||
buildPythonApplication rec {
|
||||
pname = "MAVProxy";
|
||||
version = "1.8.34";
|
||||
version = "1.8.36";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "b922c9b6cf4719667e195a02d8364ccebbe7966a9c18666f8ac22eae9d9e7a2c";
|
||||
sha256 = "1gc92gp45d9pcxhmc03kbnar61jxfpx50v3jhdrsflpzhxyhjz5g";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
|
@ -30,7 +30,7 @@ buildPythonApplication rec {
|
|||
meta = with lib; {
|
||||
description = "MAVLink proxy and command line ground station";
|
||||
homepage = "https://github.com/ArduPilot/MAVProxy";
|
||||
license = licenses.gpl3;
|
||||
license = licenses.gpl3Plus;
|
||||
maintainers = with maintainers; [ lopsided98 ];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
mkDerivation rec {
|
||||
pname = "qgroundcontrol";
|
||||
version = "4.1.2";
|
||||
version = "4.1.3";
|
||||
|
||||
qtInputs = [
|
||||
qtbase qtcharts qtlocation qtserialport qtsvg qtquickcontrols2
|
||||
|
@ -63,7 +63,7 @@ mkDerivation rec {
|
|||
owner = "mavlink";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "16q0g9b1kyan3qhhp5mmfnrx9h8q7qn83baplbiprqjgpvkxfll4";
|
||||
sha256 = "0fbf564vzckvy1dc8f6yd8vpnzwzsgynva13bl2ks06768rrq9fb";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
|
|
|
@ -13,13 +13,13 @@
|
|||
|
||||
python3.pkgs.buildPythonApplication rec {
|
||||
pname = "terminator";
|
||||
version = "2.1.0";
|
||||
version = "2.1.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "gnome-terminator";
|
||||
repo = "terminator";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-Rd5XieB7K2BkSzrAr6Kmoa30xuwvsGKpPrsG2wrU1o8=";
|
||||
sha256 = "1pfrzna30xv9yri6dsny1j5k35417m4hsg97c455vssywyl9w4jr";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{ lib, stdenv
|
||||
, fetchFromGitHub
|
||||
, rustPlatform
|
||||
, Security
|
||||
, libiconv, Security
|
||||
, pkg-config, openssl
|
||||
}:
|
||||
|
||||
|
@ -19,7 +19,8 @@ rustPlatform.buildRustPackage rec {
|
|||
cargoSha256 = "sha256-lvxEYjVMJoAFFRG5iVfGwxUeJObIxfEaWokk69l++nI=";
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
buildInputs = [ openssl ] ++ lib.optional stdenv.isDarwin Security;
|
||||
buildInputs = [ openssl ]
|
||||
++ lib.optionals stdenv.isDarwin [ libiconv Security ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Sync personal and work git repositories from multiple providers";
|
||||
|
|
|
@ -2,16 +2,16 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "lefthook";
|
||||
version = "0.7.4";
|
||||
version = "0.7.5";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
rev = "v${version}";
|
||||
owner = "evilmartians";
|
||||
repo = "lefthook";
|
||||
sha256 = "sha256-wW8Obh0YmAZHKrXLQ8364+TrAmLIYKRir2qXdWLtVkE=";
|
||||
sha256 = "sha256-IKrutZJhs2iuwhXoV+81rDoaSi/xdYRpIlF1YjGFGY4=";
|
||||
};
|
||||
|
||||
vendorSha256 = "sha256-XR7xJZfgt0Hx2DccdNlwEmuduuVU8IBR0pcIUyRhdko=";
|
||||
vendorSha256 = "sha256-Rp67FnFU27u85t02MIs7wZQoOa8oGsHVVPQ9OdIyTJg=";
|
||||
|
||||
doCheck = false;
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{ lib, stdenv, rustPlatform, cmake, fetchFromGitHub, pkg-config, openssl, Security }:
|
||||
{ lib, stdenv, rustPlatform, cmake, fetchFromGitHub, pkg-config, openssl
|
||||
, libiconv, Security }:
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "gitoxide";
|
||||
|
@ -14,8 +15,9 @@ rustPlatform.buildRustPackage rec {
|
|||
cargoSha256 = "0gw19zdxbkgnj1kcyqn1naj1dnhsx10j860m0xgs5z7bbvfg82p6";
|
||||
|
||||
nativeBuildInputs = [ cmake pkg-config ];
|
||||
buildInputs = [ openssl ]
|
||||
++ lib.optionals stdenv.isDarwin [ Security ];
|
||||
buildInputs = if stdenv.isDarwin
|
||||
then [ libiconv Security ]
|
||||
else [ openssl ];
|
||||
|
||||
# Needed to get openssl-sys to use pkg-config.
|
||||
OPENSSL_NO_VENDOR = 1;
|
||||
|
|
|
@ -3,13 +3,13 @@
|
|||
buildKodiBinaryAddon rec {
|
||||
pname = "inputstream-ffmpegdirect";
|
||||
namespace = "inputstream.ffmpegdirect";
|
||||
version = "1.21.2";
|
||||
version = "1.21.3";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "xbmc";
|
||||
repo = "inputstream.ffmpegdirect";
|
||||
rev = "${version}-${rel}";
|
||||
sha256 = "sha256-FXtjR/4/f434gp78PBSt+QrYtMYcnljO3Htxss/wH7U=";
|
||||
sha256 = "sha256-OShd6sPGXXu0rlSwuQFMWqrLscE6Y0I2eV2YJYyZNMs=";
|
||||
};
|
||||
|
||||
extraBuildInputs = [ bzip2 zlib kodi.ffmpeg ];
|
||||
|
|
|
@ -6,13 +6,13 @@
|
|||
buildKodiBinaryAddon rec {
|
||||
pname = "pvr-iptvsimple";
|
||||
namespace = "pvr.iptvsimple";
|
||||
version = "7.6.2";
|
||||
version = "7.6.4";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "kodi-pvr";
|
||||
repo = "pvr.iptvsimple";
|
||||
rev = "${version}-${rel}";
|
||||
sha256 = "sha256-MdgPUKkbqNt/WKUTrYNetlyUBQcYLSn0J8EHH2Z9I+g=";
|
||||
sha256 = "sha256-F2uvf3BChN4p4VV1vTMAAPwQchVI5paTdxSFEi0u9a0=";
|
||||
};
|
||||
|
||||
extraBuildInputs = [
|
||||
|
|
|
@ -38,15 +38,15 @@ assert usbSupport -> !udevSupport; # libusb-compat-0_1 won't be used if udev is
|
|||
assert gbmSupport || waylandSupport || x11Support;
|
||||
|
||||
let
|
||||
kodiReleaseDate = "20210219";
|
||||
kodiVersion = "19.0";
|
||||
kodiReleaseDate = "20210508";
|
||||
kodiVersion = "19.1";
|
||||
rel = "Matrix";
|
||||
|
||||
kodi_src = fetchFromGitHub {
|
||||
owner = "xbmc";
|
||||
repo = "xbmc";
|
||||
rev = "${kodiVersion}-${rel}";
|
||||
sha256 = "097dg6a7v4ia85jx1pmlpwzdpqcqxlrmniqd005q73zvgj67zc2p";
|
||||
rev = "v${kodiVersion}";
|
||||
sha256 = "0jh67vw3983lnfgqzqfislawwbpq0vxxk1ljsg7mar06mlwfxb7h";
|
||||
};
|
||||
|
||||
ffmpeg = stdenv.mkDerivation rec {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{ fetchurl, lib, stdenv }:
|
||||
|
||||
let
|
||||
version = "0.24.2";
|
||||
version = "0.24.3";
|
||||
|
||||
suffix = {
|
||||
x86_64-linux = "x86_64";
|
||||
|
@ -22,7 +22,7 @@ stdenv.mkDerivation {
|
|||
|
||||
sourceRoot = ".";
|
||||
src = dlbin {
|
||||
x86_64-linux = "0l7x9sfyx52n0mwrmicdcnhm8z10q57kk1a5wf459l8lvp59xw08";
|
||||
x86_64-linux = "sha256-i6NMVFoLm4hQJH7RnhfC0t+0DJCINoP5b/iCv9JyRdk=";
|
||||
aarch64-linux = "0m7xs12g97z1ipzaf7dgknf3azlah0p6bdr9i454azvzg955238b";
|
||||
};
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ stdenv, lib, fetchFromGitHub, makeWrapper, autoreconfHook,
|
||||
{ stdenv, lib, fetchFromGitHub, makeWrapper, autoreconfHook, fetchpatch,
|
||||
fuse, libmspack, openssl, pam, xercesc, icu, libdnet, procps, libtirpc, rpcsvc-proto,
|
||||
libX11, libXext, libXinerama, libXi, libXrender, libXrandr, libXtst,
|
||||
pkg-config, glib, gdk-pixbuf-xlib, gtk3, gtkmm3, iproute2, dbus, systemd, which,
|
||||
|
@ -23,6 +23,18 @@ stdenv.mkDerivation rec {
|
|||
buildInputs = [ fuse glib icu libdnet libmspack libtirpc openssl pam procps rpcsvc-proto xercesc ]
|
||||
++ lib.optionals withX [ gdk-pixbuf-xlib gtk3 gtkmm3 libX11 libXext libXinerama libXi libXrender libXrandr libXtst ];
|
||||
|
||||
patches = [
|
||||
# Fix building with glib 2.68. Remove after next release.
|
||||
# We drop AUTHORS due to conflicts when applying.
|
||||
# https://github.com/vmware/open-vm-tools/pull/505
|
||||
(fetchpatch {
|
||||
url = "https://github.com/vmware/open-vm-tools/commit/82931a1bcb39d5132910c7fb2ddc086c51d06662.patch";
|
||||
stripLen = 1;
|
||||
excludes = [ "AUTHORS" ];
|
||||
sha256 = "0yz5hnngr5vd4416hvmh8734a9vxa18d2xd37kl7if0p9vik6zlg";
|
||||
})
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
# Build bugfix for 10.1.0, stolen from Arch PKGBUILD
|
||||
mkdir -p common-agent/etc/config
|
||||
|
|
|
@ -6,13 +6,13 @@
|
|||
|
||||
mkDerivation rec {
|
||||
pname = "virt-manager-qt";
|
||||
version = "0.71.95";
|
||||
version = "0.72.97";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "F1ash";
|
||||
repo = "qt-virt-manager";
|
||||
rev = version;
|
||||
sha256 = "1s8753bzsjyixpv1c2l9d1xjcn8i47k45qj7pr50prc64ldf5f47";
|
||||
sha256 = "0b2bx7ah35glcsiv186sc9cqdrkhg1vs9jz036k9byk61np0cb1i";
|
||||
};
|
||||
|
||||
cmakeFlags = [
|
||||
|
@ -22,10 +22,9 @@ mkDerivation rec {
|
|||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
# Maintainer note: Check whether this patch is still needed when a new version is released
|
||||
name = "krdc-variable-name-changes.patch";
|
||||
url = "https://github.com/fadenb/qt-virt-manager/commit/4640f5f64534ed7c8a1ecc6851f1c7503988de6d.patch";
|
||||
sha256 = "1chl58nra1mj96n8jmnjbsyr6vlwkhn38afhwqsbr0bgyg23781v";
|
||||
# drop with next update
|
||||
url = "https://github.com/F1ash/qt-virt-manager/commit/0d338b037ef58c376d468c1cd4521a34ea181edd.patch";
|
||||
sha256 = "1wjqyc5wsnxfwwjzgqjr9hcqhd867amwhjd712qyvpvz8x7p2s24";
|
||||
})
|
||||
];
|
||||
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
{ lib, stdenv, fetchurl, cmake, pkg-config, python3, libX11, libXext, libXinerama, libXrandr, libXft, freetype, asciidoc
|
||||
{ lib, stdenv, fetchurl, cmake, pkg-config, python3, libX11, libXext, libXinerama, libXrandr, libXft, libXrender, freetype, asciidoc
|
||||
, xdotool, xorgserver, xsetroot, xterm, runtimeShell
|
||||
, nixosTests }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "herbstluftwm";
|
||||
version = "0.9.2";
|
||||
version = "0.9.3";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://herbstluftwm.org/tarballs/herbstluftwm-${version}.tar.gz";
|
||||
sha256 = "0avfhr68f6fjnafjdcyxcx7dkg38f2nadmhpj971qyqzfq2f6i38";
|
||||
sha256 = "01f1bv9axjhw1l2gwhdwahljssj0h8q7a1bqwbpnwvln0ayv39qb";
|
||||
};
|
||||
|
||||
outputs = [
|
||||
|
@ -36,6 +36,7 @@ stdenv.mkDerivation rec {
|
|||
libXinerama
|
||||
libXrandr
|
||||
libXft
|
||||
libXrender
|
||||
freetype
|
||||
];
|
||||
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
stdenv.mkDerivation {
|
||||
pname = "kbdd";
|
||||
version = "unstable-2017-01-29";
|
||||
version = "unstable-2021-04-26";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "qnikst";
|
||||
repo = "kbdd";
|
||||
rev = "0e1056f066ab6e3c74fd0db0c9710a9a2b2538c3";
|
||||
sha256 = "068iqkqxh7928xlmz2pvnykszn9bcq2qgkkiwf37k1vm8fdmgzlj";
|
||||
rev = "3145099e1fbbe65b27678be72465aaa5b5872874";
|
||||
sha256 = "1gzcjnflgdqnjgphiqpzwbcx60hm0h2cprncm7i8xca3ln5q6ba1";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ autoreconfHook pkg-config ];
|
||||
|
@ -17,7 +17,7 @@ stdenv.mkDerivation {
|
|||
meta = {
|
||||
description = "Simple daemon and library to make per window layout using XKB";
|
||||
homepage = "https://github.com/qnikst/kbdd";
|
||||
license = lib.licenses.gpl3;
|
||||
license = lib.licenses.gpl2Plus;
|
||||
platforms = lib.platforms.linux;
|
||||
maintainers = [ lib.maintainers.wedens ];
|
||||
};
|
||||
|
|
|
@ -4,6 +4,8 @@
|
|||
, pango, cairo, libinput, libcap, pam, gdk-pixbuf, librsvg
|
||||
, wlroots, wayland-protocols, libdrm
|
||||
, nixosTests
|
||||
# Used by the NixOS module:
|
||||
, isNixOS ? false
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
@ -27,6 +29,10 @@ stdenv.mkDerivation rec {
|
|||
})
|
||||
];
|
||||
|
||||
postPatch = lib.optionalString isNixOS ''
|
||||
echo -e '\ninclude /etc/sway/config.d/*' >> config.in
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [
|
||||
meson ninja pkg-config wayland scdoc
|
||||
];
|
||||
|
|
|
@ -4,6 +4,8 @@
|
|||
, withBaseWrapper ? true, extraSessionCommands ? "", dbus
|
||||
, withGtkWrapper ? false, wrapGAppsHook, gdk-pixbuf, glib, gtk3
|
||||
, extraOptions ? [] # E.g.: [ "--verbose" ]
|
||||
# Used by the NixOS module:
|
||||
, isNixOS ? false
|
||||
}:
|
||||
|
||||
assert extraSessionCommands != "" -> withBaseWrapper;
|
||||
|
@ -11,6 +13,7 @@ assert extraSessionCommands != "" -> withBaseWrapper;
|
|||
with lib;
|
||||
|
||||
let
|
||||
sway = sway-unwrapped.override { inherit isNixOS; };
|
||||
baseWrapper = writeShellScriptBin "sway" ''
|
||||
set -o errexit
|
||||
if [ ! "$_SWAY_WRAPPER_ALREADY_EXECUTED" ]; then
|
||||
|
@ -20,16 +23,16 @@ let
|
|||
fi
|
||||
if [ "$DBUS_SESSION_BUS_ADDRESS" ]; then
|
||||
export DBUS_SESSION_BUS_ADDRESS
|
||||
exec ${sway-unwrapped}/bin/sway "$@"
|
||||
exec ${sway}/bin/sway "$@"
|
||||
else
|
||||
exec ${dbus}/bin/dbus-run-session ${sway-unwrapped}/bin/sway "$@"
|
||||
exec ${dbus}/bin/dbus-run-session ${sway}/bin/sway "$@"
|
||||
fi
|
||||
'';
|
||||
in symlinkJoin {
|
||||
name = "sway-${sway-unwrapped.version}";
|
||||
name = "sway-${sway.version}";
|
||||
|
||||
paths = (optional withBaseWrapper baseWrapper)
|
||||
++ [ sway-unwrapped ];
|
||||
++ [ sway ];
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ]
|
||||
++ (optional withGtkWrapper wrapGAppsHook);
|
||||
|
@ -49,5 +52,5 @@ in symlinkJoin {
|
|||
|
||||
passthru.providedSessions = [ "sway" ];
|
||||
|
||||
inherit (sway-unwrapped) meta;
|
||||
inherit (sway) meta;
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# Builder for Agda packages.
|
||||
|
||||
{ stdenv, lib, self, Agda, runCommandNoCC, makeWrapper, writeText, mkShell, ghcWithPackages, nixosTests }:
|
||||
{ stdenv, lib, self, Agda, runCommandNoCC, makeWrapper, writeText, ghcWithPackages, nixosTests }:
|
||||
|
||||
with lib.strings;
|
||||
|
||||
|
|
|
@ -3,18 +3,22 @@
|
|||
# A special kind of derivation that is only meant to be consumed by the
|
||||
# nix-shell.
|
||||
{
|
||||
inputsFrom ? [], # a list of derivations whose inputs will be made available to the environment
|
||||
buildInputs ? [],
|
||||
nativeBuildInputs ? [],
|
||||
propagatedBuildInputs ? [],
|
||||
propagatedNativeBuildInputs ? [],
|
||||
...
|
||||
# a list of packages to add to the shell environment
|
||||
packages ? [ ]
|
||||
, # propagate all the inputs from the given derivations
|
||||
inputsFrom ? [ ]
|
||||
, buildInputs ? [ ]
|
||||
, nativeBuildInputs ? [ ]
|
||||
, propagatedBuildInputs ? [ ]
|
||||
, propagatedNativeBuildInputs ? [ ]
|
||||
, ...
|
||||
}@attrs:
|
||||
let
|
||||
mergeInputs = name: lib.concatLists (lib.catAttrs name
|
||||
([attrs] ++ inputsFrom));
|
||||
([ attrs ] ++ inputsFrom));
|
||||
|
||||
rest = builtins.removeAttrs attrs [
|
||||
"packages"
|
||||
"inputsFrom"
|
||||
"buildInputs"
|
||||
"nativeBuildInputs"
|
||||
|
@ -26,15 +30,15 @@ in
|
|||
|
||||
stdenv.mkDerivation ({
|
||||
name = "nix-shell";
|
||||
phases = ["nobuildPhase"];
|
||||
phases = [ "nobuildPhase" ];
|
||||
|
||||
buildInputs = mergeInputs "buildInputs";
|
||||
nativeBuildInputs = mergeInputs "nativeBuildInputs";
|
||||
nativeBuildInputs = packages ++ (mergeInputs "nativeBuildInputs");
|
||||
propagatedBuildInputs = mergeInputs "propagatedBuildInputs";
|
||||
propagatedNativeBuildInputs = mergeInputs "propagatedNativeBuildInputs";
|
||||
|
||||
shellHook = lib.concatStringsSep "\n" (lib.catAttrs "shellHook"
|
||||
(lib.reverseList inputsFrom ++ [attrs]));
|
||||
(lib.reverseList inputsFrom ++ [ attrs ]));
|
||||
|
||||
nobuildPhase = ''
|
||||
echo
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "amber-theme";
|
||||
version = "3.36-2";
|
||||
version = "3.38-1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "lassekongo83";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "1g0hkv9sxfxfnpv8x7g64lr2by7wd4k216s3y9xpibsycdbwpyi5";
|
||||
sha256 = "sha256-OrdBeAD+gdIu6u8ESE9PtqYadSuJ8nx1Z8fB4D9y4W4=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ meson ninja sassc ];
|
||||
|
|
|
@ -1,9 +1,11 @@
|
|||
{ lib, stdenv
|
||||
, fetchFromGitHub
|
||||
, sassc
|
||||
, autoreconfHook
|
||||
, meson
|
||||
, ninja
|
||||
, pkg-config
|
||||
, gtk3
|
||||
, glib
|
||||
, gnome
|
||||
, gtk-engine-murrine
|
||||
, optipng
|
||||
|
@ -13,22 +15,24 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "arc-theme";
|
||||
version = "20210127";
|
||||
version = "20210412";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "jnsh";
|
||||
repo = pname;
|
||||
rev = version;
|
||||
sha256 = "sha256-P7YZTD5bAWNWepL7qsZZAMf8ujzNbHOj/SLx8Fw3bi4=";
|
||||
sha256 = "sha256-BNJirtBtdWsIzQfsJsZzg1zFbJEzZPq1j2qZ+1QjRH8=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
autoreconfHook
|
||||
meson
|
||||
ninja
|
||||
pkg-config
|
||||
sassc
|
||||
optipng
|
||||
inkscape
|
||||
gtk3
|
||||
glib # for glib-compile-resources
|
||||
];
|
||||
|
||||
propagatedUserEnvPkgs = [
|
||||
|
@ -36,23 +40,21 @@ stdenv.mkDerivation rec {
|
|||
gtk-engine-murrine
|
||||
];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
preBuild = ''
|
||||
# Shut up inkscape's warnings about creating profile directory
|
||||
export HOME="$NIX_BUILD_ROOT"
|
||||
'';
|
||||
|
||||
configureFlags = [
|
||||
"--with-cinnamon=${cinnamon.cinnamon-common.version}"
|
||||
"--with-gnome-shell=${gnome.gnome-shell.version}"
|
||||
"--disable-unity"
|
||||
mesonFlags = [
|
||||
"-Dthemes=cinnamon,gnome-shell,gtk2,gtk3,plank,xfwm"
|
||||
"-Dvariants=light,darker,dark,lighter"
|
||||
"-Dcinnamon_version=${cinnamon.cinnamon-common.version}"
|
||||
"-Dgnome_shell_version=${gnome.gnome-shell.version}"
|
||||
"-Dgtk3_version=${gtk3.version}"
|
||||
# You will need to patch gdm to make use of this.
|
||||
"-Dgnome_shell_gresource=true"
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
install -Dm644 -t $out/share/doc/${pname} AUTHORS *.md
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Flat theme with transparent elements for GTK 3, GTK 2 and Gnome Shell";
|
||||
homepage = "https://github.com/jnsh/arc-theme";
|
||||
|
|
|
@ -24,11 +24,11 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gnome-calendar";
|
||||
version = "40.0";
|
||||
version = "40.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://gnome/sources/${pname}/${lib.versions.major version}/${pname}-${version}.tar.xz";
|
||||
sha256 = "0d74hng9jdmwdcjgj4xfrcink2gwkbp1k1mad4wanaf7q31c6f38";
|
||||
sha256 = "2M30n57uHDo8aZHDL4VjxKfE2w23ymPOUcyRjkM7M6U=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue