Commit Graph

18 Commits

Author SHA1 Message Date
Artturin
e0464e4788 treewide: replace stdenv.is with stdenv.hostPlatform.is
In preparation for the deprecation of `stdenv.isX`.

These shorthands are not conducive to cross-compilation because they
hide the platforms.

Darwin might get cross-compilation for which the continued usage of `stdenv.isDarwin` will get in the way

One example of why this is bad and especially affects compiler packages
https://www.github.com/NixOS/nixpkgs/pull/343059

There are too many files to go through manually but a treewide should
get users thinking when they see a `hostPlatform.isX` in a place where it
doesn't make sense.

```
fd --type f "\.nix" | xargs sd --fixed-strings "stdenv.is" "stdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "stdenv'.is" "stdenv'.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "clangStdenv.is" "clangStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "gccStdenv.is" "gccStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "stdenvNoCC.is" "stdenvNoCC.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "inherit (stdenv) is" "inherit (stdenv.hostPlatform) is"
fd --type f "\.nix" | xargs sd --fixed-strings "buildStdenv.is" "buildStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "effectiveStdenv.is" "effectiveStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "originalStdenv.is" "originalStdenv.hostPlatform.is"
```
2024-09-25 00:04:37 +03:00
Artturin
f9fdf2d402 treewide: move NIX_CFLAGS_COMPILE to the env attrset
with structuredAttrs lists will be bash arrays which cannot be exported
which will be a issue with some patches and some wrappers like cc-wrapper

this makes it clearer that NIX_CFLAGS_COMPILE must be a string as lists
in env cause a eval failure
2023-02-22 21:23:04 +02:00
Ben Siraphob
5d566c43b4 pkgs/applications: pkgconfig -> pkg-config 2021-01-16 23:49:59 -08:00
Ben Siraphob
108bdac3d9 pkgs/applications: stdenv.lib -> lib 2021-01-15 14:24:03 +07:00
Profpatsch
4a7f99d55d treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938

meta = with stdenv.lib;

is a widely used pattern. We want to slowly remove
the `stdenv.lib` indirection and encourage people
to use `lib` directly. Thus let’s start with the meta
field.

This used a rewriting script to mostly automatically
replace all occurances of this pattern, and add the
`lib` argument to the package header if it doesn’t
exist yet.

The script in its current form is available at
https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
2021-01-11 10:38:22 +01:00
Luflosi
f6bfc2c38b
wordgrinder: 0.7.2 -> 0.8
https://github.com/davidgiven/wordgrinder/releases/tag/0.8
2020-10-24 12:31:34 +02:00
Olli Helenius
8cb1e75e3b
wordgrinder: fix build 2020-09-13 19:47:53 +03:00
Michael Reilly
84cf00f980
treewide: Per RFC45, remove all unquoted URLs 2020-04-10 17:54:53 +01:00
volth
7b8fb5c06c treewide: remove redundant quotes 2019-09-08 23:38:31 +00:00
volth
46420bbaa3 treewide: name -> pname (easy cases) (#66585)
treewide replacement of

stdenv.mkDerivation rec {
  name = "*-${version}";
  version = "*";

to pname
2019-08-15 13:41:18 +01:00
Matthias Beyer
31bee0cc7c
wordgrinder: Fix build
First I tried to fix the build like this:

> This fixes the build of the wordgrinder package by disabling the build
> of "xwordgrinder", the non-curses frontend of wordgrinder.
>
> For re-enabling the build, this patch shall be reverted and then go on
> from there.
>
> I opted for disabling the x frontend of this program because the whole
> purpose of this is to use a curses writing program (at least for me).
> It seems that hacking around the new build system in nixpkgs is a
> non-trivial task and I wanted to get this package out of the door as
> fast as possible because I already delayed the fix by a few days (or is
> it weeks already), so this is the simple fix.
>
> If someone wants to have the X frontend again, I can invest more time at
> some point.

But then the almighty aszlig came around and told me how to do it right. So here
we go, with a patch from me that is acutally from aszlig (see #60122).

This fixes the build.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: aszlig <aszlig@nix.build>
Fixes: 6b2bd330fa ("wordgrinder: Fix sha256 hash")
Fixes: 19a3abc1b8 ("wordgrinder: 0.7.1 -> 0.7.2")
Merges: https://github.com/NixOS/nixpkgs/pull/60122
Cc: @devhell
2019-04-26 09:05:05 +02:00
aszlig
6b2bd330fa
wordgrinder: Fix sha256 hash
The hash used for fetchFromGitHub was on the archive itself, however
fetchFromGitHub is actually a wrapper of fetchzip:

hash mismatch in fixed-output derivation '...-source':
  wanted: sha256:1zqx3p9l22njni44ads3fyw3xh6807wmb5k1x2glg61z81cwc6sf
  got:    sha256:08lnq5wmspfqdjmqm15gizcq0xr7mg4h62qhvwj63v0sd6ks1cal

When using nix-prefetch-url without the --unpack argument, I get:

1zqx3p9l22njni44ads3fyw3xh6807wmb5k1x2glg61z81cwc6sf

And with the --unpack argument:

08lnq5wmspfqdjmqm15gizcq0xr7mg4h62qhvwj63v0sd6ks1cal

Just to be 100% sure the contents are the same, I also diffed the
contents of the former tarball with the outputs of the unpacked dir and
they're the same.

I didn't actually test the package (which doesn't build right now
anyway), but now at least the source checksum is fixed :-)

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @matthiasbeyer
2019-04-11 14:58:02 +02:00
Matthias Beyer
19a3abc1b8 wordgrinder: 0.7.1 -> 0.7.2 2019-04-08 10:13:47 +02:00
Matthias Beyer
f1f4f38909 Revert "Remove maintainership"
I'm baaaaack!

This patch reverts my patch where I removed myself as maintainer because
of my traveling. I'm back now and I want to maintain these packages
again.

This reverts commit ce1c1e3093.
2019-02-20 19:57:34 +01:00
Matthias Beyer
ce1c1e3093 Remove maintainership
With this patch I remove myself as a maintainer for all packages I
currently maintain.

This is due the fact that I will be basically off the grid from May 2018
until early 2019, as I will be on a trip through north america.

I will revert this patch as soon as I'm back, as I plan to continue
contributing to nixpkgs then.
But as I cannot maintain anything during that time, I'd like to get this
patch merged.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2018-04-06 10:57:19 +02:00
adisbladis
b8f6510859
wordgrinder: Fix darwin build 2018-02-10 21:26:21 +08:00
Victor Calvert
443687c31a wordgrinder: 0.6 -> 0.7.1 2018-01-05 23:21:04 -05:00
Matthias Beyer
208fd87149 wordgrinder: init at 0.6 2017-11-03 12:26:54 +02:00