default.nix for Nix system
[Thread Prev] | [Thread Next]
- Subject: default.nix for Nix system
- From: Adrian Parvin Ouano <programmer@xxxxxxxxxxxxxxxxxxx>
- Reply-to: myrddin-dev@xxxxxxxxxxxxxx
- Date: Fri, 11 May 2018 14:58:03 +0800
- To: myrddin-dev@xxxxxxxxxxxxxx
Attached to this email is a default.nix to support Nix systems.
From 4d6146f3eb085c0a99b477a3f3889e384554671c Mon Sep 17 00:00:00 2001
From: "Adrian Parvin D. Ouano" <adrianparvino@xxxxxxxxx>
Date: Fri, 11 May 2018 14:49:37 +0800
Subject: [PATCH] Add default.nix for Nix systems
---
default.nix | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
create mode 100644 default.nix
diff --git a/default.nix b/default.nix
new file mode 100644
index 00000000..646eb63e
--- /dev/null
+++ b/default.nix
@@ -0,0 +1,25 @@
+{ pkgs ? (import <nixpkgs> {})
+, stdenv ? pkgs.stdenv
+, bison ? pkgs.bison
+, binutils ? pkgs.binutils
+, fetchurl ? pkgs.fetchurl
+}:
+
+stdenv.mkDerivation rec {
+ name = "myrddin";
+
+ src = ./.;
+
+ buildInputs = [ bison binutils ];
+
+ preBuild = ''
+ make bootstrap
+ '';
+
+ postPatch = ''
+ substituteInPlace "mbld/opts.myr" --replace '"ld"' '"${binutils}/bin/ld"'
+ substituteInPlace "configure" --replace '"ld"' '"${binutils}/bin/ld"'
+ substituteInPlace "mbld/opts.myr" --replace '"as"' '"${binutils}/bin/as"'
+ substituteInPlace "configure" --replace '"as"' '"${binutils}/bin/as"'
+ '';
+}
--
2.16.2
| Re: default.nix for Nix system | Ori Bernstein <ori@xxxxxxxxxxxxxx> |
- Prev by Date: Re: Myrddin 0.2.2: Build correctly using the LLVM linker.
- Next by Date: Re: default.nix for Nix system
- Previous by thread: Re: Myrddin 0.2.2: Build correctly using the LLVM linker.
- Next by thread: Re: default.nix for Nix system
- Index(es):