Compare commits

...

111 Commits

Author SHA1 Message Date
Lluís Batlle i Rossell
99e776e665 Changing a bit the usage of 'platform' along the kernel, and expecting it to be
overrided by pkgOverrides on desire.


svn path=/nixpkgs/branches/stdenv-updates/; revision=18267
2009-11-07 20:03:42 +00:00
Lluís Batlle i Rossell
ed09bc1fec Adding an arm kernel detail I forgot: ARCH=arm
svn path=/nixpkgs/branches/stdenv-updates/; revision=18265
2009-11-07 19:02:11 +00:00
Lluís Batlle i Rossell
ad773e366c First movement towards some setting about platform, concerning different kinds of arm platforms. We can discuss the best way to do that.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18264
2009-11-07 18:32:03 +00:00
Lluís Batlle i Rossell
2ba060df3f Attempting to build the zen kernels also on the sheevaplug.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18263
2009-11-07 17:28:26 +00:00
Lluís Batlle i Rossell
b8d2c4cbc0 Updating from trunk
svn path=/nixpkgs/branches/stdenv-updates/; revision=18256
2009-11-07 13:26:28 +00:00
Lluís Batlle i Rossell
6482df96b3 Keepking libsmbios only on non-armv5tel-linux targets for hal.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18116
2009-11-04 21:08:43 +00:00
Lluís Batlle i Rossell
c8136a719a Final merge from trunk, for this sequence of attempts to update it.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18097
2009-11-04 14:21:33 +00:00
Lluís Batlle i Rossell
54e6b9187c Additional partial update from trunk.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18096
2009-11-04 14:18:28 +00:00
Lluís Batlle i Rossell
56aeae607b Partial update from trunk.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18095
2009-11-04 14:17:17 +00:00
Lluís Batlle i Rossell
7968a15473 Removing additional mergeinfo I brought in unfortunately in r18006.
I also update the root mergeinfo for it to allow an update from trunk.
(I noticed that this root wanted to merge in the merge we did from this
stdenv-updates into trunk, which of course it would be an error to get that
'commit' done into this branch)


svn path=/nixpkgs/branches/stdenv-updates/; revision=18094
2009-11-04 13:45:05 +00:00
Lluís Batlle i Rossell
24e65f3e1a Making marvell u-boot 3.4.19 build with gas from binutils 2.20
svn path=/nixpkgs/branches/stdenv-updates/; revision=18080
2009-11-03 21:29:27 +00:00
Lluís Batlle i Rossell
d218157857 Making the rest of glibc-2.9 related builds (locales and info) support the new binutils.
svn path=/nixpkgs/branches/stdenv-updates/; revision=18040
2009-10-29 22:21:53 +00:00
Ludovic Courtès
ba96fbaebc glibc: Support GNU Binutils 2.20 and above.
Reported by Lluís Batlle.

svn path=/nixpkgs/branches/stdenv-updates/; revision=18008
2009-10-28 22:04:22 +00:00
Lluís Batlle i Rossell
d3f702bde7 Merging in - the armv5tel-linux branch.
Many files got the properties changed. I think it is the mergeinfo property,
which I don't understand at all by now. If I broke anything, maybe I would get
a lesson about mergeinfo.

I run these commands, one after the other, which worked cleanly:
svn merge -r 17290:17443 https://svn.nixos.org/repos/nix/nixpkgs/branches/armv5tel-linux
svn merge -r 17463:18005 https://svn.nixos.org/repos/nix/nixpkgs/branches/armv5tel-linux
I only skipped the armv5tel-linux 'update from trunk'.

I will remove the armv5tel-linux now.

I had the armv5tel-linux branch for not to get stdenv-updates "noise" for the system I had
running the armv5tel-linux branch. It would be a lot of work to get rebuilds of the stdenv
often in that system. Anyway, I think I will maintain a 'stable' copy of stdenv-updates
in my git copy of nixpkgs, removing the updates I did not want.

I was afraid of getting two different branches, stdenv-updates and armv5tel-linux, updating
from trunk and both to be merged into trunk, touching almost the same kind of files I was
touching in the armv5tel-linux. So I decided to have only one stdenv-updates,
and have easier merges from/to trunk in it.


svn path=/nixpkgs/branches/stdenv-updates/; revision=18006
2009-10-28 18:04:38 +00:00
Lluís Batlle i Rossell
9709716036 Making ocaml choose between only bytecode or native compilers, and disabling
X11 in arm.
It isn't that X11 doesn't work in arm... it should be a getConfig I think.
I should improve this in a later commit.

svn path=/nixpkgs/branches/armv5tel-linux/; revision=18005
2009-10-28 17:23:23 +00:00
Lluís Batlle i Rossell
2c7a0d91a5 Adding gd support to mldonkey, so it creates great bandwidth graphs.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=18004
2009-10-28 17:23:16 +00:00
Lluís Batlle i Rossell
0c77836428 Fixing build of freetype under armv5tel-linux
Thanks to:
http://archmobile.org/trac/ticket/42

svn path=/nixpkgs/branches/armv5tel-linux/; revision=18003
2009-10-28 17:23:05 +00:00
Lluís Batlle i Rossell
df66d798aa Taking out glibc debug compiling.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=18002
2009-10-28 17:22:58 +00:00
Lluís Batlle i Rossell
0821fd6ec1 More locale experiments
svn path=/nixpkgs/branches/armv5tel-linux/; revision=18001
2009-10-28 17:22:50 +00:00
Lluís Batlle i Rossell
0391a54a42 Made mldonkey be built with bytecode, and install the bytecode binary.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=18000
2009-10-28 17:22:41 +00:00
Lluís Batlle i Rossell
0641e4a2ff Made ocaml build only the byte code compilers
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17999
2009-10-28 17:22:33 +00:00
Lluís Batlle i Rossell
10cb9850fd The glibc locales want the endiannes, so I made in locales.nix glibc configure.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17998
2009-10-28 17:22:25 +00:00
Lluís Batlle i Rossell
1dd2c10a8c Made icu compile with -O0, because otherwise gcc 4.3.4 fails with internal error
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17997
2009-10-28 17:22:18 +00:00
Lluís Batlle i Rossell
71da9dd913 Removing X11 from ocaml
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17996
2009-10-28 17:22:10 +00:00
Lluís Batlle i Rossell
9dfdae762b Adding ocaml cvs version, which supports arm eabi building (they claim)
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17995
2009-10-28 17:22:02 +00:00
Ludovic Courtès
598efc2e6b GNU Binutils 2.20.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17928
2009-10-22 16:59:08 +00:00
Ludovic Courtès
200d0ab40c GNU Readline: Fix application of upstream patches.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17915
2009-10-21 14:58:48 +00:00
Ludovic Courtès
e9917257c8 GNU Readline: Fix patch URL.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17901
2009-10-20 13:17:33 +00:00
Ludovic Courtès
19a129dabe GNU Readline: Add latest patches.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17900
2009-10-20 12:38:18 +00:00
Ludovic Courtès
4891f42054 GNU Bash: Update patch list.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17899
2009-10-20 12:38:15 +00:00
Ludovic Courtès
2eeaaee0d0 Bash: Generalize `update-patch-set.sh' so it can be used for Readline.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17898
2009-10-20 12:38:12 +00:00
Lluís Batlle i Rossell
834b8ac61a Changing the style of adding the coreutils dependency, which did not work
on coreutils=null

svn path=/nixpkgs/branches/stdenv-updates/; revision=17869
2009-10-18 20:45:36 +00:00
Lluís Batlle i Rossell
d492c7ca3e State a dependency of the gcc wrapper on coreutils.
I only modified accordingly the linux stdenv.
Other stdenvs may need to be updated.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17867
2009-10-18 14:14:50 +00:00
Ludovic Courtès
35f3cee3e9 gzip: Make `getopt.patch' applicable.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17686
2009-10-07 09:38:49 +00:00
Ludovic Courtès
8cded34c1e gzip: Fix on Darwin.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17685
2009-10-07 07:50:05 +00:00
Ludovic Courtès
2611955204 GNU zip 1.3.13.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17678
2009-10-06 15:38:16 +00:00
Ludovic Courtès
6455e18f06 GNU Wget: More tweaks.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17633
2009-10-03 21:29:46 +00:00
Ludovic Courtès
8351d053e2 GNU Wget: Add Perl, for the test suite.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17632
2009-10-03 16:06:30 +00:00
Ludovic Courtès
47cd4deca5 GNU Wget: Tentative fix for GnuTLS support.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17631
2009-10-03 15:29:05 +00:00
Ludovic Courtès
4061a914da GNU Wget: Use GnuTLS instead of OpenSSL.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17630
2009-10-03 13:42:07 +00:00
Ludovic Courtès
cb0d78d7e7 GNU Wget 1.12.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17629
2009-10-03 13:42:01 +00:00
Lluís Batlle i Rossell
6cb8ef5eae Merging from trunk. I did:
svn merge -r 17288:17462 https://svn.nixos.org/repos/nix/nixpkgs/trunk

I know I should be merging from stdenv-updates... I'll try to get this branch
in sync with stdenv-updates soon.


svn path=/nixpkgs/branches/armv5tel-linux/; revision=17463
2009-09-27 22:09:56 +00:00
Lluís Batlle i Rossell
e098193c03 Taken u-boot from the www.plugcomputer.org website, which hold the latest
sheevaplug u-boot not in any upstream branch. This is the only I've found with
mmc support for the sheevaplug.

svn path=/nixpkgs/branches/armv5tel-linux/; revision=17443
2009-09-26 14:43:15 +00:00
Lluís Batlle i Rossell
60d3935cf3 Adding options to uboot
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17442
2009-09-26 14:43:06 +00:00
Lluís Batlle i Rossell
4221f9baf3 Moving uboot out of os-specific/linux. It can boot bsds, and it isn't that it needs an OS to work.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17441
2009-09-26 14:43:00 +00:00
Lluís Batlle i Rossell
46eb125c61 Adding fuse, reiserfs and iso9660 to the sheevaplug kernel config.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17413
2009-09-24 22:19:39 +00:00
Lluís Batlle i Rossell
2a56d25a99 Fixing purity in 'man' build.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17412
2009-09-24 22:19:31 +00:00
Lluís Batlle i Rossell
e815313873 Fixing the linux 2.6.31 expression for armv5tel
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17411
2009-09-24 22:19:24 +00:00
Lluís Batlle i Rossell
5edf342745 Adding UBI fs
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17410
2009-09-24 22:19:17 +00:00
Lluís Batlle i Rossell
f56066fb2a Fixing all-packages, after breaking that with the previous commit. Some args
did not match.

svn path=/nixpkgs/branches/armv5tel-linux/; revision=17386
2009-09-23 20:36:48 +00:00
Lluís Batlle i Rossell
a26f3ed219 Adding u-boot for the sheevaplug to boot.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17385
2009-09-23 20:36:38 +00:00
Lluís Batlle i Rossell
96ad0829cd Disabling libxcrypt on armv5tel (it doesn't build)
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17384
2009-09-23 20:36:19 +00:00
Lluís Batlle i Rossell
cee15d59b2 Made linux-2.6.31 build for armv5tel with a specified config.
The config is made by "make kirkwood_defconfig", and then enabling initrd.

svn path=/nixpkgs/branches/armv5tel-linux/; revision=17383
2009-09-23 20:35:42 +00:00
Lluís Batlle i Rossell
d2a9908a28 Adding a patch for strace that allows building on armv5tel gnueabi
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17382
2009-09-23 20:35:13 +00:00
Lluís Batlle i Rossell
26d20dbd14 Disabling libsmbios on armv5tel for hal.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17381
2009-09-23 20:35:05 +00:00
Lluís Batlle i Rossell
65c28ad201 Make the modules-closure allow for a list with no modules at all.
Adding the 'ensureDir' I added, depmod does not complain.

svn path=/nixpkgs/branches/armv5tel-linux/; revision=17380
2009-09-23 20:34:58 +00:00
Lluís Batlle i Rossell
d265b6e517 Make initrd be wrapped for u-boot, for armv5tel.
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17379
2009-09-23 20:34:52 +00:00
Lluís Batlle i Rossell
6a5b2f1128 Fixing the sha256 for the small vim. That was already done for the big vim.
They changed the package for the very same version we already had a hash for.

svn path=/nixpkgs/branches/armv5tel-linux/; revision=17378
2009-09-23 20:34:45 +00:00
Lluís Batlle i Rossell
33f2da4b7e Trying to get an arm kernel
svn path=/nixpkgs/branches/armv5tel-linux/; revision=17377
2009-09-23 20:34:38 +00:00
Lluís Batlle i Rossell
a077717a88 Merging from trunk. I did:
svn merge -r 17269:17288 https://svn.nixos.org/repos/nix/nixpkgs/trunk


svn path=/nixpkgs/branches/armv5tel-linux/; revision=17289
2009-09-19 22:33:22 +00:00
Lluís Batlle i Rossell
6c1c78f6b5 Updating from trunk.
I did:
svn merge -r 17114:17269 https://svn.nixos.org/repos/nix/nixpkgs/trunk


svn path=/nixpkgs/branches/armv5tel-linux/; revision=17270
2009-09-19 08:36:46 +00:00
Lluís Batlle i Rossell
e954d49496 Made nixpkgs use coreutils 7.5 on arm
svn path=/nixpkgs/branches/stdenv-updates/; revision=17268
2009-09-18 21:37:06 +00:00
Lluís Batlle i Rossell
93400d329b Fixing the bootstrap tools for armv5tel
svn path=/nixpkgs/branches/stdenv-updates/; revision=17267
2009-09-18 21:23:55 +00:00
Lluís Batlle i Rossell
13ceb88d53 Fixing the build of uclibc on armv5tel-linux, needed for the bootstrap files
svn path=/nixpkgs/branches/stdenv-updates/; revision=17266
2009-09-18 21:23:40 +00:00
Lluís Batlle i Rossell
8e9a701c4e Fixing a double gcc wrappering I did not voluntarely.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17240
2009-09-17 22:17:37 +00:00
Lluís Batlle i Rossell
a87f6271d9 Fixing the uclibc reference. I keep on making 'slight' changes after my succesful tests,
before committing.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17239
2009-09-17 22:08:40 +00:00
Lluís Batlle i Rossell
84e910616c Made the bootstrap-tools build curl and bzip2 so they properly work, even the
curl network calls, totally as static binaries.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17238
2009-09-17 22:06:58 +00:00
Lluís Batlle i Rossell
d2c403de5c Removing any reference to my attempts trying to get --enable-static-nss working
svn path=/nixpkgs/branches/stdenv-updates/; revision=17237
2009-09-17 22:06:54 +00:00
Lluís Batlle i Rossell
e4e2259149 Adding uclibc
svn path=/nixpkgs/branches/stdenv-updates/; revision=17236
2009-09-17 22:06:49 +00:00
Ludovic Courtès
2bde571319 GNU Coreutils 7.6.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17176
2009-09-16 08:06:32 +00:00
Lluís Batlle i Rossell
74a6c348ed Making the glibc expression not to disable-static on staticLibNSS.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17167
2009-09-15 14:25:48 +00:00
Eelco Dolstra
5b5bb582f4 * Set the MIME type to application/octet-stream.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17155
2009-09-15 11:07:07 +00:00
Lluís Batlle i Rossell
2502e04909 Removing gmp forced cflags, needed for gcc 4.3.2, which I don't use anymore
in stdenvLinux.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17152
2009-09-15 09:43:45 +00:00
Lluís Batlle i Rossell
6b3a9ea05e Fixing the static linking of the curl bootstrap tool, so it's linked with static nss libs from glibc.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17145
2009-09-15 06:27:52 +00:00
Lluís Batlle i Rossell
35f637d338 Updating bootstrap-tools to a public version (in an internet reachable host).
svn path=/nixpkgs/branches/stdenv-updates/; revision=17140
2009-09-14 20:15:00 +00:00
Lluís Batlle i Rossell
ce4faee4e6 Making a special unpack-bootstrap-tools script for arm, because there
we need double-patchelfing to get working binaries.
Once we get patchelf fixed, we may have a single script.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17139
2009-09-14 20:14:30 +00:00
Lluís Batlle i Rossell
66471b96c3 Reapplying a commit I lost while moving commits here and there with git.
(I had a patch in nixpkgs trunk to revert some arm things I commited there,while I worked in a branch without that patch)

svn path=/nixpkgs/branches/stdenv-updates/; revision=17138
2009-09-14 20:14:23 +00:00
Lluís Batlle i Rossell
4ba4357021 Made new bootstrap files (not stripped), which work. Also stripped should work. I had to fix the unpack script.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17137
2009-09-14 20:14:10 +00:00
Lluís Batlle i Rossell
6e21143f22 Made make-bootstrap-tools work with the fedora10 bootstrap-files-fedora I built.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17136
2009-09-14 20:13:40 +00:00
Lluís Batlle i Rossell
793bbb8701 Keeping with the stdenv's gcc (not a gcc built by stdenv) in
make-bootstrap-tools. I think it should work, having rethought on it.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17135
2009-09-14 20:13:32 +00:00
Lluís Batlle i Rossell
b547b7ca01 Making a cleaner gcc4.3 expression for !enableShared,
and made the bootstrap tools use the stdenv gcc.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17134
2009-09-14 20:13:26 +00:00
Lluís Batlle i Rossell
414f01beae Make the perl and glibc arm stuff only enabled under arm.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17133
2009-09-14 20:13:19 +00:00
Lluís Batlle i Rossell
0edcb58adc Trying to get make-bootstrap-tools work with a gcc --disable-shared.
dietLibc doesn't build in armv5tel-gnueabi, I still don't know why.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17132
2009-09-14 20:13:08 +00:00
Lluís Batlle i Rossell
85cf7fef96 Enabling stdenvLinux for the armv5tel platform (armv5tel-unknown-linux-gnueabi, I mean)
svn path=/nixpkgs/branches/stdenv-updates/; revision=17131
2009-09-14 20:13:02 +00:00
Lluís Batlle i Rossell
2c77bcbc25 Adding some bootstrap files for arm, done using the fedora f10 binaries. I plan to
change this to binaries generated with make-bootstrap-files when I get it working.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17130
2009-09-14 20:12:56 +00:00
Lluís Batlle i Rossell
627f810fbc Rename the gcc wrapper used at bootstrap
svn path=/nixpkgs/branches/stdenv-updates/; revision=17129
2009-09-14 20:12:41 +00:00
Lluís Batlle i Rossell
11221a6f7b Making glibc grab the libgcc_s.so.1 from gcc during the install. It needs to run some
of its programs at that stage, and if the glibc programs have been compiled with
-shared-libgcc (the default with a gcc built without --disable-shared), it will need
the libgcc_s.so.1 available exactly on the $out/lib path. The libc scripts force
the library-path calling directly its just built dynamic loader. Bootstrapping
gcc and glibc in the same 'prefix' would not need anything like this.

Btw, I think the postInstall phase doesn't work, because the glibc I got has still
this libgcc_s.so.1 in it. I've to check if the phase runs well or not, maybe on a
faster computer.

svn path=/nixpkgs/branches/stdenv-updates/; revision=17128
2009-09-14 20:12:35 +00:00
Lluís Batlle i Rossell
378cec3857 Making glibc-2.9 not keep the source in its store derivation, and disable -g on it.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17127
2009-09-14 20:12:29 +00:00
Lluís Batlle i Rossell
a92ad6be9b Updating gcc from 4.3.3 to 4.3.4 (4.3.3 said 'internal error' building on armv5tel-gnueabi)
svn path=/nixpkgs/branches/stdenv-updates/; revision=17126
2009-09-14 20:12:22 +00:00
Lluís Batlle i Rossell
2d288613ea Fixing the perl build in stdenvNative (fedora f10 sheevaplug)
svn path=/nixpkgs/branches/stdenv-updates/; revision=17125
2009-09-14 20:12:15 +00:00
Lluís Batlle i Rossell
be16921e65 Making klibc build for arm with eabi.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17124
2009-09-14 20:12:09 +00:00
Lluís Batlle i Rossell
0800577f0e Fixing glibc2.9 build, mimicking the eglibc build.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17123
2009-09-14 20:12:02 +00:00
Lluís Batlle i Rossell
4c3cd34b71 Fixing eglibc builder (-O2 required)
svn path=/nixpkgs/branches/stdenv-updates/; revision=17122
2009-09-14 20:11:54 +00:00
Lluís Batlle i Rossell
19ce1416a4 Making the eglibc build similar to glibc. Fixing the rpath problem - it should not be set to glibc libs.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17121
2009-09-14 20:11:47 +00:00
Lluís Batlle i Rossell
23a93297ef Making eglibc build with gnueabi.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17120
2009-09-14 20:11:37 +00:00
Lluís Batlle i Rossell
487d357798 Adding eglibc, trying to build it.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17119
2009-09-14 20:11:30 +00:00
Lluís Batlle i Rossell
a4cbc79915 Fixing gmp building in Fedora's gcc
svn path=/nixpkgs/branches/stdenv-updates/; revision=17118
2009-09-14 20:11:21 +00:00
Lluís Batlle i Rossell
6b7f9f1a79 Fine tuning for glibc-2.9 to build
svn path=/nixpkgs/branches/stdenv-updates/; revision=17117
2009-09-14 20:11:14 +00:00
Lluís Batlle i Rossell
e30a22b123 Updating from trunk.
I did:
svn merge -r 16493:17114 https://svn.nixos.org/repos/nix/nixpkgs/trunk


svn path=/nixpkgs/branches/stdenv-updates/; revision=17115
2009-09-14 19:14:56 +00:00
Ludovic Courtès
01b736a69b GNU Coreutils 7.5.
svn path=/nixpkgs/branches/stdenv-updates/; revision=17001
2009-09-10 09:32:33 +00:00
Ludovic Courtès
21dcacbd24 GCC wrapper: Make sure the absence of `gcj' doesn't cause a failure.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16648
2009-08-10 14:10:09 +00:00
Ludovic Courtès
456cdea408 GCC wrapper: Don't create dangling symlinks; create a `gcj' symlink.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16647
2009-08-10 13:43:08 +00:00
Ludovic Courtès
9832732048 Bash: Update name.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16644
2009-08-10 13:04:49 +00:00
Ludovic Courtès
1d4a34f20f Bash: Automatically generate patch list; update it.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16643
2009-08-10 13:04:08 +00:00
Ludovic Courtès
74716b53f6 Bash: Remove duplicate `postInstall' attribute.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16639
2009-08-10 09:52:34 +00:00
Ludovic Courtès
2f21a53035 Bash: Install the completion examples.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16638
2009-08-10 09:43:19 +00:00
Lluís Batlle i Rossell
21d0a473a9 Updating from trunk.
I did:
svn merge -r 16162:16493 https://svn.nixos.org/repos/nix/nixpkgs/trunk
On conflict regarding svn:mergeinfo for a firefox expression, I chose to update svn:mergeinfo instead of what "they" wanted: delete svn:mergeinfo.


svn path=/nixpkgs/branches/stdenv-updates/; revision=16495
2009-07-28 19:53:26 +00:00
Ludovic Courtès
aec3767c15 Readline: Explicitly link against ncurses.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16471
2009-07-27 12:50:12 +00:00
Ludovic Courtès
3f5904edd9 GNU Awk 3.1.7.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16461
2009-07-26 11:00:51 +00:00
Ludovic Courtès
fd85ac630d Fix typo.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16426
2009-07-18 22:24:11 +00:00
Ludovic Courtès
39e889c038 Remove distinction between gmp' and gmpxx'.
svn path=/nixpkgs/branches/stdenv-updates/; revision=16425
2009-07-18 22:17:35 +00:00
69 changed files with 3088 additions and 201 deletions

View File

@@ -1,4 +1,4 @@
{stdenv, fetchurl, ocaml, zlib, ncurses}:
{stdenv, fetchurl, ocaml, zlib, ncurses, gd, libpng}:
stdenv.mkDerivation {
name = "mldonkey-3.0.0";
@@ -13,6 +13,16 @@ stdenv.mkDerivation {
homepage = http://mldonkey.sourceforge.net/;
};
buildInputs = [ ocaml zlib ncurses ];
configureFlags = "--disable-gd --disable-gui";
buildInputs = [ ocaml zlib ncurses gd libpng ];
configureFlags = [ "--disable-gui" "--enable-ocamlver=3.11.1" ];
# Byte code compilation (the ocaml opt compiler is not supported in many platforms)
buildPhase = "make mlnet.byte";
installPhase = ''
ensureDir $out/bin
cp mlnet.byte $out/bin/mlnet
'';
# ocaml bytecode selfcontained binaries loose the bytecode if stripped
dontStrip = true;
}

View File

@@ -83,7 +83,7 @@ mkGccWrapper() {
if ! test -f "$src"; then
echo "$src does not exist (skipping)"
return
return 1
fi
gccProg="$src"
@@ -91,18 +91,24 @@ mkGccWrapper() {
chmod +x "$dst"
}
mkGccWrapper $out/bin/gcc $gccPath/gcc
ln -s gcc $out/bin/cc
mkGccWrapper $out/bin/g++ $gccPath/g++
ln -s g++ $out/bin/c++
if test -e $gccPath/gfortran; then
mkGccWrapper $out/bin/gfortran $gccPath/gfortran
ln -s gfortran $out/bin/g77
ln -s gfortran $out/bin/f77
if mkGccWrapper $out/bin/gcc $gccPath/gcc
then
ln -sv gcc $out/bin/cc
fi
if mkGccWrapper $out/bin/g++ $gccPath/g++
then
ln -sv g++ $out/bin/c++
fi
if mkGccWrapper $out/bin/gfortran $gccPath/gfortran
then
ln -sv gfortran $out/bin/g77
ln -sv gfortran $out/bin/f77
fi
mkGccWrapper $out/bin/gcj $gccPath/gcj || true
# Create a symlink to as (the assembler). This is useful when a
# gcc-wrapper is installed in a user environment, as it ensures that

View File

@@ -6,11 +6,11 @@
# variables so that the compiler and the linker just "work".
{ name ? "", stdenv, nativeTools, nativeLibc, nativePrefix ? ""
, gcc ? null, libc ? null, binutils ? null, shell ? ""
, gcc ? null, libc ? null, binutils ? null, coreutils ? null, shell ? ""
}:
assert nativeTools -> nativePrefix != "";
assert !nativeTools -> gcc != null && binutils != null;
assert !nativeTools -> gcc != null && binutils != null && coreutils != null;
assert !nativeLibc -> libc != null;
let
@@ -35,6 +35,8 @@ stdenv.mkDerivation {
inherit nativeTools nativeLibc nativePrefix gcc;
libc = if nativeLibc then null else libc;
binutils = if nativeTools then null else binutils;
# The wrapper scripts use 'cat', so we may need coreutils
coreutils = if nativeTools then null else coreutils;
langC = if nativeTools then true else gcc.langC;
langCC = if nativeTools then true else gcc.langCC;
@@ -54,6 +56,7 @@ stdenv.mkDerivation {
if !nativeLibc then
(if stdenv.system == "i686-linux" then "ld-linux.so.2" else
if stdenv.system == "x86_64-linux" then "ld-linux-x86-64.so.2" else
if stdenv.system == "armv5tel-linux" then "ld-linux.so.3" else
if stdenv.system == "powerpc-linux" then "ld.so.1" else
abort "don't know the name of the dynamic linker for this platform")
else "";

View File

@@ -27,3 +27,7 @@ fi
if test -n "@libc@"; then
addToSearchPath PATH @libc@/bin
fi
if test -n "@coreutils@"; then
addToSearchPath PATH @coreutils@/bin
fi

View File

@@ -12,12 +12,17 @@
# `contents = {object = ...; symlink = /init;}' is a typical
# argument.
{stdenv, perl, cpio, contents}:
{stdenv, perl, cpio, contents, uboot ? null}:
assert stdenv.system == "armv5tel-linux" -> uboot != null;
stdenv.mkDerivation {
name = "initrd";
builder = ./make-initrd.sh;
buildInputs = [perl cpio];
buildInputs = [perl cpio]
++ stdenv.lib.optional (stdenv.system == "armv5tel-linux") [ uboot ];
makeUInitrd = if (stdenv.system == "armv5tel-linux") then true else false;
# !!! should use XML.
objects = map (x: x.object) contents;

View File

@@ -37,3 +37,8 @@ storePaths=$(perl $pathsFromGraph closure-*)
# Put the closure in a gzipped cpio archive.
ensureDir $out
(cd root && find * -print0 | cpio -ov -H newc --null | gzip -9 > $out/initrd)
if [ -n "$makeUInitrd" ]; then
mv $out/initrd $out/initrd.gz
mkimage -A arm -O linux -T ramdisk -C gzip -d $out/initrd.gz $out/initrd
fi

View File

@@ -22,7 +22,7 @@ for module in $rootModules; do
done
echo "closure:"
ensureDir $out
ensureDir $out/lib/modules/"$version"
for module in $closure; do
target=$(echo $module | sed "s^/nix/store/.*/lib/modules/^$out/lib/modules/^")
if test -e "$target"; then continue; fi

View File

@@ -3,6 +3,7 @@
, langJava ? false
, profiledCompiler ? false
, staticCompiler ? false
, enableShared ? true
, texinfo ? null
, gmp, mpfr
, bison ? null, flex ? null
@@ -15,7 +16,7 @@ assert langTreelang -> bison != null && flex != null;
with stdenv.lib;
let version = "4.3.3"; in
let version = "4.3.4"; in
stdenv.mkDerivation ({
name = "${name}-${version}";
@@ -25,19 +26,19 @@ stdenv.mkDerivation ({
src =
optional /*langC*/ true (fetchurl {
url = "mirror://gcc/releases/gcc-${version}/gcc-core-${version}.tar.bz2";
sha256 = "08yksvipnqmqbmif30rwjkg3y0m6ray5r84wa2argv8q0bpz9426";
sha256 = "1yk80nwyw8vkpw8d3x7lkg3zrv3ngjqlvj0i8zslzgj7a27q729i";
}) ++
optional langCC (fetchurl {
url = "mirror://gcc/releases/gcc-${version}/gcc-g++-${version}.tar.bz2";
sha256 = "12z2zh03yq214qs2cqzh8c64jjfz544nk1lzi9rygjwm8yjsvzm9";
sha256 = "0d8pyk5c9zmph25f4fl63vd8vhljj6ildbxpz2hr594g5i6pplpq";
}) ++
optional langFortran (fetchurl {
url = "mirror://gcc/releases/gcc-${version}/gcc-fortran-${version}.tar.bz2";
sha256 = "1b2wbysviyh7l9fqbd6zy5y6y89xgysy99gr8wx8xkc1hy2nwdsq";
sha256 = "1xf2njykv1qcgxiqwj693dxjf77ss1rcxirylvnsp5hs89mdlj12";
}) ++
optional langJava (fetchurl {
url = "mirror://gcc/releases/gcc-${version}/gcc-java-${version}.tar.bz2";
sha256 = "1mlazpydd9qv7zwxkbb5sw3clfawfndhcc3f5lzycminvn6qmfkb";
sha256 = "1v3krhxi3zyaqfj0x8dbxvg67fjp29cr1psyf71r9zf757p3vqsw";
});
patches =
@@ -56,6 +57,7 @@ stdenv.mkDerivation ({
configureFlags = "
${if enableMultilib then "" else "--disable-multilib"}
${if enableShared then "" else "--disable-shared"}
--disable-libstdcxx-pch
--with-system-zlib
--enable-languages=${

View File

@@ -1,5 +1,10 @@
args: with args;
let
useX11 = (stdenv.system != "armv5tel-linux");
useNativeCompilers = (stdenv.system != "armv5tel-linux");
inherit (stdenv.lib) optionals optionalString;
in
stdenv.mkDerivation (rec {
name = "ocaml-3.11.1";
@@ -10,10 +15,10 @@ stdenv.mkDerivation (rec {
};
prefixKey = "-prefix ";
configureFlags = ["-no-tk" "-x11lib" x11];
buildFlags = "world bootstrap world.opt";
buildInputs = [x11 ncurses];
installTargets = "install installopt";
configureFlags = ["-no-tk"] ++ optionals useX11 [ "-x11lib" x11 ];
buildFlags = "world" + optionalString useNativeCompilers " bootstrap world.opt";
buildInputs = [ncurses] ++ optionals useX11 [ x11 ];
installTargets = "install" + optionalString useNativeCompilers " installopt";
patchPhase = ''
CAT=$(type -tp cat)
sed -e "s@/bin/cat@$CAT@" -i config/auto-aux/sharpbang

View File

@@ -0,0 +1,31 @@
args: with args;
stdenv.mkDerivation (rec {
name = "ocaml-cvs-2009-09-24";
src = fetchcvs {
cvsRoot = ":pserver:anoncvs@camlcvs.inria.fr:/caml";
module = "ocaml";
date = "2009-09-24";
sha256 = "3909bffebc9ce36ca51711d7d95596cba94376ebb1975c6ed46b09c9892c3ef1";
};
prefixKey = "-prefix ";
configureFlags = ["-no-tk"];
buildFlags = "world" +
(if (stdenv.system != "armv5tel-linux") then "bootstrap world.opt" else "");
buildInputs = [ncurses];
installTargets = "install" + (if (stdenv.system != "armv5tel-linux") then "installopt" else "");
patchPhase = ''
CAT=$(type -tp cat)
sed -e "s@/bin/cat@$CAT@" -i config/auto-aux/sharpbang
'';
meta = {
homepage = http://caml.inria.fr/ocaml;
license = "QPL, LGPL2 (library part)";
desctiption = "Most popular variant of the Caml language";
};
})

View File

@@ -2,6 +2,13 @@
, impureLibcPath ? null
}:
let
preBuildNoNative = ''
# Make Cwd work on NixOS (where we don't have a /bin/pwd).
substituteInPlace lib/Cwd.pm --replace "'/bin/pwd'" "'$(type -tP pwd)'"
'';
preBuildNative = "";
in
stdenv.mkDerivation {
name = "perl-5.10.0";
@@ -24,16 +31,21 @@ stdenv.mkDerivation {
# "installstyle" option to ensure that modules are put under
# $out/lib/perl5 - this is the general default, but because $out
# contains the string "perl", Configure would select $out/lib.
configureFlags = ''
-de -Dcc=gcc -Uinstallusrbinperl -Dinstallstyle=lib/perl5 -Duseshrplib
${if stdenv ? glibc then "-Dusethreads" else ""}
'';
# Miniperl needs -lm. perl needs -lrt.
configureFlags = [
"-de"
"-Dcc=gcc"
"-Uinstallusrbinperl"
"-Dinstallstyle=lib/perl5"
"-Duseshrplib"
(if stdenv ? glibc then "-Dusethreads" else "")
];
configureScript = "${stdenv.shell} ./Configure";
dontAddPrefix = true;
preConfigure =
configurePhase =
''
configureFlags="$configureFlags -Dprefix=$out -Dman1dir=$out/share/man/man1 -Dman3dir=$out/share/man/man3"
@@ -41,13 +53,11 @@ stdenv.mkDerivation {
GLIBC=${if impureLibcPath == null then "$(cat $NIX_GCC/nix-support/orig-libc)" else impureLibcPath}
configureFlags="$configureFlags -Dlocincpth=$GLIBC/include -Dloclibpth=$GLIBC/lib"
fi
${stdenv.shell} ./Configure $configureFlags \
${if stdenv.system == "armv5tel-linux" then "-Dldflags=\"-lm -lrt\"" else ""};
'';
preBuild =
''
# Make Cwd work on NixOS (where we don't have a /bin/pwd).
${if stdenv.system == "i686-darwin" then "" else "substituteInPlace lib/Cwd.pm --replace \"'/bin/pwd'\" \"'$(type -tP pwd)'\""}
'';
preBuild = if (stdenv.gcc.nativeTools) then preBuildNative else preBuildNoNative;
setupHook = ./setup-hook.sh;
}

View File

@@ -0,0 +1,63 @@
# Glibc cannot have itself in its RPATH.
export NIX_NO_SELF_RPATH=1
source $stdenv/setup
# Explicitly tell glibc to use our pwd, not /bin/pwd.
export PWD_P=$(type -tP pwd)
# Needed to install share/zoneinfo/zone.tab. Set to impure /bin/sh to
# prevent a retained dependency on the bootstrap tools in the
# stdenv-linux bootstrap.
export BASH_SHELL=/bin/sh
preConfigure() {
for i in libc/configure libc/io/ftwtest-sh; do
# Can't use substituteInPlace here because replace hasn't been
# built yet in the bootstrap.
sed -i "$i" -e "s^/bin/pwd^$PWD_P^g"
done
# Include source for debugging
ensureDir $out/src
cp -R libc ports $out/src
ln -s $out/src/ports $out/src/libc/ports
# glibc wants -O2 minimum
export CFLAGS="-pipe -g -O2"
mkdir $NIX_BUILD_TOP/build
cd $NIX_BUILD_TOP/build
configureScript=$out/src/libc/configure
}
postConfigure() {
# Hack: get rid of the `-static' flag set by the bootstrap stdenv.
# This has to be done *after* `configure' because it builds some
# test binaries.
export NIX_CFLAGS_LINK=
export NIX_LDFLAGS_BEFORE=
export NIX_DONT_SET_RPATH=1
unset CFLAGS
}
postInstall() {
if test -n "$installLocales"; then
make localedata/install-locales
fi
rm $out/etc/ld.so.cache
(cd $out/include && ln -s $kernelHeaders/include/* .) || exit 1
# Fix for NIXOS-54 (ldd not working on x86_64). Make a symlink
# "lib64" to "lib".
if test -n "$is64bit"; then
ln -s lib $out/lib64
fi
}
genericBuild

View File

@@ -0,0 +1,32 @@
{ stdenv, fetchsvn, kernelHeaders
, installLocales ? true
, profilingLibraries ? false
}:
stdenv.mkDerivation rec {
name = "eglibc-2.10";
src = fetchsvn {
url = svn://svn.eglibc.org/branches/eglibc-2_10;
rev = 8690;
sha256 = "029hklrx2rlhsb5r2csd0gapjm0rbr8n28ib6jnnhms12x302viq";
};
inherit kernelHeaders installLocales;
configureFlags = [
"--with-headers=${kernelHeaders}/include"
"--without-fp"
"--enable-add-ons=libidn,ports,nptl"
"--disable-profile"
"--host=arm-linux-gnueabi"
"--build=arm-linux-gnueabi"
];
builder = ./builder.sh;
meta = {
homepage = http://www.gnu.org/software/libc/;
description = "The GNU C Library";
};
}

View File

@@ -1,5 +1,4 @@
{ stdenv, fetchurl
, # FreeType supports hinting using a TrueType bytecode interpreter,
# as well as sub-pixel rendering. These are patented by Apple and
# Microsoft, respectively, so they are disabled by default. This
@@ -8,7 +7,7 @@
useEncumberedCode ? false
}:
stdenv.mkDerivation rec {
stdenv.mkDerivation (rec {
name = "freetype-2.3.11";
src = fetchurl {
@@ -26,4 +25,7 @@ stdenv.mkDerivation rec {
homepage = http://www.freetype.org/;
license = "GPLv2+"; # or the FreeType License (BSD + advertising clause)
};
}
} //
# The asm for armel is written with the 'asm' keyword.
(if (stdenv.system == "armv5tel-linux") then
{CFLAGS = "-std=gnu99";} else {}))

View File

@@ -0,0 +1,42 @@
Support GNU Binutils 2.20 and beyond. Patch from
http://sourceware.org/ml/libc-alpha/2009-09/msg00009.html .
diff --git a/configure b/configure
index 48e6952..b1d84d7 100755
--- a/configure
+++ b/configure
@@ -4841,7 +4841,7 @@ $as_echo_n "checking version of $AS... " >&6; }
ac_prog_version=`$AS --version 2>&1 | sed -n 's/^.*GNU assembler.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
- 2.1[3-9]*)
+ 2.1[3-9]*|[2-9].[2-9]*)
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
@@ -4904,7 +4904,7 @@ $as_echo_n "checking version of $LD... " >&6; }
ac_prog_version=`$LD --version 2>&1 | sed -n 's/^.*GNU ld.* \([0-9][0-9]*\.[0-9.]*\).*$/\1/p'`
case $ac_prog_version in
'') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
- 2.1[3-9]*)
+ 2.1[3-9]*|[2-9].[2-9]*)
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
diff --git a/configure.in b/configure.in
index 4584afe..7c4f71f 100644
--- a/configure.in
+++ b/configure.in
@@ -897,10 +897,10 @@ AC_SUBST(MIG)dnl Needed by sysdeps/mach/configure.in
# Accept binutils 2.13 or newer.
AC_CHECK_PROG_VER(AS, $AS, --version,
[GNU assembler.* \([0-9]*\.[0-9.]*\)],
- [2.1[3-9]*], AS=: critic_missing="$critic_missing as")
+ [2.1[3-9]*|[2-9].[2-9]*], AS=: critic_missing="$critic_missing as")
AC_CHECK_PROG_VER(LD, $LD, --version,
[GNU ld.* \([0-9][0-9]*\.[0-9.]*\)],
- [2.1[3-9]*], LD=: critic_missing="$critic_missing ld")
+ [2.1[3-9]*|[2-9].[2-9]*], LD=: critic_missing="$critic_missing ld")
# We need the physical current working directory. We cannot use the
# "pwd -P" shell builtin since that's not portable. Instead we try to

View File

@@ -26,11 +26,13 @@ preConfigure() {
# don't want as a dependency in the Nixpkgs bootstrap. So force
# the output file to be newer.
touch locale/C-translit.h
tar xvjf "$srcPorts"
mkdir ../build
cd ../build
mkdir build
cd build
configureScript=../$sourceRoot/configure
configureScript=../configure
}
@@ -42,6 +44,7 @@ postConfigure() {
export NIX_LDFLAGS_BEFORE=
export NIX_DONT_SET_RPATH=1
unset CFLAGS
}

View File

@@ -9,8 +9,13 @@ stdenv.mkDerivation rec {
builder = ./builder.sh;
src = fetchurl {
url = http://nixos.org/tarballs/glibc-2.9-20081208.tar.bz2;
sha256 = "0zhxbgcsl97pf349m0lz8d5ljvvzrcqc23yf08d888xlk4ms8m3h";
url = http://ftp.gnu.org/gnu/glibc/glibc-2.9.tar.bz2;
sha256 = "0v53m7flx6qcx7cvrvvw6a4dx4x3y6k8nvpc4wfv5xaaqy2am2q9";
};
srcPorts = fetchurl {
url = http://ftp.gnu.org/gnu/glibc/glibc-ports-2.9.tar.bz2;
sha256 = "0r2sn527wxqifi63di7ns9wbjh1cainxn978w178khhy7yw9fk42";
};
inherit kernelHeaders installLocales;
@@ -46,12 +51,28 @@ stdenv.mkDerivation rec {
/* Have rpcgen(1) look for cpp(1) in $PATH. */
./rpcgen-path.patch
/* Support GNU Binutils 2.20 and above. */
./binutils-2.20.patch
];
configureFlags = ''
--enable-add-ons
--with-headers=${kernelHeaders}/include
${if profilingLibraries then "--enable-profile" else "--disable-profile"}
configureFlags = [
"--enable-add-ons"
"--with-headers=${kernelHeaders}/include"
(if profilingLibraries then "--enable-profile" else "--disable-profile")
] ++ (if (stdenv.system == "armv5tel-linux") then [
"--host=arm-linux-gnueabi"
"--build=arm-linux-gnueabi"
"--without-fp"
] else []);
preInstall = ''
ensureDir $out/lib
ln -s ${stdenv.gcc.gcc}/lib/libgcc_s.so.1 $out/lib/libgcc_s.so.1
'';
postInstall = ''
rm $out/lib/libgcc_s.so.1
'';
# Workaround for this bug:

View File

@@ -8,6 +8,11 @@ stdenv.mkDerivation rec {
sha256 = "0zhxbgcsl97pf349m0lz8d5ljvvzrcqc23yf08d888xlk4ms8m3h";
};
patches = [
/* Support GNU Binutils 2.20 and above. */
./binutils-2.20.patch
];
preConfigure = ''
export PWD_P=$(type -tP pwd)
for i in configure io/ftwtest-sh; do

View File

@@ -10,13 +10,35 @@
stdenv.mkDerivation rec {
name = "glibc-locales-2.9";
builder = ./localesbuilder.sh;
src = fetchurl {
url = http://nixos.org/tarballs/glibc-2.9-20081208.tar.bz2;
sha256 = "0zhxbgcsl97pf349m0lz8d5ljvvzrcqc23yf08d888xlk4ms8m3h";
url = http://ftp.gnu.org/gnu/glibc/glibc-2.9.tar.bz2;
sha256 = "0v53m7flx6qcx7cvrvvw6a4dx4x3y6k8nvpc4wfv5xaaqy2am2q9";
};
configurePhase = "true";
srcPorts = fetchurl {
url = http://ftp.gnu.org/gnu/glibc/glibc-ports-2.9.tar.bz2;
sha256 = "0r2sn527wxqifi63di7ns9wbjh1cainxn978w178khhy7yw9fk42";
};
inherit (stdenv) is64bit;
configureFlags = [
"--enable-add-ons"
"--without-headers"
"--disable-profile"
] ++ (if (stdenv.system == "armv5tel-linux") then [
"--host=arm-linux-gnueabi"
"--build=arm-linux-gnueabi"
"--without-fp"
] else []);
patches = [
/* Support GNU Binutils 2.20 and above. */
./binutils-2.20.patch
];
# Awful hack: `localedef' doesn't allow the path to `locale-archive'
# to be overriden, but you *can* specify a prefix, i.e. it will use
@@ -25,8 +47,6 @@ stdenv.mkDerivation rec {
# $TMPDIR/nix/store/...-glibc-.../lib/locale/locale-archive.
buildPhase =
''
touch config.make
touch config.status
mkdir -p $TMPDIR/"$(dirname $(readlink -f $(type -p localedef)))/../lib/locale"
make localedata/install-locales \
LOCALEDEF="localedef --prefix=$TMPDIR" \

View File

@@ -0,0 +1,50 @@
# Glibc cannot have itself in its RPATH.
export NIX_NO_SELF_RPATH=1
source $stdenv/setup
# Explicitly tell glibc to use our pwd, not /bin/pwd.
export PWD_P=$(type -tP pwd)
# Needed to install share/zoneinfo/zone.tab. Set to impure /bin/sh to
# prevent a retained dependency on the bootstrap tools in the
# stdenv-linux bootstrap.
export BASH_SHELL=/bin/sh
preConfigure() {
for i in configure io/ftwtest-sh; do
# Can't use substituteInPlace here because replace hasn't been
# built yet in the bootstrap.
sed -i "$i" -e "s^/bin/pwd^$PWD_P^g"
done
# In the glibc 2.6/2.7 tarballs C-translit.h is a little bit older
# than C-translit.h.in, forcing Make to rebuild it unnecessarily.
# This wouldn't be problem except that it requires Perl, which we
# don't want as a dependency in the Nixpkgs bootstrap. So force
# the output file to be newer.
touch locale/C-translit.h
tar xvjf "$srcPorts"
mkdir build
cd build
configureScript=../configure
}
postConfigure() {
# Hack: get rid of the `-static' flag set by the bootstrap stdenv.
# This has to be done *after* `configure' because it builds some
# test binaries.
export NIX_CFLAGS_LINK=
export NIX_LDFLAGS_BEFORE=
export NIX_DONT_SET_RPATH=1
unset CFLAGS
}
genericBuild

View File

@@ -10,6 +10,9 @@ stdenv.mkDerivation {
patchFlags = "-p0";
CFLAGS = "-O0";
CXXFLAGS = "-O0";
patches = [
(fetchurl {
url = "http://sources.gentoo.org/viewcvs.py/*checkout*/gentoo-x86/dev-libs/icu/files/icu-3.8-setBreakType-public.diff?rev=1.1";

View File

@@ -1,4 +1,7 @@
{stdenv, fetchurl}:
# I could not build it in armv5tel-linux
assert stdenv.system != "armv5tel-linux";
stdenv.mkDerivation {
name = "libxcrypt-3.0.2";

View File

@@ -0,0 +1,18 @@
This patch is to make sure that `libncurses' is among the `NEEDED'
dependencies of `libreadline.so' and `libhistory.so'.
Failing to do that, applications linking against Readline are
forced to explicitly link against libncurses as well; in addition,
this trick doesn't work when using GNU ld's `--as-needed'.
--- shlib/Makefile.in 2009-01-06 18:03:22.000000000 +0100
+++ shlib/Makefile.in 2009-07-27 14:43:25.000000000 +0200
@@ -84,7 +84,7 @@ SHOBJ_LDFLAGS = @SHOBJ_LDFLAGS@
SHOBJ_XLDFLAGS = @SHOBJ_XLDFLAGS@
SHOBJ_LIBS = @SHOBJ_LIBS@
-SHLIB_XLDFLAGS = @LDFLAGS@ @SHLIB_XLDFLAGS@
+SHLIB_XLDFLAGS = @LDFLAGS@ @SHLIB_XLDFLAGS@ -lncurses
SHLIB_LIBS = @SHLIB_LIBS@
SHLIB_DOT = @SHLIB_DOT@

View File

@@ -0,0 +1,8 @@
# Automatically generated by `update-patch-set.sh'; do not edit.
patch: [
(patch "001" "1wbqnsxm4nd8rjckl8mdqcb82pphnsj2yxs4f2nf88kyhwzy544i")
(patch "002" "070c3jz8fs5q17yy3l70wxklgnw6hp5ac9zhb0jdnrr9hf0wi6kl")
(patch "003" "1gwssafy42hcijcynmlpqsasch7kqxbv2cqw0p7f9p2y6vp9ng2j")
(patch "004" "1yzaycdfqjs5jdl0k7qg9cx47bdlq9xs0m6lfq42ys3yscmb1jzm")
]

View File

@@ -9,7 +9,20 @@ stdenv.mkDerivation rec {
};
propagatedBuildInputs = [ncurses];
patchFlags = "-p0";
patches =
[ ./link-against-ncurses.patch ]
++
(let
patch = nr: sha256:
fetchurl {
url = "mirror://gnu/readline/readline-6.0-patches/readline60-${nr}";
inherit sha256;
};
in
import ./readline-patches.nix patch);
meta = {
description = "GNU Readline, a library for interactive line editing";
@@ -31,5 +44,7 @@ stdenv.mkDerivation rec {
homepage = http://savannah.gnu.org/projects/readline/;
license = "GPLv3+";
maintainers = [ stdenv.lib.maintainers.ludo ];
};
}

View File

@@ -1,11 +1,11 @@
{stdenv, fetchurl, noSysDirs}:
stdenv.mkDerivation rec {
name = "binutils-2.19.1";
name = "binutils-2.20";
src = fetchurl {
url = "mirror://gnu/binutils/${name}.tar.bz2";
sha256 = "1xirhxwc94bk6hn2k6i5ly4knbcjsqgy2lp7kl1s5q5csys2b0iy";
sha256 = "1c3m789p5rwmmnck5ms4zcnc40axss3gxzivz571al1vmbq0kpz1";
};
patches = [
@@ -14,16 +14,16 @@ stdenv.mkDerivation rec {
# RUNPATH can be overriden using LD_LIBRARY_PATH at runtime.
./new-dtags.patch
];
inherit noSysDirs;
preConfigure = ''
# Clear the default library search path.
if test "$noSysDirs" = "1"; then
echo 'NATIVE_LIB_DIRS=' >> ld/configure.tgt
echo 'NATIVE_LIB_DIRS=' >> ld/configure.tgt
fi
'';
configureFlags = "--disable-werror"; # needed for dietlibc build
meta = {

View File

@@ -3,6 +3,8 @@
stdenv.mkDerivation {
name = "strace-4.5.18";
patches = [ ./strace-4.5.18-arm-syscalls.patch ];
src = fetchurl {
url = mirror://sourceforge/strace/strace-4.5.18.tar.bz2;
sha256 = "1l16vax3mn2wak288g1inmn30i49vlghnvfwr0z2rwh41r3vgrwm";

View File

@@ -0,0 +1,162 @@
From f5da8d0c38ea0eb660cb17de7aa62cda6899eb75 Mon Sep 17 00:00:00 2001
From: ldv <ldv>
Date: Thu, 1 Jan 2009 23:20:38 +0000
Subject: [PATCH] 2008-11-13 Kirill A. Shutemov <kirill@shutemov.name>
* linux/arm/syscallent.h: Fix build on ARM EABI which does not
provide syscalls socketcall and ipc.
---
ChangeLog | 5 +++++
linux/arm/syscallent.h | 4 +++-
2 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/linux/arm/syscallent.h b/linux/arm/syscallent.h
index 5ccef2f..edc3641 100644
--- a/linux/arm/syscallent.h
+++ b/linux/arm/syscallent.h
@@ -431,6 +431,7 @@
{ 5, 0, printargs, "SYS_398" }, /* 398 */
{ 5, 0, printargs, "SYS_399" }, /* 399 */
+#ifndef __ARM_EABI__
#if SYS_socket_subcall != 400
#error fix me
#endif
@@ -481,3 +482,4 @@
{ 4, TI, sys_shmdt, "shmdt" }, /* 440 */
{ 4, TI, sys_shmget, "shmget" }, /* 441 */
{ 4, TI, sys_shmctl, "shmctl" }, /* 442 */
+#endif
--
1.6.1.3
From 885d06bc92bae2f6aad85ef2fe0b806a06f60712 Mon Sep 17 00:00:00 2001
From: ldv <ldv>
Date: Thu, 1 Jan 2009 23:23:47 +0000
Subject: [PATCH] 2008-11-13 Kirill A. Shutemov <kirill@shutemov.name>
* linux/arm/syscallent.h: Update syscalls.
Based on patch by Enrico Scholz.
---
ChangeLog | 3 +
linux/arm/syscallent.h | 98 ++++++++++++++++++++++++------------------------
2 files changed, 52 insertions(+), 49 deletions(-)
diff --git a/linux/arm/syscallent.h b/linux/arm/syscallent.h
index edc3641..6dd783a 100644
--- a/linux/arm/syscallent.h
+++ b/linux/arm/syscallent.h
@@ -328,63 +328,63 @@
{ 5, TN, sys_getsockopt, "getsockopt" }, /* 295 */
{ 3, TN, sys_sendmsg, "sendmsg" }, /* 296 */
{ 3, TN, sys_recvmsg, "recvmsg" }, /* 297 */
- { 5, 0, printargs, "SYS_298" }, /* 298 */
- { 5, 0, printargs, "SYS_299" }, /* 299 */
- { 5, 0, printargs, "SYS_300" }, /* 300 */
- { 5, 0, printargs, "SYS_301" }, /* 301 */
- { 5, 0, printargs, "SYS_302" }, /* 302 */
- { 5, 0, printargs, "SYS_303" }, /* 303 */
- { 5, 0, printargs, "SYS_304" }, /* 304 */
- { 5, 0, printargs, "SYS_305" }, /* 305 */
- { 5, 0, printargs, "SYS_306" }, /* 306 */
- { 5, 0, printargs, "SYS_307" }, /* 307 */
- { 5, 0, printargs, "SYS_308" }, /* 308 */
- { 5, 0, printargs, "SYS_309" }, /* 309 */
- { 5, 0, printargs, "SYS_310" }, /* 310 */
- { 5, 0, printargs, "SYS_311" }, /* 311 */
- { 5, 0, printargs, "SYS_312" }, /* 312 */
- { 5, 0, printargs, "SYS_313" }, /* 313 */
- { 5, 0, printargs, "SYS_314" }, /* 314 */
- { 5, 0, printargs, "SYS_315" }, /* 315 */
- { 5, 0, printargs, "SYS_316" }, /* 316 */
- { 5, 0, printargs, "SYS_317" }, /* 317 */
- { 5, 0, printargs, "SYS_318" }, /* 318 */
- { 5, 0, printargs, "SYS_319" }, /* 319 */
- { 5, 0, printargs, "SYS_320" }, /* 320 */
- { 5, 0, printargs, "SYS_321" }, /* 321 */
- { 5, 0, printargs, "SYS_322" }, /* 322 */
- { 5, 0, printargs, "SYS_323" }, /* 323 */
- { 5, 0, printargs, "SYS_324" }, /* 324 */
- { 5, 0, printargs, "SYS_325" }, /* 325 */
- { 5, 0, printargs, "SYS_326" }, /* 326 */
- { 5, 0, printargs, "SYS_327" }, /* 327 */
- { 5, 0, printargs, "SYS_328" }, /* 328 */
- { 5, 0, printargs, "SYS_329" }, /* 329 */
- { 5, 0, printargs, "SYS_330" }, /* 330 */
- { 5, 0, printargs, "SYS_331" }, /* 331 */
- { 5, 0, printargs, "SYS_332" }, /* 332 */
- { 5, 0, printargs, "SYS_333" }, /* 333 */
- { 5, 0, printargs, "SYS_334" }, /* 334 */
+ { 4, TI, sys_semop, "semop" }, /* 298 */
+ { 4, TI, sys_semget, "semget" }, /* 299 */
+ { 4, TI, sys_semctl, "semctl" }, /* 300 */
+ { 4, TI, sys_msgsnd, "msgsnd" }, /* 301 */
+ { 4, TI, sys_msgrcv, "msgrcv" }, /* 302 */
+ { 4, TI, sys_msgget, "msgget" }, /* 303 */
+ { 4, TI, sys_msgctl, "msgctl" }, /* 304 */
+ { 4, TI, sys_shmat, "shmat" }, /* 305 */
+ { 4, TI, sys_shmdt, "shmdt" }, /* 306 */
+ { 4, TI, sys_shmget, "shmget" }, /* 307 */
+ { 4, TI, sys_shmctl, "shmctl" }, /* 308 */
+ { 5, 0, printargs, "add_key" }, /* 309 */
+ { 4, 0, printargs, "request_key" }, /* 310 */
+ { 5, 0, printargs, "keyctl" }, /* 311 */
+ { 5, TI, sys_semtimedop, "semtimedop" }, /* 312 */
+ { 5, 0, printargs, "vserver" }, /* 313 */
+ { 3, 0, printargs, "ioprio_set" }, /* 314 */
+ { 2, 0, printargs, "ioprio_get" }, /* 315 */
+ { 0, TD, printargs, "inotify_init" }, /* 316 */
+ { 3, TD, sys_inotify_add_watch, "inotify_add_watch" }, /* 317 */
+ { 2, TD, sys_inotify_rm_watch, "inotify_rm_watch" }, /* 318 */
+ { 6, 0, sys_mbind, "mbind" }, /* 319 */
+ { 3, 0, sys_set_mempolicy, "set_mempolicy" }, /* 320 */
+ { 5, 0, sys_get_mempolicy, "get_mempolicy" }, /* 321 */
+ { 4, TD|TF, sys_openat, "openat" }, /* 322 */
+ { 3, TD|TF, sys_mkdirat, "mkdirat" }, /* 323 */
+ { 4, TD|TF, sys_mknodat, "mknodat" }, /* 324 */
+ { 5, TD|TF, sys_fchownat, "fchownat" }, /* 325 */
+ { 3, TD|TF, sys_futimesat, "futimesat" }, /* 326 */
+ { 4, TD|TD, sys_newfstatat, "newfstatat" }, /* 327 */
+ { 3, TD|TF, sys_unlinkat, "unlinkat" }, /* 328 */
+ { 4, TD|TF, sys_renameat, "renameat" }, /* 329 */
+ { 5, TD|TF, sys_linkat, "linkat" }, /* 330 */
+ { 3, TD|TF, sys_symlinkat, "symlinkat" }, /* 331 */
+ { 4, TD|TF, sys_readlinkat, "readlinkat" }, /* 332 */
+ { 3, TD|TF, sys_fchmodat, "fchmodat" }, /* 333 */
+ { 3, TD|TF, sys_faccessat, "faccessat" }, /* 334 */
{ 5, 0, printargs, "SYS_335" }, /* 335 */
{ 5, 0, printargs, "SYS_336" }, /* 336 */
- { 5, 0, printargs, "SYS_337" }, /* 337 */
- { 5, 0, printargs, "SYS_338" }, /* 338 */
- { 5, 0, printargs, "SYS_339" }, /* 339 */
- { 5, 0, printargs, "SYS_340" }, /* 340 */
+ { 1, TP, sys_unshare, "unshare" }, /* 337 */
+ { 2, 0, printargs, "set_robust_list" }, /* 338 */
+ { 3, 0, printargs, "get_robust_list" }, /* 339 */
+ { 6, TD, printargs, "splice" }, /* 340 */
{ 5, 0, printargs, "SYS_341" }, /* 341 */
- { 5, 0, printargs, "SYS_342" }, /* 342 */
- { 5, 0, printargs, "SYS_343" }, /* 343 */
+ { 4, TD, printargs, "tee" }, /* 342 */
+ { 4, TD, printargs, "vmsplice" }, /* 343 */
{ 6, 0, sys_move_pages, "move_pages" }, /* 344 */
{ 3, 0, sys_getcpu, "getcpu" }, /* 345 */
{ 5, 0, printargs, "SYS_346" }, /* 346 */
- { 5, 0, printargs, "SYS_347" }, /* 347 */
- { 5, 0, printargs, "SYS_348" }, /* 348 */
+ { 5, 0, printargs, "kexec_load" }, /* 347 */
+ { 4, TD|TF, sys_utimensat, "utimensat" }, /* 348 */
{ 3, TD|TS, sys_signalfd, "signalfd" }, /* 349 */
{ 4, TD, sys_timerfd, "timerfd" }, /* 350 */
{ 1, TD, sys_eventfd, "eventfd" }, /* 351 */
- { 5, 0, printargs, "SYS_352" }, /* 352 */
- { 5, 0, printargs, "SYS_353" }, /* 353 */
- { 5, 0, printargs, "SYS_354" }, /* 354 */
+ { 6, TF, sys_fallocate, "fallocate" }, /* 352 */
+ { 4, TD, sys_timerfd_settime, "timerfd_settime"}, /* 353 */
+ { 2, TD, sys_timerfd_gettime, "timerfd_gettime"}, /* 354 */
{ 5, 0, printargs, "SYS_355" }, /* 355 */
{ 5, 0, printargs, "SYS_356" }, /* 356 */
{ 5, 0, printargs, "SYS_357" }, /* 357 */
--
1.6.1.3

View File

@@ -0,0 +1,53 @@
{stdenv, fetchurl, unzip}:
assert stdenv.system == "armv5tel-linux";
# All this file is made for the Marvell Sheevaplug
stdenv.mkDerivation {
name = "uboot-sheevaplug-3.4.19";
src = fetchurl {
url = "ftp://ftp.denx.de/pub/u-boot/u-boot-1.1.4.tar.bz2";
sha256 = "19vp4rlikz7h72pqsjhgz7nmgjy4c6vabvxkw67wni70vy5ddy8s";
};
srcAddon = fetchurl {
url = "http://www.plugcomputer.org/data/uboot/u-boot-3.4.19.zip";
sha256 = "1wag1l6agr8dbnnfaw6bgcrwynwwgry4ihb3gp438699wmkmy91k";
};
postUnpack = ''
mv u-boot-1.1.4 u-boot-3.4.19
unzip -o $srcAddon
sourceRoot=u-boot-3.4.19
'';
patches = [ ./gas220.patch ];
# Remove the cross compiler prefix, and add reiserfs support
configurePhase = ''
make mrproper
make rd88f6281Sheevaplug_config NBOOT=1 LE=1
sed -i /CROSS_COMPILE/d include/config.mk
'';
buildPhase = ''
unset src
make clean all
'';
buildInputs = [ unzip ];
dontStrip = true;
NIX_STRIP_DEBUG = false;
installPhase = ''
ensureDir $out
cp u-boot-rd88f6281Sheevaplug_400db_nand.bin $out
cp u-boot u-boot.map $out
ensureDir $out/bin
cp tools/{envcrc,mkimage} $out/bin
'';
}

View File

@@ -0,0 +1,18 @@
Patch to allow assembling with binutils 2.20. It worked without this patch in 2.19.1
diff --git a/board/mv_feroceon/USP/jump.S b/board/mv_feroceon/USP/jump.S
index 4b6b9ee..58037fc 100644
--- a/board/mv_feroceon/USP/jump.S
+++ b/board/mv_feroceon/USP/jump.S
@@ -29,9 +29,11 @@ disclaimer.
#include "sys/mvCpuIfRegs.h"
-jumpStart:
.section ".reset_vector_sect",#alloc, #execinstr
+
+jumpStart:
+
#if defined(MV_88F6082) || defined(MV_88F6183) || defined(DB_88F5181_OLD) || defined(DB_FPGA) || \
defined(MV88F6281) || defined(MV88F6192) || defined(MV88F6180) || defined(MV_88F6183L) || \
defined(MV88F6190)

View File

@@ -13,9 +13,9 @@ stdenv.mkDerivation rec {
buildInputs = [
pkgconfig python pciutils expat libusb dbus.libs dbus_glib glib
libuuid perl perlXMLParser gettext zlib gperf
consolekit policykit libsmbios
consolekit policykit
# !!! libsmbios is broken; it doesn't install headers.
];
] ++ stdenv.lib.optional (stdenv.system != "armv5tel-linux") [ libsmbios ];
# !!! Hm, maybe the pci/usb.ids location should be in /etc, so that
# we don't have to rebuild HAL when we update the PCI/USB IDs.
@@ -28,7 +28,8 @@ stdenv.mkDerivation rec {
--enable-umount-helper
'';
propagatedBuildInputs = [libusb libsmbios];
propagatedBuildInputs = [ libusb ]
++ stdenv.lib.optional (stdenv.system != "armv5tel-linux") [ libsmbios ];
preConfigure = ''
for i in hald/linux/probing/probe-smbios.c hald/linux/osspec.c \

View File

@@ -16,6 +16,7 @@ stdenv.mkDerivation {
if stdenv.system == "i686-linux" then "i386" else
if stdenv.system == "x86_64-linux" then "x86_64" else
if stdenv.system == "powerpc-linux" then "powerpc" else
if stdenv.system == "armv5tel-linux" then "arm" else
abort "don't know what the kernel include directory is called for this platform";
buildInputs = [perl];

View File

@@ -54,6 +54,11 @@ configurePhase() {
cat .config
}
postBuild() {
if [ -n "$makeUImage" ]; then
make uImage
fi
}
installPhase() {
@@ -65,15 +70,24 @@ installPhase() {
archDir=x86
fi
# Copy the bzImage and System.map.
cp System.map $out
if test "$arch" = um; then
ensureDir $out/bin
cp linux $out/bin
else
cp arch/$archDir/boot/bzImage $out/vmlinuz
if [ -n "$makeUImage" ]; then
image=arch/$archDir/boot/uImage
cp arch/$archDir/boot/uImage $out
else
cp arch/$archDir/boot/bzImage $out/vmlinuz
fi
fi
cp vmlinux $out
# Install the modules in $out/lib/modules with matching paths
# in modules.dep (i.e., refererring to $out/lib/modules, not
# /lib/modules). The depmod_opts= is to prevent the kernel

File diff suppressed because it is too large Load Diff

View File

@@ -37,10 +37,12 @@
, preConfigure ? ""
, extraMeta ? {}
, platform ? { uboot = null; }
, ...
}:
assert stdenv.system == "i686-linux" || stdenv.system == "x86_64-linux";
assert stdenv.system == "i686-linux" || stdenv.system == "x86_64-linux"
|| stdenv.system == "armv5tel-linux";
let
@@ -71,13 +73,15 @@ stdenv.mkDerivation {
map (p: if p ? extraConfig then p.extraConfig else "") kernelPatches;
in lib.concatStrings (addNewlines (configFromPatches ++ extraConfig));
buildInputs = [perl mktemp];
buildInputs = [perl mktemp]
++ lib.optional (platform.uboot != null) [platform.uboot];
arch =
if xen then "xen" else
if userModeLinux then "um" else
if stdenv.system == "i686-linux" then "i386" else
if stdenv.system == "x86_64-linux" then "x86_64" else
if stdenv.system == "armv5tel-linux" then "arm" else
abort "Platform ${stdenv.system} is not supported.";
makeFlags = if userModeLinux then "ARCH=um SHELL=bash" else "";
@@ -87,6 +91,8 @@ stdenv.mkDerivation {
allowLocalVersion = false; # don't allow patches to set a suffix
inherit localVersion; # but do allow the user to set one.
makeUImage = if (platform.uboot != null) then true else false;
meta = {
description =
(if userModeLinux then

View File

@@ -19,6 +19,7 @@ import ./generic.nix (
config =
if stdenv.system == "i686-linux" then ./config-2.6.28-i686-smp else
if stdenv.system == "x86_64-linux" then ./config-2.6.28-x86_64-smp else
if stdenv.system == "armv5tel-linux" then ./config-2.6.28-arm else
abort "No kernel configuration for your platform!";
}

View File

@@ -19,6 +19,7 @@ import ./generic.nix (
config =
if stdenv.system == "i686-linux" then ./config-2.6.29-i686-smp else
if stdenv.system == "x86_64-linux" then ./config-2.6.29-x86_64-smp else
if stdenv.system == "armv5tel-linux" then ./config-2.6.29-arm else
abort "No kernel configuration for your platform!";
}

View File

@@ -20,7 +20,7 @@ import ./generic.nix (
iwlwifi = true;
};
preConfigure = ''
preConfigure = if (stdenv.system != "armv5tel-linux") then ''
killOption () {
sed -re 's/^('"$1"')=[ym]/# \1 is not set/' -i .config
}
@@ -55,9 +55,10 @@ import ./generic.nix (
setOptionYes CONFIG_PREEMPT_VOLUNTARY
cp .config ${config}
'';
'' else "";
config = "./kernel-config";
config = if (stdenv.system == "armv5tel-linux") then
(./config-2.6.31-armv5tel) else "./kernel-config";
}
// args

View File

@@ -15,6 +15,8 @@ stdenv.mkDerivation {
makeFlags = ["V=1" "prefix=$out" "SHLIBDIR=$out/lib"];
preBuild = ''
sed -i /CONFIG_AEABI/d defconfig
echo "CONFIG_AEABI=y" >> defconfig
makeFlags=$(eval "echo $makeFlags")
mkdir linux

View File

@@ -1,4 +1,4 @@
{stdenv, fetchurl, pam, libxcrypt}:
{stdenv, fetchurl, pam, libxcrypt ? null}:
stdenv.mkDerivation {
name = "pam_unix2-2.6";
@@ -8,5 +8,5 @@ stdenv.mkDerivation {
sha256 = "067xnyd3q8ik73glxwyx1lydk4bgl78lzq44mnqqp4jrpnpd04ml";
};
buildInputs = [pam libxcrypt];
buildInputs = [pam ];
}

View File

@@ -0,0 +1,38 @@
{stdenv, fetchurl, kernelHeaders}:
assert stdenv.isLinux;
stdenv.mkDerivation {
name = "uclibc-0.9.30.1";
src = fetchurl {
url = http://www.uclibc.org/downloads/uClibc-0.9.30.1.tar.bz2;
sha256 = "132cf27hkgi0q4qlwbiyj4ffj76sja0jcxm0aqzzgks65jh6k5rd";
};
configurePhase = ''
make defconfig
sed -e s@/usr/include@${kernelHeaders}@ \
-e 's@^RUNTIME_PREFIX.*@RUNTIME_PREFIX="/"@' \
-e 's@^DEVEL_PREFIX.*@DEVEL_PREFIX="/"@' \
${if stdenv.system=="armv5tel-linux" then
''-e 's/.*CONFIG_ARM_OABI.*//' \
-e 's/.*CONFIG_ARM_EABI.*/CONFIG_ARM_EABI=y/' \
-e 's/.*ARCH_BIG_ENDIAN.*/#ARCH_BIG_ENDIAN=y/' \
-e 's/.*ARCH_WANTS_BIG_ENDIAN.*/#ARCH_WANTS_BIG_ENDIAN=y/' \
-e 's/.*ARCH_WANTS_LITTLE_ENDIAN.*/ARCH_WANTS_LITTLE_ENDIAN=y/' '' else ""} \
-i .config
make oldconfig
'';
installPhase = ''
mkdir -p $out
make PREFIX=$out install
(cd $out/include && ln -s ${kernelHeaders}/include/* .) || exit 1
'';
meta = {
homepage = http://www.uclibc.org/;
description = "A small implementation of the C library";
license = "LGPLv2";
};
}

View File

@@ -3,7 +3,10 @@ let
s = import ./src-for-2.6.31-zen5.nix;
in
(import ../kernel/generic.nix) (rec {
inherit (a) stdenv fetchurl perl mktemp module_init_tools;
inherit (a) stdenv fetchurl perl mktemp module_init_tools platform;
uboot = if (platform.name == "sheevaplug") then
platform.uboot else null;
src = a.builderDefs.fetchGitFromSrcInfo s;
version = "2.6.31-zen5";
@@ -11,7 +14,7 @@ let
features = {
iwlwifi = true;
zen = true;
fbConDecor = true;
fbConDecor = if (platform.name == "pc") then true else false;
aufs = true;
};
@@ -23,7 +26,7 @@ let
linux;
};
preConfigure = ''
configFunctions = ''
killOption () {
sed -re 's/^('"$1"')=.*/# \1 is not set/' -i .config
}
@@ -38,7 +41,10 @@ let
setOptionYes () {
setOptionVal "$1" y
}
'';
configurePC = ''
make allmodconfig
killOption CONFIG_CMDLINE_OVERRIDE
@@ -99,4 +105,89 @@ let
''
cp .config ${config}
'';
configureBaseSheevaplug = ''
ARCH=arm make kirkwood_defconfig
'';
configureBaseVersatileARM = ''
ARCH=arm make versatile_defconfig
'';
configureARM = ''
killOption CONFIG_CMDLINE_OVERRIDE
killOption 'CONFIG_.*_DEBUG.*'
killOption 'CONFIG_DEBUG.*'
killOption CONFIG_AUDIT_ARCH
killOption CONFIG_PERF_COUNTERS
killOption 'CONFIG_GCOV.*'
killOption 'CONFIG_KGDB.*'
killOption 'CONFIG_.*_TEST'
killOption CONFIG_TASKSTATS
killOption CONFIG_SLQB
killOption CONFIG_SLQB_ALLOCATOR
setOptionYes CONFIG_SLUB_ALLOCATOR
setOptionYes CONFIG_SLUB
killOption CONFIG_ACPI_CUSTOM_DSDT_INITRD
killOption CONFIG_DEVTMPFS
killOption CONFIG_DEVTMPFS_MOUNT
killOption CONFIG_IMA
'' +
''
killOption CONFIG_USB_OTG_BLACKLIST_HUB
''+
''
killOption CONFIG_KERNEL_BZIP2
killOption CONFIG_KERNEL_LZMA
setOptionYes CONFIG_KERNEL_GZIP
''+
''
killOption CONFIG_FB_TILEBLITTING
killOption CONFIG_FB_S3
killOption CONFIG_FB_VT8623
killOption CONFIG_FB_ARK
killOption CONFIG_FRAMEBUFFER_CONSOLE
killOption CONFIG_FB
make oldconfig
killOption CONFIG_FB_CON_DECOR
killOption CONFIG_FB_VESA
''+
''
killOption CONFIG_PREEMPT_NONE
setOptionYes CONFIG_PREEMPT_VOLUNTARY
''+
''
killOption CONFIG_PRAMFS
''+
''
setOptionYes CONFIG_MTD_UBI
setOptionYes CONFIG_REISERFS_FS
setOptionYes CONFIG_FUSE_FS
setOptionYes CONFIG_ISO9660_FS
''+
(if a.lib.attrByPath ["ckSched"] false a then ''
killOption CONFIG_CPU_CFS
setOptionYes CONFIG_CPU_BFS
killOption CONFIG_NO_HZ
killOption CONFIG_HZ_1000
setOptionYes CONFIG_HZ_250
setOptionVal CONFIG_HZ 250
''else "") +
''
cp .config ${config}
'';
preConfigure = configFunctions +
(if (platform.name == "pc") then
(configureBaseSheevaplug + configureARM)
else if (platform.name == "sheevaplug") then
(configureBaseSheevaplug + configureARM)
else if (platform.name == "versatileARM") then
(configureBaseVersatileARM + configureARM)
else throw "platform not supported"
);
})

View File

@@ -0,0 +1,37 @@
# Automatically generated by `update-patch-set.sh'; do not edit.
patch: [
(patch "001" "06q3y3i2kp09bnjd99lxa95psdmj2haril7pxhdbz9sx9qh19dg3")
(patch "002" "1x2w3mmz1qga30zf95wmnpjsdp8cnd2ljl29mfq9r6q1cvjifla9")
(patch "003" "1n3vg6p4nc7kd896s0fp48y9f6ddf3bkpdqzgmdpgqxi243c8073")
(patch "004" "1bnja962g9isrqhrw8dzxsx7ssvc2ayk1a9vmg2dx6gai8gys0sb")
(patch "005" "0l4l62riap2kqy20789x7f6bfx361yvixds0gnh10rli4v05h1j2")
(patch "006" "1r429n2b5cs2gi5zjv1hlr8k7jplnjg3y563369z799x1x9651y7")
(patch "007" "0vb11vy8r5ayr88hrlli8xj2qcird1qg8l99nknrwnni4jg5b3am")
(patch "008" "1z6q0lq1yxwpf6nf1z39jbyycv6cfv6gwpaqmgg7pnw31z029nw7")
(patch "009" "0avyvz8rkj66x715zf1b3w2pgbwwzaj977v9pcrscjksc50c4iq0")
(patch "010" "05j8xq2s1wnii1za1s6nglzga9xp7q1dmcs1bqqrlggz8mmnyhgj")
(patch "011" "1m2lhfhy6bl3j88qi9kcn6n1qb439n8pmhl4cqsmi2g8xwli9j7z")
(patch "012" "1ww327ga4s7607jgr0xd6nh8bg4xgf2vk63p2yy9b1iaq7lxdi5j")
(patch "013" "0fjc3qj4q6q2zfq1qmiarp6s4hhbh80q47xwws0mvgpks7wwl33n")
(patch "014" "16n3l7627n8b1p9s9ss9fcj7nbn1s6yndwmlh3v751knj73c9v8k")
(patch "015" "0548fm4vd3sv3y4g3csysm1mm7jk5hvyfwglw1c0pj2lvyzf583v")
(patch "016" "06fmf6jmgzl0x1vd7pkyi90sa1wjywkd42gi1phqmrwgj9p96flg")
(patch "017" "08gh63spac39z90n1d8gpx571x7n4bwzp2yqm3ik9c1rcgz2mvib")
(patch "018" "0cg6q3fn0j8kzd9w7plnwrbyxv8hzwx9vjp3ij9vx1p3n26vpcqx")
(patch "019" "0xbl1f5l04pmrs5dsq2nbpcs58zgz0f48nj4hqic143h0y7r8jah")
(patch "020" "11371hsarqc5czij1lmkj79c0h1b7hninkzrzmqpr1hnwgmrm6hw")
(patch "021" "0k8ii0yb4zhxmc90n3y2wpkczrxh7j1avjflnsi42j8hidpjsiq2")
(patch "022" "04lh6n91bif6wbcmizps40yc9qwfw720xq3vmmrkz1m13b3isnh4")
(patch "023" "11nwbnp4gmsjw46gq9gahzlbdagl3r1vdvcxvxfwlqppflim42sq")
(patch "024" "1aqp6z2mlp1m921ckgiiqd42fnvjrhil4bkkw58vjcgygv2bm7m5")
(patch "025" "023aixd4v3adsvnni9jf2qcfgpsza544k76k2ny78d036vb00ygp")
(patch "026" "1jzn8185iw49126mngbz8007dd6ca9m04n5yhhc5c9b6ki0g9gd9")
(patch "027" "1wkp9ci0ccvgmnjyg5z3qkcfh2z7p3rgdm8cc5k8mk5sn5mw4pgn")
(patch "028" "06id09sb9rvlw7phibs6aw7ncjddikia0mjr9jdis75byfx2q8jv")
(patch "029" "0rpsam2m9mxnxcgcdr461sijprqi9wv6i9gg5c7c46gwj4gs5x8m")
(patch "030" "1wwajl7fb5vy25m08fp4jshgqdh02m66zj7yq8i0j65675ldx1bz")
(patch "031" "037viyi9n9hnc5yyfgrr1ssvqr2vkasn08x3qvyxak7f0s4k2gv0")
(patch "032" "1pma7w85vq831izaqc4p9831hfsfl31s4n155azkrxywpqv4fsza")
(patch "033" "1x845nfqg8wr1x4wls9jdrzdq1lbig02w07wpmfr4h4r6bhgd5n4")
]

View File

@@ -3,7 +3,7 @@
assert interactive -> readline != null;
stdenv.mkDerivation rec {
name = "bash-4.0-p17";
name = "bash-4.0-p28";
src = fetchurl {
url = "mirror://gnu/bash/bash-4.0.tar.gz";
@@ -19,8 +19,6 @@ stdenv.mkDerivation rec {
-DSSH_SOURCE_BASHRC
'';
postInstall = "ln -s bash $out/bin/sh";
patchFlags = "-p0";
patches =
@@ -30,25 +28,8 @@ stdenv.mkDerivation rec {
url = "mirror://gnu/bash/bash-4.0-patches/bash40-${nr}";
inherit sha256;
};
in [
(patch "001" "06q3y3i2kp09bnjd99lxa95psdmj2haril7pxhdbz9sx9qh19dg3")
(patch "002" "1x2w3mmz1qga30zf95wmnpjsdp8cnd2ljl29mfq9r6q1cvjifla9")
(patch "003" "1n3vg6p4nc7kd896s0fp48y9f6ddf3bkpdqzgmdpgqxi243c8073")
(patch "004" "1bnja962g9isrqhrw8dzxsx7ssvc2ayk1a9vmg2dx6gai8gys0sb")
(patch "005" "0l4l62riap2kqy20789x7f6bfx361yvixds0gnh10rli4v05h1j2")
(patch "006" "1r429n2b5cs2gi5zjv1hlr8k7jplnjg3y563369z799x1x9651y7")
(patch "007" "0vb11vy8r5ayr88hrlli8xj2qcird1qg8l99nknrwnni4jg5b3am")
(patch "008" "1z6q0lq1yxwpf6nf1z39jbyycv6cfv6gwpaqmgg7pnw31z029nw7")
(patch "009" "0avyvz8rkj66x715zf1b3w2pgbwwzaj977v9pcrscjksc50c4iq0")
(patch "010" "05j8xq2s1wnii1za1s6nglzga9xp7q1dmcs1bqqrlggz8mmnyhgj")
(patch "011" "1m2lhfhy6bl3j88qi9kcn6n1qb439n8pmhl4cqsmi2g8xwli9j7z")
(patch "012" "1ww327ga4s7607jgr0xd6nh8bg4xgf2vk63p2yy9b1iaq7lxdi5j")
(patch "013" "0fjc3qj4q6q2zfq1qmiarp6s4hhbh80q47xwws0mvgpks7wwl33n")
(patch "014" "16n3l7627n8b1p9s9ss9fcj7nbn1s6yndwmlh3v751knj73c9v8k")
(patch "015" "0548fm4vd3sv3y4g3csysm1mm7jk5hvyfwglw1c0pj2lvyzf583v")
(patch "016" "06fmf6jmgzl0x1vd7pkyi90sa1wjywkd42gi1phqmrwgj9p96flg")
(patch "017" "08gh63spac39z90n1d8gpx571x7n4bwzp2yqm3ik9c1rcgz2mvib")
];
in
import ./bash-patches.nix patch;
# Note: Bison is needed because the patches above modify parse.y.
buildInputs = [bison]
@@ -57,6 +38,18 @@ stdenv.mkDerivation rec {
configureFlags = "--with-installed-readline";
postInstall = ''
# Add an `sh' -> `bash' symlink.
ln -s bash "$out/bin/sh"
# Install the completion examples.
ensureDir "$out/etc"
cp -v "examples/complete/bash_completion" "$out/etc"
ensureDir "$out/etc/bash_completion.d"
cp -v "examples/complete/complete.gnu-longopt" "$out/etc/bash_completion.d"
'';
meta = {
homepage = http://www.gnu.org/software/bash/;
description =
@@ -75,5 +68,7 @@ stdenv.mkDerivation rec {
'';
license = "GPLv3+";
maintainers = [ stdenv.lib.maintainers.ludo ];
};
}

View File

@@ -0,0 +1,47 @@
#!/bin/sh
# Update patch set for GNU Bash or Readline.
if [ $# -ne 2 ]
then
echo "Usage: $(basename $0) PROJECT VERSION"
echo ""
echo "Update the patch set for PROJECT (one of \`bash' or \`readline') for"
echo "the given version (e.g., \`4.0'). Produce \`PROJECT-patches.nix'."
exit 1
fi
PROJECT="$1"
VERSION="$2"
VERSION_CONDENSED="$(echo $VERSION | sed -es/\\.//g)"
GPG="$(if $(type -P gpg2 > /dev/null); then echo gpg2; else echo gpg; fi)"
PATCH_LIST="$PROJECT-patches.nix"
set -e
start=1
end=100 # must be > 99 for correct padding
rm -vf "$PATCH_LIST"
( echo "# Automatically generated by \`$(basename $0)'; do not edit." ; \
echo "" ; \
echo "patch: [" ) \
>> "$PATCH_LIST"
for i in `seq -w $start $end`
do
wget ftp.gnu.org/gnu/$PROJECT/$PROJECT-$VERSION-patches/$PROJECT$VERSION_CONDENSED-$i || break
wget ftp.gnu.org/gnu/$PROJECT/$PROJECT-$VERSION-patches/$PROJECT$VERSION_CONDENSED-$i.sig
"$GPG" --verify $PROJECT$VERSION_CONDENSED-$i.sig
echo "(patch \"$i\" \"$(nix-hash --flat --type sha256 --base32 $PROJECT$VERSION_CONDENSED-$i)\")" \
>> "$PATCH_LIST"
rm -f $PROJECT$VERSION_CONDENSED-$i{,.sig}
done
echo "]" >> "$PATCH_LIST"
echo "Got $(expr $i - 1) patches."
echo "Patch list has been written to \`$PATCH_LIST'."

View File

@@ -54,6 +54,7 @@ rec {
stdenv =
if stdenvType == "i686-linux" then stdenvLinux else
if stdenvType == "x86_64-linux" then stdenvLinux else
if stdenvType == "armv5tel-linux" then stdenvLinux else
if stdenvType == "powerpc-linux" then /* stdenvLinux */ stdenvNative else
if stdenvType == "i686-mingw" then stdenvMinGW else
if stdenvType == "i686-darwin" then stdenvNix else

View File

@@ -71,7 +71,8 @@ let
isDarwin = result.system == "i686-darwin" || result.system == "powerpc-darwin";
isLinux = result.system == "i686-linux"
|| result.system == "x86_64-linux"
|| result.system == "powerpc-linux";
|| result.system == "powerpc-linux"
|| result.system == "armv5tel-linux";
isi686 = result.system == "i686-linux"
|| result.system == "i686-darwin"
|| result.system == "i686-freebsd"

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,13 @@
{
sh = ./sh;
bzip2 = ./bzip2;
mkdir = ./mkdir;
cpio = ./cpio;
ln = ./ln;
curl = ./curl.bz2;
bootstrapTools = {
url = "http://vicerveza.homeunix.net/~viric/tmp/bootstrap-tools-armv5tel-linux.cpio.bz2";
sha256 = "0b7mrcl7naj1xpqx1qnlmd825dxzikzhxir3mw4pr3dy28n0b2ka";
};
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -13,6 +13,7 @@ rec {
if system == "i686-linux" then import ./bootstrap/i686
else if system == "x86_64-linux" then import ./bootstrap/x86_64
else if system == "powerpc-linux" then import ./bootstrap/powerpc
else if system == "armv5tel-linux" then import ./bootstrap/armv5tel
else abort "unsupported platform for the pure Linux stdenv";
@@ -50,7 +51,10 @@ rec {
builder = bootstrapFiles.sh;
args = [ ./scripts/unpack-bootstrap-tools.sh ];
args = if (system == "armv5tel-linux") then
([ ./scripts/unpack-bootstrap-tools-arm.sh ])
else
([ ./scripts/unpack-bootstrap-tools.sh ]);
inherit (bootstrapFiles) bzip2 mkdir curl cpio;
@@ -120,12 +124,12 @@ rec {
# A helper function to call gcc-wrapper.
wrapGCC =
{gcc ? bootstrapTools, libc, binutils, shell ? "", name ? "bootstrap-gcc"}:
{gcc ? bootstrapTools, libc, binutils, coreutils, shell ? "", name ? "bootstrap-gcc-wrapper"}:
import ../../build-support/gcc-wrapper {
nativeTools = false;
nativeLibc = false;
inherit gcc binutils libc shell name;
inherit gcc binutils coreutils libc shell name;
stdenv = stdenvLinuxBoot0;
};
@@ -134,7 +138,8 @@ rec {
# of bootstrap tools only, and a minimal Glibc to keep the GCC
# configure script happy.
stdenvLinuxBoot1 = stdenvBootFun {
gcc = wrapGCC {libc = bootstrapGlibc; binutils = bootstrapTools;};
gcc = wrapGCC {libc = bootstrapGlibc; binutils = bootstrapTools;
coreutils = bootstrapTools; };
inherit fetchurl;
};
@@ -156,7 +161,8 @@ rec {
# this one uses the Glibc built in step 3. It still uses
# the rest of the bootstrap tools, including GCC.
stdenvLinuxBoot2 = removeAttrs (stdenvBootFun {
gcc = wrapGCC {binutils = bootstrapTools; libc = stdenvLinuxGlibc;};
gcc = wrapGCC {binutils = bootstrapTools; coreutils = bootstrapTools;
libc = stdenvLinuxGlibc;};
extraAttrs = {glibc = stdenvLinuxGlibc;};
inherit fetchurl;
}) ["gcc" "binutils"];
@@ -176,6 +182,7 @@ rec {
stdenvLinuxBoot3 = stdenvBootFun {
gcc = wrapGCC rec {
inherit (stdenvLinuxBoot2Pkgs) binutils;
coreutils = bootstrapTools;
libc = stdenvLinuxGlibc;
gcc = stdenvLinuxBoot2Pkgs.gcc.gcc;
name = "";
@@ -210,6 +217,7 @@ rec {
gcc = wrapGCC rec {
inherit (stdenvLinuxBoot2Pkgs) binutils;
inherit (stdenvLinuxBoot3Pkgs) coreutils;
libc = stdenvLinuxGlibc;
gcc = stdenvLinuxBoot2Pkgs.gcc.gcc;
shell = stdenvLinuxBoot3Pkgs.bash + "/bin/bash";

View File

@@ -10,20 +10,26 @@ rec {
aclSupport = false;
});
gccLinkStatic = wrapGCCWith (import ../../build-support/gcc-wrapper) uclibc
stdenv.gcc.gcc;
stdenvLinkStatic = overrideGCC stdenv gccLinkStatic;
curlDiet = import ../../tools/networking/curl {
curlStatic = import ../../tools/networking/curl {
stdenv = stdenvLinkStatic;
inherit fetchurl;
stdenv = useDietLibC stdenv;
zlibSupport = false;
sslSupport = false;
linkStatic = true;
};
bzip2Diet = import ../../tools/compression/bzip2 {
bzip2Static = import ../../tools/compression/bzip2 {
stdenv = stdenvLinkStatic;
inherit fetchurl;
stdenv = useDietLibC stdenv;
linkStatic = true;
};
#gccNoShared = wrapGCC ( gcc.gcc.override { enableShared = false; } );
build =
@@ -33,6 +39,7 @@ rec {
buildInputs = [nukeReferences cpio];
buildCommand = ''
set -x
ensureDir $out/bin $out/lib $out/libexec
# Copy what we need of Glibc.
@@ -132,8 +139,8 @@ rec {
cp ${klibc}/lib/klibc/bin.static/cpio $out/in-nixpkgs
cp ${klibc}/lib/klibc/bin.static/mkdir $out/in-nixpkgs
cp ${klibc}/lib/klibc/bin.static/ln $out/in-nixpkgs
cp ${curlDiet}/bin/curl $out/in-nixpkgs
cp ${bzip2Diet}/bin/bzip2 $out/in-nixpkgs
cp ${curlStatic}/bin/curl $out/in-nixpkgs
cp ${bzip2Static}/bin/bzip2 $out/in-nixpkgs
chmod u+w $out/in-nixpkgs/*
strip $out/in-nixpkgs/*
nuke-refs $out/in-nixpkgs/*

View File

@@ -0,0 +1,48 @@
set -e
# Unpack the bootstrap tools tarball.
echo Unpacking the bootstrap tools...
$mkdir $out
$bzip2 -d < $tarball | (cd $out && $cpio -V -i)
# Set the ELF interpreter / RPATH in the bootstrap binaries.
echo Patching the bootstrap tools...
# On x86_64, ld-linux-x86-64.so.2 barfs on patchelf'ed programs. So
# use a copy of patchelf.
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? $out/bin/cp $out/bin/patchelf .
for i in $out/bin/* $out/libexec/gcc/*/*/*; do
echo patching $i
if ! test -L $i; then
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
$out/bin/patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
$out/bin/patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
fi
done
for i in $out/lib/librt* ; do
echo patching $i
if ! test -L $i; then
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
$out/bin/patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
$out/bin/patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
fi
done
# Fix the libc linker script.
export PATH=$out/bin
cat $out/lib/libc.so | sed "s|/nix/store/e*-[^/]*/|$out/|g" > $out/lib/libc.so.tmp
mv $out/lib/libc.so.tmp $out/lib/libc.so
cat $out/lib/libpthread.so | sed "s|/nix/store/e*-[^/]*/|$out/|g" > $out/lib/libpthread.so.tmp
mv $out/lib/libpthread.so.tmp $out/lib/libpthread.so
# Provide some additional symlinks.
ln -s bash $out/bin/sh
ln -s bzip2 $out/bin/bunzip2
# fetchurl needs curl.
bzip2 -d < $curl > $out/bin/curl
chmod +x $out/bin/curl

View File

@@ -10,13 +10,24 @@ echo Patching the bootstrap tools...
# On x86_64, ld-linux-x86-64.so.2 barfs on patchelf'ed programs. So
# use a copy of patchelf.
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.2 $out/bin/cp $out/bin/patchelf .
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? $out/bin/cp $out/bin/patchelf .
for i in $out/bin/* $out/libexec/gcc/*/*/*; do
echo patching $i
if ! test -L $i; then
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.2 \
./patchelf --set-interpreter $out/lib/ld-linux*.so.2 --set-rpath $out/lib --force-rpath $i
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
$out/bin/patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
$out/bin/patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
fi
done
for i in $out/lib/librt* ; do
echo patching $i
if ! test -L $i; then
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
$out/bin/patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
$out/bin/patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
fi
done
@@ -24,6 +35,8 @@ done
export PATH=$out/bin
cat $out/lib/libc.so | sed "s|/nix/store/e*-[^/]*/|$out/|g" > $out/lib/libc.so.tmp
mv $out/lib/libc.so.tmp $out/lib/libc.so
cat $out/lib/libpthread.so | sed "s|/nix/store/e*-[^/]*/|$out/|g" > $out/lib/libpthread.so.tmp
mv $out/lib/libpthread.so.tmp $out/lib/libpthread.so
# Provide some additional symlinks.
ln -s bash $out/bin/sh

View File

@@ -1,4 +1,4 @@
{stdenv, fetchurl}:
{stdenv, fetchurl, linkStatic ? false}:
stdenv.mkDerivation {
name = "bzip2-1.0.5";
@@ -11,7 +11,11 @@ stdenv.mkDerivation {
};
sharedLibrary =
!stdenv.isDarwin && !(stdenv ? isDietLibC) && !(stdenv ? isStatic) && stdenv.system != "i686-cygwin";
!stdenv.isDarwin && !(stdenv ? isDietLibC) && !(stdenv ? isStatic) && stdenv.system != "i686-cygwin" && !linkStatic;
makeFlags = if linkStatic then "LDFLAGS=-static" else "";
inherit linkStatic;
meta = {
homepage = http://www.bzip.org;

View File

@@ -1,17 +1,35 @@
{stdenv, fetchurl}:
stdenv.mkDerivation {
name = "gzip-1.3.12";
stdenv.mkDerivation rec {
name = "gzip-1.3.13";
src = fetchurl {
url = http://ftp.gnu.org/gnu/gzip/gzip-1.3.12.tar.gz;
sha256 = "1bw7sm68xjlnlzgcx66hnw80ac1qqyvhw0vw27zilgbzbzh5nmiz";
url = "mirror://gnu/gzip/${name}.tar.gz";
sha256 = "18vwa7x0b1sql9bs2d15n94fx3him1m6xpnwsfz52djjbjgzy1hx";
};
patches = [ ./getopt.patch ];
doCheck = true;
meta = {
homepage = http://www.gzip.org/;
description = "The gzip compression program";
homepage = http://www.gnu.org/software/gzip/;
description = "Gzip, the GNU zip compression program";
longDescription =
''gzip (GNU zip) is a popular data compression program written by
Jean-loup Gailly for the GNU project. Mark Adler wrote the
decompression part.
We developed this program as a replacement for compress because of
the Unisys and IBM patents covering the LZW algorithm used by
compress. These patents made it impossible for us to use compress,
and we needed a replacement. The superior compression ratio of gzip
is just a bonus.
'';
license = "GPLv3+";
maintainers = [ stdenv.lib.maintainers.ludo ];
};
patches = [./gnulib-futimens.patch];
}

View File

@@ -0,0 +1,54 @@
See http://lists.gnu.org/archive/html/bug-gnulib/2009-10/msg00089.html .
From dd0ebefe4fe761f6f422a400430db53c64dbffd7 Mon Sep 17 00:00:00 2001
From: Eric Blake <ebb9@byu.net>
Date: Tue, 6 Oct 2009 20:44:13 -0600
Subject: [PATCH] getopt: fix compilation on darwin
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* lib/getopt.in.h (includes): Leave breadcrumbs during system
include.
* lib/unistd.in.h (getopt): Use them to avoid recursive include.
Reported by Ludovic Courtès.
Signed-off-by: Eric Blake <ebb9@byu.net>
---
ChangeLog | 5 +++++
lib/getopt.in.h | 6 +++++-
lib/unistd.in.h | 2 +-
3 files changed, 11 insertions(+), 2 deletions(-)
diff --git a/lib/getopt.in.h b/lib/getopt.in.h
index 9de467a..7377f3c 100644
--- a/lib/getopt.in.h
+++ b/lib/getopt.in.h
@@ -22,9 +22,13 @@
@PRAGMA_SYSTEM_HEADER@
#endif
-/* The include_next requires a split double-inclusion guard. */
+/* The include_next requires a split double-inclusion guard. We must
+ also inform the replacement unistd.h to not recursively use
+ <getopt.h>; our definitions will be present soon enough. */
#if @HAVE_GETOPT_H@
+# define _GL_SYSTEM_GETOPT
# @INCLUDE_NEXT@ @NEXT_GETOPT_H@
+# undef _GL_SYSTEM_GETOPT
#endif
#ifndef _GL_GETOPT_H
diff --git a/lib/unistd.in.h b/lib/unistd.in.h
index 38e2e13..b6ea889 100644
--- a/lib/unistd.in.h
+++ b/lib/unistd.in.h
@@ -49,7 +49,7 @@
#endif
/* Get getopt(), optarg, optind, opterr, optopt. */
-#if @GNULIB_UNISTD_H_GETOPT@
+#if @GNULIB_UNISTD_H_GETOPT@ && !defined _GL_SYSTEM_GETOPT
# include <getopt.h>
#endif

View File

@@ -1,42 +0,0 @@
now hat glibc-2.6 declares futimens.
http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00089.html
diff -ru cpio-2.7.orig/lib/utimens.c cpio-2.7/lib/utimens.c
--- cpio-2.7.orig/lib/utimens.c 2007-05-20 21:23:57.000000000 +0900
+++ cpio-2.7/lib/utimens.c 2007-05-21 08:40:22.000000000 +0900
@@ -73,7 +73,7 @@
Return 0 on success, -1 (setting errno) on failure. */
int
-futimens (int fd ATTRIBUTE_UNUSED,
+gl_futimens (int fd ATTRIBUTE_UNUSED,
char const *file, struct timespec const timespec[2])
{
/* There's currently no interface to set file timestamps with
@@ -166,5 +166,5 @@
int
utimens (char const *file, struct timespec const timespec[2])
{
- return futimens (-1, file, timespec);
+ return gl_futimens (-1, file, timespec);
}
diff -ru cpio-2.7.orig/lib/utimens.h cpio-2.7/lib/utimens.h
--- cpio-2.7.orig/lib/utimens.h 2007-05-20 21:23:57.000000000 +0900
+++ cpio-2.7/lib/utimens.h 2007-05-21 08:39:57.000000000 +0900
@@ -1,3 +1,3 @@
#include "timespec.h"
-int futimens (int, char const *, struct timespec const [2]);
+int gl_futimens (int, char const *, struct timespec const [2]);
int utimens (char const *, struct timespec const [2]);
diff -ur gzip-1.3.12.orig/gzip.c gzip-1.3.12/gzip.c
--- gzip-1.3.12.orig/gzip.c 2007-05-21 09:12:46.000000000 +0900
+++ gzip-1.3.12/gzip.c 2007-05-21 09:13:14.000000000 +0900
@@ -1637,7 +1637,7 @@
}
}
- if (futimens (ofd, ofname, timespec) != 0)
+ if (gl_futimens (ofd, ofname, timespec) != 0)
{
int e = errno;
WARN ((stderr, "%s: ", program_name));

View File

@@ -0,0 +1,28 @@
{stdenv, fetchurl, aclSupport ? false, acl}:
stdenv.mkDerivation rec {
name = "coreutils-7.5";
src = fetchurl {
url = "mirror://gnu/coreutils/${name}.tar.gz";
sha256 = "1hf333y85fm0q7f1apx2zjjhivwj620nc8kcifdcm0sg8fwlj7rl";
};
buildInputs = stdenv.lib.optional aclSupport acl;
meta = {
homepage = http://www.gnu.org/software/coreutils/;
description = "The basic file, shell and text manipulation utilities of the GNU operating system";
longDescription = ''
The GNU Core Utilities are the basic file, shell and text
manipulation utilities of the GNU operating system. These are
the core utilities which are expected to exist on every
operating system.
'';
license = "GPLv3+";
maintainers = [ stdenv.lib.maintainers.ludo ];
};
}

View File

@@ -1,15 +1,15 @@
{stdenv, fetchurl, aclSupport ? false, acl}:
stdenv.mkDerivation rec {
name = "coreutils-7.2";
name = "coreutils-7.6";
src = fetchurl {
url = "mirror://gnu/coreutils/${name}.tar.gz";
sha256 = "1cpx66kwcg5w78by8i27wb24j0flz2ivv9fqmd4av8z5jbnbyxyx";
sha256 = "1m153jmnrg9v4x6qiw7azd3cjms13s32yihbzb7zi9bw8a5zx6qx";
};
buildInputs = stdenv.lib.optional aclSupport acl;
meta = {
homepage = http://www.gnu.org/software/coreutils/;
description = "The basic file, shell and text manipulation utilities of the GNU operating system";
@@ -22,5 +22,7 @@ stdenv.mkDerivation rec {
'';
license = "GPLv3+";
maintainers = [ stdenv.lib.maintainers.ludo ];
};
}

View File

@@ -1,4 +1,4 @@
{stdenv, fetchurl, zlibSupport ? false, zlib ? null, sslSupport ? false, openssl ? null}:
{stdenv, fetchurl, zlibSupport ? false, zlib ? null, sslSupport ? false, openssl ? null, linkStatic ? false}:
assert zlibSupport -> zlib != null;
assert sslSupport -> openssl != null;
@@ -20,12 +20,20 @@ stdenv.mkDerivation rec {
configureFlags = ''
${if sslSupport then "--with-ssl=${openssl}" else "--without-ssl"}
${if linkStatic then "--enable-static --disable-shared" else ""}
'';
dontDisableStatic = if linkStatic then true else false;
CFLAGS = if stdenv ? isDietLibC then "-DHAVE_INET_NTOA_R_2_ARGS=1" else "";
LDFLAGS = if linkStatic then "-static" else "";
CXX = "g++";
CXXCPP = "g++ -E";
# libtool hack to get a static binary. Notice that to 'configure' I passed
# other LDFLAGS, because it doesn't use libtool for linking in the tests.
makeFlags = if linkStatic then "LDFLAGS=-all-static" else "";
passthru = {
inherit sslSupport openssl;
};

View File

@@ -1,17 +1,46 @@
{stdenv, fetchurl, gettext, openssl ? null}:
{ stdenv, fetchurl, gettext, perl, gnutls ? null }:
stdenv.mkDerivation rec {
name = "wget-1.11.4";
name = "wget-1.12";
src = fetchurl {
url = "mirror://gnu/wget/${name}.tar.bz2";
sha256 = "1yr7w182n7lvkajvq07wnw65sw2vmxjkc3611kpc728vhvi54zwb";
sha256 = "16msgly5xn0qj6ngsw34q9j7ag8jkci6020w21d30jgqw8wdj8y8";
};
buildInputs = [gettext openssl];
patches = [ ./gnutls-support.patch ];
preConfigure =
'' for i in "doc/texi2pod.pl" "tests/run-px" "util/rmold.pl"
do
sed -i "$i" -e 's|/usr/bin.*perl|${perl}/bin/perl|g'
done
'';
buildInputs = [ gettext perl ]
++ stdenv.lib.optional (gnutls != null) gnutls;
configureFlags =
if gnutls != null
then "--with-ssl=gnutls"
else "";
doCheck = true;
meta = {
description = "A console downloading program. Has some features for mirroring sites.";
homepage = http://www.gnu.org/software/wget;
description = "GNU Wget, a tool for retrieving files using HTTP, HTTPS, and FTP";
longDescription =
'' GNU Wget is a free software package for retrieving files using HTTP,
HTTPS and FTP, the most widely-used Internet protocols. It is a
non-interactive commandline tool, so it may easily be called from
scripts, cron jobs, terminals without X-Windows support, etc.
'';
license = "GPLv3+";
homepage = http://www.gnu.org/software/wget/;
maintainers = [ stdenv.lib.maintainers.ludo ];
};
}

View File

@@ -0,0 +1,16 @@
This patch fixes GnuTLS support:
http.o: In function `gethttp':
http.c:(.text+0x26c6): undefined reference to `ssl_connect_wget'
--- wget-1.12/src/http.c 2009-09-22 05:02:18.000000000 +0200
+++ wget-1.12/src/http.c 2009-10-03 17:24:46.000000000 +0200
@@ -1762,7 +1762,7 @@ gethttp (struct url *u, struct http_stat
if (conn->scheme == SCHEME_HTTPS)
{
- if (!ssl_connect_wget (sock))
+ if (!ssl_connect (sock))
{
fd_close (sock);
return CONSSLERR;

View File

@@ -1,15 +1,35 @@
{stdenv, fetchurl}:
stdenv.mkDerivation {
name = "gawk-3.1.6";
stdenv.mkDerivation rec {
name = "gawk-3.1.7";
src = fetchurl {
url = mirror://gnu/gawk/gawk-3.1.6.tar.bz2;
sha256 = "0v6ba4hxfiiy3bny5japd3zmzxlh8vdkmswk96yngd6i1dddsgsi";
url = "mirror://gnu/gawk/${name}.tar.bz2";
sha256 = "0wfyiqc28cxb5wjbdph4y33h1fdf56nj6cm7as546niwjsw7cazi";
};
doCheck = true;
meta = {
homepage = http://www.gnu.org/software/gawk/;
description = "GNU implementation of the AWK programming language";
description = "GNU implementation of the Awk programming language";
longDescription = ''
Many computer users need to manipulate text files: extract and then
operate on data from parts of certain lines while discarding the rest,
make changes in various text files wherever certain patterns appear,
and so on. To write a program to do these things in a language such as
C or Pascal is a time-consuming inconvenience that may take many lines
of code. The job is easy with awk, especially the GNU implementation:
Gawk.
The awk utility interprets a special-purpose programming language that
makes it possible to handle many data-reformatting jobs with just a few
lines of code.
'';
license = "GPLv3+";
maintainers = [ stdenv.lib.maintainers.ludo ];
};
}

View File

@@ -321,7 +321,7 @@ let
};
makeInitrd = {contents}: import ../build-support/kernel/make-initrd.nix {
inherit stdenv perl cpio contents;
inherit stdenv perl cpio contents uboot;
};
makeSetupHook = script: runCommand "hook" {} ''
@@ -409,6 +409,23 @@ let
'';
platformPC = assert system == "i686-linux" || system == "x86_64-linux"; {
name = "pc";
uboot = null;
};
platformSheevaplug = assert system == "armv5tel-linux"; {
name = "sheevaplug";
inherit uboot;
};
platformVersatileARM = assert system == "armv5tel-linux"; {
name = "versatileARM";
uboot = null;
};
platform = platformPC;
### TOOLS
darwinArchUtility = import ../os-specific/darwin/arch {
@@ -589,14 +606,22 @@ let
inherit fetchurl stdenv ppl;
};
coreutils = useFromStdenv "coreutils"
(makeOverridable (if stdenv ? isDietLibC
coreutils75_real = makeOverridable (import ../tools/misc/coreutils/7.5.nix) {
inherit fetchurl stdenv acl;
aclSupport = stdenv.isLinux;
};
coreutils_real = makeOverridable (if stdenv ? isDietLibC
then import ../tools/misc/coreutils-5
else import ../tools/misc/coreutils)
{
inherit fetchurl stdenv acl;
aclSupport = stdenv.isLinux;
});
};
coreutils = useFromStdenv "coreutils"
(if system == "armv5tel-linux" then coreutils75_real
else coreutils_real);
cpio = import ../tools/archivers/cpio {
inherit fetchurl stdenv;
@@ -1096,7 +1121,7 @@ let
};
mldonkey = import ../applications/networking/p2p/mldonkey {
inherit fetchurl stdenv ocaml zlib ncurses;
inherit fetchurl stdenv ocaml zlib ncurses gd libpng;
};
monit = builderDefsPackage ../tools/system/monit {
@@ -1682,7 +1707,7 @@ let
};
wget = import ../tools/networking/wget {
inherit fetchurl stdenv gettext openssl;
inherit fetchurl stdenv gettext gnutls perl;
};
which = import ../tools/system/which {
@@ -2171,7 +2196,7 @@ let
ocaml = ocaml_3_11_1;
ocaml_3_08_0 = import ../development/compilers/ocaml/3.08.0.nix {
inherit fetchurl stdenv x11 ncurses;
inherit fetchurl stdenv fetchcvs x11 ncurses;
};
ocaml_3_09_1 = import ../development/compilers/ocaml/3.09.1.nix {
@@ -2264,7 +2289,7 @@ let
nativePrefix = if stdenv ? gcc then stdenv.gcc.nativePrefix else "";
gcc = baseGCC;
libc = glibc;
inherit stdenv binutils;
inherit stdenv binutils coreutils;
};
wrapGCC = wrapGCCWith (import ../build-support/gcc-wrapper) glibc;
@@ -3446,11 +3471,16 @@ let
#installLocales = false;
};
glibc29 = import ../development/libraries/glibc-2.9 {
glibc29 = makeOverridable (import ../development/libraries/glibc-2.9) {
inherit fetchurl stdenv kernelHeaders;
installLocales = getPkgConfig "glibc" "locales" false;
};
eglibc = import ../development/libraries/eglibc {
inherit fetchsvn stdenv kernelHeaders;
installLocales = getPkgConfig "glibc" "locales" false;
};
glibcLocales = makeOverridable (import ../development/libraries/glibc-2.9/locales.nix) {
inherit fetchurl stdenv;
};
@@ -3491,13 +3521,11 @@ let
gmp = import ../development/libraries/gmp {
inherit fetchurl stdenv m4;
cxx = false;
};
gmpxx = import ../development/libraries/gmp {
inherit fetchurl stdenv m4;
cxx = true;
};
# `gmpxx' used to mean "GMP with C++ bindings". Now `gmp' has C++ bindings
# by default, so that distinction is obsolete.
gmpxx = gmp;
goffice = import ../development/libraries/goffice {
inherit fetchurl stdenv pkgconfig libgsf libxml2 cairo
@@ -5550,13 +5578,14 @@ let
};
kernel_2_6_31 = makeOverridable (import ../os-specific/linux/kernel/linux-2.6.31.nix) {
inherit fetchurl stdenv perl mktemp module_init_tools;
inherit fetchurl stdenv perl mktemp module_init_tools platform;
kernelPatches = [];
};
kernel_2_6_31_zen5 = makeOverridable (import ../os-specific/linux/zen-kernel/2.6.31-zen5.nix) {
inherit fetchurl stdenv perl mktemp module_init_tools
lib builderDefs;
inherit platform;
};
kernel_2_6_31_zen5_bfs = kernel_2_6_31_zen5.override {
@@ -5860,7 +5889,7 @@ let
};
pam_unix2 = import ../os-specific/linux/pam_unix2 {
inherit stdenv fetchurl pam libxcrypt;
inherit stdenv fetchurl pam;
};
pcmciaUtils = composedArgsAndFun (import ../os-specific/linux/pcmciautils) {
@@ -5984,6 +6013,14 @@ let
inherit (xlibs) libX11 xproto;
};*/
uboot = import ../misc/uboot {
inherit fetchurl stdenv unzip;
};
uclibc = import ../os-specific/linux/uclibc {
inherit fetchurl stdenv kernelHeaders;
};
udev = makeOverridable (import ../os-specific/linux/udev) {
inherit fetchurl stdenv gperf pkgconfig acl libusb usbutils pciutils glib;
};