Commit Graph

7709 Commits

Author SHA1 Message Date
github-actions[bot]
2bffd64e73
Merge master into staging-next 2024-03-15 00:01:59 +00:00
Pol Dellaiera
8c40e060f3
build-support/php: update warnings when composer validate fails 2024-03-14 21:52:08 +01:00
github-actions[bot]
c160165e60
Merge master into staging-next 2024-03-14 18:01:26 +00:00
Silvan Mosberger
f60515ddea
Merge pull request #293416 from DanielSidhion/remove-makesnap
snapTools: remove
2024-03-14 16:46:22 +01:00
Lily Foster
ae86a507ed npmHooks.npmInstallHook: ignore bundle deps when calculating files to install
This assumes that downstream users of `buildNpmPackage` would rather our
own built `node_modules` be copied to the output rather than only the
`bundleDependencies` specified in the `package.json` file.

Having the latter behavior seems unexpected and unintuitive, and would
not work as installing from an `npm pack` is intended to (since doing
that would not do a `rebuild` step on those dependencies and it would
skip reifying a full dependency tree).
2024-03-14 14:04:51 +01:00
Robert Hensing
09364e249d
Merge pull request #295378 from hercules-ci/makeDerivationArgument
make-derivation.nix: Factor out `makeDerivationArgument`
2024-03-14 13:01:35 +01:00
Robert Hensing
8dad51a2e2 make-derivation.nix: Split makeDerivationArgument, mkDerivation with duplicate functionality 2024-03-12 18:16:56 +01:00
Philip Taron
e27bcfed1c
Avoid top-level with in pkgs/build-support/cc-wrapper/default.nix (#295213) 2024-03-12 08:34:58 +01:00
github-actions[bot]
0917422ffe
Merge staging-next into staging 2024-03-12 06:01:24 +00:00
Silvan Mosberger
1d14cc5182
Merge pull request #294944 from hercules-ci/docs-dedup-trivial-builders
trivial-builders: Deduplicate docs
2024-03-12 02:16:01 +01:00
Silvan Mosberger
aabd5fbfcf
Merge pull request #292259 from dawidd6/docker-nix-ssl
dockerTools: set NIX_SSL_CERT_FILE in image
2024-03-12 02:01:08 +01:00
a-n-n-a-l-e-e
ce789e7e35
llvmPackages_{12,13,14,15,16,17,git}.{libcxx,libcxxabi}: merge libcxxabi into libcxx (#292043)
- merge libcxxabi into libcxx for LLVM 12, 13, 14, 15, 16, 17, and git.
- remove the link time workaround `-lc++ -lc++abi` from 58 packages as it is no longer required.
- fixes https://github.com/NixOS/nixpkgs/issues/166205
- provides alternative fixes for. https://github.com/NixOS/nixpkgs/issues/269548 https://github.com/NixOS/nix/issues/9640
- pkgsCross.x86_64-freebsd builds work again

This change can be represented in 3 stages
1. merge libcxxabi into libcxx -- files: pkgs/development/compilers/llvm/[12, git]/{libcxx, libcxxabi}
2. update stdenv to account for merge -- files: stdenv.{adapters, cc.wrapper, darwin}
3. remove all references to libcxxabi outside of llvm (about 58 packages modified)

### merging libcxxabi into libcxx
- take the union of the libcxxabi and libcxx cmake flags
- eliminate the libcxx-headers-only package - it was only needed to break libcxx <-> libcxxabi circular dependency
- libcxx.cxxabi is removed. external cxxabi (freebsd) will symlink headers / libs into libcxx.
- darwin will re-export the libcxxabi symbols into libcxx so linking `-lc++` is sufficient.
- linux/freebsd `libc++.so` is a linker script `LINK(libc++.so.1, -lc++abi)` making `-lc++` sufficient.
- libcxx/default.nix [12, 17] are identical except for patches and `LIBCXX_ADDITIONAL_LIBRARIES` (only used in 16+)
- git/libcxx/defaul.nix  does not link with -nostdlib when useLLVM is true so flag is removed. this is not much different than before as libcxxabi used -nostdlib where libcxx did not, so libc was linked in anyway.

### stdenv changes
- darwin bootstrap, remove references to libcxxabi and cxxabi
- cc-wrapper: remove c++ link workaround when libcxx.cxxabi doesn't exist (still exists for LLVM pre 12)
- adapter: update overrideLibcxx to account for a pkgs.stdenv that only has libcxx

### 58 package updates
- remove `NIX_LDFLAGS = "-l${stdenv.cc.libcxx.cxxabi.libName}` as no longer needed
- swift, nodejs_v8 remove libcxxabi references in the clang override

https://github.com/NixOS/nixpkgs/pull/292043
2024-03-11 03:53:37 -07:00
Robert Hensing
e99021ff75 trivial-builders: Deduplicate docs
I didn't have the opportunity to do all work at once, so I've added
TODOs to bring attention to the situation.
2024-03-11 11:33:14 +01:00
github-actions[bot]
1966fd4ba6
Merge staging-next into staging 2024-03-09 18:01:41 +00:00
David McFarland
445b240555
Merge pull request #290351 from corngood/dotnet-fixes
dotnet: infrastructure cleanup
2024-03-09 11:34:48 -04:00
github-actions[bot]
38b6fd7904
Merge staging-next into staging 2024-03-08 06:01:32 +00:00
github-actions[bot]
b2ae37aca4
Merge master into staging-next 2024-03-08 06:01:02 +00:00
adisbladis
434df3c94b
Merge pull request #289231 from adisbladis/fetchnpmlock
importNpmLock: init
2024-03-08 15:14:37 +13:00
David McFarland
92a255d13b nuget-to-nix: fix error handling 2024-03-06 10:14:21 -04:00
github-actions[bot]
b859baf176
Merge staging-next into staging 2024-03-06 12:01:41 +00:00
github-actions[bot]
d6370b05b5
Merge master into staging-next 2024-03-06 12:01:15 +00:00
Pol Dellaiera
c224b6e894
Merge pull request #293582 from drupol/build-support/php/improve-composer-validate
build-support/php: update `composer validate` steps
2024-03-06 10:47:35 +01:00
github-actions[bot]
b5be23cc08
Merge staging-next into staging 2024-03-06 00:02:47 +00:00
github-actions[bot]
8660ec23c7
Merge master into staging-next 2024-03-06 00:02:17 +00:00
David McFarland
5706443baf
Merge pull request #190129 from corngood/dotnet-sdk
dotnetCorePackages.dotnet_8: build from source
2024-03-05 18:41:04 -04:00
Pol Dellaiera
b2af238d31
build-support/php: update composer validate steps 2024-03-05 22:50:46 +01:00
Pol Dellaiera
bc627a6aca
build-support/php: move functions around (dry) 2024-03-05 19:39:35 +01:00
Pol Dellaiera
cf9e77ef8e
phpPackages.composer: 2.6.6 -> 2.7.1
Diff: https://github.com/composer/composer/compare/2.6.6..2.7.1
Changelog: https://github.com/composer/composer/releases/tag/2.7.1
Fix CVE: CVE-2024-24821
2024-03-05 19:39:35 +01:00
Pol Dellaiera
39502e7aa7
build-support/php/composer-local-repo-plugin: 1.0.3 -> 1.1.0 2024-03-05 19:39:35 +01:00
DS
1d85557b50 snapTools: remove
`snapTools.makeSnap` has produced broken snaps since at least Oct 2020,
as indicated by the following issue: https://github.com/NixOS/nixpkgs/issues/100618

No person has shown interest in maintaining it, and given that there is
no fix available, it's assumed that all attempts made to fix that
function have not succeeded.

Given that `snapTools` only contained `makeSnap`, it was removed
completely.
2024-03-04 22:22:14 -08:00
adisbladis
b6e4b86809 importNpmLock: init
This is an alternative to `fetchNpmDeps` that is notably different in that it uses metadata from `package.json` & `package-lock.json` instead of specifying a fixed-output hash.

Notable features:
- IFD free.
- Only fetches a node dependency once. No massive FODs.
- Support for URL, Git and path dependencies.
- Uses most of the existing `npmHooks`

`importNpmLock` can be used _only_ in the cases where we need to check in a `package-lock.json` in the tree.
Currently this means that we have 13 packages that would be candidates to use this function, though I expect most usage to be in private repositories.

This is upstreaming the builder portion of https://github.com/adisbladis/buildNodeModules into nixpkgs (different naming but the code is the same).
I will archive this repository and consider nixpkgs the new upstream once it's been merged.

For more explanations and rationale see https://discourse.nixos.org/t/buildnodemodules-the-dumbest-node-to-nix-packaging-tool-yet/35733

Example usage:
``` nix
stdenv.mkDerivation {
  pname = "my-nodejs-app";
  version = "0.1.0";

  src = ./.;

  nativeBuildInputs = [
    importNpmLock.hooks.npmConfigHook
    nodejs
    nodejs.passthru.python # for node-gyp
    npmHooks.npmBuildHook
    npmHooks.npmInstallHook
  ];

  npmDeps = buildNodeModules.fetchNodeModules {
    npmRoot = ./.;
  };
}
```
2024-03-05 12:23:28 +13:00
github-actions[bot]
77ea4cb645
Merge staging-next into staging 2024-03-04 12:06:32 +00:00
github-actions[bot]
6620dd578c
Merge master into staging-next 2024-03-04 12:06:01 +00:00
github-actions[bot]
7e5216523f
Merge staging-next into staging 2024-03-04 06:11:00 +00:00
github-actions[bot]
1a3380fec6
Merge master into staging-next 2024-03-04 06:10:33 +00:00
Vladimír Čunát
ea4b95755d
Revert "writers: add support for wrapping" 2024-03-04 07:05:23 +01:00
lassulus
97345af560
Merge pull request #291854 from DavHau/writers-wrap
writers: add support for wrapping
2024-03-04 08:37:18 +07:00
David McFarland
6b047e397a mkNugetDeps: provide default for nugetDeps 2024-03-03 09:57:47 -04:00
David McFarland
ca181cefee nuget-to-nix: skip local sources 2024-03-03 09:57:47 -04:00
Sandro
0c448ca515
Merge pull request #292616 from alyssais/libredirect-LFS64
libredirect: don't test LFS64 functions on musl
2024-03-02 20:31:14 +01:00
Martin Weinelt
76d0baf0c2
Merge pull request #292777 from alyssais/rustdoc-wrap
wrapRustc: wrap rustdoc
2024-03-02 15:09:14 +01:00
Alyssa Ross
6f8fa05acf
wrapRustc: wrap rustdoc
We need to set -crt-static on musl for rustdoc as well, so let's unify
the wrappers.  Ideally, rather than wrapping rustdoc, we'd have
rustdoc use the wrapped rustc, but that's currently only possible with
an unstable option (--test-builder).

The options set by the wrapper, -C target-feature and --sysroot, are
supported by both rustdoc and rustc, but other flags maybe not be
supported by both, so I've introduced different environment
variables (the existing NIX_RUSTFLAGS and a new NIX_RUSTDOCFLAGS) to
allow those to be set independently.

This fixes cargo-auditable in pkgsMusl., which broke because its
doctests stopped working when -crt-static was moved to the wrapper.

Fixes: 79156bf13a ("rustc: move crt-static default override to wrapper (#291829)")
2024-03-02 13:09:07 +01:00
github-actions[bot]
9819563ca9
Merge master into staging-next 2024-03-02 06:00:53 +00:00
Gabriella Gonzalez
b8698cd8d6
macOS support for NixOS tests (#282401)
Closes #193336
Closes #261694
Related to #108984

The goal here was to get the following flake to build and run on
`aarch64-darwin`:

```nix
{ inputs.nixpkgs.url = <this branch>;

  outputs = { nixpkgs, ... }: {
    checks.aarch64-darwin.default =
      nixpkgs.legacyPackages.aarch64-darwin.nixosTest {
        name = "test";

        nodes.machine = { };

        testScript = "";
      };
  };
}
```

… and after this change it does.  There's no longer a need for the
user to set `nodes.*.nixpkgs.pkgs` or
`nodes.*.virtualisation.host.pkgs` as the correct values are inferred
from the host system.
2024-03-02 06:33:14 +01:00
Alyssa Ross
13eea132c0
libredirect: don't test LFS64 functions on musl
These were removed in musl 1.2.4.
2024-03-02 01:02:36 +01:00
github-actions[bot]
18bc3c64e6
Merge master into staging-next 2024-03-01 12:00:58 +00:00
Vladimír Čunát
0e4d8e918e
Merge #291901: clang: don't set -march for overridden target
...into staging-next
2024-03-01 11:32:18 +01:00
Alyssa Ross
12b0e8ac74
clang: don't set -march for overridden target
If -target is explicitly passed to clang, we shouldn't pass our -march
value for the default target, because it probably won't exist for the
target being used.  Up until now, clang has been lenient with this,
but it's a hard error with clang 17, so since gcc.arch is always set
on aarch64, fixing this is a hard requirement for upgrading our
default clang to 17.

Before (with clang 17 on aarch64-linux):

	$ clang -target bpf -c -o /dev/null test.bpf.c
	clang: warning: ignoring '-fstack-protector-strong' option as it is not currently supported for target 'bpf' [-Woption-ignored]
	clang: error: unsupported option '-march=' for target 'bpf'
	clang: warning: argument unused during compilation: '--gcc-toolchain=/nix/store/cngak08nb1yk44gnjipv5rg1ahh1xkax-gcc-13.2.0' [-Wunused-command-line-argument]

After:

	$ clang -target bpf -c -o /dev/null test.bpf.c
	clang: warning: ignoring '-fstack-protector-strong' option as it is not currently supported for target 'bpf' [-Woption-ignored]
	clang: warning: argument unused during compilation: '--gcc-toolchain=/nix/store/cngak08nb1yk44gnjipv5rg1ahh1xkax-gcc-13.2.0' [-Wunused-command-line-argument]
2024-03-01 09:51:49 +01:00
lassulus
2db7e7c5e2
Merge pull request #292300 from hsjobeki/writers
doc & fix: Clean up writers/data.nix file
2024-03-01 13:44:29 +07:00
github-actions[bot]
c7d7e4a7a5
Merge staging-next into staging 2024-02-29 18:01:30 +00:00