···545546Here in the nixpkgs manual we describe mostly _package tests_; for _module tests_ head over to the corresponding [section in the NixOS manual](https://nixos.org/manual/nixos/stable/#sec-nixos-tests).
547548-### Writing package tests {#ssec-package-tests-writing}
0000000000000000000549550This is an example using the `phoronix-test-suite` package with the current best practices.
551
···545546Here in the nixpkgs manual we describe mostly _package tests_; for _module tests_ head over to the corresponding [section in the NixOS manual](https://nixos.org/manual/nixos/stable/#sec-nixos-tests).
547548+### Writing inline package tests {#ssec-inline-package-tests-writing}
549+550+For very simple tests, they can be written inline:
551+552+```nix
553+{ …, yq-go }:
554+555+buildGoModule rec {
556+ …
557+558+ passthru.tests = {
559+ simple = runCommand "${pname}-test" {} ''
560+ echo "test: 1" | ${yq-go}/bin/yq eval -j > $out
561+ [ "$(cat $out | tr -d $'\n ')" = '{"test":1}' ]
562+ '';
563+ };
564+}
565+```
566+567+### Writing larger package tests {#ssec-package-tests-writing}
568569This is an example using the `phoronix-test-suite` package with the current best practices.
570
+24-1
doc/stdenv/meta.chapter.md
···134This attribute is special in that it is not actually under the `meta` attribute set but rather under the `passthru` attribute set. This is due to how `meta` attributes work, and the fact that they are supposed to contain only metadata, not derivations.
135:::
136137-An attribute set with as values tests. A test is a derivation, which builds successfully when the test passes, and fails to build otherwise. A derivation that is a test needs to have `meta.timeout` defined.
000000000000000000000138139The NixOS tests are available as `nixosTests` in parameters of derivations. For instance, the OpenSMTPD derivation includes lines similar to:
140···147 };
148}
149```
00150151### `timeout` {#var-meta-timeout}
152
···134This attribute is special in that it is not actually under the `meta` attribute set but rather under the `passthru` attribute set. This is due to how `meta` attributes work, and the fact that they are supposed to contain only metadata, not derivations.
135:::
136137+An attribute set with tests as values. A test is a derivation that builds when the test passes and fails to build otherwise.
138+139+You can run these tests with:
140+141+```ShellSession
142+$ cd path/to/nixpkgs
143+$ nix-build -A your-package.tests
144+```
145+146+#### Package tests
147+148+Tests that are part of the source package are often executed in the `installCheckPhase`.
149+150+Prefer `passthru.tests` for tests that are introduced in nixpkgs because:
151+152+* `passthru.tests` tests the 'real' package, independently from the environment in which it was built
153+* we can run `passthru.tests` independently
154+* `installCheckPhase` adds overhead to each build
155+156+For more on how to write and run package tests, see <xref linkend="sec-package-tests"/>.
157+158+#### NixOS tests
159160The NixOS tests are available as `nixosTests` in parameters of derivations. For instance, the OpenSMTPD derivation includes lines similar to:
161···168 };
169}
170```
171+172+NixOS tests run in a VM, so they are slower than regular package tests. For more information see [NixOS module tests](https://nixos.org/manual/nixos/stable/#sec-nixos-tests).
173174### `timeout` {#var-meta-timeout}
175
+2
doc/stdenv/stdenv.chapter.md
···714715The installCheck phase checks whether the package was installed correctly by running its test suite against the installed directories. The default `installCheck` calls `make installcheck`.
71600717#### Variables controlling the installCheck phase {#variables-controlling-the-installcheck-phase}
718719##### `doInstallCheck` {#var-stdenv-doInstallCheck}
···714715The installCheck phase checks whether the package was installed correctly by running its test suite against the installed directories. The default `installCheck` calls `make installcheck`.
716717+It is often better to add tests that are not part of the source distribution to `passthru.tests` (see <xref linkend="var-meta-tests"/>). This avoids adding overhead to every build and enables us to run them independently.
718+719#### Variables controlling the installCheck phase {#variables-controlling-the-installcheck-phase}
720721##### `doInstallCheck` {#var-stdenv-doInstallCheck}
+1-1
lib/generators.nix
···248 then v.__pretty v.val
249 else if v == {} then "{ }"
250 else if v ? type && v.type == "derivation" then
251- "<derivation ${v.drvPath}>"
252 else "{" + introSpace
253 + libStr.concatStringsSep introSpace (libAttr.mapAttrsToList
254 (name: value:
···248 then v.__pretty v.val
249 else if v == {} then "{ }"
250 else if v ? type && v.type == "derivation" then
251+ "<derivation ${v.drvPath or "???"}>"
252 else "{" + introSpace
253 + libStr.concatStringsSep introSpace (libAttr.mapAttrsToList
254 (name: value:
+62-68
maintainers/scripts/pluginupdate.py
···42}
4344log = logging.getLogger()
45-log.addHandler(logging.StreamHandler())
46-4748def retry(ExceptionToCheck: Any, tries: int = 4, delay: float = 3, backoff: float = 2):
49 """Retry calling the decorated function using an exponential backoff.
···88 owner: str
89 repo: str
90 branch: str
91- alias: str
929394class Repo:
···203 name: str,
204 root: Path,
205 get_plugins: str,
206- generate_nix: Callable[[List[Tuple[str, str, Plugin]], str], None],
207 default_in: Optional[Path] = None,
208 default_out: Optional[Path] = None,
209 deprecated: Optional[Path] = None,
···213 self.name = name
214 self.root = root
215 self.get_plugins = get_plugins
216- self._generate_nix = generate_nix
217 self.default_in = default_in or root.joinpath(f"{name}-plugin-names")
218 self.default_out = default_out or root.joinpath("generated.nix")
219 self.deprecated = deprecated or root.joinpath("deprecated.json")
···226 def load_plugin_spec(self, plugin_file) -> List[PluginDesc]:
227 return load_plugin_spec(plugin_file)
228229- def generate_nix(self, plugins, outfile):
230 '''Returns nothing for now, writes directly to outfile'''
231- self._generate_nix(plugins, outfile)
232233 def get_update(self, input_file: str, outfile: str, proc: int):
234 return get_update(input_file, outfile, proc, editor=self)
···237 def attr_path(self):
238 return self.name + "Plugins"
239000240 def rewrite_input(self, *args, **kwargs):
241 return rewrite_input(*args, **kwargs)
2420000000000000000000000000000000000000000000000243244245···272273274def prefetch_plugin(
275- user: str,
276- repo_name: str,
277- branch: str,
278- alias: Optional[str],
279 cache: "Optional[Cache]" = None,
280) -> Tuple[Plugin, Dict[str, str]]:
0281 log.info(f"Fetching last commit for plugin {user}/{repo_name}@{branch}")
282 repo = Repo(user, repo_name, branch, alias)
283 commit, date = repo.latest_commit()
···302303304def fetch_plugin_from_pluginline(plugin_line: str) -> Plugin:
305- plugin, _ = prefetch_plugin(*parse_plugin_line(plugin_line))
306 return plugin
307308···421422423def prefetch(
424- args: PluginDesc, cache: Cache
425) -> Tuple[str, str, Union[Exception, Plugin], dict]:
426- owner, repo = args.owner, args.repo
427 try:
428- plugin, redirect = prefetch_plugin(owner, repo, args.branch, args.alias, cache)
429 cache[plugin.commit] = plugin
430 return (owner, repo, plugin, redirect)
431 except Exception as e:
···466 with open(input_file, "w") as f:
467 f.writelines(lines)
468469-# TODO move to Editor ?
470-def parse_args(editor: Editor):
471- parser = argparse.ArgumentParser(
472- description=(
473- f"Updates nix derivations for {editor.name} plugins"
474- f"By default from {editor.default_in} to {editor.default_out}"
475- )
476- )
477- parser.add_argument(
478- "--add",
479- dest="add_plugins",
480- default=[],
481- action="append",
482- help=f"Plugin to add to {editor.attr_path} from Github in the form owner/repo",
483- )
484- parser.add_argument(
485- "--input-names",
486- "-i",
487- dest="input_file",
488- default=editor.default_in,
489- help="A list of plugins in the form owner/repo",
490- )
491- parser.add_argument(
492- "--out",
493- "-o",
494- dest="outfile",
495- default=editor.default_out,
496- help="Filename to save generated nix code",
497- )
498- parser.add_argument(
499- "--proc",
500- "-p",
501- dest="proc",
502- type=int,
503- default=30,
504- help="Number of concurrent processes to spawn.",
505- )
506- parser.add_argument(
507- "--no-commit", "-n", action="store_true", default=False,
508- help="Whether to autocommit changes"
509- )
510- parser.add_argument(
511- "--debug", "-d", choices=LOG_LEVELS.keys(),
512- default=logging.getLevelName(logging.WARN),
513- help="Adjust log level"
514- )
515- return parser.parse_args()
516-517518def commit(repo: git.Repo, message: str, files: List[Path]) -> None:
519 repo.index.add([str(f.resolve()) for f in files])
···547 return update
548549550-def update_plugins(editor: Editor):
551 """The main entry function of this module. All input arguments are grouped in the `Editor`."""
552553- args = parse_args(editor)
554 log.setLevel(LOG_LEVELS[args.debug])
555-556 log.info("Start updating plugins")
557 nixpkgs_repo = git.Repo(editor.root, search_parent_directories=True)
558 update = editor.get_update(args.input_file, args.outfile, args.proc)
···581 if autocommit:
582 commit(
583 nixpkgs_repo,
584- "{editor.attr_path}.{name}: init at {version}".format(
585- editor=editor.name, name=plugin.normalized_name, version=plugin.version
0586 ),
587 [args.outfile, args.input_file],
588 )
···42}
4344log = logging.getLogger()
004546def retry(ExceptionToCheck: Any, tries: int = 4, delay: float = 3, backoff: float = 2):
47 """Retry calling the decorated function using an exponential backoff.
···86 owner: str
87 repo: str
88 branch: str
89+ alias: Optional[str]
909192class Repo:
···201 name: str,
202 root: Path,
203 get_plugins: str,
0204 default_in: Optional[Path] = None,
205 default_out: Optional[Path] = None,
206 deprecated: Optional[Path] = None,
···210 self.name = name
211 self.root = root
212 self.get_plugins = get_plugins
0213 self.default_in = default_in or root.joinpath(f"{name}-plugin-names")
214 self.default_out = default_out or root.joinpath("generated.nix")
215 self.deprecated = deprecated or root.joinpath("deprecated.json")
···222 def load_plugin_spec(self, plugin_file) -> List[PluginDesc]:
223 return load_plugin_spec(plugin_file)
224225+ def generate_nix(self, plugins, outfile: str):
226 '''Returns nothing for now, writes directly to outfile'''
227+ raise NotImplementedError()
228229 def get_update(self, input_file: str, outfile: str, proc: int):
230 return get_update(input_file, outfile, proc, editor=self)
···233 def attr_path(self):
234 return self.name + "Plugins"
235236+ def get_drv_name(self, name: str):
237+ return self.attr_path + "." + name
238+239 def rewrite_input(self, *args, **kwargs):
240 return rewrite_input(*args, **kwargs)
241242+ def create_parser(self):
243+ parser = argparse.ArgumentParser(
244+ description=(
245+ f"Updates nix derivations for {self.name} plugins"
246+ f"By default from {self.default_in} to {self.default_out}"
247+ )
248+ )
249+ parser.add_argument(
250+ "--add",
251+ dest="add_plugins",
252+ default=[],
253+ action="append",
254+ help=f"Plugin to add to {self.attr_path} from Github in the form owner/repo",
255+ )
256+ parser.add_argument(
257+ "--input-names",
258+ "-i",
259+ dest="input_file",
260+ default=self.default_in,
261+ help="A list of plugins in the form owner/repo",
262+ )
263+ parser.add_argument(
264+ "--out",
265+ "-o",
266+ dest="outfile",
267+ default=self.default_out,
268+ help="Filename to save generated nix code",
269+ )
270+ parser.add_argument(
271+ "--proc",
272+ "-p",
273+ dest="proc",
274+ type=int,
275+ default=30,
276+ help="Number of concurrent processes to spawn.",
277+ )
278+ parser.add_argument(
279+ "--no-commit", "-n", action="store_true", default=False,
280+ help="Whether to autocommit changes"
281+ )
282+ parser.add_argument(
283+ "--debug", "-d", choices=LOG_LEVELS.keys(),
284+ default=logging.getLevelName(logging.WARN),
285+ help="Adjust log level"
286+ )
287+ return parser
288289290···317318319def prefetch_plugin(
320+ p: PluginDesc,
000321 cache: "Optional[Cache]" = None,
322) -> Tuple[Plugin, Dict[str, str]]:
323+ user, repo_name, branch, alias = p.owner, p.repo, p.branch, p.alias
324 log.info(f"Fetching last commit for plugin {user}/{repo_name}@{branch}")
325 repo = Repo(user, repo_name, branch, alias)
326 commit, date = repo.latest_commit()
···345346347def fetch_plugin_from_pluginline(plugin_line: str) -> Plugin:
348+ plugin, _ = prefetch_plugin(parse_plugin_line(plugin_line))
349 return plugin
350351···464465466def prefetch(
467+ pluginDesc: PluginDesc, cache: Cache
468) -> Tuple[str, str, Union[Exception, Plugin], dict]:
469+ owner, repo = pluginDesc.owner, pluginDesc.repo
470 try:
471+ plugin, redirect = prefetch_plugin(pluginDesc, cache)
472 cache[plugin.commit] = plugin
473 return (owner, repo, plugin, redirect)
474 except Exception as e:
···509 with open(input_file, "w") as f:
510 f.writelines(lines)
511000000000000000000000000000000000000000000000000512513def commit(repo: git.Repo, message: str, files: List[Path]) -> None:
514 repo.index.add([str(f.resolve()) for f in files])
···542 return update
543544545+def update_plugins(editor: Editor, args):
546 """The main entry function of this module. All input arguments are grouped in the `Editor`."""
5470548 log.setLevel(LOG_LEVELS[args.debug])
0549 log.info("Start updating plugins")
550 nixpkgs_repo = git.Repo(editor.root, search_parent_directories=True)
551 update = editor.get_update(args.input_file, args.outfile, args.proc)
···574 if autocommit:
575 commit(
576 nixpkgs_repo,
577+ "{drv_name}: init at {version}".format(
578+ drv_name=editor.get_drv_name(plugin.normalized_name),
579+ version=plugin.version
580 ),
581 [args.outfile, args.input_file],
582 )
···668 to use wildcards in the <literal>source</literal> argument.
669 </para>
670 </listitem>
00000671 <listitem>
672 <para>
673 The <literal>openrazer</literal> and
···701 configures the address and port the web UI is listening, it
702 defaults to <literal>:9001</literal>. To be able to access the
703 web UI this port needs to be opened in the firewall.
0000000704 </para>
705 </listitem>
706 </itemizedlist>
···668 to use wildcards in the <literal>source</literal> argument.
669 </para>
670 </listitem>
671+ </itemizedlist>
672+ <para>
673+ <<<<<<< HEAD
674+ </para>
675+ <itemizedlist>
676 <listitem>
677 <para>
678 The <literal>openrazer</literal> and
···706 configures the address and port the web UI is listening, it
707 defaults to <literal>:9001</literal>. To be able to access the
708 web UI this port needs to be opened in the firewall.
709+ </para>
710+ </listitem>
711+ <listitem>
712+ <para>
713+ The <literal>varnish</literal> package was upgraded from 6.3.x
714+ to 6.5.x. <literal>varnish60</literal> for the last LTS
715+ release is also still available.
716 </para>
717 </listitem>
718 </itemizedlist>
+3
nixos/doc/manual/release-notes/rl-2111.section.md
···171172- `programs.neovim.runtime` switched to a `linkFarm` internally, making it impossible to use wildcards in the `source` argument.
1730174- The `openrazer` and `openrazer-daemon` packages as well as the `hardware.openrazer` module now require users to be members of the `openrazer` group instead of `plugdev`. With this change, users no longer need be granted the entire set of `plugdev` group permissions, which can include permissions other than those required by `openrazer`. This is desirable from a security point of view. The setting [`harware.openrazer.users`](options.html#opt-services.hardware.openrazer.users) can be used to add users to the `openrazer` group.
175176- The `yambar` package has been split into `yambar` and `yambar-wayland`, corresponding to the xorg and wayland backend respectively. Please switch to `yambar-wayland` if you are on wayland.
···178- The `services.minio` module gained an additional option `consoleAddress`, that
179configures the address and port the web UI is listening, it defaults to `:9001`.
180To be able to access the web UI this port needs to be opened in the firewall.
00181182## Other Notable Changes {#sec-release-21.11-notable-changes}
183
···171172- `programs.neovim.runtime` switched to a `linkFarm` internally, making it impossible to use wildcards in the `source` argument.
173174+<<<<<<< HEAD
175- The `openrazer` and `openrazer-daemon` packages as well as the `hardware.openrazer` module now require users to be members of the `openrazer` group instead of `plugdev`. With this change, users no longer need be granted the entire set of `plugdev` group permissions, which can include permissions other than those required by `openrazer`. This is desirable from a security point of view. The setting [`harware.openrazer.users`](options.html#opt-services.hardware.openrazer.users) can be used to add users to the `openrazer` group.
176177- The `yambar` package has been split into `yambar` and `yambar-wayland`, corresponding to the xorg and wayland backend respectively. Please switch to `yambar-wayland` if you are on wayland.
···179- The `services.minio` module gained an additional option `consoleAddress`, that
180configures the address and port the web UI is listening, it defaults to `:9001`.
181To be able to access the web UI this port needs to be opened in the firewall.
182+183+- The `varnish` package was upgraded from 6.3.x to 6.5.x. `varnish60` for the last LTS release is also still available.
184185## Other Notable Changes {#sec-release-21.11-notable-changes}
186
···43 IPv6 addresses must be enclosed in square brackets.
44 Note: this option overrides <literal>addSSL</literal>
45 and <literal>onlySSL</literal>.
00046 '';
0000000000000047 };
4849 enableACME = mkOption {
···43 IPv6 addresses must be enclosed in square brackets.
44 Note: this option overrides <literal>addSSL</literal>
45 and <literal>onlySSL</literal>.
46+47+ If you only want to set the addresses manually and not
48+ the ports, take a look at <literal>listenAddresses</literal>
49 '';
50+ };
51+52+ listenAddresses = mkOption {
53+ type = with types; listOf str;
54+55+ description = ''
56+ Listen addresses for this virtual host.
57+ Compared to <literal>listen</literal> this only sets the addreses
58+ and the ports are choosen automatically.
59+60+ Note: This option overrides <literal>enableIPv6</literal>
61+ '';
62+ default = [];
63+ example = [ "127.0.0.1" "::1" ];
64 };
6566 enableACME = mkOption {
···164 systemd.packages = with pkgs.gnome; [ gdm gnome-session gnome-shell ];
165 environment.systemPackages = [ pkgs.gnome.adwaita-icon-theme ];
166167+ # We dont use the upstream gdm service
168+ # it has to be disabled since the gdm package has it
169+ # https://github.com/NixOS/nixpkgs/issues/108672
170+ systemd.services.gdm.enable = false;
171+172 systemd.services.display-manager.wants = [
173 # Because sd_login_monitor_new requires /run/systemd/machines
174 "systemd-machined.service"
···78 'su - test7 -c "SSH_AUTH_SOCK=HOLEY doas env"'
79 ):
80 raise Exception("failed to exclude SSH_AUTH_SOCK")
81+82+ # Test that the doas setuid wrapper precedes the unwrapped version in PATH after
83+ # calling doas.
84+ # The PATH set by doas is defined in
85+ # ../../pkgs/tools/security/doas/0001-add-NixOS-specific-dirs-to-safe-PATH.patch
86+ with subtest("recursive calls to doas from subprocesses should succeed"):
87+ machine.succeed('doas -u test0 sh -c "doas -u test0 true"')
88 '';
89 }
90)
···28 else "");
29in stdenv.mkDerivation rec {
30 pname = "signal-desktop";
31- version = "5.12.2"; # Please backport all updates to the stable channel.
32 # All releases have a limited lifetime and "expire" 90 days after the release.
33 # When releases "expire" the application becomes unusable until an update is
34 # applied. The expiration date for the current release can be extracted with:
···3839 src = fetchurl {
40 url = "https://updates.signal.org/desktop/apt/pool/main/s/signal-desktop/signal-desktop_${version}_amd64.deb";
41- sha256 = "0z8nphlm3q9gqri6bqh1iaayx5yy0bhrmjb7l7facdkm1aahmaa7";
42 };
4344 nativeBuildInputs = [
···28 else "");
29in stdenv.mkDerivation rec {
30 pname = "signal-desktop";
31+ version = "5.13.1"; # Please backport all updates to the stable channel.
32 # All releases have a limited lifetime and "expire" 90 days after the release.
33 # When releases "expire" the application becomes unusable until an update is
34 # applied. The expiration date for the current release can be extracted with:
···3839 src = fetchurl {
40 url = "https://updates.signal.org/desktop/apt/pool/main/s/signal-desktop/signal-desktop_${version}_amd64.deb";
41+ sha256 = "0k3gbs6y19vri5n087wc6fdhydkis3h6rhxd3w1j9rhrb5fxjv3q";
42 };
4344 nativeBuildInputs = [
···1+{ lib, stdenvNoCC, fetchurl, makeWrapper, perl, installShellFiles }:
2+3+stdenvNoCC.mkDerivation rec {
4+ pname = "listadmin";
5+ version = "2.73";
6+7+ src = fetchurl {
8+ url = "mirror://sourceforge/project/listadmin/${version}/listadmin-${version}.tar.gz";
9+ sha256 = "00333d65ygdbm1hqr4yp2j8vh1cgh3hyfm7iy9y1alf0p0f6aqac";
10+ };
11+12+ buildInputs = [ perl ];
13+ nativeBuildInputs = [ makeWrapper installShellFiles ];
14+15+ # There is a Makefile, but we don’t need it, and it prints errors
16+ dontBuild = true;
17+18+ installPhase = ''
19+ mkdir -p $out/bin $out/share/man/man1
20+ install -m 755 listadmin.pl $out/bin/listadmin
21+ installManPage listadmin.1
22+23+ wrapProgram $out/bin/listadmin \
24+ --prefix PERL5LIB : "${with perl.pkgs; makeFullPerlPath [
25+ TextReform NetINET6Glue LWPProtocolhttps
26+ ]}"
27+ '';
28+29+ doInstallCheck = true;
30+ installCheckPhase = ''
31+ $out/bin/listadmin --help 2> /dev/null
32+ '';
33+34+ meta = with lib; {
35+ description = "Command line mailman moderator queue manipulation";
36+ longDescription = ''
37+ listadmin is a command line tool to manipulate the queues of messages
38+ held for moderator approval by mailman. It is designed to keep user
39+ interaction to a minimum, in theory you could run it from cron to prune
40+ the queue. It can use the score from a header added by SpamAssassin to
41+ filter, or it can match specific senders, subjects, or reasons.
42+ '';
43+ homepage = "https://sourceforge.net/projects/listadmin/";
44+ license = licenses.publicDomain;
45+ platforms = platforms.unix;
46+ maintainers = with maintainers; [ nomeata ];
47+ };
48+}
···1+{ lib, wrapFirefox, gpgme, gnupg }:
2+3+browser:
4+args:
5+6+(wrapFirefox browser ({
7+ libName = "thunderbird";
8+} // args))
9+10+.overrideAttrs (old: {
11+ # Thunderbird's native GPG support does not yet support smartcards.
12+ # The official upstream recommendation is to configure fall back to gnupg
13+ # using the Thunderbird config `mail.openpgp.allow_external_gnupg`
14+ # and GPG keys set up; instructions with pictures at:
15+ # https://anweshadas.in/how-to-use-yubikey-or-any-gpg-smartcard-in-thunderbird-78/
16+ # For that to work out of the box, it requires `gnupg` on PATH and
17+ # `gpgme` in `LD_LIBRARY_PATH`; we do this below.
18+ buildCommand = old.buildCommand + ''
19+ wrapProgram $out/bin/thunderbird \
20+ --prefix LD_LIBRARY_PATH ':' "${lib.makeLibraryPath [ gpgme ]}" \
21+ --prefix PATH ':' "${lib.makeBinPath [ gnupg ]}"
22+ '';
23+})
···23with python.pkgs;
4buildPythonApplication rec {
5- version = "0.3.9";
6 pname = "nbstripout";
78 # Mercurial should be added as a build input but because it's a Python
···1415 src = fetchPypi {
16 inherit pname version;
17- sha256 = "b46dddbf78b8b137176bc72729124e378242ef9ce93af63f6e0a8c4850c972e7";
18 };
1920 # for some reason, darwin uses /bin/sh echo native instead of echo binary, so
···23with python.pkgs;
4buildPythonApplication rec {
5+ version = "0.5.0";
6 pname = "nbstripout";
78 # Mercurial should be added as a build input but because it's a Python
···1415 src = fetchPypi {
16 inherit pname version;
17+ sha256 = "86ab50136998d62c9fa92478d2eb9ddc4137e51a28568f78fa8f24a6fbb6a7d8";
18 };
1920 # for some reason, darwin uses /bin/sh echo native instead of echo binary, so
···65 EOF
66 '';
6768+ # fixupPhase is moving the man to share/man which breaks it because it's a
69+ # relative symlink.
70+ postFixup = ''
71+ ln -nsf ../zulu-11.jdk/Contents/Home/man $out/share/man
72+ '';
73+74 passthru = {
75 home = jdk;
76 };
+11-13
pkgs/development/compilers/vlang/default.nix
···1-{ lib, stdenv, fetchFromGitHub, glfw, freetype, openssl, upx ? null }:
2-3-assert stdenv.hostPlatform.isUnix -> upx != null;
45stdenv.mkDerivation rec {
6 pname = "vlang";
···25 propagatedBuildInputs = [ glfw freetype openssl ]
26 ++ lib.optional stdenv.hostPlatform.isUnix upx;
2728- buildPhase = ''
29- runHook preBuild
30- cc -std=gnu11 $CFLAGS -w -o v $vc/v.c -lm $LDFLAGS
31- # vlang seems to want to write to $HOME/.vmodules,
32- # so lets give it a writable HOME
33- HOME=$PWD ./v -prod self
34- # Exclude thirdparty/vschannel as it is windows-specific.
35- find thirdparty -path thirdparty/vschannel -prune -o -type f -name "*.c" -execdir cc -std=gnu11 $CFLAGS -w -c {} $LDFLAGS ';'
36- runHook postBuild
37- '';
3839 installPhase = ''
40 runHook preInstall
···43 cp -r {cmd,vlib,thirdparty} $out/lib
44 mv v $out/lib
45 ln -s $out/lib/v $out/bin/v
046 runHook postInstall
47 '';
48
···56buildPythonPackage rec {
7 pname = "celery";
8- version = "5.1.1";
910 src = fetchPypi {
11 inherit pname version;
12- sha256 = "54436cd97b031bf2e08064223240e2a83d601d9414bcb1b702f94c6c33c29485";
13 };
1415 # click is only used for the repl, in most cases this shouldn't impact
···56buildPythonPackage rec {
7 pname = "celery";
8+ version = "5.1.2";
910 src = fetchPypi {
11 inherit pname version;
12+ sha256 = "8d9a3de9162965e97f8e8cc584c67aad83b3f7a267584fa47701ed11c3e0d4b0";
13 };
1415 # click is only used for the repl, in most cases this shouldn't impact
···5 # they fix more, because it even has at least one bugs less than 2.7.4.
6 # 2.8.0 does not start properly on linux
7 # They just starting making that 2.8.0 work on linux.
8- name = "egoboo-2.7.3";
0910 src = fetchurl {
11- url = "mirror://sourceforge/egoboo/${name}.tar.gz";
12 sha256 = "18cjgp9kakrsa90jcb4cl8hhh9k57mi5d1sy5ijjpd3p7zl647hd";
13 };
14···22 # The user will need to have all the files in '.' to run egoboo, with
23 # writeable controls.txt and setup.txt
24 installPhase = ''
25- mkdir -p $out/share/${name}
26- cp -v game/egoboo $out/share/${name}
27 cd ..
28- cp -v -Rd controls.txt setup.txt players modules basicdat $out/share/${name}
29 '';
3031 buildInputs = [ libGLU libGL SDL SDL_mixer SDL_image SDL_ttf ];
···5 # they fix more, because it even has at least one bugs less than 2.7.4.
6 # 2.8.0 does not start properly on linux
7 # They just starting making that 2.8.0 work on linux.
8+ pname = "egoboo";
9+ version = "2.7.3";
1011 src = fetchurl {
12+ url = "mirror://sourceforge/egoboo/egoboo-${version}.tar.gz";
13 sha256 = "18cjgp9kakrsa90jcb4cl8hhh9k57mi5d1sy5ijjpd3p7zl647hd";
14 };
15···23 # The user will need to have all the files in '.' to run egoboo, with
24 # writeable controls.txt and setup.txt
25 installPhase = ''
26+ mkdir -p $out/share/egoboo-${version}
27+ cp -v game/egoboo $out/share/egoboo-${version}
28 cd ..
29+ cp -v -Rd controls.txt setup.txt players modules basicdat $out/share/egoboo-${version}
30 '';
3132 buildInputs = [ libGLU libGL SDL SDL_mixer SDL_image SDL_ttf ];
···5 version = "1.42";
67 src = fetchurl {
8- url = "https://www.lcdf.org/type/${pname}-${version}.tar.gz";
9 sha256 = "YYd5NbGYcETd/0u5CgUgDKcWRnijVeFwv18aVVbMnyk=";
10 };
11···19 resources from a Macintosh font file or create a Macintosh Type 1 font
20 file from a PFA or PFB font.
21 '';
22- homepage = "http://www.lcdf.org/type/";
23 # README from tarball says "BSD-like" and points to non-existing LICENSE
24 # file...
25 license = "Click"; # MIT with extra clause, https://github.com/kohler/t1utils/blob/master/LICENSE
···5 version = "1.42";
67 src = fetchurl {
8+ url = "https://www.lcdf.org/type/t1utils-${version}.tar.gz";
9 sha256 = "YYd5NbGYcETd/0u5CgUgDKcWRnijVeFwv18aVVbMnyk=";
10 };
11···19 resources from a Macintosh font file or create a Macintosh Type 1 font
20 file from a PFA or PFB font.
21 '';
22+ homepage = "https://www.lcdf.org/type/";
23 # README from tarball says "BSD-like" and points to non-existing LICENSE
24 # file...
25 license = "Click"; # MIT with extra clause, https://github.com/kohler/t1utils/blob/master/LICENSE
···473 mess = mame; # added 2019-10-30
474 mcgrid = throw "mcgrid has been removed from nixpkgs, as it's not compatible with rivet 3"; # added 2020-05-23
475 mcomix = throw "mcomix has been removed from nixpkgs, as it's unmaintained; try mcomix3 a Python 3 fork"; # added 2019-12-10, modified 2020-11-25
476- mirage = throw "mirage has been femoved from nixpkgs, as it's unmaintained"; # added 2019-12-10
00477 mopidy-gmusic = throw "mopidy-gmusic has been removed because Google Play Music was discontinued"; # added 2021-03-07
478 mopidy-local-images = throw "mopidy-local-images has been removed as it's unmaintained. It's functionality has been merged into the mopidy-local extension."; # added 2020-10-18
479 mopidy-local-sqlite = throw "mopidy-local-sqlite has been removed as it's unmaintained. It's functionality has been merged into the mopidy-local extension."; # added 2020-10-18
···894 v8_3_16_14 = throw "v8_3_16_14 was removed in 2019-11-01: no longer referenced by other packages";
895 valadoc = throw "valadoc was deprecated on 2019-10-10: valadoc was merged into vala 0.38";
896 vamp = { vampSDK = vamp-plugin-sdk; }; # added 2020-03-26
00897 venus = throw "venus has been removed from nixpkgs, as it's unmaintained"; # added 2021-02-05
898 vdirsyncerStable = vdirsyncer; # added 2020-11-08, see https://github.com/NixOS/nixpkgs/issues/103026#issuecomment-723428168
899 vimbWrapper = vimb; # added 2015-01
···473 mess = mame; # added 2019-10-30
474 mcgrid = throw "mcgrid has been removed from nixpkgs, as it's not compatible with rivet 3"; # added 2020-05-23
475 mcomix = throw "mcomix has been removed from nixpkgs, as it's unmaintained; try mcomix3 a Python 3 fork"; # added 2019-12-10, modified 2020-11-25
476+ mirage = throw "mirage has been removed from nixpkgs, as it's unmaintained"; # added 2019-12-10
477+ minergate = throw "minergate has been removed from nixpkgs, because the package is unmaintained and the site has a bad reputation"; # added 2021-08-13
478+ minergate-cli = throw "minergatecli has been removed from nixpkgs, because the package is unmaintained and the site has a bad reputation"; # added 2021-08-13
479 mopidy-gmusic = throw "mopidy-gmusic has been removed because Google Play Music was discontinued"; # added 2021-03-07
480 mopidy-local-images = throw "mopidy-local-images has been removed as it's unmaintained. It's functionality has been merged into the mopidy-local extension."; # added 2020-10-18
481 mopidy-local-sqlite = throw "mopidy-local-sqlite has been removed as it's unmaintained. It's functionality has been merged into the mopidy-local extension."; # added 2020-10-18
···896 v8_3_16_14 = throw "v8_3_16_14 was removed in 2019-11-01: no longer referenced by other packages";
897 valadoc = throw "valadoc was deprecated on 2019-10-10: valadoc was merged into vala 0.38";
898 vamp = { vampSDK = vamp-plugin-sdk; }; # added 2020-03-26
899+ varnish62 = throw "varnish62 was removed from nixpkgs, because it is unmaintained upstream. Please switch to a different release."; # 2021-07-26
900+ varnish63 = throw "varnish63 was removed from nixpkgs, because it is unmaintained upstream. Please switch to a different release."; # 2021-07-26
901 venus = throw "venus has been removed from nixpkgs, as it's unmaintained"; # added 2021-02-05
902 vdirsyncerStable = vdirsyncer; # added 2020-11-08, see https://github.com/NixOS/nixpkgs/issues/103026#issuecomment-723428168
903 vimbWrapper = vimb; # added 2015-01