summary refs log tree commit diff
path: root/pkgs/build-support/dotnet/build-dotnet-module/default.nix
Commit message (Collapse)AuthorAge
* buildDotnetModule: parse version before passing it to dotnetmdarocha2023-10-17
| | | | | This avoids problems when the Nix version attribute does not fit the format required by .NET
* buildDotnetModule: fix running fetch-deps with no nugetDeps defined.mdarocha2023-09-30
| | | | This eases the initial setup when creating a package
* buildDotnetModule: remove fetch-deps from tool packagesDavid McFarland2023-06-24
| | | | | This helps if we want to run nixpkgs.*.fetch-deps. Previously e.g. fable.fetch-deps existed, but was broken.
* buildDotnetModule: use tmp file for fetch-deps outputDavid McFarland2023-06-24
|
* buildDotnetModule: unset TMPDIR instead of setting it emptyDavid McFarland2023-06-24
| | | | | | | | | | | This was breaking nix-prefetch-url when running fetch-deps in nix-shell. e.g. $ TMPDIR= nix-prefetch-url foo nix-prefetch-url: src/libutil/util.cc:119: nix::Path nix::canonPath(PathView, bool): Assertion `path != ""' failed. [2] 881198 abort (core dumped)
* buildDotnetModule: allow lockFile path to be set in nugetDepsDavid McFarland2023-06-24
| | | | This allows fetch-deps to find the lock-file for roslyn.
* buildDotnetModule: add useDotnetFromEnv optionmdarocha2023-06-20
| | | | | This causes an alternative wrapper to be used, that takes the dotnet runtime from the environment.
* buildDotnetModule: tweaks to support paketmdarocha2023-06-20
| | | | | Projects that use paket, and have it setup so that it's executed transparently during "dotnet restore" as a dotnet tool should now work.
* buildDotnetModule: add support for dotnet toolsGuillaume Maudoux2023-04-29
|
* Merge pull request #217587 from winterqt/build-dotnet-module-darwin-sandbox7c6f434c2023-04-17
|\ | | | | buildDotnetModule: fix sandboxed builds on darwin
| * buildDotnetModule: fix sandboxed builds on darwinWinter2023-02-21
| | | | | | | | | | | | | | | | ICU tries to unconditionally load files from /usr/share/icu on Darwin, which makes builds fail in the sandbox. Thus, let's disable ICU during the build on Darwin by setting DOTNET_SYSTEM_GLOBALIZATION_INVARIANT [0]. [0]: https://learn.microsoft.com/en-us/dotnet/core/runtime-config/globalization#invariant-mode
* | treewide: don't hardcode /nix/store (no rebuilds changes)Artturin2023-03-24
| | | | | | | | improve experience for other store locations
* | buildDotnetModule: add support for using combinePackages as dotnet-sdkmdarocha2023-03-19
| | | | | | | | | | | | | | | | | | | | This allows packages that require several dotnet versions to build (like BeatSaberModManager) to properly depend on the dotnet-sdk specific deps. This in turns avoids having to regenerate the deps of those packages after each dotnet-sdk update. This also changes nuget-to-nix to accept a file with a list of exclusions instead of a folder.
* | buildDotnetModule: point fetch-deps at module's deps file by defaultAtemu2023-02-28
|/ | | | | | Previously, you had to provide the path to the deps.nix of the package inside your Nixpkgs checkout as an argument manually. Now it just does that by default when no argument is passed.
* build-dotnet-module: fix mktempErik Arvstedt2023-01-09
| | | | | | | Re-add missing `-t` arg which I erroneously removed in a98e52085584d806bd80ab203c7b75c4e361f522. Without it, the tmpdir is created in $PWD.
* build-dotnet-module: avoid `/run/user` for downloading packagesErik Arvstedt2023-01-07
| | | | | | | | | | | Inside `nix-shell`, `TMPDIR` (used by `mktemp`) is set to `/run/user/<uid>` which is usually a tmpfs stored in RAM. When fetching a large dotnet deps tree to this tmpdir from a nix-shell (e.g. via `btcpayserver/update.sh`), this can easily exceed system RAM and `fetch-deps` fails. mktemp arg `-t` is deprecated and can be omitted.
* build-dotnet-module: restore for current runtime by defaultDavid McFarland2022-12-19
|
* build-dotnet-module: add useAppHost parameter so it can be disabledDavid McFarland2022-12-19
|
* build-dotnet: make passthru.packages a derivationDavid McFarland2022-12-19
|
* build-dotnet-module: strip --runtime flags without using ridDavid McFarland2022-12-19
|
* dotnetCorePackages: move systemToDotnetRid out of sdkDavid McFarland2022-12-19
|
* treewide: fix typosfigsoda2022-12-17
|
* build-dotnet-module: don't end with exit code 1 when update was sucessfullSandro Jäckel2022-10-25
| | | | otherwise scripts might end prematurely
* nuget-to-nix: find sources deterministicallyDavid McFarland2022-10-02
| | | | | | | | | | | | | | | The source used to download a particular package still isn't deterministic in nuget. Even worse, the hash of the package can vary between sources. This makes nuget use the first enabled source containing the package. The order of the dependencies may be slightly different because it now uses glob order of the lower-case package names and versions, instead of sorting the output. If the package actually downloaded was the first source that contains the package, then it will be hashed from disk to avoid downloading it again.
* nuget-to-nix: exclude by package source, not listDavid McFarland2022-10-02
| | | | This allows exclusions to be by version.
* build-dotnet-module: fix fetch-deps usage messageDavid McFarland2022-10-02
|
* build-dotnet-module: limit package platforms by sdk supportDavid McFarland2022-10-02
|
* build-dotnet-module: clean up tmp file handlingDavid McFarland2022-10-02
| | | | | | | | | Having: rm -rf "$src" "$HOME" Was slightly terrifying IMO, especially where the trap was installed before HOME was set.
* buildDotnetModule: add the option to keep sources to fetch-depsIvar Scholten2022-09-18
|
* buildDotnetModule: move nugetDeps throw to when its actually neededIvar Scholten2022-09-18
| | | | | | | Previously we had an assert that would complain when nugetDeps wasnt set, which also didnt allow any passthru attributes (like fetch-deps) to be build. That causes a cycle where you need nugetDeps to fetch the nuget deps, but arent able to build the script to do so.
* buildDotnetModule: dont require specifing a projectFileIvar Scholten2022-09-18
| | | | | In a lot of cases dotnet can figure this out by itself, so we can just invoke it without the project argument.
* buildDotnetModule: format with nixpkgs-fmtIvar Scholten2022-09-18
|
* build-dotnet-module/fetch-deps: fixup temp naming when pname has a capital X ↵Cole Helbling2022-09-16
| | | | | | | | | | | | | | | | in it For example, this script doesn't work for `xivlauncher` because its proper `pname` is `XIVLauncher`, and `mktemp` complains about "too few X's": $ mktemp -td "XXXXXX-XIVLauncher-home" mktemp: too few X's in template ‘XXXXXX-XIVLauncher-home’ vs $ mktemp -td "XIVLauncher-home-XXXXXX" /tmp/XIVLauncher-home-EdGMei
* buildDotnetModule: restore for all platforms in fetch-depsIvar Scholten2022-09-11
| | | | | | | | This makes buildDotnetModule restore nuget dependencies for the platforms set in meta.platforms. This should help with generating lockfiles for platforms other than the host machine. Co-authored-by: mdarocha <git@mdarocha.pl>
* build-dotnet-module: Allow specifying the output path of fetch-depsZhaofeng Li2022-08-18
|
* buildDotnetModule: set fetch-deps utils via PATHEvan Petousis2022-08-18
|
* buildDotnetModule: use coreutils in fetch-depsEvan Petousis2022-08-18
| | | | | | cp on macOS doesn't support the -T flag, which causes the fetch-deps script to fail. Use Nix's coreutils to ensure the script works consistently across all platforms.
* buildDotnetModule: use platform-agnostic cp formatEvan Petousis2022-08-18
| | | | | | cp on macOS doesn't support the -T flag, which causes the fetch-deps script to fail. Appending `/.` to the source argument replicates the same functionality.
* buildDotnetModule: exclude sdk-specific packages in fetch-deps resultmdarocha2022-08-10
|
* buildDotnetModule: include sdk-specific packages in nuget sourcemdarocha2022-08-10
| | | | | | | | Some packages are defined by the build proccess, and change every time the dotnet-sdk package changes. To avoid having to regenerate every dependant packages dependencies every dotnet update, this moves these packages into the `dotnet-sdk` `passthru` attribute, and includes them every time `buildDotnetModule` is used.
* buildDotnetModule: add option to make a self-contained buildmdarocha2022-07-26
|
* Merge pull request #173889 from IvarWithoutBones/fix/dotnet-crossRick van Schijndel2022-07-16
|\ | | | | dotnet ecosystem: fix cross compilation
| * buildDotnetModule: fix cross compilationIvar Scholten2022-06-20
| |
* | Merge pull request #178446 from zimbatm/dotnet-nugetdepsIvv2022-06-21
|\ \ | | | | | | buildDotnetModule: allow passing derivations to nugetDeps
| * | buildDotnetModule: allow passing derivations to nugetDepszimbatm2022-06-21
| |/ | | | | | | | | | | | | | | Sometimes I want to pass a different implementation of `mkNugetDeps`. For example in private repos, it can be handy to use `__noChroot = true` and bypass the deps.nix generation altogether. Or some Nuget packages ship with ELF binaries that need to be patched, and that's best done as soon as possible.
* / buildDotnetModule: use src-only in fetch-deps scriptmdarocha2022-06-21
|/
* buildDotnetModule: change default dotnet SDK and runtime to version 6Ivar Scholten2022-05-16
| | | | dotnet 5 is now EOL.
* buildDotnetModule: nuget source cleanup=2022-04-30
| | | | | | | | | | | | There used to be a few issues with the way we generate the nuget source: * The derivation generated for the deps would have "nuget-deps" in them twice: /nix/store/...-foo-1.0-nuget-deps-nuget-deps * We always tried to generate the dependencies for "projectReferences" even when it wasn't set, causing a warning. This fixes those issues :)
* Merge pull request #162771 from IvarWithoutBones/dotnet-setuphookSandro2022-03-11
|\
| * treewide: don't unnecessary set dotnet-related env varsIvar Scholten2022-03-04
| | | | | | | | These have been moved to a setup hook in dotnet-{sdk,runtime,aspnetcore}