Commit Graph

203 Commits

Author SHA1 Message Date
Tuomas Tynkkynen
f4dd2fed7f ghc: Replace meta.available checks for enableIntegerSimple
This sort of code breaks config.{allowBroken, allowUnsupportedSystem} =
true by making them do unpredictable things.
2018-09-28 15:01:00 +03:00
John Ericson
e6a476c862 ghc, ghcjs: Get rid of extraneous alex, happy, and hscolour args
The compilers themselves can pull them from `bootPkgs`, where they
should always come from anyways. This enforces that, simplifies that
code, and allows use to avoid more `rec { ... }` too.
2018-09-24 20:00:39 -04:00
John Ericson
0828e2d8c3 treewide: Remove usage of remaining redundant platform compatability stuff
Want to get this out of here for 18.09, so it can be deprecated
thereafter.
2018-08-30 17:20:32 -04:00
Matthew Bauer
13c8acc3db Revert "Merge pull request #44767 from obsidiansystems/wrapper-env-var-path"
This reverts commit 89efc27f57, reversing
changes made to d0f11020ca.
2018-08-22 01:14:53 +02:00
John Ericson
30ea1bfd22 ghc-*: Tool env vars no longer need to be made full paths 2018-08-08 17:16:16 -04:00
volth
52f53c69ce pkgs/*: remove unreferenced function arguments 2018-07-21 02:48:04 +00:00
Will Dietz
2996d29f71 ghc: don't use LLVM w/musl on non-cross
Doesn't appear to be needed on musl-native on x86_64,
and on non-x86(-64) it's included anyway.
2018-07-11 21:34:47 -05:00
Will Dietz
0e40e0cc7d ghcHEAD: useLLVM needed for musl here as well 2018-06-25 15:50:36 -05:00
Will Dietz
61e3bd20a0 ghcHEAD: move hardeningDisable definition for cleaner diff against 8.4.3
NFCI (no functionality change intendend)
2018-06-25 15:50:36 -05:00
Will Dietz
449fbec9be ghcHEAD: add musl and cross fixes recently applied to 8.4.3 and 8.2.2 2018-06-25 15:50:27 -05:00
Matthew Bauer
fd7a6ea0af haskell: make generic builder follow compiler’s shared config
enableShared in generic-builder.nix should default to what the GHC
compiler was compiled with. Add a passthru to all of the GHC compilers
to hold the value of enableShared. If enableShared is not set in the
GHC we just use false as the default value for enableSharedLibraries.

Note: I may have missed some compilers. Only GHC & GHCJS are covered
by this commit but this shouldn’t break evaluation of anything else.
2018-06-20 18:40:53 -04:00
John Ericson
812decd5c1 ghc: Default integer-simple usage based one whether GNU MP is available
The user's choice is still always respected
2018-06-11 15:51:57 -04:00
Peter Simons
57fed4f5b5 haskell.compiler.ghcHEAD: disable format hardening 2018-05-30 03:46:16 +02:00
Peter Simons
e168ae6a9d ghc: build version >8.4 with hscolour to enable source links
Fixes https://github.com/NixOS/nixpkgs/issues/41179.
2018-05-30 03:46:16 +02:00
Jan Malakhovski
ad35019501 Merge branch 'master' into staging
Fixed conflicts:
- lib/systems/for-meta.nix: in favor of staging
- pkgs/os-specific/darwin/xcode/default.nix: in favor of master
2018-05-26 00:20:17 +00:00
Moritz Angermann
fe1eec9e24 ghc 8.4.2, head: Drop libiconv on windows.
nixpkgs#37012 and  nixpkgs#37707 introduces the setup-hooks for libiconv, which inject `-liconv` into the `NIX_LDFLAGS`. This breaks horribly on windows where the linker end up having no idea how to linke `-liconv`. The configure.ac file specifically ignores libiconv on windows.
2018-05-23 10:41:17 -04:00
John Ericson
c7458ded5c ghc 8.4.2, head: Adjust enableShared enableTerminfo for windows 2018-05-23 10:41:17 -04:00
Moritz Angermann
10b76a4cab ghc: paxmark all unwraped executables across the board
Shell glob works even as the exact set of executable (filenames) varries
beween configuations. Need to skip non ELFs (e.g. shell scripts),
however.
2018-05-23 10:41:15 -04:00
John Ericson
1978115c3b ghc: Handle flavors better 2018-05-23 10:27:42 -04:00
John Ericson
9ce15ea60c ghc: Normalize derivations 2018-05-23 10:27:42 -04:00
John Ericson
18742471af Merge remote-tracking branch 'upstream/master' into staging
Use newer vagrant from master
2018-05-23 09:40:37 -04:00
Peter Simons
5db3a9df5e
Revert "ghc, haskell infra: #40642 direct to master" 2018-05-23 09:36:16 +02:00
John Ericson
d6ecbbe921
Merge branch 'staging' into feature/clean-ghc 2018-05-21 17:43:30 -04:00
Moritz Angermann
4b48094285 ghc 8.4.2, head: Drop libiconv on windows.
nixpkgs#37012 and  nixpkgs#37707 introduces the setup-hooks for libiconv, which inject `-liconv` into the `NIX_LDFLAGS`. This breaks horribly on windows where the linker end up having no idea how to linke `-liconv`. The configure.ac file specifically ignores libiconv on windows.
2018-05-21 15:11:12 -04:00
John Ericson
03602f8162 ghc 8.4.2, head: Adjust enableShared enableTerminfo for windows 2018-05-21 15:11:12 -04:00
Moritz Angermann
6af0c192d1 ghc: paxmark all unwraped executables across the board
Shell glob works even as the exact set of executable (filenames) varries
beween configuations.
2018-05-21 15:11:12 -04:00
John Ericson
8d2ce113d5 ghc: Handle flavors better 2018-05-21 15:11:12 -04:00
John Ericson
6f2f081b90 ghc: Normalize derivations 2018-05-21 15:11:12 -04:00
John Ericson
5e17335bd7 Merge remote-tracking branch 'upstream/staging' into strictDeps 2018-05-14 23:33:03 -04:00
John Ericson
330ca731e8 treewide: Get rid of all uses of crossConfig
The hack of using `crossConfig` to enforce stricter handling of
dependencies is replaced with a dedicated `strictDeps` for that purpose.
(Experience has shown that my punning was a terrible idea that made more
difficult and embarrising to teach teach.)

Now that is is clear, a few packages now use `strictDeps`, to fix
various bugs:

 - bintools-wrapper and cc-wrapper
2018-05-14 23:30:37 -04:00
Will Fancher
8012aee0a7 Don't enableShared in GHC when using android prebuilt 2018-05-07 23:57:31 -04:00
Will Fancher
0afb45d574 Set the C standard when building GHC
Should this be in cc-wrapper?
2018-05-07 23:57:31 -04:00
John Ericson
b9acfb4ecf treewide: isArm -> isAarch32
Following legacy packing conventions, `isArm` was defined just for
32-bit ARM instruction set. This is confusing to non packagers though,
because Aarch64 is an ARM instruction set.

The official ARM overview for ARMv8[1] is surprisingly not confusing,
given the overall state of affairs for ARM naming conventions, and
offers us a solution. It divides the nomenclature into three levels:

```
ISA:             ARMv8   {-A, -R, -M}
                 /    \
Mode:     Aarch32     Aarch64
             |         /   \
Encoding:   A64      A32   T32
```

At the top is the overall v8 instruction set archicture. Second are the
two modes, defined by bitwidth but differing in other semantics too, and
buttom are the encodings, (hopefully?) isomorphic if they encode the
same mode.

The 32 bit encodings are mostly backwards compatible with previous
non-Thumb and Thumb encodings, and if so we can pun the mode names to
instead mean "sets of compatable or isomorphic encodings", and then
voilà we have nice names for 32-bit and 64-bit arm instruction sets
which do not use the word ARM so as to not confused either laymen or
experienced ARM packages.

[1]: https://developer.arm.com/products/architecture/a-profile

(cherry picked from commit ba52ae5048)
2018-04-25 15:50:41 -04:00
John Ericson
ba52ae5048 treewide: isArm -> isAarch32
Following legacy packing conventions, `isArm` was defined just for
32-bit ARM instruction set. This is confusing to non packagers though,
because Aarch64 is an ARM instruction set.

The official ARM overview for ARMv8[1] is surprisingly not confusing,
given the overall state of affairs for ARM naming conventions, and
offers us a solution. It divides the nomenclature into three levels:

```
ISA:             ARMv8   {-A, -R, -M}
                 /    \
Mode:     Aarch32     Aarch64
             |         /   \
Encoding:   A64      A32   T32
```

At the top is the overall v8 instruction set archicture. Second are the
two modes, defined by bitwidth but differing in other semantics too, and
buttom are the encodings, (hopefully?) isomorphic if they encode the
same mode.

The 32 bit encodings are mostly backwards compatible with previous
non-Thumb and Thumb encodings, and if so we can pun the mode names to
instead mean "sets of compatable or isomorphic encodings", and then
voilà we have nice names for 32-bit and 64-bit arm instruction sets
which do not use the word ARM so as to not confused either laymen or
experienced ARM packages.

[1]: https://developer.arm.com/products/architecture/a-profile
2018-04-25 15:28:55 -04:00
Will Fancher
a9646b39cf Fix haskellCompilerName version.
This matters for `callCabal2nix`, when the cabal file has something
like `if impl(ghc >= 7.7)`
2018-02-22 03:11:25 -05:00
Ben Gamari
bf687907d7 haskell lib: Make Cabal compiler names explicit
Cabal2nix expects a --compiler flag that contains a Cabal Compiler description.
We used to use the compiler's derivation name for this, but this breaks when
cross-compiling due to the target suffix. Instead we add an explicit
haskellCompilerName attribute to Haskell compiler derivations.
2018-01-21 23:31:05 -05:00
John Ericson
a2516efb26 ghcHEAD: Bump version ghc-8.5.20180118 2018-01-21 23:31:04 -05:00
Ben Gamari
af03b7746a ghc 8.2.2 & head: Work around ARM bugs in BFD ld by using gold 2018-01-21 23:31:03 -05:00
Ryan Trinkle
bd0de2f1cb ghc: Fix env vars and configure flags to be weird
GHC currently handles this stuff in a quite non-standard way, basically
taking prog var `FOO` to mean `FOO_FROM_TARGET`. It's because it
(wrongly) thinks from stage 2's perspective.
2018-01-21 23:31:03 -05:00
John Ericson
e760de8108 ghc: Predicate libiconv on not using glibc instead of Darwin 2018-01-21 23:31:03 -05:00
John Ericson
398ac54593 ghc: Fix cross compilation to work with new system 2018-01-21 23:31:03 -05:00
John Ericson
bc16cfc009 ghc: Remove old cross work
That way the next commit can apply a similar diff to each GHC.
2018-01-21 23:31:02 -05:00
John Ericson
0eb3acaf38 ghc: echo -n mk/build.mk to avoid extra line 2018-01-21 23:27:38 -05:00
John Ericson
5a6b6b4ac5 ghc: Normalize derivations a bit before cross
These changes will affect the final derivation
2018-01-21 23:27:38 -05:00
John Ericson
3fb5fd0060 ghc: Normalize derivations in hash-preserving ways 2018-01-03 17:04:19 -05:00
John Ericson
faa4b45a1e ghc 8.2.2, head: Inline common* bindings
Cross case purposely changed as it will be rewritten anyways. But no
native hashes should be changed.
2018-01-02 21:00:23 -05:00
John Ericson
a5cc983c45 ghc: Clean up, and add passthru.targetPrefix, in preparation for cross
No hashes should be changed.
2018-01-02 19:50:38 -05:00
Matthew Pickering
e7a327da5c ghcHEAD: 8.3.20170808 -> 8.5.20171208 2017-12-09 11:04:31 +00:00
Peter Simons
8d8061ec20
Revert "Revive multiple outputs for Haskell packages." 2017-12-05 09:36:08 +01:00
Nicholas Clarke
d90165c7db Revert "Revert "Merge pull request #27209 from nc6/nc/haskell-multiple-out""
This reverts commit 89f5d52cf4.
2017-11-27 16:05:22 +00:00
John Ericson
4d4f94cde4 treewide: Depend on targetPackages.stdenv.cc.bintools instead of binutils directly
One should do this when needed executables at run time. It is more
honest and cross-friendly than refering to binutils directly, if one
neeeds the default binary tools for the target platform, rather than
binutils in particular.
2017-11-05 17:10:53 -05:00
Peter Simons
89f5d52cf4 Revert "Merge pull request #27209 from nc6/nc/haskell-multiple-out"
This reverts commit dfb0f25484, reversing
changes made to 7f8ff02437. These changes broke
the ghcWithPackages wrapper:

    nix-shell -p "haskellPackages.ghcWithPackages (ps: [ps.mtl])" --run "ghc-pkg list mtl"
    /nix/store/szz84j5k1dy3jdashis6ws28d8l8zxxb-ghc-8.0.2-with-packages/lib/ghc-8.0.2/package.conf.d
        (no packages)
2017-09-06 10:19:18 +02:00
Nicholas Clarke
8c642d5937 Provide hscolour, happy, alex bin to buildInputs.
Use stdenv.lib.getBin instead of `.bin`
2017-09-04 12:35:57 +01:00
Matthew Pickering
770743bd91 Bump ghc HEAD version ghc-8.3.20170808 2017-08-08 17:32:32 +00:00
Matthew Pickering
4021d4d5ee Make version a parameter in GHC HEAD derivation
If you want to override the source but the major version changes (ie 8.1
-> 8.3) then you also have to modify the version. Otherwise the build
will fail with difficult to understand errors, making version a
parameter makes it easy to override.
2017-08-08 17:19:02 +00:00
Silvan Mosberger
f5fa5fa4d6 pkgs: refactor needless quoting of homepage meta attribute (#27809)
* pkgs: refactor needless quoting of homepage meta attribute

A lot of packages are needlessly quoting the homepage meta attribute
(about 1400, 22%), this commit refactors all of those instances.

* pkgs: Fixing some links that were wrongfully unquoted in the previous
commit

* Fixed some instances
2017-08-01 22:03:30 +02:00
John Ericson
12795a7068 misc: Remove almost all uses of stdenv.{ccCross,binutils} 2017-06-22 17:53:52 -04:00
John Ericson
594d264205 cross stdenv adaptor: Support --host --build --target across the board
Packages get --host and --target by default, but can explicitly request
any subset to be passed as needed. See docs for more info.

rustc: Avoid hash breakage by using the old (ignored)
dontSetConfigureCross when not cross building
2017-06-22 17:52:28 -04:00
John Ericson
8f970d09fe ghcHEAD: Actually split docs into their own output
I put `outputs = ...` in the wrong spot in the last PR, oops. Sorry
about that.
2017-06-22 16:56:58 -04:00
John Ericson
dd99d1f8d0 ghcHEAD: Split docs into their own output
This ghc was forgetten from 2089dd4ab6
2017-06-17 15:13:43 -04:00
Peter Simons
a1b6c5f5d6 Revert "Use consistent package naming for HEAD.nix files" for GHC and GHCjs.
This reverts commit 31b0e34d1d. The version
numbers used in that commit were no improvement.
2017-05-09 17:59:28 +02:00
rht
31b0e34d1d
Use consistent package naming for HEAD.nix files 2017-05-09 10:31:15 +07:00
John Ericson
295315cc87 binutilsCross: Remove and use binutils instead always
See previous commit for what was done to `binutils` to make this
possible.

There were some uses of `forcedNativePackages` added. The
combination of overrides with that attribute is highly spooky: it's
often important that if an overridden package comes from it, the
replaced arguments for that package come from it. Long term this
package set and all the spookiness should be gone and irrelevant:

  "Move along, nothing to see here!"

No hashes should be changed with this commit
2017-04-25 21:36:19 -04:00
3noch
4b77d425aa
Fix GHCJS HEAD patch; support GHCJS libdir link; use full ghcEnv for GHCJS
Original:
f3110651c8

(With some tweaks from @cstrahan)

closes #23199
2017-03-02 11:35:11 -05:00
3noch
7d356ff696
Disable large address space in GHC iOS X compiler
Original:
17cea33d1a
2017-03-02 11:34:15 -05:00
Bas van Dijk
dfcc9e2994 ghc: support building with integer-simple and provide package sets for it
If the flag enableIntegerSimple is true GHC will be build with the GPL-free but
slower integer-simple library instead of the faster but GPLed integer-gmp
library.

The attribute `pkgs.haskell.compiler.integer-simple."${ghcVersion}"` provides a
GHC compiler build with `integer-simple`.

Similarly, the attribute `pkgs.haskell.packages.integer-simple."${ghcVersion}"`
provides a package set supporting `integer-simple`.

Closes https://github.com/NixOS/nixpkgs/pull/22121.
Closes https://github.com/NixOS/nixpkgs/issues/5493.
2017-02-02 10:57:00 +01:00
John Ericson
a1a798f017 top-level: crossSystem is no longer exposed to packages. Use *Platform. 2017-01-24 11:37:56 -05:00
Shea Levy
46bec22f66 Revert "Add function to build a ghc standalone archive (OSX/iOS only)"
Partial revert of accidental changes.

This reverts commit 4f9f00fcc9.
2017-01-23 18:37:15 -05:00
Shea Levy
4f9f00fcc9 Add function to build a ghc standalone archive (OSX/iOS only) 2017-01-23 18:35:03 -05:00
Shea Levy
845dd121f8 ghc-head: Put ./boot into commonPreConfigure 2017-01-06 22:10:29 -05:00
Shea Levy
3c2cbd3259 ghc-head: bump 2017-01-06 08:39:12 -05:00
Matthew Pickering
4541b10904 Refactor ghcHEAD postPatch / preConfigure phases
This is for GHC developers using NixOS where patchShebangs is
inconvenient as it dirties the tree but unnecessary for compilation.
2016-12-26 13:27:34 +00:00
Matthew Pickering
d906fb2c9a Bump ghcHEAD to latest commit 2016-12-26 13:27:33 +00:00
Matthew Pickering
0cd5ebb48f Configure checkPhase for ghcHEAD
The testsuite requires python3 so we have to add it as a dependency.
2016-12-26 13:27:33 +00:00
Will Dietz
387066357d ghc-8.x: paxmark ghc and haddock 2016-12-19 10:55:29 +01:00
Franz Pletz
f01dd648f5
Merge branch 'master' into staging 2016-11-23 02:06:26 +01:00
Peter Simons
02668d6c6a ghc: drop patch that disables use of response files
https://github.com/NixOS/nixpkgs/issues/11762 has been fixed by
1ad1edbb32.
2016-11-19 20:21:32 -04:00
Shea Levy
64ec4dd87b Add haskell packages set for cross ghc 2016-11-18 10:44:53 -05:00
Shea Levy
da547f7961 ghcHEAD: Add back response files patch 2016-11-17 01:05:21 -05:00
Shea Levy
d9e63424b7 ghc-HEAD: Run boot after patches.
This allows for patches affecting configure.ac to take effect
2016-11-15 19:44:21 -05:00
Shea Levy
6f7593fddc ghc-head: fix hash.
Apparently fetchgit lies...
2016-11-15 18:30:32 -05:00
Shea Levy
845b56d25a Initial support for cross-compiling ghc 2016-11-15 16:59:09 -05:00
Daniel Haraj
bac1189399 haskell.compiler.ghcHEAD: fix patchPhase #10752 2016-11-09 14:26:43 -05:00
Ollie Charles
a4f2d339fe haskell.compiler.ghcHEAD: Update to latest upstream 2016-11-08 10:03:05 +00:00
Mathieu Boespflug
4b34e4a7cb haskell.compiler.ghcHEAD: update to latest upstream (20160930).
Includes several fixes necessary for inline-java full functionality.
2016-10-04 17:51:37 +02:00
Mathieu Boespflug
5f8891153b haskell.compiler.ghcHEAD: update to latest upstream (20160826). 2016-08-26 21:15:04 +02:00
Tuomas Tynkkynen
74a3a2cd7e treewide: Use makeBinPath 2016-08-23 01:18:10 +03:00
Peter Simons
8e462995ba Bring my stdenv.lib.maintainers user name in line with my github nick. 2016-05-16 22:49:55 +02:00
Peter Simons
2422ae0838 ghc: update 8.0.x pre-release from rc2 to rc3 2016-04-14 09:17:55 +02:00
Thomas Tuegel
3ef7671cea ncurses: combine $lib and $out outputs
The $lib output refers to the terminfo database in $out, which is about
10x larger than the ncurses shared library. Splitting these outputs
saves a small amount of space for any derivations that use the terminfo
database but not the ncurses library, but we do not have evidence that
any such exist.
2016-03-08 11:35:24 -06:00
Vladimír Čunát
09af15654f Merge master into closure-size
The kde-5 stuff still didn't merge well.
I hand-fixed what I saw, but there may be more problems.
2016-03-08 09:58:19 +01:00
John Ericson
114cd6765d haskell: Expose the package set used to build each GHC, where possible
Tested to not change hashes
2016-02-21 10:16:13 -08:00
Vladimír Čunát
f9f6f41bff Merge branch 'master' into closure-size
TODO: there was more significant refactoring of qtbase and plasma 5.5
on master, and I'm deferring pointing to correct outputs to later.
2015-12-31 09:53:02 +01:00
Peter Simons
1f108490f1 ghc-HEAD: update build instructions and bump version to current Git master
Closes https://github.com/NixOS/nixpkgs/issues/10752.
2015-12-16 21:33:56 +01:00
Vladimír Čunát
148e03b2f1 gmp: split into multiple outputs 2015-10-28 10:15:49 +01:00
Vladimír Čunát
91407a8bdf ncurses: split into multiple outputs
Some programs (e.g. tput) might better be moved somewhere else than
$dev/bin, but that can be improved later if need be.
2015-10-13 20:18:44 +02:00
Peter Simons
d34f7ded49 ghc-head: update to current HEAD 2015-08-28 22:28:06 +02:00
Peter Simons
bfa187de68 ghc-head: bump version to current git HEAD 2015-08-09 20:16:19 +02:00
Peter Simons
eb5f4d3d36 ghc: make sure the HEAD version is built with a deterministic version number 2015-08-09 20:16:19 +02:00
Mateusz Kowalczyk
2b833d5297 haskell-ghc: update head to 20150705 2015-07-05 21:01:37 +01:00