Commit graph

587 commits

Author SHA1 Message Date
Alyssa Ross
bd0c7ad05a
lib.systems: rust: Make rustcTargetSpec the primary entrypoint (#446668) 2026-03-07 08:22:44 +00:00
Tobias Mayer
4c05f197e6 lib.systems: s/makeMuslParsedPlatform/mkMuslSystem/ 2026-03-06 23:38:09 +01:00
Tristan Ross
3faec18180
lib.systems: expose makeMuslParsedPlatform (#490520) 2026-03-06 16:37:06 +00:00
İlkecan Bozdoğan
6acae46c84 lib: don't inherit unused functions 2026-03-04 00:10:00 +03:00
İlkecan Bozdoğan
e394a579b0 lib: update type signatures
- concrete types start with uppercase: Int, String, Bool, Derivation,
  etc.
- type variables start with lowercase: a, b, etc.
- list:
  - use `[x]` for homogeneous lists instead of `List x` or `[ x ]`
  - use `List` for heterogeneous lists (not that common in `lib`)
- attr:
  - use `AttrSet` for a generic attribute set type
  - use `{ key1 :: Type1; key2 :: Type2; ... }` for adding signatures
    for known attribute names and types
  - use `{ key1 = value1; key2 = value2; ... }` for adding attributes
    with known literals
  - end with an ellipsis (`...`) if the set can contain unknown
    attributes
  - use `{ [String] :: x }` if all the attributes has the same type `x`
- prefer `Any` over `a` if the latter is not reused
2026-03-04 00:10:00 +03:00
John Ericson
704e1a5c16
lib.systems: add uefi support (#477645) 2026-03-02 05:32:37 +00:00
dramforever
60ac986e49 lib.systems: rust: Make rustcTargetSpec the primary entrypoint
Make rustcTargetSpec the primary entrypoint for setting a custom target,
and wire up all the other stuff so they are hopefully as working and as
broken as before.

In particular, to specify a custom target, the user now just specifies
rust.rustcTargetSpec. rust.platform and rust.cargoShortTarget are
populated from rust.rustcTargetSpec now. In addition, rust.rustcTarget
defaults to rust.cargoShortTarget. (rust.rustcTarget and
rust.cargoShortTarget really should always be the same, but I think we
can deal with that later).

This allows the user to more easily control the basename of
rust.rustcTargetSpec by passing e.g.
"${./rust}/mips64el_mips3-unknown-linux-gnuabi64.json", which allows
cc-rs and in turn std to work.
2026-02-27 13:34:31 +08:00
dramforever
550a1b8eb5 lib.systems: Refactor rust.platform generation
In preparation for a future commit, refactor rust.platform somewhat.

No functional changes intended. Most of the diff here is whitespace
changes.
2026-02-25 11:18:23 +08:00
Tobias Mayer
4cd3967a68 lib.systems: expose makeMuslParsedPlatform
Moving this helper from pkgs/stdenv/stage.nix so it can be used
for alternative variations of pkgsMusl and pkgsStatic.
2026-02-14 23:09:33 +01:00
Alexandre Esteves
4255fb08c9 lib.systems: fix path to wine executable 2026-02-10 20:16:44 +00:00
Alyssa Ross
95c8d1ec1e
lib/systems/platforms: Add ppc64; linux: Add 64-bit POWER settings, strip vmlinux kernels (#447752) 2026-02-02 12:10:28 +00:00
Theo Paris
9f605ca95e
lib.systems: add uefi support
Signed-off-by: Theo Paris <theo@theoparis.com>
Change-Id: I51ce15449fc83f0ff39277d7cde7b34a6a6a6964

lib.systems: remove i686-uefi
2026-01-25 21:59:21 -08:00
Alexandre Esteves
03a5813e98 lib/systems: Add nodejs as emulator for pkgsCross.ghcjs 2026-01-25 23:16:19 +00:00
OPNA2608
2a6945e553 lib/systems/platforms: Drop powernv extraConfig
Settings are covered by ppc64 changes in common-config.
2026-01-22 15:41:33 +01:00
OPNA2608
3e6bae2fa4 lib/systems/platforms: Add ppc64 2026-01-22 15:40:36 +01:00
nixpkgs-ci[bot]
db8a4e9f0b
Merge master into staging-next 2026-01-15 18:09:05 +00:00
John Ericson
3ea6894af1
Add clang64 toolchain to pkgsCross (#450796) 2026-01-15 14:49:16 +00:00
nixpkgs-ci[bot]
95416609f8
Merge master into staging-next 2026-01-13 18:07:18 +00:00
aleksana
38be8c6c9b lib.systems: correct and simplify canExecute condition regarding march 2026-01-13 18:44:51 +08:00
umbrageodotus
7d034687f2 lib.systems.examples: Add LLVM x86-64 UCRT platform and clean up
Co-authored-by: Eveeifyeve <88671402+Eveeifyeve@users.noreply.github.com>
2026-01-12 21:56:05 -05:00
nixpkgs-ci[bot]
02cebb4644
Merge staging-next into staging 2026-01-06 18:07:38 +00:00
Sandro Jäckel
2459f7a596
platforms: drop REISERFS_FS 2026-01-03 04:37:48 +01:00
Alessandro Di Federico
90b59828be uclibc-ng: detect CONFIG_ARM_EABI from platform
This commit introduces a `isEabi` predicate for platforms and employs it
to detect whether to configure uclibc with CONFIG_ARM_EABI or not.
2025-12-30 19:05:44 +01:00
David McFarland
3dcf921c7b lib.systems: add isPE 2025-12-05 13:40:49 -04:00
K900
934d11cb78 Merge remote-tracking branch 'origin/staging-next' into staging 2025-11-02 00:50:30 +03:00
Wolfgang Walther
4949737a38
systems/examples: remove x86_64-unknown-redox
relibc itself has been removed in 2024 already.
2025-10-28 21:54:04 +01:00
nixpkgs-ci[bot]
584512ec5c
Merge staging-next into staging 2025-10-25 12:06:42 +00:00
Alyssa Ross
d563aa57de
lib.systems.parse: Default glibc ppc64 to ELFv1 ABI (#451088) 2025-10-25 09:57:43 +00:00
OPNA2608
37492033eb lib.systems.parse: Default glibc ppc64 to ELFv1 ABI 2025-10-11 21:00:33 +02:00
OPNA2608
8448c28919 lib.systems.examples.ppc64-elfv1: Drop manual fix of rust.rustcTarget
ABI is now simplified automatically.
2025-10-11 20:57:29 +02:00
OPNA2608
8b06bf875c lib.systems: Simplify ABI on POWER for rust.rustcTarget
Rust does not know how to parse "gnuabielfv{1,2}", so simplify those down to just "gnu".
This obsoletes the manual rustcTarget fix in the ppc64-elfv1 example.
2025-10-11 20:48:52 +02:00
Randy Eckenrode
2ab175889a
lib.systems.darwinMinVersion: 11.3 -> 14.0 2025-10-09 18:23:26 -04:00
Randy Eckenrode
cf45eef8ec
lib.systems.darwinSdkVersion: 11.3 -> 14.4 2025-10-09 18:23:26 -04:00
Philip Taron
44998896c6
lib: remove optional builtins prefixes from prelude functions (#447402) 2025-09-30 16:28:04 +00:00
NAHO
6177c4ad72
lib: remove optional builtins prefixes from prelude functions
Remove optional builtins prefixes from prelude functions by running:

    builtins=(
      abort
      baseNameOf
      break
      derivation
      derivationStrict
      dirOf
      false
      fetchGit
      fetchMercurial
      fetchTarball
      fetchTree
      fromTOML
      import
      isNull
      map
      null
      placeholder
      removeAttrs
      scopedImport
      throw
      toString
      true
    )

    fd --type file . lib --exec-batch sed --in-place --regexp-extended "
      s/\<builtins\.($(
        printf '%s\n' "${builtins[@]}" |
          paste --delimiter '|' --serial -
      ))\>/\1/g
    "

    nix fmt
2025-09-30 09:02:59 +02:00
David McFarland
39fd8e4adf cygwin: init as a target toolchain
The old cygwin support used -pc-windows-cygnus as the config.  This is
supported by LLVM, but not by GNU. This will change it to -pc-cygwin,
which is more generally supported.

Because the kernel is now 'cygwin' rather than 'windows', isWindows will
return false. There are lots of different reasons isWindows is used in
nixpkgs, but in my experience they often have to do with posix
compatibility and don't apply to cygwin.

Co-authored-by: Brian McKenna <brian@brianmckenna.org>
2025-09-27 13:29:44 -03:00
Marie Ramlow
b6d48619ed lib.systems: add ppc32 target 2025-09-10 08:15:07 +02:00
Fabián Heredia Montiel
0e9af74ced Merge remote-tracking branch 'origin/master' into staging-next 2025-08-18 22:43:58 -06:00
Emily
6e959288bb lib.systems.examples: bump Android SDK and NDK
Per <https://github.com/android/ndk/wiki>, NDK 26 is EOL.
2025-08-18 16:52:14 +01:00
nixpkgs-ci[bot]
c0dd2454fa
Merge staging-next into staging 2025-08-01 00:21:45 +00:00
Ross Smyth
4af7c6bdee lib.systems: Add examples & helpers for MSVC 2025-07-31 11:41:15 -04:00
Wolfgang Walther
90604d95bc
Merge branch 'staging-next' into staging 2025-07-24 14:33:09 +02:00
Wolfgang Walther
5a0711127c
treewide: run nixfmt 1.0.0 2025-07-24 13:55:40 +02:00
Colin
b3daf8c3a5 nodejs: split destCPU into stdenv.$platform.node
this architecture mapping is used broadly in the node ecosystem.
an assortment of tools and hooks, like buildNpmPackage or
pnpm.configHook, will benefit from reusing these values. placing them in
stdenv makes sense because (1) several of these tools don't currently
depend on nodejs, and may even be available where nodejs is not and (2)
`stdenv.{build,host,target}Platform` seems to be less error-prone than
`pkgs*.nodejs.{os,arch}` -- especially for setup hooks where the offsets
are shifted.
2025-07-07 03:07:58 +00:00
OPNA2608
8c6307d19b lib.systems.examples: Add rust.rustcTarget for ppc64-elfv1 2025-07-05 22:16:59 +02:00
OPNA2608
3a51005a85 lib.systems.inspect.patterns: init isAbiElfv1 2025-06-26 09:28:04 +02:00
OPNA2608
f5d07900bf lib.systems.examples: Split glibc powerpc64 back into 2 ABI options
ELFv1 is the historically better supported one on glibc, ELFv2 seems to have some issues with our toolchain.

Restore the option to pick the ABI with pkgsCross.
2025-06-21 11:01:02 +02:00
Alyssa Ross
f4c841ae5e
lib.systems: don't throw if go unsupported
Better to have a value that can actually be checked for, rather than
throwing, so optional Go support can be disabled when unsupported.
2025-05-30 14:57:33 +02:00
Gutyina Gergő
b3b0fd266b
lib: prefer replaceString over replaceStrings 2025-05-28 00:20:57 +02:00
Weijia Wang
9988795010 lib.systems.loongarch64-multiplatform: init 2025-05-25 14:43:14 +02:00