Merge staging-next into staging
This commit is contained in:
commit
044fbf6429
@ -109,6 +109,10 @@ fb0e5be84331188a69b3edd31679ca6576edb75a
|
||||
# postgresql: move packages.nix to ext/default.nix
|
||||
719034f6f6749d624faa28dff259309fc0e3e730
|
||||
|
||||
# php ecosystem: reformat with nixfmt-rfc-style
|
||||
75ae7621330ff8db944ce4dff4374e182d5d151f
|
||||
c759efa5e7f825913f9a69ef20f025f50f56dc4d
|
||||
|
||||
# pkgs/os-specific/bsd: Reformat with nixfmt-rfc-style 2024-03-01
|
||||
3fe3b055adfc020e6a923c466b6bcd978a13069a
|
||||
|
||||
|
@ -330,7 +330,14 @@ Container system, boot system and library changes are some examples of the pull
|
||||
## How to merge pull requests
|
||||
[pr-merge]: #how-to-merge-pull-requests
|
||||
|
||||
The *Nixpkgs committers* are people who have been given
|
||||
To streamline automated updates, leverage the nixpkgs-merge-bot by simply commenting `@NixOS/nixpkgs-merge-bot merge`. The bot will verify if the following conditions are met, refusing to merge otherwise:
|
||||
|
||||
- the commenter that issued the command should be among the package maintainers;
|
||||
- the package should reside in `pkgs/by-name`.
|
||||
|
||||
Further, nixpkgs-merge-bot will ensure all ofBorg checks (except the Darwin-related ones) are successfully completed before merging the pull request. Should the checks still be underway, the bot patiently waits for ofBorg to finish before attempting the merge again.
|
||||
|
||||
For other pull requests, the *Nixpkgs committers* are people who have been given
|
||||
permission to merge.
|
||||
|
||||
It is possible for community members that have enough knowledge and experience on a special topic to contribute by merging pull requests.
|
||||
|
@ -105,7 +105,15 @@ in pkgs.stdenv.mkDerivation {
|
||||
ln -s ${optionsDoc.optionsJSON}/share/doc/nixos/options.json ./config-options.json
|
||||
'';
|
||||
|
||||
buildPhase = ''
|
||||
buildPhase = let
|
||||
pythonInterpreterTable = pkgs.callPackage ./doc-support/python-interpreter-table.nix {};
|
||||
pythonSection = with lib.strings; replaceStrings
|
||||
[ "@python-interpreter-table@" ]
|
||||
[ pythonInterpreterTable ]
|
||||
(readFile ./languages-frameworks/python.section.md);
|
||||
in ''
|
||||
cp ${builtins.toFile "python.section.md" pythonSection} ./languages-frameworks/python.section.md
|
||||
|
||||
cat \
|
||||
./functions/library.md.in \
|
||||
${lib-docs}/index.md \
|
||||
|
63
doc/doc-support/python-interpreter-table.nix
Normal file
63
doc/doc-support/python-interpreter-table.nix
Normal file
@ -0,0 +1,63 @@
|
||||
# For debugging, run in this directory:
|
||||
# nix eval --impure --raw --expr 'import ./python-interpreter-table.nix {}'
|
||||
{ pkgs ? (import ../.. { config = { }; overlays = []; }) }:
|
||||
let
|
||||
lib = pkgs.lib;
|
||||
inherit (lib.attrsets) attrNames filterAttrs;
|
||||
inherit (lib.lists) elem filter map naturalSort reverseList;
|
||||
inherit (lib.strings) concatStringsSep;
|
||||
|
||||
isPythonInterpreter = name:
|
||||
/* NB: Package names that don't follow the regular expression:
|
||||
- `python-cosmopolitan` is not part of `pkgs.pythonInterpreters`.
|
||||
- `_prebuilt` interpreters are used for bootstrapping internally.
|
||||
- `python3Minimal` contains python packages, left behind conservatively.
|
||||
- `rustpython` lacks `pythonVersion` and `implementation`.
|
||||
*/
|
||||
(lib.strings.match "(pypy|python)([[:digit:]]*)" name) != null;
|
||||
|
||||
interpreterName = pname:
|
||||
let
|
||||
cuteName = {
|
||||
cpython = "CPython";
|
||||
pypy = "PyPy";
|
||||
};
|
||||
interpreter = pkgs.${pname};
|
||||
in
|
||||
"${cuteName.${interpreter.implementation}} ${interpreter.pythonVersion}";
|
||||
|
||||
interpreters = reverseList (naturalSort (
|
||||
filter isPythonInterpreter (attrNames pkgs.pythonInterpreters)
|
||||
));
|
||||
|
||||
aliases = pname:
|
||||
attrNames (
|
||||
filterAttrs (name: value:
|
||||
isPythonInterpreter name
|
||||
&& name != pname
|
||||
&& interpreterName name == interpreterName pname
|
||||
) pkgs
|
||||
);
|
||||
|
||||
result = map (pname: {
|
||||
inherit pname;
|
||||
aliases = aliases pname;
|
||||
interpreter = interpreterName pname;
|
||||
}) interpreters;
|
||||
|
||||
toMarkdown = data:
|
||||
let
|
||||
line = package: ''
|
||||
| ${package.pname} | ${join ", " package.aliases or [ ]} | ${package.interpreter} |
|
||||
'';
|
||||
in
|
||||
join "" (map line data);
|
||||
|
||||
join = lib.strings.concatStringsSep;
|
||||
|
||||
in
|
||||
''
|
||||
| Package | Aliases | Interpeter |
|
||||
|---------|---------|------------|
|
||||
${toMarkdown result}
|
||||
''
|
@ -4,16 +4,7 @@
|
||||
|
||||
### Interpreters {#interpreters}
|
||||
|
||||
| Package | Aliases | Interpreter |
|
||||
|------------|-----------------|-------------|
|
||||
| python27 | python2, python | CPython 2.7 |
|
||||
| python39 | | CPython 3.9 |
|
||||
| python310 | | CPython 3.10 |
|
||||
| python311 | python3 | CPython 3.11 |
|
||||
| python312 | | CPython 3.12 |
|
||||
| python313 | | CPython 3.13 |
|
||||
| pypy27 | pypy2, pypy | PyPy2.7 |
|
||||
| pypy39 | pypy3 | PyPy 3.9 |
|
||||
@python-interpreter-table@
|
||||
|
||||
The Nix expressions for the interpreters can be found in
|
||||
`pkgs/development/interpreters/python`.
|
||||
|
@ -1,6 +1,6 @@
|
||||
{ lib, ... }:
|
||||
rec {
|
||||
/*
|
||||
/**
|
||||
`fix f` computes the fixed point of the given function `f`. In other words, the return value is `x` in `x = f x`.
|
||||
|
||||
`f` must be a lazy function.
|
||||
@ -63,27 +63,52 @@ rec {
|
||||
See [`extends`](#function-library-lib.fixedPoints.extends) for an example use case.
|
||||
There `self` is also often called `final`.
|
||||
|
||||
Type: fix :: (a -> a) -> a
|
||||
|
||||
Example:
|
||||
fix (self: { foo = "foo"; bar = "bar"; foobar = self.foo + self.bar; })
|
||||
=> { bar = "bar"; foo = "foo"; foobar = "foobar"; }
|
||||
# Inputs
|
||||
|
||||
fix (self: [ 1 2 (elemAt self 0 + elemAt self 1) ])
|
||||
=> [ 1 2 3 ]
|
||||
`f`
|
||||
|
||||
: 1\. Function argument
|
||||
|
||||
# Type
|
||||
|
||||
```
|
||||
fix :: (a -> a) -> a
|
||||
```
|
||||
|
||||
# Examples
|
||||
:::{.example}
|
||||
## `lib.fixedPoints.fix` usage example
|
||||
|
||||
```nix
|
||||
fix (self: { foo = "foo"; bar = "bar"; foobar = self.foo + self.bar; })
|
||||
=> { bar = "bar"; foo = "foo"; foobar = "foobar"; }
|
||||
|
||||
fix (self: [ 1 2 (elemAt self 0 + elemAt self 1) ])
|
||||
=> [ 1 2 3 ]
|
||||
```
|
||||
|
||||
:::
|
||||
*/
|
||||
fix = f: let x = f x; in x;
|
||||
|
||||
/*
|
||||
/**
|
||||
A variant of `fix` that records the original recursive attribute set in the
|
||||
result, in an attribute named `__unfix__`.
|
||||
|
||||
This is useful in combination with the `extends` function to
|
||||
implement deep overriding.
|
||||
|
||||
|
||||
# Inputs
|
||||
|
||||
`f`
|
||||
|
||||
: 1\. Function argument
|
||||
*/
|
||||
fix' = f: let x = f x // { __unfix__ = f; }; in x;
|
||||
|
||||
/*
|
||||
/**
|
||||
Return the fixpoint that `f` converges to when called iteratively, starting
|
||||
with the input `x`.
|
||||
|
||||
@ -92,7 +117,22 @@ rec {
|
||||
0
|
||||
```
|
||||
|
||||
Type: (a -> a) -> a -> a
|
||||
|
||||
# Inputs
|
||||
|
||||
`f`
|
||||
|
||||
: 1\. Function argument
|
||||
|
||||
`x`
|
||||
|
||||
: 2\. Function argument
|
||||
|
||||
# Type
|
||||
|
||||
```
|
||||
(a -> a) -> a -> a
|
||||
```
|
||||
*/
|
||||
converge = f: x:
|
||||
let
|
||||
@ -102,7 +142,7 @@ rec {
|
||||
then x
|
||||
else converge f x';
|
||||
|
||||
/*
|
||||
/**
|
||||
Extend a function using an overlay.
|
||||
|
||||
Overlays allow modifying and extending fixed-point functions, specifically ones returning attribute sets.
|
||||
@ -217,32 +257,50 @@ rec {
|
||||
```
|
||||
:::
|
||||
|
||||
Type:
|
||||
extends :: (Attrs -> Attrs -> Attrs) # The overlay to apply to the fixed-point function
|
||||
-> (Attrs -> Attrs) # A fixed-point function
|
||||
-> (Attrs -> Attrs) # The resulting fixed-point function
|
||||
|
||||
Example:
|
||||
f = final: { a = 1; b = final.a + 2; }
|
||||
# Inputs
|
||||
|
||||
fix f
|
||||
=> { a = 1; b = 3; }
|
||||
`overlay`
|
||||
|
||||
fix (extends (final: prev: { a = prev.a + 10; }) f)
|
||||
=> { a = 11; b = 13; }
|
||||
: The overlay to apply to the fixed-point function
|
||||
|
||||
fix (extends (final: prev: { b = final.a + 5; }) f)
|
||||
=> { a = 1; b = 6; }
|
||||
`f`
|
||||
|
||||
fix (extends (final: prev: { c = final.a + final.b; }) f)
|
||||
=> { a = 1; b = 3; c = 4; }
|
||||
: The fixed-point function
|
||||
|
||||
# Type
|
||||
|
||||
```
|
||||
extends :: (Attrs -> Attrs -> Attrs) # The overlay to apply to the fixed-point function
|
||||
-> (Attrs -> Attrs) # A fixed-point function
|
||||
-> (Attrs -> Attrs) # The resulting fixed-point function
|
||||
```
|
||||
|
||||
# Examples
|
||||
:::{.example}
|
||||
## `lib.fixedPoints.extends` usage example
|
||||
|
||||
```nix
|
||||
f = final: { a = 1; b = final.a + 2; }
|
||||
|
||||
fix f
|
||||
=> { a = 1; b = 3; }
|
||||
|
||||
fix (extends (final: prev: { a = prev.a + 10; }) f)
|
||||
=> { a = 11; b = 13; }
|
||||
|
||||
fix (extends (final: prev: { b = final.a + 5; }) f)
|
||||
=> { a = 1; b = 6; }
|
||||
|
||||
fix (extends (final: prev: { c = final.a + final.b; }) f)
|
||||
=> { a = 1; b = 3; c = 4; }
|
||||
```
|
||||
|
||||
:::
|
||||
*/
|
||||
extends =
|
||||
# The overlay to apply to the fixed-point function
|
||||
overlay:
|
||||
# The fixed-point function
|
||||
f:
|
||||
# Wrap with parenthesis to prevent nixdoc from rendering the `final` argument in the documentation
|
||||
# The result should be thought of as a function, the argument of that function is not an argument to `extends` itself
|
||||
(
|
||||
final:
|
||||
@ -252,10 +310,29 @@ rec {
|
||||
prev // overlay final prev
|
||||
);
|
||||
|
||||
/*
|
||||
/**
|
||||
Compose two extending functions of the type expected by 'extends'
|
||||
into one where changes made in the first are available in the
|
||||
'super' of the second
|
||||
|
||||
|
||||
# Inputs
|
||||
|
||||
`f`
|
||||
|
||||
: 1\. Function argument
|
||||
|
||||
`g`
|
||||
|
||||
: 2\. Function argument
|
||||
|
||||
`final`
|
||||
|
||||
: 3\. Function argument
|
||||
|
||||
`prev`
|
||||
|
||||
: 4\. Function argument
|
||||
*/
|
||||
composeExtensions =
|
||||
f: g: final: prev:
|
||||
@ -263,7 +340,7 @@ rec {
|
||||
prev' = prev // fApplied;
|
||||
in fApplied // g final prev';
|
||||
|
||||
/*
|
||||
/**
|
||||
Compose several extending functions of the type expected by 'extends' into
|
||||
one where changes made in preceding functions are made available to
|
||||
subsequent ones.
|
||||
@ -276,7 +353,7 @@ rec {
|
||||
composeManyExtensions =
|
||||
lib.foldr (x: y: composeExtensions x y) (final: prev: {});
|
||||
|
||||
/*
|
||||
/**
|
||||
Create an overridable, recursive attribute set. For example:
|
||||
|
||||
```
|
||||
@ -298,9 +375,20 @@ rec {
|
||||
*/
|
||||
makeExtensible = makeExtensibleWithCustomName "extend";
|
||||
|
||||
/*
|
||||
/**
|
||||
Same as `makeExtensible` but the name of the extending attribute is
|
||||
customized.
|
||||
|
||||
|
||||
# Inputs
|
||||
|
||||
`extenderName`
|
||||
|
||||
: 1\. Function argument
|
||||
|
||||
`rattrs`
|
||||
|
||||
: 2\. Function argument
|
||||
*/
|
||||
makeExtensibleWithCustomName = extenderName: rattrs:
|
||||
fix' (self: (rattrs self) // {
|
||||
|
@ -9963,6 +9963,12 @@
|
||||
githubId = 8580434;
|
||||
name = "Jonny Bolton";
|
||||
};
|
||||
jonochang = {
|
||||
name = "Jono Chang";
|
||||
email = "j.g.chang@gmail.com";
|
||||
github = "jonochang";
|
||||
githubId = 13179;
|
||||
};
|
||||
jonringer = {
|
||||
email = "jonringer117@gmail.com";
|
||||
matrix = "@jonringer:matrix.org";
|
||||
|
@ -135,6 +135,8 @@ The pre-existing [services.ankisyncd](#opt-services.ankisyncd.enable) has been m
|
||||
|
||||
- [nh](https://github.com/viperML/nh), yet another Nix CLI helper. Available as [programs.nh](#opt-programs.nh.enable).
|
||||
|
||||
- [oink](https://github.com/rlado/oink), a dynamic DNS client for Porkbun. Available as [services.oink](#opt-services.oink.enable).
|
||||
|
||||
- [ollama](https://ollama.ai), server for running large language models locally.
|
||||
|
||||
- [ownCloud Infinite Scale Stack](https://owncloud.com/infinite-scale-4-0/), a modern and scalable rewrite of ownCloud.
|
||||
|
@ -1109,6 +1109,7 @@
|
||||
./services/networking/ocserv.nix
|
||||
./services/networking/ofono.nix
|
||||
./services/networking/oidentd.nix
|
||||
./services/networking/oink.nix
|
||||
./services/networking/onedrive.nix
|
||||
./services/networking/openconnect.nix
|
||||
./services/networking/openvpn.nix
|
||||
|
@ -164,8 +164,11 @@ in
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
# TODO: drop with 24.11
|
||||
services.archisteamfarm.dataDir = lib.mkIf (lib.versionAtLeast config.system.stateVersion "24.05") (lib.mkDefault "/var/lib/asf");
|
||||
services.archisteamfarm = {
|
||||
# TODO: drop with 24.11
|
||||
dataDir = lib.mkIf (lib.versionAtLeast config.system.stateVersion "24.05") (lib.mkDefault "/var/lib/asf");
|
||||
settings.IPC = lib.mkIf (!cfg.web-ui.enable) false;
|
||||
};
|
||||
|
||||
users = {
|
||||
users.archisteamfarm = {
|
||||
|
@ -113,6 +113,9 @@ in
|
||||
nameValuePair "wyoming-faster-whisper-${server}" {
|
||||
inherit (options) enable;
|
||||
description = "Wyoming faster-whisper server instance ${server}";
|
||||
wants = [
|
||||
"network-online.target"
|
||||
];
|
||||
after = [
|
||||
"network-online.target"
|
||||
];
|
||||
|
@ -108,6 +108,9 @@ in
|
||||
config = mkIf cfg.enable {
|
||||
systemd.services."wyoming-openwakeword" = {
|
||||
description = "Wyoming openWakeWord server";
|
||||
wants = [
|
||||
"network-online.target"
|
||||
];
|
||||
after = [
|
||||
"network-online.target"
|
||||
];
|
||||
|
@ -117,6 +117,9 @@ in
|
||||
nameValuePair "wyoming-piper-${server}" {
|
||||
inherit (options) enable;
|
||||
description = "Wyoming Piper server instance ${server}";
|
||||
wants = [
|
||||
"network-online.target"
|
||||
];
|
||||
after = [
|
||||
"network-online.target"
|
||||
];
|
||||
|
@ -70,7 +70,9 @@ in {
|
||||
storage.lookup = mkDefault "db";
|
||||
storage.blob = mkDefault "blob";
|
||||
resolver.type = mkDefault "system";
|
||||
resolver.public-suffix = mkDefault ["https://publicsuffix.org/list/public_suffix_list.dat"];
|
||||
resolver.public-suffix = lib.mkDefault [
|
||||
"file://${pkgs.publicsuffix-list}/share/publicsuffix/public_suffix_list.dat"
|
||||
];
|
||||
};
|
||||
|
||||
systemd.services.stalwart-mail = {
|
||||
|
@ -278,6 +278,9 @@ in
|
||||
"https://kea.readthedocs.io/en/kea-${package.version}/arm/agent.html"
|
||||
];
|
||||
|
||||
wants = [
|
||||
"network-online.target"
|
||||
];
|
||||
after = [
|
||||
"network-online.target"
|
||||
"time-sync.target"
|
||||
|
84
nixos/modules/services/networking/oink.nix
Normal file
84
nixos/modules/services/networking/oink.nix
Normal file
@ -0,0 +1,84 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.services.oink;
|
||||
makeOinkConfig = attrs: (pkgs.formats.json { }).generate
|
||||
"oink.json" (mapAttrs' (k: v: nameValuePair (toLower k) v) attrs);
|
||||
oinkConfig = makeOinkConfig {
|
||||
global = cfg.settings;
|
||||
domains = cfg.domains;
|
||||
};
|
||||
in
|
||||
{
|
||||
options.services.oink = {
|
||||
enable = mkEnableOption "Oink, a dynamic DNS client for Porkbun";
|
||||
package = mkPackageOption pkgs "oink" { };
|
||||
settings = {
|
||||
apiKey = mkOption {
|
||||
type = types.str;
|
||||
description = "API key to use when modifying DNS records.";
|
||||
};
|
||||
secretApiKey = mkOption {
|
||||
type = types.str;
|
||||
description = "Secret API key to use when modifying DNS records.";
|
||||
};
|
||||
interval = mkOption {
|
||||
# https://github.com/rlado/oink/blob/v1.1.1/src/main.go#L364
|
||||
type = types.ints.between 60 172800; # 48 hours
|
||||
default = 900;
|
||||
description = "Seconds to wait before sending another request.";
|
||||
};
|
||||
ttl = mkOption {
|
||||
type = types.ints.between 600 172800;
|
||||
default = 600;
|
||||
description = ''
|
||||
The TTL ("Time to Live") value to set for your DNS records.
|
||||
|
||||
The TTL controls how long in seconds your records will be cached
|
||||
for. A smaller value will allow the record to update quicker.
|
||||
'';
|
||||
};
|
||||
};
|
||||
domains = mkOption {
|
||||
type = with types; listOf (attrsOf anything);
|
||||
default = [];
|
||||
example = [
|
||||
{
|
||||
domain = "nixos.org";
|
||||
subdomain = "";
|
||||
ttl = 1200;
|
||||
}
|
||||
{
|
||||
domain = "nixos.org";
|
||||
subdomain = "hydra";
|
||||
}
|
||||
];
|
||||
description = ''
|
||||
List of attribute sets containing configuration for each domain.
|
||||
|
||||
Each attribute set must have two attributes, one named *domain*
|
||||
and another named *subdomain*. The domain attribute must specify
|
||||
the root domain that you want to configure, and the subdomain
|
||||
attribute must specify its subdomain if any. If you want to
|
||||
configure the root domain rather than a subdomain, leave the
|
||||
subdomain attribute as an empty string.
|
||||
|
||||
Additionally, you can use attributes from *services.oink.settings*
|
||||
to override settings per-domain.
|
||||
|
||||
Every domain listed here *must* have API access enabled in
|
||||
Porkbun's control panel.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
systemd.services.oink = {
|
||||
description = "Dynamic DNS client for Porkbun";
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
script = "${cfg.package}/bin/oink -c ${oinkConfig}";
|
||||
};
|
||||
};
|
||||
}
|
@ -80,6 +80,15 @@ let
|
||||
description = "Commands called at the end of the interface setup.";
|
||||
};
|
||||
|
||||
preShutdown = mkOption {
|
||||
example = literalExpression ''"''${pkgs.iproute2}/bin/ip netns del foo"'';
|
||||
default = "";
|
||||
type = with types; coercedTo (listOf str) (concatStringsSep "\n") lines;
|
||||
description = ''
|
||||
Commands called before shutting down the interface.
|
||||
'';
|
||||
};
|
||||
|
||||
postShutdown = mkOption {
|
||||
example = literalExpression ''"''${pkgs.openresolv}/bin/resolvconf -d wg0"'';
|
||||
default = "";
|
||||
@ -497,6 +506,7 @@ let
|
||||
'';
|
||||
|
||||
postStop = ''
|
||||
${values.preShutdown}
|
||||
${ipPostMove} link del dev "${name}"
|
||||
${values.postShutdown}
|
||||
'';
|
||||
|
@ -128,10 +128,14 @@ in
|
||||
contents."/etc/dbus-1".source = pkgs.makeDBusConf {
|
||||
inherit (cfg) apparmor;
|
||||
suidHelper = "/bin/false";
|
||||
serviceDirectories = [ pkgs.dbus ];
|
||||
serviceDirectories = [ pkgs.dbus config.boot.initrd.systemd.package ];
|
||||
};
|
||||
packages = [ pkgs.dbus ];
|
||||
storePaths = [ "${pkgs.dbus}/bin/dbus-daemon" ];
|
||||
storePaths = [
|
||||
"${pkgs.dbus}/bin/dbus-daemon"
|
||||
"${config.boot.initrd.systemd.package}/share/dbus-1/system-services"
|
||||
"${config.boot.initrd.systemd.package}/share/dbus-1/system.d"
|
||||
];
|
||||
targets.sockets.wants = [ "dbus.socket" ];
|
||||
};
|
||||
})
|
||||
|
@ -7,6 +7,20 @@ let
|
||||
dnsmasqResolve = config.services.dnsmasq.enable &&
|
||||
config.services.dnsmasq.resolveLocalQueries;
|
||||
|
||||
resolvedConf = ''
|
||||
[Resolve]
|
||||
${optionalString (config.networking.nameservers != [])
|
||||
"DNS=${concatStringsSep " " config.networking.nameservers}"}
|
||||
${optionalString (cfg.fallbackDns != null)
|
||||
"FallbackDNS=${concatStringsSep " " cfg.fallbackDns}"}
|
||||
${optionalString (cfg.domains != [])
|
||||
"Domains=${concatStringsSep " " cfg.domains}"}
|
||||
LLMNR=${cfg.llmnr}
|
||||
DNSSEC=${cfg.dnssec}
|
||||
DNSOverTLS=${cfg.dnsovertls}
|
||||
${config.services.resolved.extraConfig}
|
||||
'';
|
||||
|
||||
in
|
||||
{
|
||||
|
||||
@ -126,60 +140,87 @@ in
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
assertions = [
|
||||
{ assertion = !config.networking.useHostResolvConf;
|
||||
message = "Using host resolv.conf is not supported with systemd-resolved";
|
||||
}
|
||||
];
|
||||
|
||||
users.users.systemd-resolve.group = "systemd-resolve";
|
||||
|
||||
# add resolve to nss hosts database if enabled and nscd enabled
|
||||
# system.nssModules is configured in nixos/modules/system/boot/systemd.nix
|
||||
# added with order 501 to allow modules to go before with mkBefore
|
||||
system.nssDatabases.hosts = (mkOrder 501 ["resolve [!UNAVAIL=return]"]);
|
||||
|
||||
systemd.additionalUpstreamSystemUnits = [
|
||||
"systemd-resolved.service"
|
||||
];
|
||||
|
||||
systemd.services.systemd-resolved = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
aliases = [ "dbus-org.freedesktop.resolve1.service" ];
|
||||
restartTriggers = [ config.environment.etc."systemd/resolved.conf".source ];
|
||||
};
|
||||
|
||||
environment.etc = {
|
||||
"systemd/resolved.conf".text = ''
|
||||
[Resolve]
|
||||
${optionalString (config.networking.nameservers != [])
|
||||
"DNS=${concatStringsSep " " config.networking.nameservers}"}
|
||||
${optionalString (cfg.fallbackDns != null)
|
||||
"FallbackDNS=${concatStringsSep " " cfg.fallbackDns}"}
|
||||
${optionalString (cfg.domains != [])
|
||||
"Domains=${concatStringsSep " " cfg.domains}"}
|
||||
LLMNR=${cfg.llmnr}
|
||||
DNSSEC=${cfg.dnssec}
|
||||
DNSOverTLS=${cfg.dnsovertls}
|
||||
${config.services.resolved.extraConfig}
|
||||
boot.initrd.services.resolved.enable = mkOption {
|
||||
default = config.boot.initrd.systemd.network.enable;
|
||||
defaultText = "config.boot.initrd.systemd.network.enable";
|
||||
description = ''
|
||||
Whether to enable resolved for stage 1 networking.
|
||||
Uses the toplevel 'services.resolved' options for 'resolved.conf'
|
||||
'';
|
||||
|
||||
# symlink the dynamic stub resolver of resolv.conf as recommended by upstream:
|
||||
# https://www.freedesktop.org/software/systemd/man/systemd-resolved.html#/etc/resolv.conf
|
||||
"resolv.conf".source = "/run/systemd/resolve/stub-resolv.conf";
|
||||
} // optionalAttrs dnsmasqResolve {
|
||||
"dnsmasq-resolv.conf".source = "/run/systemd/resolve/resolv.conf";
|
||||
};
|
||||
|
||||
# If networkmanager is enabled, ask it to interface with resolved.
|
||||
networking.networkmanager.dns = "systemd-resolved";
|
||||
|
||||
networking.resolvconf.package = pkgs.systemd;
|
||||
|
||||
};
|
||||
|
||||
config = mkMerge [
|
||||
(mkIf cfg.enable {
|
||||
|
||||
assertions = [
|
||||
{ assertion = !config.networking.useHostResolvConf;
|
||||
message = "Using host resolv.conf is not supported with systemd-resolved";
|
||||
}
|
||||
];
|
||||
|
||||
users.users.systemd-resolve.group = "systemd-resolve";
|
||||
|
||||
# add resolve to nss hosts database if enabled and nscd enabled
|
||||
# system.nssModules is configured in nixos/modules/system/boot/systemd.nix
|
||||
# added with order 501 to allow modules to go before with mkBefore
|
||||
system.nssDatabases.hosts = (mkOrder 501 ["resolve [!UNAVAIL=return]"]);
|
||||
|
||||
systemd.additionalUpstreamSystemUnits = [
|
||||
"systemd-resolved.service"
|
||||
];
|
||||
|
||||
systemd.services.systemd-resolved = {
|
||||
wantedBy = [ "sysinit.target" ];
|
||||
aliases = [ "dbus-org.freedesktop.resolve1.service" ];
|
||||
restartTriggers = [ config.environment.etc."systemd/resolved.conf".source ];
|
||||
};
|
||||
|
||||
environment.etc = {
|
||||
"systemd/resolved.conf".text = resolvedConf;
|
||||
|
||||
# symlink the dynamic stub resolver of resolv.conf as recommended by upstream:
|
||||
# https://www.freedesktop.org/software/systemd/man/systemd-resolved.html#/etc/resolv.conf
|
||||
"resolv.conf".source = "/run/systemd/resolve/stub-resolv.conf";
|
||||
} // optionalAttrs dnsmasqResolve {
|
||||
"dnsmasq-resolv.conf".source = "/run/systemd/resolve/resolv.conf";
|
||||
};
|
||||
|
||||
# If networkmanager is enabled, ask it to interface with resolved.
|
||||
networking.networkmanager.dns = "systemd-resolved";
|
||||
|
||||
networking.resolvconf.package = pkgs.systemd;
|
||||
|
||||
})
|
||||
|
||||
(mkIf config.boot.initrd.services.resolved.enable {
|
||||
|
||||
assertions = [
|
||||
{
|
||||
assertion = config.boot.initrd.systemd.enable;
|
||||
message = "'boot.initrd.services.resolved.enable' can only be enabled with systemd stage 1.";
|
||||
}
|
||||
];
|
||||
|
||||
boot.initrd.systemd = {
|
||||
contents = {
|
||||
"/etc/tmpfiles.d/resolv.conf".text =
|
||||
"L /etc/resolv.conf - - - - /run/systemd/resolve/stub-resolv.conf";
|
||||
"/etc/systemd/resolved.conf".text = resolvedConf;
|
||||
};
|
||||
|
||||
additionalUpstreamUnits = ["systemd-resolved.service"];
|
||||
users.systemd-resolve = {};
|
||||
groups.systemd-resolve = {};
|
||||
storePaths = ["${config.boot.initrd.systemd.package}/lib/systemd/systemd-resolved"];
|
||||
services.systemd-resolved = {
|
||||
wantedBy = ["sysinit.target"];
|
||||
aliases = [ "dbus-org.freedesktop.resolve1.service" ];
|
||||
};
|
||||
};
|
||||
|
||||
})
|
||||
];
|
||||
|
||||
}
|
||||
|
@ -930,6 +930,7 @@ in {
|
||||
systemd-oomd = handleTest ./systemd-oomd.nix {};
|
||||
systemd-portabled = handleTest ./systemd-portabled.nix {};
|
||||
systemd-repart = handleTest ./systemd-repart.nix {};
|
||||
systemd-resolved = handleTest ./systemd-resolved.nix {};
|
||||
systemd-shutdown = handleTest ./systemd-shutdown.nix {};
|
||||
systemd-sysupdate = runTest ./systemd-sysupdate.nix;
|
||||
systemd-sysusers-mutable = runTest ./systemd-sysusers-mutable.nix;
|
||||
|
@ -1,122 +1,147 @@
|
||||
# Rudimentary test checking that the Stalwart email server can:
|
||||
# - receive some message through SMTP submission, then
|
||||
# - serve this message through IMAP.
|
||||
{
|
||||
system ? builtins.currentSystem,
|
||||
config ? { },
|
||||
pkgs ? import ../../.. { inherit system config; },
|
||||
|
||||
lib ? pkgs.lib,
|
||||
}:
|
||||
let
|
||||
certs = import ./common/acme/server/snakeoil-certs.nix;
|
||||
domain = certs.domain;
|
||||
makeTest = import ./make-test-python.nix;
|
||||
mkTestName =
|
||||
pkg: "${pkg.pname}_${pkg.version}";
|
||||
stalwartPackages = {
|
||||
inherit (pkgs) stalwart-mail_0_6 stalwart-mail;
|
||||
};
|
||||
stalwartAtLeast = lib.versionAtLeast;
|
||||
makeStalwartTest =
|
||||
{
|
||||
package,
|
||||
name ? mkTestName package,
|
||||
}:
|
||||
makeTest {
|
||||
inherit name;
|
||||
meta.maintainers = with lib.maintainers; [
|
||||
happysalada pacien onny
|
||||
];
|
||||
|
||||
in import ./make-test-python.nix ({ lib, ... }: {
|
||||
name = "stalwart-mail";
|
||||
nodes.machine = { lib, ... }: {
|
||||
|
||||
nodes.main = { pkgs, ... }: {
|
||||
security.pki.certificateFiles = [ certs.ca.cert ];
|
||||
security.pki.certificateFiles = [ certs.ca.cert ];
|
||||
|
||||
services.stalwart-mail = {
|
||||
enable = true;
|
||||
settings = {
|
||||
server.hostname = domain;
|
||||
|
||||
certificate."snakeoil" = {
|
||||
cert = "file://${certs.${domain}.cert}";
|
||||
private-key = "file://${certs.${domain}.key}";
|
||||
};
|
||||
|
||||
server.tls = {
|
||||
certificate = "snakeoil";
|
||||
services.stalwart-mail = {
|
||||
enable = true;
|
||||
implicit = false;
|
||||
};
|
||||
inherit package;
|
||||
settings = {
|
||||
server.hostname = domain;
|
||||
|
||||
server.listener = {
|
||||
"smtp-submission" = {
|
||||
bind = [ "[::]:587" ];
|
||||
protocol = "smtp";
|
||||
};
|
||||
# TODO: Remove backwards compatibility as soon as we drop legacy version 0.6.0
|
||||
certificate."snakeoil" = let
|
||||
certPath = if stalwartAtLeast package.version "0.7.0" then "%{file://${certs.${domain}.cert}}%" else "file://${certs.${domain}.cert}";
|
||||
keyPath = if stalwartAtLeast package.version "0.7.0" then "%{file:${certs.${domain}.key}}%" else "file://${certs.${domain}.key}";
|
||||
in {
|
||||
cert = certPath;
|
||||
private-key = keyPath;
|
||||
};
|
||||
|
||||
"imap" = {
|
||||
bind = [ "[::]:143" ];
|
||||
protocol = "imap";
|
||||
server.tls = {
|
||||
certificate = "snakeoil";
|
||||
enable = true;
|
||||
implicit = false;
|
||||
};
|
||||
|
||||
server.listener = {
|
||||
"smtp-submission" = {
|
||||
bind = [ "[::]:587" ];
|
||||
protocol = "smtp";
|
||||
};
|
||||
|
||||
"imap" = {
|
||||
bind = [ "[::]:143" ];
|
||||
protocol = "imap";
|
||||
};
|
||||
};
|
||||
|
||||
session.auth.mechanisms = "[plain]";
|
||||
session.auth.directory = "'in-memory'";
|
||||
storage.directory = "in-memory";
|
||||
|
||||
session.rcpt.directory = "'in-memory'";
|
||||
queue.outbound.next-hop = "'local'";
|
||||
|
||||
directory."in-memory" = {
|
||||
type = "memory";
|
||||
# TODO: Remove backwards compatibility as soon as we drop legacy version 0.6.0
|
||||
principals = let
|
||||
condition = if stalwartAtLeast package.version "0.7.0" then "class" else "type";
|
||||
in builtins.map (p: p // { ${condition} = "individual"; }) [
|
||||
{
|
||||
name = "alice";
|
||||
secret = "foobar";
|
||||
email = [ "alice@${domain}" ];
|
||||
}
|
||||
{
|
||||
name = "bob";
|
||||
secret = "foobar";
|
||||
email = [ "bob@${domain}" ];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
resolver.public-suffix = [ ]; # do not fetch from web in sandbox
|
||||
environment.systemPackages = [
|
||||
(pkgs.writers.writePython3Bin "test-smtp-submission" { } ''
|
||||
from smtplib import SMTP
|
||||
|
||||
session.auth.mechanisms = "[plain]";
|
||||
session.auth.directory = "'in-memory'";
|
||||
storage.directory = "in-memory";
|
||||
with SMTP('localhost', 587) as smtp:
|
||||
smtp.starttls()
|
||||
smtp.login('alice', 'foobar')
|
||||
smtp.sendmail(
|
||||
'alice@${domain}',
|
||||
'bob@${domain}',
|
||||
"""
|
||||
From: alice@${domain}
|
||||
To: bob@${domain}
|
||||
Subject: Some test message
|
||||
|
||||
session.rcpt.directory = "'in-memory'";
|
||||
queue.outbound.next-hop = "'local'";
|
||||
This is a test message.
|
||||
""".strip()
|
||||
)
|
||||
'')
|
||||
|
||||
(pkgs.writers.writePython3Bin "test-imap-read" { } ''
|
||||
from imaplib import IMAP4
|
||||
|
||||
with IMAP4('localhost') as imap:
|
||||
imap.starttls()
|
||||
status, [caps] = imap.login('bob', 'foobar')
|
||||
assert status == 'OK'
|
||||
imap.select()
|
||||
status, [ref] = imap.search(None, 'ALL')
|
||||
assert status == 'OK'
|
||||
[msgId] = ref.split()
|
||||
status, msg = imap.fetch(msgId, 'BODY[TEXT]')
|
||||
assert status == 'OK'
|
||||
assert msg[0][1].strip() == b'This is a test message.'
|
||||
'')
|
||||
];
|
||||
|
||||
directory."in-memory" = {
|
||||
type = "memory";
|
||||
principals = [
|
||||
{
|
||||
type = "individual";
|
||||
name = "alice";
|
||||
secret = "foobar";
|
||||
email = [ "alice@${domain}" ];
|
||||
}
|
||||
{
|
||||
type = "individual";
|
||||
name = "bob";
|
||||
secret = "foobar";
|
||||
email = [ "bob@${domain}" ];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
start_all()
|
||||
machine.wait_for_unit("stalwart-mail.service")
|
||||
machine.wait_for_open_port(587)
|
||||
machine.wait_for_open_port(143)
|
||||
|
||||
machine.succeed("test-smtp-submission")
|
||||
machine.succeed("test-imap-read")
|
||||
'';
|
||||
};
|
||||
|
||||
environment.systemPackages = [
|
||||
(pkgs.writers.writePython3Bin "test-smtp-submission" { } ''
|
||||
from smtplib import SMTP
|
||||
|
||||
with SMTP('localhost', 587) as smtp:
|
||||
smtp.starttls()
|
||||
smtp.login('alice', 'foobar')
|
||||
smtp.sendmail(
|
||||
'alice@${domain}',
|
||||
'bob@${domain}',
|
||||
"""
|
||||
From: alice@${domain}
|
||||
To: bob@${domain}
|
||||
Subject: Some test message
|
||||
|
||||
This is a test message.
|
||||
""".strip()
|
||||
)
|
||||
'')
|
||||
|
||||
(pkgs.writers.writePython3Bin "test-imap-read" { } ''
|
||||
from imaplib import IMAP4
|
||||
|
||||
with IMAP4('localhost') as imap:
|
||||
imap.starttls()
|
||||
status, [caps] = imap.login('bob', 'foobar')
|
||||
assert status == 'OK'
|
||||
imap.select()
|
||||
status, [ref] = imap.search(None, 'ALL')
|
||||
assert status == 'OK'
|
||||
[msgId] = ref.split()
|
||||
status, msg = imap.fetch(msgId, 'BODY[TEXT]')
|
||||
assert status == 'OK'
|
||||
assert msg[0][1].strip() == b'This is a test message.'
|
||||
'')
|
||||
];
|
||||
};
|
||||
|
||||
testScript = /* python */ ''
|
||||
main.wait_for_unit("stalwart-mail.service")
|
||||
main.wait_for_open_port(587)
|
||||
main.wait_for_open_port(143)
|
||||
|
||||
main.succeed("test-smtp-submission")
|
||||
main.succeed("test-imap-read")
|
||||
'';
|
||||
|
||||
meta = {
|
||||
maintainers = with lib.maintainers; [ happysalada pacien ];
|
||||
};
|
||||
})
|
||||
in
|
||||
lib.mapAttrs (_: package: makeStalwartTest { inherit package; }) stalwartPackages
|
||||
|
75
nixos/tests/systemd-resolved.nix
Normal file
75
nixos/tests/systemd-resolved.nix
Normal file
@ -0,0 +1,75 @@
|
||||
import ./make-test-python.nix ({ pkgs, lib, ... }: {
|
||||
name = "systemd-resolved";
|
||||
meta.maintainers = [ lib.maintainers.elvishjerricco ];
|
||||
|
||||
nodes.server = { lib, config, ... }: let
|
||||
exampleZone = pkgs.writeTextDir "example.com.zone" ''
|
||||
@ SOA ns.example.com. noc.example.com. 2019031301 86400 7200 3600000 172800
|
||||
@ A ${(lib.head config.networking.interfaces.eth1.ipv4.addresses).address}
|
||||
@ AAAA ${(lib.head config.networking.interfaces.eth1.ipv6.addresses).address}
|
||||
'';
|
||||
in {
|
||||
networking.firewall.enable = false;
|
||||
networking.useDHCP = false;
|
||||
|
||||
networking.interfaces.eth1.ipv6.addresses = lib.mkForce [
|
||||
{ address = "fd00::1"; prefixLength = 64; }
|
||||
];
|
||||
|
||||
services.knot = {
|
||||
enable = true;
|
||||
settings = {
|
||||
server.listen = [
|
||||
"0.0.0.0@53"
|
||||
"::@53"
|
||||
];
|
||||
template.default.storage = exampleZone;
|
||||
zone."example.com".file = "example.com.zone";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
nodes.client = { nodes, ... }: let
|
||||
inherit (lib.head nodes.server.networking.interfaces.eth1.ipv4.addresses) address;
|
||||
in {
|
||||
networking.nameservers = [ address ];
|
||||
networking.interfaces.eth1.ipv6.addresses = lib.mkForce [
|
||||
{ address = "fd00::2"; prefixLength = 64; }
|
||||
];
|
||||
services.resolved.enable = true;
|
||||
services.resolved.fallbackDns = [ ];
|
||||
networking.useNetworkd = true;
|
||||
networking.useDHCP = false;
|
||||
systemd.network.networks."40-eth0".enable = false;
|
||||
|
||||
testing.initrdBackdoor = true;
|
||||
boot.initrd = {
|
||||
systemd.enable = true;
|
||||
systemd.initrdBin = [ pkgs.iputils ];
|
||||
network.enable = true;
|
||||
services.resolved.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
testScript = { nodes, ... }: let
|
||||
address4 = (lib.head nodes.server.networking.interfaces.eth1.ipv4.addresses).address;
|
||||
address6 = (lib.head nodes.server.networking.interfaces.eth1.ipv6.addresses).address;
|
||||
in ''
|
||||
start_all()
|
||||
server.wait_for_unit("multi-user.target")
|
||||
|
||||
def test_client():
|
||||
query = client.succeed("resolvectl query example.com")
|
||||
assert "${address4}" in query
|
||||
assert "${address6}" in query
|
||||
client.succeed("ping -4 -c 1 example.com")
|
||||
client.succeed("ping -6 -c 1 example.com")
|
||||
|
||||
client.wait_for_unit("initrd.target")
|
||||
test_client()
|
||||
client.switch_root()
|
||||
|
||||
client.wait_for_unit("multi-user.target")
|
||||
test_client()
|
||||
'';
|
||||
})
|
@ -2,11 +2,11 @@
|
||||
|
||||
let
|
||||
pname = "ledger-live-desktop";
|
||||
version = "2.80.0";
|
||||
version = "2.81.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://download.live.ledger.com/${pname}-${version}-linux-x86_64.AppImage";
|
||||
hash = "sha256-mtvLrA2wQM1om9En16/4AQFeddcRDoEyOwrefo5tOkk=";
|
||||
hash = "sha256-dnlIIOOYmCN209avQFMcoekB7nJpc2dJnS2OBI+dq7E=";
|
||||
};
|
||||
|
||||
appimageContents = appimageTools.extractType2 {
|
||||
|
@ -166,9 +166,9 @@ rec {
|
||||
mkTerraform = attrs: pluggable (generic attrs);
|
||||
|
||||
terraform_1 = mkTerraform {
|
||||
version = "1.8.3";
|
||||
hash = "sha256-4W1Cs3PAGn43eGDK15qSvN+gLdkkoFIwhejcJsCqcYA=";
|
||||
vendorHash = "sha256-2+ctm1lJjCHITWV7BqoqgBlXKjNT4lueAt4F3UtoL9Q=";
|
||||
version = "1.8.4";
|
||||
hash = "sha256-YCFmjQ/xlyB0spumw8hBUmr9UVC7ZPNGrxYecFKi3aw=";
|
||||
vendorHash = "sha256-PXA2AWq1IFmnqhhU92S9UaIYTUAAn5lsg3S7h5hBOQE=";
|
||||
patches = [ ./provider-path-0_15.patch ];
|
||||
passthru = {
|
||||
inherit plugins;
|
||||
|
1118
pkgs/applications/office/espanso/Cargo.lock
generated
1118
pkgs/applications/office/espanso/Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@ -28,6 +28,7 @@
|
||||
, QTKit
|
||||
, AVKit
|
||||
, WebKit
|
||||
, System
|
||||
, waylandSupport ? false
|
||||
, x11Support ? stdenv.isLinux
|
||||
, testers
|
||||
@ -39,13 +40,13 @@ assert stdenv.isDarwin -> !x11Support;
|
||||
assert stdenv.isDarwin -> !waylandSupport;
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "espanso";
|
||||
version = "2.1.8";
|
||||
version = "2.2-unstable-2024-05-14";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "espanso";
|
||||
repo = "espanso";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-5TUo5B1UZZARgTHbK2+520e3mGZkZ5tTez1qvZvMnxs=";
|
||||
rev = "8daadcc949c35a7b7aa20b7f544fdcff83e2c5f7";
|
||||
hash = "sha256-4MArENBmX6tDVLZE1O8cuJe7A0R+sLZoxBkDvIwIVZ4=";
|
||||
};
|
||||
|
||||
cargoLock = {
|
||||
@ -55,10 +56,6 @@ rustPlatform.buildRustPackage rec {
|
||||
};
|
||||
};
|
||||
|
||||
cargoPatches = lib.optionals stdenv.isDarwin [
|
||||
./inject-wx-on-darwin.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
extra-cmake-modules
|
||||
pkg-config
|
||||
@ -70,7 +67,7 @@ rustPlatform.buildRustPackage rec {
|
||||
buildNoDefaultFeatures = true;
|
||||
buildFeatures = [
|
||||
"modulo"
|
||||
] ++ lib.optionals waylandSupport[
|
||||
] ++ lib.optionals waylandSupport [
|
||||
"wayland"
|
||||
] ++ lib.optionals stdenv.isLinux [
|
||||
"vendored-tls"
|
||||
@ -96,6 +93,7 @@ rustPlatform.buildRustPackage rec {
|
||||
QTKit
|
||||
AVKit
|
||||
WebKit
|
||||
System
|
||||
] ++ lib.optionals waylandSupport [
|
||||
wl-clipboard
|
||||
] ++ lib.optionals x11Support [
|
||||
@ -108,39 +106,39 @@ rustPlatform.buildRustPackage rec {
|
||||
|
||||
postPatch = lib.optionalString stdenv.isDarwin ''
|
||||
substituteInPlace scripts/create_bundle.sh \
|
||||
--replace target/mac/ $out/Applications/ \
|
||||
--replace /bin/echo ${coreutils}/bin/echo
|
||||
--replace-fail target/mac/ $out/Applications/ \
|
||||
--replace-fail /bin/echo ${coreutils}/bin/echo
|
||||
patchShebangs scripts/create_bundle.sh
|
||||
substituteInPlace espanso/src/res/macos/Info.plist \
|
||||
--replace "<string>espanso</string>" "<string>${placeholder "out"}/Applications/Espanso.app/Contents/MacOS/espanso</string>"
|
||||
substituteInPlace espanso/src/res/macos/com.federicoterzi.espanso.plist \
|
||||
--replace "<string>/Applications/Espanso.app/Contents/MacOS/espanso</string>" "<string>${placeholder "out"}/Applications/Espanso.app/Contents/MacOS/espanso</string>" \
|
||||
--replace "<string>/usr/bin" "<string>${placeholder "out"}/bin:/usr/bin"
|
||||
--replace-fail "<string>espanso</string>" "<string>${placeholder "out"}/Applications/Espanso.app/Contents/MacOS/espanso</string>"
|
||||
substituteInPlace espanso/src/path/macos.rs espanso/src/path/linux.rs \
|
||||
--replace '"/usr/local/bin/espanso"' '"${placeholder "out"}/bin/espanso"'
|
||||
--replace-fail '"/usr/local/bin/espanso"' '"${placeholder "out"}/bin/espanso"'
|
||||
'';
|
||||
|
||||
# Some tests require networking
|
||||
doCheck = false;
|
||||
|
||||
postInstall = if stdenv.isDarwin then ''
|
||||
EXEC_PATH=$out/bin/espanso BUILD_ARCH=current ${stdenv.shell} ./scripts/create_bundle.sh
|
||||
'' else ''
|
||||
wrapProgram $out/bin/espanso \
|
||||
--prefix PATH : ${lib.makeBinPath (
|
||||
lib.optionals stdenv.isLinux [
|
||||
libnotify
|
||||
setxkbmap
|
||||
] ++ lib.optionals waylandSupport [
|
||||
wl-clipboard
|
||||
] ++ lib.optionals x11Support [
|
||||
xclip
|
||||
]
|
||||
)}
|
||||
'';
|
||||
postInstall =
|
||||
if stdenv.isDarwin then ''
|
||||
EXEC_PATH=$out/bin/espanso BUILD_ARCH=current ${stdenv.shell} ./scripts/create_bundle.sh
|
||||
'' else ''
|
||||
wrapProgram $out/bin/espanso \
|
||||
--prefix PATH : ${lib.makeBinPath (
|
||||
lib.optionals stdenv.isLinux [
|
||||
libnotify
|
||||
setxkbmap
|
||||
] ++ lib.optionals waylandSupport [
|
||||
wl-clipboard
|
||||
] ++ lib.optionals x11Support [
|
||||
xclip
|
||||
]
|
||||
)}
|
||||
'';
|
||||
|
||||
passthru.tests.version = testers.testVersion {
|
||||
package = espanso;
|
||||
# remove when updating to a release version
|
||||
version = "2.2.1";
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
@ -148,8 +146,15 @@ rustPlatform.buildRustPackage rec {
|
||||
mainProgram = "espanso";
|
||||
homepage = "https://espanso.org";
|
||||
license = licenses.gpl3Plus;
|
||||
maintainers = with maintainers; [ kimat pyrox0 ];
|
||||
maintainers = with maintainers; [ kimat pyrox0 n8henrie ];
|
||||
platforms = platforms.unix;
|
||||
# With apple_sdk_10_12,
|
||||
# kCFURLVolumeAvailableCapacityForImportantUsageKey
|
||||
# is undefined.
|
||||
# With apple_sdk_11_0, there is an issue with
|
||||
# kColorSyncGenericGrayProfile.
|
||||
broken = stdenv.hostPlatform.system == "x86_64-darwin";
|
||||
|
||||
|
||||
longDescription = ''
|
||||
Espanso detects when you type a keyword and replaces it while you're typing.
|
||||
|
@ -1,223 +0,0 @@
|
||||
From 6a7400c20831c5ff502c7336d6db2be743f156be Mon Sep 17 00:00:00 2001
|
||||
From: Nikola Knezevic <nikola.knezevic@imc.com>
|
||||
Date: Tue, 16 Aug 2022 22:28:46 +0200
|
||||
Subject: [PATCH] Build using system wx on darwin
|
||||
|
||||
---
|
||||
espanso-modulo/build.rs | 174 ++++------------------------------------
|
||||
1 file changed, 17 insertions(+), 157 deletions(-)
|
||||
|
||||
diff --git a/espanso-modulo/build.rs b/espanso-modulo/build.rs
|
||||
index b8b889a..5d972ec 100644
|
||||
--- a/espanso-modulo/build.rs
|
||||
+++ b/espanso-modulo/build.rs
|
||||
@@ -156,161 +156,6 @@ fn build_native() {
|
||||
);
|
||||
}
|
||||
|
||||
-#[cfg(target_os = "macos")]
|
||||
-fn build_native() {
|
||||
- use std::process::Command;
|
||||
-
|
||||
- let project_dir =
|
||||
- PathBuf::from(std::env::var("CARGO_MANIFEST_DIR").expect("missing CARGO_MANIFEST_DIR"));
|
||||
- let wx_archive = project_dir.join("vendor").join(WX_WIDGETS_ARCHIVE_NAME);
|
||||
- if !wx_archive.is_file() {
|
||||
- panic!("could not find wxWidgets archive!");
|
||||
- }
|
||||
-
|
||||
- let out_dir = if let Ok(out_path) = std::env::var(WX_WIDGETS_BUILD_OUT_DIR_ENV_NAME) {
|
||||
- println!(
|
||||
- "detected wxWidgets build output directory override: {}",
|
||||
- out_path
|
||||
- );
|
||||
- let path = PathBuf::from(out_path);
|
||||
- std::fs::create_dir_all(&path).expect("unable to create wxWidgets out dir");
|
||||
- path
|
||||
- } else {
|
||||
- PathBuf::from(std::env::var("OUT_DIR").expect("missing OUT_DIR"))
|
||||
- };
|
||||
- let out_wx_dir = out_dir.join("wx");
|
||||
- println!("wxWidgets will be compiled into: {}", out_wx_dir.display());
|
||||
-
|
||||
- let target_arch = match std::env::var("CARGO_CFG_TARGET_ARCH")
|
||||
- .expect("unable to read target arch")
|
||||
- .as_str()
|
||||
- {
|
||||
- "x86_64" => "x86_64",
|
||||
- "aarch64" => "arm64",
|
||||
- arch => panic!("unsupported arch {}", arch),
|
||||
- };
|
||||
-
|
||||
- let should_use_ci_m1_workaround =
|
||||
- std::env::var("CI").unwrap_or_default() == "true" && target_arch == "arm64";
|
||||
-
|
||||
- if !out_wx_dir.is_dir() {
|
||||
- // Extract the wxWidgets archive
|
||||
- let wx_archive =
|
||||
- std::fs::File::open(&wx_archive).expect("unable to open wxWidgets source archive");
|
||||
- let mut archive = zip::ZipArchive::new(wx_archive).expect("unable to read wxWidgets archive");
|
||||
- archive
|
||||
- .extract(&out_wx_dir)
|
||||
- .expect("unable to extract wxWidgets source dir");
|
||||
-
|
||||
- // Compile wxWidgets
|
||||
- let build_dir = out_wx_dir.join("build-cocoa");
|
||||
- std::fs::create_dir_all(&build_dir).expect("unable to create build-cocoa directory");
|
||||
-
|
||||
- let mut handle = if should_use_ci_m1_workaround {
|
||||
- // Because of a configuration problem on the GitHub CI pipeline,
|
||||
- // we need to use a series of workarounds to build for M1 machines.
|
||||
- // See: https://github.com/actions/virtual-environments/issues/3288#issuecomment-830207746
|
||||
- Command::new(out_wx_dir.join("configure"))
|
||||
- .current_dir(build_dir.to_string_lossy().to_string())
|
||||
- .args(&[
|
||||
- "--disable-shared",
|
||||
- "--without-libtiff",
|
||||
- "--without-liblzma",
|
||||
- "--with-libjpeg=builtin",
|
||||
- "--with-libpng=builtin",
|
||||
- "--enable-universal-binary=arm64,x86_64",
|
||||
- ])
|
||||
- .spawn()
|
||||
- .expect("failed to execute configure")
|
||||
- } else {
|
||||
- Command::new(out_wx_dir.join("configure"))
|
||||
- .current_dir(build_dir.to_string_lossy().to_string())
|
||||
- .args(&[
|
||||
- "--disable-shared",
|
||||
- "--without-libtiff",
|
||||
- "--without-liblzma",
|
||||
- "--with-libjpeg=builtin",
|
||||
- "--with-libpng=builtin",
|
||||
- &format!("--enable-macosx_arch={}", target_arch),
|
||||
- ])
|
||||
- .spawn()
|
||||
- .expect("failed to execute configure")
|
||||
- };
|
||||
-
|
||||
- if !handle
|
||||
- .wait()
|
||||
- .expect("unable to wait for configure command")
|
||||
- .success()
|
||||
- {
|
||||
- panic!("configure returned non-zero exit code!");
|
||||
- }
|
||||
-
|
||||
- let mut handle = Command::new("make")
|
||||
- .current_dir(build_dir.to_string_lossy().to_string())
|
||||
- .args(&["-j8"])
|
||||
- .spawn()
|
||||
- .expect("failed to execute make");
|
||||
- if !handle
|
||||
- .wait()
|
||||
- .expect("unable to wait for make command")
|
||||
- .success()
|
||||
- {
|
||||
- panic!("make returned non-zero exit code!");
|
||||
- }
|
||||
- }
|
||||
-
|
||||
- // Make sure wxWidgets is compiled
|
||||
- if !out_wx_dir.join("build-cocoa").is_dir() {
|
||||
- panic!("wxWidgets is not compiled correctly, missing 'build-cocoa/' directory")
|
||||
- }
|
||||
-
|
||||
- // If using the M1 CI workaround, convert all the universal libraries to arm64 ones
|
||||
- // This is needed until https://github.com/rust-lang/rust/issues/55235 is fixed
|
||||
- if should_use_ci_m1_workaround {
|
||||
- convert_fat_libraries_to_arm(&out_wx_dir.join("build-cocoa").join("lib"));
|
||||
- convert_fat_libraries_to_arm(&out_wx_dir.join("build-cocoa"));
|
||||
- }
|
||||
-
|
||||
- let config_path = out_wx_dir.join("build-cocoa").join("wx-config");
|
||||
- let cpp_flags = get_cpp_flags(&config_path);
|
||||
-
|
||||
- let mut build = cc::Build::new();
|
||||
- build
|
||||
- .cpp(true)
|
||||
- .file("src/sys/form/form.cpp")
|
||||
- .file("src/sys/common/common.cpp")
|
||||
- .file("src/sys/search/search.cpp")
|
||||
- .file("src/sys/wizard/wizard.cpp")
|
||||
- .file("src/sys/wizard/wizard_gui.cpp")
|
||||
- .file("src/sys/welcome/welcome.cpp")
|
||||
- .file("src/sys/welcome/welcome_gui.cpp")
|
||||
- .file("src/sys/textview/textview.cpp")
|
||||
- .file("src/sys/textview/textview_gui.cpp")
|
||||
- .file("src/sys/troubleshooting/troubleshooting.cpp")
|
||||
- .file("src/sys/troubleshooting/troubleshooting_gui.cpp")
|
||||
- .file("src/sys/common/mac.mm");
|
||||
- build.flag("-std=c++17");
|
||||
-
|
||||
- for flag in cpp_flags {
|
||||
- build.flag(&flag);
|
||||
- }
|
||||
-
|
||||
- build.compile("espansomodulosys");
|
||||
-
|
||||
- // Render linker flags
|
||||
-
|
||||
- generate_linker_flags(&config_path);
|
||||
-
|
||||
- // On (older) OSX we need to link against the clang runtime,
|
||||
- // which is hidden in some non-default path.
|
||||
- //
|
||||
- // More details at https://github.com/alexcrichton/curl-rust/issues/279.
|
||||
- if let Some(path) = macos_link_search_path() {
|
||||
- println!("cargo:rustc-link-lib=clang_rt.osx");
|
||||
- println!("cargo:rustc-link-search={}", path);
|
||||
- }
|
||||
-}
|
||||
-
|
||||
#[cfg(target_os = "macos")]
|
||||
fn convert_fat_libraries_to_arm(lib_dir: &Path) {
|
||||
for entry in
|
||||
@@ -440,12 +285,17 @@ fn macos_link_search_path() -> Option<String> {
|
||||
None
|
||||
}
|
||||
|
||||
+#[cfg(not(target_os = "macos"))]
|
||||
+fn macos_link_search_path() -> Option<String> {
|
||||
+ return None
|
||||
+}
|
||||
+
|
||||
// TODO: add documentation for linux
|
||||
// Install wxWidgets:
|
||||
// sudo apt install libwxgtk3.0-0v5 libwxgtk3.0-dev
|
||||
//
|
||||
// cargo run
|
||||
-#[cfg(target_os = "linux")]
|
||||
+#[cfg(not(target_os = "windows"))]
|
||||
fn build_native() {
|
||||
// Make sure wxWidgets is installed
|
||||
// Depending on the installation package, the 'wx-config' command might also be available as 'wx-config-gtk3',
|
||||
@@ -483,7 +333,8 @@ fn build_native() {
|
||||
.file("src/sys/textview/textview.cpp")
|
||||
.file("src/sys/textview/textview_gui.cpp")
|
||||
.file("src/sys/troubleshooting/troubleshooting.cpp")
|
||||
- .file("src/sys/troubleshooting/troubleshooting_gui.cpp");
|
||||
+ .file("src/sys/troubleshooting/troubleshooting_gui.cpp")
|
||||
+ .file("src/sys/common/mac.mm");
|
||||
build.flag("-std=c++17");
|
||||
|
||||
for flag in cpp_flags {
|
||||
@@ -495,6 +346,15 @@ fn build_native() {
|
||||
// Render linker flags
|
||||
|
||||
generate_linker_flags(&config_path);
|
||||
+
|
||||
+ // On (older) OSX we need to link against the clang runtime,
|
||||
+ // which is hidden in some non-default path.
|
||||
+ //
|
||||
+ // More details at https://github.com/alexcrichton/curl-rust/issues/279.
|
||||
+ if let Some(path) = macos_link_search_path() {
|
||||
+ println!("cargo:rustc-link-lib=clang_rt.osx");
|
||||
+ println!("cargo:rustc-link-search={}", path);
|
||||
+ }
|
||||
}
|
||||
|
||||
fn main() {
|
||||
--
|
||||
2.37.1
|
||||
|
@ -2,11 +2,11 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gerrit";
|
||||
version = "3.9.4";
|
||||
version = "3.10.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://gerrit-releases.storage.googleapis.com/gerrit-${version}.war";
|
||||
hash = "sha256-pjrWXfae1momJRTfdIPalsLynAGwqp1VtX9M9uqzJwM=";
|
||||
hash = "sha256-mlaXCRQlqg2uwzm2/Vi15K5D6lmUUscfZQk/lW1YR+s=";
|
||||
};
|
||||
|
||||
buildCommand = ''
|
||||
|
@ -2,6 +2,7 @@
|
||||
{
|
||||
v1 = {
|
||||
buildComposerProject = callPackage ./v1/build-composer-project.nix { };
|
||||
buildComposerWithPlugin = callPackage ./v1/build-composer-with-plugin.nix { };
|
||||
mkComposerRepository = callPackage ./v1/build-composer-repository.nix { };
|
||||
composerHooks = callPackages ./v1/hooks { };
|
||||
};
|
||||
|
@ -1,5 +1,4 @@
|
||||
{
|
||||
callPackage,
|
||||
nix-update-script,
|
||||
stdenvNoCC,
|
||||
lib,
|
||||
@ -12,8 +11,7 @@ let
|
||||
|
||||
let
|
||||
phpDrv = finalAttrs.php or php;
|
||||
composer = finalAttrs.composer or phpDrv.packages.composer;
|
||||
composer-local-repo-plugin = callPackage ../../pkgs/composer-local-repo-plugin.nix { };
|
||||
composer = finalAttrs.composer or phpDrv.packages.composer-local-repo-plugin;
|
||||
in
|
||||
{
|
||||
composerLock = previousAttrs.composerLock or null;
|
||||
@ -24,7 +22,6 @@ let
|
||||
|
||||
nativeBuildInputs = (previousAttrs.nativeBuildInputs or [ ]) ++ [
|
||||
composer
|
||||
composer-local-repo-plugin
|
||||
phpDrv
|
||||
phpDrv.composerHooks.composerInstallHook
|
||||
];
|
||||
@ -74,7 +71,7 @@ let
|
||||
|
||||
composerRepository =
|
||||
previousAttrs.composerRepository or (phpDrv.mkComposerRepository {
|
||||
inherit composer composer-local-repo-plugin;
|
||||
inherit composer;
|
||||
inherit (finalAttrs)
|
||||
patches
|
||||
pname
|
||||
|
@ -1,5 +1,4 @@
|
||||
{
|
||||
callPackage,
|
||||
stdenvNoCC,
|
||||
lib,
|
||||
php,
|
||||
@ -23,8 +22,7 @@ let
|
||||
|
||||
let
|
||||
phpDrv = finalAttrs.php or php;
|
||||
composer = finalAttrs.composer or phpDrv.packages.composer;
|
||||
composer-local-repo-plugin = callPackage ../../pkgs/composer-local-repo-plugin.nix { };
|
||||
composer = finalAttrs.composer or phpDrv.packages.composer-local-repo-plugin;
|
||||
in
|
||||
assert (lib.assertMsg (previousAttrs ? src) "mkComposerRepository expects src argument.");
|
||||
assert (
|
||||
@ -58,7 +56,6 @@ let
|
||||
|
||||
nativeBuildInputs = (previousAttrs.nativeBuildInputs or [ ]) ++ [
|
||||
composer
|
||||
composer-local-repo-plugin
|
||||
phpDrv
|
||||
phpDrv.composerHooks.composerRepositoryHook
|
||||
];
|
||||
|
@ -0,0 +1,161 @@
|
||||
{
|
||||
stdenvNoCC,
|
||||
writeText,
|
||||
lib,
|
||||
makeBinaryWrapper,
|
||||
php,
|
||||
cacert,
|
||||
nix-update-script,
|
||||
}:
|
||||
|
||||
let
|
||||
composerJsonBuilder =
|
||||
pluginName: pluginVersion:
|
||||
writeText "composer.json" (
|
||||
builtins.toJSON {
|
||||
name = "nix/plugin";
|
||||
description = "Nix Composer plugin";
|
||||
license = "MIT";
|
||||
require = {
|
||||
"${pluginName}" = "${pluginVersion}";
|
||||
};
|
||||
config = {
|
||||
"allow-plugins" = {
|
||||
"${pluginName}" = true;
|
||||
};
|
||||
};
|
||||
repositories = [
|
||||
{
|
||||
type = "path";
|
||||
url = "./src";
|
||||
options = {
|
||||
versions = {
|
||||
"${pluginName}" = "${pluginVersion}";
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
||||
);
|
||||
|
||||
buildComposerWithPluginOverride =
|
||||
finalAttrs: previousAttrs:
|
||||
|
||||
let
|
||||
phpDrv = finalAttrs.php or php;
|
||||
composer = finalAttrs.composer or phpDrv.packages.composer;
|
||||
in
|
||||
{
|
||||
composerLock = previousAttrs.composerLock or null;
|
||||
composerNoDev = previousAttrs.composerNoDev or true;
|
||||
composerNoPlugins = previousAttrs.composerNoPlugins or true;
|
||||
composerNoScripts = previousAttrs.composerNoScripts or true;
|
||||
composerStrictValidation = previousAttrs.composerStrictValidation or true;
|
||||
composerGlobal = true;
|
||||
|
||||
nativeBuildInputs = (previousAttrs.nativeBuildInputs or [ ]) ++ [
|
||||
composer
|
||||
phpDrv
|
||||
makeBinaryWrapper
|
||||
];
|
||||
|
||||
buildInputs = (previousAttrs.buildInputs or [ ]) ++ [ phpDrv ];
|
||||
|
||||
patches = previousAttrs.patches or [ ];
|
||||
strictDeps = previousAttrs.strictDeps or true;
|
||||
|
||||
# Should we keep these empty phases?
|
||||
configurePhase =
|
||||
previousAttrs.configurePhase or ''
|
||||
runHook preConfigure
|
||||
|
||||
runHook postConfigure
|
||||
'';
|
||||
|
||||
buildPhase =
|
||||
previousAttrs.buildPhase or ''
|
||||
runHook preBuild
|
||||
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
doCheck = previousAttrs.doCheck or true;
|
||||
|
||||
checkPhase =
|
||||
previousAttrs.checkPhase or ''
|
||||
runHook preCheck
|
||||
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
installPhase =
|
||||
previousAttrs.installPhase or ''
|
||||
runHook preInstall
|
||||
|
||||
makeWrapper ${lib.getExe composer} $out/bin/composer \
|
||||
--prefix COMPOSER_HOME : ${finalAttrs.vendor}
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
doInstallCheck = previousAttrs.doInstallCheck or false;
|
||||
installCheckPhase =
|
||||
previousAttrs.installCheckPhase or ''
|
||||
runHook preInstallCheck
|
||||
|
||||
composer global show ${finalAttrs.pname}
|
||||
|
||||
runHook postInstallCheck
|
||||
'';
|
||||
|
||||
vendor = previousAttrs.vendor or stdenvNoCC.mkDerivation {
|
||||
pname = "${finalAttrs.pname}-vendor";
|
||||
pluginName = finalAttrs.pname;
|
||||
|
||||
inherit (finalAttrs) version src;
|
||||
|
||||
composerLock = previousAttrs.composerLock or null;
|
||||
composerNoDev = previousAttrs.composerNoDev or true;
|
||||
composerNoPlugins = previousAttrs.composerNoPlugins or true;
|
||||
composerNoScripts = previousAttrs.composerNoScripts or true;
|
||||
composerStrictValidation = previousAttrs.composerStrictValidation or true;
|
||||
composerGlobal = true;
|
||||
composerJson = composerJsonBuilder finalAttrs.pname finalAttrs.version;
|
||||
|
||||
nativeBuildInputs = [
|
||||
cacert
|
||||
composer
|
||||
phpDrv.composerHooks.composerWithPluginVendorHook
|
||||
];
|
||||
|
||||
dontPatchShebangs = true;
|
||||
doCheck = true;
|
||||
doInstallCheck = true;
|
||||
|
||||
env = {
|
||||
COMPOSER_CACHE_DIR = "/dev/null";
|
||||
COMPOSER_HTACCESS_PROTECT = "0";
|
||||
};
|
||||
|
||||
outputHashMode = "recursive";
|
||||
outputHashAlgo = "sha256";
|
||||
outputHash = finalAttrs.vendorHash;
|
||||
};
|
||||
|
||||
# Projects providing a lockfile from upstream can be automatically updated.
|
||||
passthru = previousAttrs.passthru or { } // {
|
||||
updateScript =
|
||||
previousAttrs.passthru.updateScript
|
||||
or (if finalAttrs.vendor.composerLock == null then nix-update-script { } else null);
|
||||
};
|
||||
|
||||
env = {
|
||||
COMPOSER_CACHE_DIR = "/dev/null";
|
||||
COMPOSER_DISABLE_NETWORK = "1";
|
||||
COMPOSER_MIRROR_PATH_REPOS = "1";
|
||||
};
|
||||
|
||||
meta = previousAttrs.meta or composer.meta;
|
||||
};
|
||||
in
|
||||
args: (stdenvNoCC.mkDerivation args).overrideAttrs buildComposerWithPluginOverride
|
@ -83,7 +83,7 @@ composerInstallBuildHook() {
|
||||
|
||||
# Since this file cannot be generated in the composer-repository-hook.sh
|
||||
# because the file contains hardcoded nix store paths, we generate it here.
|
||||
composer-local-repo-plugin --no-ansi build-local-repo-lock -m "${composerRepository}" .
|
||||
composer build-local-repo-lock -m "${composerRepository}" .
|
||||
|
||||
echo "Finished composerInstallBuildHook"
|
||||
}
|
||||
|
@ -63,7 +63,7 @@ composerRepositoryBuildHook() {
|
||||
# Build the local composer repository
|
||||
# The command 'build-local-repo' is provided by the Composer plugin
|
||||
# nix-community/composer-local-repo-plugin.
|
||||
composer-local-repo-plugin --no-ansi build-local-repo-lock ${composerNoDev:+--no-dev} -r repository
|
||||
composer build-local-repo-lock ${composerNoDev:+--no-dev} -r repository
|
||||
|
||||
echo "Finished composerRepositoryBuildHook"
|
||||
}
|
||||
|
@ -0,0 +1,93 @@
|
||||
declare composerLock
|
||||
declare version
|
||||
declare composerNoDev
|
||||
declare composerNoPlugins
|
||||
declare composerNoScripts
|
||||
declare composerStrictValidation
|
||||
|
||||
preConfigureHooks+=(composerWithPluginConfigureHook)
|
||||
preBuildHooks+=(composerWithPluginBuildHook)
|
||||
preCheckHooks+=(composerWithPluginCheckHook)
|
||||
preInstallHooks+=(composerWithPluginInstallHook)
|
||||
preInstallCheckHooks+=(composerWithPluginInstallCheckHook)
|
||||
|
||||
source @phpScriptUtils@
|
||||
|
||||
composerWithPluginConfigureHook() {
|
||||
echo "Executing composerWithPluginConfigureHook"
|
||||
|
||||
mkdir -p $out
|
||||
|
||||
export COMPOSER_HOME=$out
|
||||
|
||||
if [[ -e "$composerLock" ]]; then
|
||||
cp $composerLock $out/composer.lock
|
||||
fi
|
||||
|
||||
cp $composerJson $out/composer.json
|
||||
cp -ar $src $out/src
|
||||
|
||||
if [[ ! -f "$out/composer.lock" ]]; then
|
||||
setComposeRootVersion
|
||||
|
||||
composer \
|
||||
global \
|
||||
--no-install \
|
||||
--no-interaction \
|
||||
--no-progress \
|
||||
${composerNoDev:+--no-dev} \
|
||||
${composerNoPlugins:+--no-plugins} \
|
||||
${composerNoScripts:+--no-scripts} \
|
||||
update
|
||||
|
||||
echo
|
||||
echo -e "\e[31mERROR: No composer.lock found\e[0m"
|
||||
echo
|
||||
echo -e '\e[31mNo composer.lock file found, consider adding one to your repository to ensure reproducible builds.\e[0m'
|
||||
echo -e "\e[31mIn the meantime, a composer.lock file has been generated for you in $out/composer.lock\e[0m"
|
||||
echo
|
||||
echo -e '\e[31mTo fix the issue:\e[0m'
|
||||
echo -e "\e[31m1. Copy the composer.lock file from $out/composer.lock to the project's source:\e[0m"
|
||||
echo -e "\e[31m cp $out/composer.lock <path>\e[0m"
|
||||
echo -e '\e[31m2. Add the composerLock attribute, pointing to the copied composer.lock file:\e[0m'
|
||||
echo -e '\e[31m composerLock = ./composer.lock;\e[0m'
|
||||
echo
|
||||
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Finished composerWithPluginConfigureHook"
|
||||
}
|
||||
|
||||
composerWithPluginBuildHook() {
|
||||
echo "Executing composerWithPluginBuildHook"
|
||||
|
||||
echo "Finished composerWithPluginBuildHook"
|
||||
}
|
||||
|
||||
composerWithPluginCheckHook() {
|
||||
echo "Executing composerWithPluginCheckHook"
|
||||
|
||||
checkComposerValidate
|
||||
|
||||
echo "Finished composerWithPluginCheckHook"
|
||||
}
|
||||
|
||||
composerWithPluginInstallHook() {
|
||||
echo "Executing composerWithPluginInstallHook"
|
||||
|
||||
composer \
|
||||
global \
|
||||
--no-interaction \
|
||||
--no-progress \
|
||||
${composerNoDev:+--no-dev} \
|
||||
${composerNoPlugins:+--no-plugins} \
|
||||
${composerNoScripts:+--no-scripts} \
|
||||
install
|
||||
|
||||
echo "Finished composerWithPluginInstallHook"
|
||||
}
|
||||
|
||||
composerWithPluginInstallCheckHook() {
|
||||
composer global show $pluginName
|
||||
}
|
@ -42,4 +42,19 @@ in
|
||||
phpScriptUtils = lib.getExe php-script-utils;
|
||||
};
|
||||
} ./composer-install-hook.sh;
|
||||
|
||||
composerWithPluginVendorHook = makeSetupHook {
|
||||
name = "composer-with-plugin-vendor-hook.sh";
|
||||
propagatedBuildInputs = [
|
||||
jq
|
||||
moreutils
|
||||
cacert
|
||||
];
|
||||
substitutions = {
|
||||
# Specify the stdenv's `diff` by abspath to ensure that the user's build
|
||||
# inputs do not cause us to find the wrong `diff`.
|
||||
cmp = "${lib.getBin buildPackages.diffutils}/bin/cmp";
|
||||
phpScriptUtils = lib.getExe php-script-utils;
|
||||
};
|
||||
} ./composer-with-plugin-vendor-hook.sh;
|
||||
}
|
||||
|
@ -1,5 +1,6 @@
|
||||
declare version
|
||||
declare composerStrictValidation
|
||||
declare composerGlobal
|
||||
|
||||
setComposeRootVersion() {
|
||||
set +e # Disable exit on error
|
||||
@ -13,7 +14,16 @@ setComposeRootVersion() {
|
||||
}
|
||||
|
||||
checkComposerValidate() {
|
||||
if ! composer validate --strict --no-ansi --no-interaction --quiet --no-check-all --no-check-lock; then
|
||||
setComposeRootVersion
|
||||
|
||||
if [ "1" == "${composerGlobal-}" ]; then
|
||||
global="global";
|
||||
else
|
||||
global="";
|
||||
fi
|
||||
|
||||
command="composer ${global} validate --strict --quiet --no-interaction --no-check-all --no-check-lock"
|
||||
if ! $command; then
|
||||
if [ "1" == "${composerStrictValidation-}" ]; then
|
||||
echo
|
||||
echo -e "\e[31mERROR: composer files validation failed\e[0m"
|
||||
@ -42,7 +52,8 @@ checkComposerValidate() {
|
||||
fi
|
||||
fi
|
||||
|
||||
if ! composer validate --strict --no-ansi --no-interaction --quiet --no-check-all --check-lock; then
|
||||
command="composer ${global} validate --strict --no-ansi --no-interaction --quiet --no-check-all --check-lock"
|
||||
if ! $command; then
|
||||
if [ "1" == "${composerStrictValidation-}" ]; then
|
||||
echo
|
||||
echo -e "\e[31mERROR: composer files validation failed\e[0m"
|
||||
|
@ -1,116 +0,0 @@
|
||||
{
|
||||
php,
|
||||
callPackage,
|
||||
stdenvNoCC,
|
||||
lib,
|
||||
fetchFromGitHub,
|
||||
makeBinaryWrapper,
|
||||
}:
|
||||
|
||||
let
|
||||
composer = callPackage ./composer-phar.nix { inherit (php.packages.composer) version pharHash; };
|
||||
|
||||
composerKeys = stdenvNoCC.mkDerivation (finalComposerKeysAttrs: {
|
||||
pname = "composer-keys";
|
||||
version = "fa5a62092f33e094073fbda23bbfc7188df3cbc5";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "composer";
|
||||
repo = "composer.github.io";
|
||||
rev = "${finalComposerKeysAttrs.version}";
|
||||
hash = "sha256-3Sfn71LDG1jHwuEIU8iEnV3k6D6QTX7KVIKVaNSuCVE=";
|
||||
};
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out
|
||||
install releases.pub $out/keys.tags.pub
|
||||
install snapshots.pub $out/keys.dev.pub
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
});
|
||||
in
|
||||
stdenvNoCC.mkDerivation (finalAttrs: {
|
||||
pname = "composer-local-repo-plugin";
|
||||
version = "1.1.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "nix-community";
|
||||
repo = "composer-local-repo-plugin";
|
||||
rev = finalAttrs.version;
|
||||
hash = "sha256-edbn07r/Uc1g0qOuVBZBs6N1bMN5kIfA1b4FCufdw5M=";
|
||||
};
|
||||
|
||||
env = {
|
||||
COMPOSER_CACHE_DIR = "/dev/null";
|
||||
COMPOSER_MIRROR_PATH_REPOS = "1";
|
||||
COMPOSER_HTACCESS_PROTECT = "0";
|
||||
COMPOSER_DISABLE_NETWORK = "1";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeBinaryWrapper ];
|
||||
|
||||
buildInputs = [ composer ];
|
||||
|
||||
configurePhase = ''
|
||||
runHook preConfigure
|
||||
|
||||
export COMPOSER_HOME=${placeholder "out"}
|
||||
|
||||
runHook postConfigure
|
||||
'';
|
||||
|
||||
buildPhase = ''
|
||||
runHook preBuild
|
||||
|
||||
# Configure composer globally
|
||||
composer global init --quiet --no-interaction --no-ansi \
|
||||
--name="nixos/composer" \
|
||||
--homepage "https://nixos.org/" \
|
||||
--description "Composer with nix-community/composer-local-repo-plugin" \
|
||||
--license "MIT"
|
||||
|
||||
composer global config --quiet minimum-stability dev
|
||||
composer global config --quiet prefer-stable true
|
||||
composer global config --quiet apcu-autoloader false
|
||||
composer global config --quiet allow-plugins.nix-community/composer-local-repo-plugin true
|
||||
composer global config --quiet repo.packagist false
|
||||
composer global config --quiet repo.plugin path $src
|
||||
|
||||
# Install the local repository plugin
|
||||
composer global require --quiet --no-ansi --no-interaction nix-community/composer-local-repo-plugin
|
||||
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
checkPhase = ''
|
||||
runHook preCheck
|
||||
|
||||
composer global validate --no-ansi
|
||||
composer global show --no-ansi nix-community/composer-local-repo-plugin
|
||||
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out
|
||||
cp -ar ${composerKeys}/* $out/
|
||||
|
||||
makeWrapper ${composer}/bin/composer $out/bin/composer-local-repo-plugin \
|
||||
--prefix COMPOSER_HOME : $out
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Composer local repo plugin for Composer";
|
||||
homepage = "https://github.com/nix-community/composer-local-repo-plugin";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ drupol ];
|
||||
platforms = lib.platforms.all;
|
||||
};
|
||||
})
|
@ -1,6 +1,5 @@
|
||||
{
|
||||
_7zz,
|
||||
cacert,
|
||||
curl,
|
||||
fetchurl,
|
||||
git,
|
||||
@ -37,7 +36,6 @@ stdenvNoCC.mkDerivation (finalAttrs: {
|
||||
--prefix PATH : ${
|
||||
lib.makeBinPath [
|
||||
_7zz
|
||||
cacert
|
||||
curl
|
||||
git
|
||||
unzip
|
||||
|
@ -37,13 +37,10 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
libclang
|
||||
libffi
|
||||
libxml2
|
||||
zlib
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
] ++ lib.optionals (!stdenv.isDarwin) [
|
||||
libclang
|
||||
];
|
||||
|
||||
@ -51,6 +48,8 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
(lib.cmakeOptionType "path" "CLANG_RESOURCE_DIR" "${lib.getDev libclang}")
|
||||
(lib.cmakeBool "SPHINX_HTML" withHTML)
|
||||
(lib.cmakeBool "SPHINX_MAN" withManual)
|
||||
] ++ lib.optionals stdenv.isDarwin [
|
||||
(lib.cmakeOptionType "path" "Clang_DIR" "${lib.getDev libclang}/lib/cmake/clang")
|
||||
];
|
||||
|
||||
# 97% tests passed, 97 tests failed out of 2881
|
||||
|
@ -1,77 +1,74 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, cmake
|
||||
, fetchFromGitHub
|
||||
, wrapQtAppsHook
|
||||
, qtmultimedia
|
||||
, qttools
|
||||
, qtdeclarative
|
||||
, qtnetworkauth
|
||||
, qtbase
|
||||
, makeWrapper
|
||||
, catch2
|
||||
, nodejs
|
||||
, libpulseaudio
|
||||
, openssl
|
||||
, rsync
|
||||
, typescript
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
cmake,
|
||||
fetchFromGitHub,
|
||||
makeWrapper,
|
||||
catch2,
|
||||
nodejs,
|
||||
libpulseaudio,
|
||||
openssl,
|
||||
rsync,
|
||||
typescript,
|
||||
qt6,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "imgbrd-grabber";
|
||||
version = "7.10.0";
|
||||
version = "7.12.2";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Bionus";
|
||||
repo = "imgbrd-grabber";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-AT6pN2do0LlH6xAXKcFQv+oderD88/EiG1JnCw6kOOg=";
|
||||
rev = "refs/tags/v${finalAttrs.version}";
|
||||
hash = "sha256-6XfIaASfbvdPovtdDEJtsk4pEL4Dhmyq8ml4X7KZ4DE=";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
openssl
|
||||
libpulseaudio
|
||||
typescript
|
||||
];
|
||||
buildInputs =
|
||||
with qt6;
|
||||
[
|
||||
qtbase
|
||||
qtdeclarative
|
||||
qttools
|
||||
qtnetworkauth
|
||||
qtmultimedia
|
||||
]
|
||||
++ [
|
||||
openssl
|
||||
libpulseaudio
|
||||
typescript
|
||||
nodejs
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
makeWrapper
|
||||
qtmultimedia
|
||||
qtbase
|
||||
qtdeclarative
|
||||
qttools
|
||||
qtnetworkauth
|
||||
nodejs
|
||||
qt6.wrapQtAppsHook
|
||||
cmake
|
||||
wrapQtAppsHook
|
||||
];
|
||||
|
||||
extraOutputsToLink = [ "doc" ];
|
||||
|
||||
postPatch = ''
|
||||
preBuild = ''
|
||||
export HOME=$TMPDIR
|
||||
|
||||
# the package.sh script provides some install helpers
|
||||
# using this might make it easier to maintain/less likely for the
|
||||
# install phase to fail across version bumps
|
||||
patchShebangs ./scripts/package.sh
|
||||
patchShebangs ../scripts/package.sh
|
||||
'';
|
||||
|
||||
postPatch = ''
|
||||
|
||||
# ensure the script uses the rsync package from nixpkgs
|
||||
substituteInPlace ../scripts/package.sh --replace "rsync" "${rsync}/bin/rsync"
|
||||
substituteInPlace ../scripts/package.sh --replace-fail "rsync" "${lib.getExe rsync}"
|
||||
|
||||
|
||||
# the npm build step only runs typescript
|
||||
# run this step directly so it doesn't try and fail to download the unnecessary node_modules, etc.
|
||||
substituteInPlace ./sites/CMakeLists.txt --replace "npm install" "npm run build"
|
||||
|
||||
# remove the vendored catch2
|
||||
rm -rf tests/src/vendor/catch
|
||||
substituteInPlace ./sites/CMakeLists.txt --replace-fail "npm install" "npm run build"
|
||||
|
||||
# link the catch2 sources from nixpkgs
|
||||
ln -sf ${catch2.src} tests/src/vendor/catch
|
||||
'';
|
||||
|
||||
preBuild = ''
|
||||
export HOME=$TMPDIR
|
||||
ln -sf ${catch2.src} tests/src/
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
@ -88,13 +85,16 @@ stdenv.mkDerivation rec {
|
||||
ln -s $out/share/Grabber/Grabber-cli $out/bin/Grabber-cli
|
||||
'';
|
||||
|
||||
sourceRoot = "${src.name}/src";
|
||||
sourceRoot = "${finalAttrs.src.name}/src";
|
||||
|
||||
meta = with lib; {
|
||||
meta = {
|
||||
description = "Very customizable imageboard/booru downloader with powerful filenaming features";
|
||||
license = licenses.asl20;
|
||||
license = lib.licenses.asl20;
|
||||
homepage = "https://bionus.github.io/imgbrd-grabber/";
|
||||
mainProgram = "Grabber";
|
||||
maintainers = [ maintainers.evanjs ];
|
||||
maintainers = with lib.maintainers; [
|
||||
evanjs
|
||||
luftmensch-luftmensch
|
||||
];
|
||||
};
|
||||
}
|
||||
})
|
@ -1,6 +1,6 @@
|
||||
{ lib, stdenv, fetchFromGitHub, removeReferencesTo, cmake, gettext, msgpack-c, libtermkey, libiconv
|
||||
, libuv, lua, ncurses, pkg-config
|
||||
, unibilium, gperf
|
||||
{ lib, stdenv, fetchFromGitHub, removeReferencesTo, cmake, gettext, msgpack-c, libiconv
|
||||
, libuv, lua, pkg-config
|
||||
, unibilium
|
||||
, libvterm-neovim
|
||||
, tree-sitter
|
||||
, fetchurl
|
||||
@ -93,8 +93,6 @@ in {
|
||||
;
|
||||
|
||||
buildInputs = [
|
||||
gperf
|
||||
libtermkey
|
||||
libuv
|
||||
libvterm-neovim
|
||||
# This is actually a c library, hence it's not included in neovimLuaEnv,
|
||||
@ -103,7 +101,6 @@ in {
|
||||
# and it's definition at: pkgs/development/lua-modules/overrides.nix
|
||||
lua.pkgs.libluv
|
||||
msgpack-c
|
||||
ncurses
|
||||
neovimLuaEnv
|
||||
tree-sitter
|
||||
unibilium
|
||||
|
30
pkgs/by-name/oi/oink/package.nix
Normal file
30
pkgs/by-name/oi/oink/package.nix
Normal file
@ -0,0 +1,30 @@
|
||||
{ lib
|
||||
, buildGoModule
|
||||
, fetchFromGitHub
|
||||
}:
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "oink";
|
||||
version = "1.1.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "rlado";
|
||||
repo = "oink";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-nSLoochU0mRxD83EXH3xsrfBBg4SnvIyf5qUiwSeh0c=";
|
||||
};
|
||||
|
||||
vendorHash = null;
|
||||
|
||||
postInstall = ''
|
||||
mv $out/bin/src $out/bin/oink
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Dynamic DNS client for Porkbun";
|
||||
homepage = "https://github.com/rlado/oink";
|
||||
license = lib.licenses.mit;
|
||||
mainProgram = "oink";
|
||||
maintainers = with lib.maintainers; [ jtbx ];
|
||||
};
|
||||
}
|
@ -2,16 +2,16 @@
|
||||
|
||||
buildGoModule rec {
|
||||
name = "regal";
|
||||
version = "0.21.3";
|
||||
version = "0.22.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "StyraInc";
|
||||
repo = "regal";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-MeEamVAETl+PJXJ2HpbhYdEG3kqvEeT5bGzRHyTrjcY=";
|
||||
hash = "sha256-3Q37ukeqf3n8UhriQNCWyRCgWOcxwO4TsNcsEnJn5eg=";
|
||||
};
|
||||
|
||||
vendorHash = "sha256-5rj2dCWya24VUmIFf0oJQop80trq9NnqqFlBW/A6opk=";
|
||||
vendorHash = "sha256-ejTBfoDYMt5Jpuq+uNgpdHCafR7IUVr8OFB84+m/ZFg=";
|
||||
|
||||
meta = with lib; {
|
||||
description = "a linter and language server for Rego";
|
||||
|
48
pkgs/by-name/st/stackql/package.nix
Normal file
48
pkgs/by-name/st/stackql/package.nix
Normal file
@ -0,0 +1,48 @@
|
||||
{
|
||||
lib,
|
||||
fetchFromGitHub,
|
||||
buildGoModule,
|
||||
testers,
|
||||
stackql,
|
||||
}:
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "stackql";
|
||||
version = "0.5.643";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "stackql";
|
||||
repo = "stackql";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-9W6bEI+5Q0Kgbd14sWKde3I6WIVz1ZxsXmR009mOPog=";
|
||||
};
|
||||
|
||||
vendorHash = "sha256-xcly4jtdUkx/s+YWYFBVeuI2kQBu2oqbLN9ZKkHppkA=";
|
||||
|
||||
ldflags = [
|
||||
"-s"
|
||||
"-w"
|
||||
"-X github.com/stackql/stackql/internal/stackql/cmd.BuildMajorVersion=${builtins.elemAt (lib.splitVersion version) 0}"
|
||||
"-X github.com/stackql/stackql/internal/stackql/cmd.BuildMinorVersion=${builtins.elemAt (lib.splitVersion version) 1}"
|
||||
"-X github.com/stackql/stackql/internal/stackql/cmd.BuildPatchVersion=${builtins.elemAt (lib.splitVersion version) 2}"
|
||||
"-X github.com/stackql/stackql/internal/stackql/cmd.BuildDate=2024-05-15T07:51:52Z" # date of commit hash
|
||||
"-X stackql/internal/stackql/planbuilder.PlanCacheEnabled=true"
|
||||
];
|
||||
|
||||
__darwinAllowLocalNetworking = true;
|
||||
|
||||
checkFlags = [ "--tags json1,sqleanal" ];
|
||||
|
||||
passthru.tests.version = testers.testVersion {
|
||||
package = stackql;
|
||||
version = "v${version}";
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = "https://github.com/stackql/stackql";
|
||||
description = "Deploy, manage and query cloud resources and interact with APIs using SQL";
|
||||
mainProgram = "stackql";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ jonochang ];
|
||||
};
|
||||
}
|
@ -164,7 +164,7 @@ let
|
||||
nixos = lib.recurseIntoAttrs nixosTests."php${lib.strings.replaceStrings [ "." ] [ "" ] (lib.versions.majorMinor php.version)}";
|
||||
package = tests.php;
|
||||
};
|
||||
inherit (php-packages) extensions buildPecl mkComposerRepository buildComposerProject composerHooks mkExtension;
|
||||
inherit (php-packages) extensions buildPecl mkComposerRepository buildComposerProject buildComposerWithPlugin composerHooks mkExtension;
|
||||
packages = php-packages.tools;
|
||||
meta = php.meta // {
|
||||
outputsToInstall = [ "out" ];
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, static ? stdenv.hostPlatform.isStatic
|
||||
, cxxStandard ? null
|
||||
|
@ -3,7 +3,6 @@
|
||||
, cmake
|
||||
, enet
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, flac
|
||||
, freetype
|
||||
, gtk3
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch, buildPackages, autoreconfHook }:
|
||||
{ lib, stdenv, fetchurl, buildPackages, autoreconfHook }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "apr";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.75.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.77.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.78.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.79.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.80.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.81.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.82.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.83.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.84.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ callPackage, fetchurl, fetchpatch, ... } @ args:
|
||||
{ callPackage, fetchurl, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
version = "1.85.0";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch, gtk-doc, meson, ninja, pkg-config, python3
|
||||
{ lib, stdenv, fetchurl, gtk-doc, meson, ninja, pkg-config, python3
|
||||
, docbook_xsl, fontconfig, freetype, libpng, pixman, zlib
|
||||
, x11Support? !stdenv.isDarwin || true, libXext, libXrender
|
||||
, gobjectSupport ? true, glib
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
}:
|
||||
|
||||
|
@ -1,6 +1,5 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchpatch
|
||||
, fetchurl
|
||||
, blas
|
||||
, cmake
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ fetchurl, fetchpatch, lib, stdenv, cmake }:
|
||||
{ fetchurl, lib, stdenv, cmake }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "cmocka";
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, fetchpatch
|
||||
, pkg-config
|
||||
, libGL
|
||||
, glib
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, example-robot-data
|
||||
, pinocchio
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchFromGitHub, cmake, jsoncpp, libossp_uuid, zlib, lib, fetchpatch
|
||||
{ stdenv, fetchFromGitHub, cmake, jsoncpp, libossp_uuid, zlib, lib
|
||||
# optional but of negligible size
|
||||
, openssl, brotli, c-ares
|
||||
# optional databases
|
||||
|
@ -1,8 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, substituteAll
|
||||
, cmake
|
||||
, ninja
|
||||
, openssl
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, eglexternalplatform
|
||||
, pkg-config
|
||||
, meson
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, doxygen
|
||||
, gettext
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook }:
|
||||
{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "fcgi";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, eigen, libccd, octomap }:
|
||||
{ lib, stdenv, fetchFromGitHub, cmake, eigen, libccd, octomap }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "fcl";
|
||||
|
@ -1,6 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub, fetchpatch
|
||||
, fetchFromGitHub
|
||||
, cmake
|
||||
, enableShared ? !stdenv.hostPlatform.isStatic
|
||||
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, fetchpatch
|
||||
, libpng
|
||||
, libjpeg
|
||||
, libtiff
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, ninja
|
||||
, useFloat ? false
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitLab
|
||||
, fetchpatch
|
||||
, intltool
|
||||
, meson
|
||||
, mesonEmulatorHook
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ stdenv
|
||||
, lib
|
||||
, fetchurl
|
||||
, fetchpatch
|
||||
, fixDarwinDylibNames
|
||||
, pkgsStatic
|
||||
}:
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchpatch, fetchFromGitHub, autoreconfHook
|
||||
{ lib, stdenv, fetchFromGitHub, autoreconfHook
|
||||
, blas, gfortran, openssh, mpi
|
||||
} :
|
||||
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ stdenv
|
||||
, lib
|
||||
, fetchurl
|
||||
, fetchpatch2
|
||||
, meson
|
||||
, ninja
|
||||
, pkg-config
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, doxygen
|
||||
, boost
|
||||
|
@ -1,6 +1,5 @@
|
||||
{ mkDerivation
|
||||
, lib
|
||||
, fetchpatch
|
||||
, extra-cmake-modules
|
||||
, kauth
|
||||
, kconfig
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
mkDerivation, fetchpatch,
|
||||
mkDerivation,
|
||||
extra-cmake-modules,
|
||||
attica, karchive, kcompletion, kconfig, kcoreaddons, ki18n, kiconthemes,
|
||||
kio, kitemviews, kpackage, kservice, ktextwidgets, kwidgetsaddons, kxmlgui, qtbase,
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
mkDerivation, fetchpatch,
|
||||
mkDerivation,
|
||||
extra-cmake-modules,
|
||||
kconfig, kcoreaddons, ki18n, kio, kservice, plasma-framework, qtbase,
|
||||
qtdeclarative, solid, threadweaver, kwindowsystem
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
mkDerivation, extra-cmake-modules, intltool, qtbase
|
||||
, accounts-qt, qtdeclarative, kaccounts-integration, kconfig, kcoreaddons, ki18n, kio, kirigami2
|
||||
, fetchpatch, signond
|
||||
, signond
|
||||
}:
|
||||
|
||||
mkDerivation {
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, lib, fetchFromGitHub, fetchpatch, pkg-config, cmake, git, doxygen, help2man, ncurses, tecla
|
||||
{ stdenv, lib, fetchFromGitHub, pkg-config, cmake, git, doxygen, help2man, ncurses, tecla
|
||||
, libusb1, udev }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch, pkg-config, fontconfig, autoreconfHook, DiskArbitration
|
||||
{ lib, stdenv, fetchurl, pkg-config, fontconfig, autoreconfHook, DiskArbitration
|
||||
, withJava ? false, jdk17, ant, stripJavaArchivesHook
|
||||
, withAACS ? false, libaacs
|
||||
, withBDplus ? false, libbdplus
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch, libwpg, libwpd, lcms, pkg-config, librevenge, icu, boost, cppunit }:
|
||||
{ lib, stdenv, fetchurl, libwpg, libwpd, lcms, pkg-config, librevenge, icu, boost, cppunit }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "libcdr";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch, cmake, minizip, pcsclite, opensc, openssl
|
||||
{ lib, stdenv, fetchurl, cmake, minizip, pcsclite, opensc, openssl
|
||||
, xercesc, xml-security-c, pkg-config, xsd, zlib, xalanc, xxd }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch, python3 }:
|
||||
{ lib, stdenv, fetchurl, python3 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "libevdev";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ fetchurl, fetchpatch, lib, stdenv, zlib, openssl, libuuid, pkg-config, bzip2 }:
|
||||
{ fetchurl, lib, stdenv, zlib, openssl, libuuid, pkg-config, bzip2 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "20231119";
|
||||
|
@ -1,5 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch
|
||||
, autoreconfHook
|
||||
{ lib, stdenv, fetchurl
|
||||
|
||||
, doCheck ? true # test suite depends on dejagnu which cannot be used during bootstrapping
|
||||
, dejagnu
|
||||
|
@ -1,5 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch
|
||||
, autoreconfHook
|
||||
{ lib, stdenv, fetchurl
|
||||
|
||||
# test suite depends on dejagnu which cannot be used during bootstrapping
|
||||
# dejagnu also requires tcl which can't be built statically at the moment
|
||||
|
@ -1,6 +1,6 @@
|
||||
{ lib, stdenv, fetchzip, pkg-config, glib, cairo, Carbon, fontconfig
|
||||
, libtiff, giflib, libjpeg, libpng
|
||||
, libXrender, libexif, autoreconfHook, fetchpatch }:
|
||||
, libXrender, libexif, autoreconfHook }:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "libgdiplus";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchurl, fetchpatch, autoreconfHook }:
|
||||
{ lib, stdenv, fetchurl, autoreconfHook }:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "libmd";
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, alsa-lib
|
||||
, cmake
|
||||
, doxygen
|
||||
|
@ -1,6 +1,5 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchpatch
|
||||
, fetchurl
|
||||
, gitUpdater
|
||||
, meson
|
||||
|
@ -1,6 +1,5 @@
|
||||
{ lib, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, pkg-config
|
||||
}:
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchFromGitHub, fetchpatch }:
|
||||
{ lib, stdenv, fetchFromGitHub }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "libschrift";
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, lib, fetchFromGitHub, fetchpatch, autoreconfHook, xz, buildPackages }:
|
||||
{ stdenv, lib, fetchFromGitHub, autoreconfHook, xz, buildPackages }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "libunwind";
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, autoreconfHook
|
||||
, doxygen
|
||||
, pkg-config
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, libjpeg
|
||||
, openssl
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user