[Nix-dev] Custom libc
How can I override glibc in nix-shell and use eglibc, for instance? Are there any examples? Do I need to override stdenv for that? Overriding the attributes of glibc (version and sha) directly doesn't seem to work. Could anyone provide an example? ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] "IO" in Nix
Not to turn this into a flame war, but there were discussions in the past whether Nix should have been a DSL embedded in, say, Haskell. IIRC, you felt okay about it being a standalone DSL, do you still feel the same way? P.S. Yes, I know about Guix, but it's written in (a uni-typed) Scheme. ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Packaging software that mutates itself
On Fri, May 06, 2016 at 01:02:15AM +0300, Nikita Karetnikov wrote: > The server is controlled by other people. I'd like to add that I'm assuming that these people are not malicious. In this case, I'm more worried about a misconfigured package that might break my system in some way. ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Packaging software that mutates itself
I've talked a bit about this on IRC earlier today, but I think the issue deserves an in-depth discussion. It's more of a general policy question, a clash of an imperative world and a pure functional one. I'm trying to package a Java program, a client, which can be (among other things) updated by the server. At first, I put everything into the store, but then the client received an update command from the server and attempted to create a directory in the store (probably based on the program location), which failed. The program is proprietary, so I tried to find a way to change this behavior in the docs, but there doesn't seem to be any way to do it. And it wouldn't solve the issue anyway. The server is controlled by other people. Even if I find a way to solve this for this particular version, e.g., by putting some files into a mutable directory (more on this below), the new client version, which will be installed by the server, might contain other unexpected features, which might prevent the client from operating properly. Has anyone packaged something like this? What's a proper way to solve this without compromising the integrity of a system (think of potential security issues or just proper operation)? NixOS supports containers, but I haven't used them yet, can it be the answer? What would be an expected mutable location for something like this? There's, for instance, /var/lib as described in http://www.pathname.com/fhs/pub/fhs-2.3.html#VARLIBVARIABLESTATEINFORMATION, but I can't even use it since that requires sudo, which is a no go for a build script. I need to copy the files into a mutable directory at build time (I'm using the builder.sh way as described in the Nixpkgs manual). ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Dynamically changing authorized_keys to work with ssh-copy-id
On Wed, Apr 06, 2016 at 01:10:56AM +0300, Nikita Karetnikov wrote: > I've been told on IRC (by clever) that it's somehow possible with the fields > I'm > using, but (after re-reading 'man configuration.nix') I can't think of > a way to make it work. So what are my options? Perhaps there's a different > (Nix way) of handling this which I haven't considered. Okay, I've asked again, though, I yet have to try it. IIUC, the idea is to not set 'keyFiles' (and use 'keys' if needed), which should make sshd check '~/.ssh/authorized_keys'. ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Dynamically changing authorized_keys to work with ssh-copy-id
TL;DR: I'd like to change '~/.ssh/authorized_keys' via ssh-copy-id. The file gets changed, but the changes have no effect on the running system. In 'configuration.nix', I already have 'openssh.authorizedKeys.keys', so I've also tried pointing 'openssh.authorizedKeys.keyFiles' to '~/.ssh/authorized_keys'. The problem is that 'nixos-rebuild switch' creates a new file in the store containing the keys from both 'keys' and 'keyFiles', which is what sshd uses, so changes made by ssh-copy-id are not taken into account. The solutions I've seen so far, which I haven't tried since I consider them unacceptable: restart sshd in cron to make it pick the new keys or modify the store. I've been told on IRC (by clever) that it's somehow possible with the fields I'm using, but (after re-reading 'man configuration.nix') I can't think of a way to make it work. So what are my options? Perhaps there's a different (Nix way) of handling this which I haven't considered. ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Configuring vim with override
Wed, Mar 02, 2016 at 10:00:00AM +1100, Jookia wrote: > vim_configurable is used like this: > > myVim = pkgs.vim_configurable.merge { > features = "huge"; # one of tiny, small, normal, big or huge > gui = "gtk"; > cfg = { > pythonSupport = true; > python3Support = true; > multibyteSupport = true; > }; > flags = { > xim.enable = true; > }; > }; When I tried something similar today, rehash && vim --version didn't show +cscope. But then I decided (finally!) to check the hash of my current vim and the one that was built. They were different. Probably one of my previous attempts did work, but I failed to notice. So now the question is why the current vim package doesn't point to the right version. ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Configuring vim with override
I'd like to enable cscope and clipboard support in vim by editing only the configuration.nix file. If I understand the NixOS manual correctly, it should look like this: environment.systemPackages = [ (pkgs.emacs.override { gtk = pkgs.gtk3; }) ]; https://nixos.org/nixos/manual/index.html#sec-customising-packages So I've tried something similar: environment.systemPackages.pkgs = [ ... (vimNox.override { cscopeSupport = true; clipboardSupport = true; }) ... ] I use vimNox here since nox shows it as vim_configurable, which is defined like this: https://github.com/NixOS/nixpkgs/blob/e2f7744f80e444c3e7b8680854de31fdc5c81543/pkgs/applications/editors/vim/configurable.nix#L148 This doesn't work, however. I've also tried using vim, vimHugeX, vim_configurable with various solutions from GitHub: https://github.com/NixOS/nixpkgs/search?utf8=%E2%9C%93=override+filename%3Aconfiguration.nix+language%3Anix No luck, though. What's the right way? ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Haskell: Stackage and Nix
> Hi! I am also interested in handling Stackage packages with NixOS. I > personally think that NixOS itself does all the things Stackage do and > more. Unfortunately, I am to build several existing projects which use > Stackage and not Nix. > > Nikita, are you going to patch Stack with patchelf or construct a > chroot env instead? I haven't thought about it much. I needed it for the project I was working on, but now it's not a priority for me. FWIW, stack works okay-ish on NixOS. You just have to switch the compiler version to avoid running stack setup and install system libs with nix-env whenever stack build complains. I could probably join the effort, but I don't really know where to start since I have no deep knowledge of either project. ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] PSA: basic NixOS installer
I wrote a simple script for myself for installing on a UEFI machine. Maybe someone will find it useful: https://github.com/nkaretnikov/nixos-installer The main idea is to allow you to boot with a minimal config, so you could iterate on it, instead of dancing around with a flash drive in case you mistype something. Make sure to read the README. And let me know if there are any issues. ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Increase the size of /run/user/1000
I'm aware of boot.runSize, but it doesn't seem to affect /run/user/1000. What's the proper way to do it? signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Haskell: Stackage and Nix
Is there a way to build packages from Stackage? It'd be cool to have a separate namespace for that, so I could refer to a package as stackagePackages.something. That's the only relevant post I've found: http://article.gmane.org/gmane.linux.distributions.nixos/15724 But it seems to require a lot of work. For the record, I'm aware of Stack and trying it now, but it's also not pleasant because you have to manage non-Haskell libs yourself. signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] gold linker in shell.nix
Stdenv should put ld.gold on PATH, so then it can be used just as ld.gold is used, I guess. So, are you suggesting to just enable it system-wide? How can I do that? ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] gold linker in shell.nix
How do I link with gold in nix-shell? ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Haskell NG: multiple project usage
I added a new datatype to tasty-core, which I'd like to use in tasty-quickcheck. I generated two default.nix files as described here: http://stackoverflow.com/questions/27968909/how-to-get-cabal-and-nix-work-together And put this shell.nix file into the tasty-quickcheck directory: https://gist.github.com/nkaretnikov/ec2c1765b37b8db2324d After running nix-shell -I ~ --pure and cabal build in the same directory, tasty-quickcheck still can't find my datatype. What's wrong? ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Haskell NG: let's update the wiki
The current Haskell package set will be removed in a few weeks: https://github.com/NixOS/nixpkgs/pull/6670#issuecomment-77688859 So it'd be nice to prepare the wiki. I've added a new section and a useful snippet: https://nixos.org/wiki/Haskell#Haskell_NG I cannot just paste the other code I've found due to copyright-related issues, so it needs to be done by the authors. Please help! signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Permission error when installing mpd
If you have a moment, please record the error you're seeing when you just use mpd.enable = true, and then file a bug on github. https://github.com/NixOS/nixpkgs/issues/6470 signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Permission error when installing mpd
Looking at the source (nixos/modules/services/audio/mpd.nix), it looks like the mpd service is designed to run as the mpd user. If you are willing to go with that design, I guess you should not set services.mpd.dataDir, and make sure the mpd user has read access to your music directory. (It tries to create /home/nikita because that's where its dataDir is supposed to go.) I'm willing to go with anything. I've tried setting just mpd.enable = true; but it has a similar permission-related problem. Could anyone share the configuration that's known to work, so I could forget about it? signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Permission error when installing mpd
I've tried various options, but mpd always fails with a permission error. Here's one example: services.mpd.enable = true; services.mpd.dataDir = /home/nikita/dotfiles/mpd/.mpd; services.mpd.musicDirectory = /home/nikita/music; Both directories exist. $ journalctl -u mpd.service Feb 19 09:11:22 mu systemd[1]: Starting Music Player Daemon... Feb 19 09:11:22 mu systemd[1]: mpd.service: control process exited, code=exited status=1 Feb 19 09:11:22 mu systemd[1]: Failed to start Music Player Daemon. Feb 19 09:11:22 mu systemd[1]: Unit mpd.service entered failed state. Feb 19 09:11:22 mu systemd[1]: mpd.service failed. Feb 19 09:11:22 mu mpd-pre-start[15264]: mkdir: cannot create directory ‘/home/nikita’: Permission denied Why is it even trying to create /home/nikita? signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Automatically locking the screen with xautolock
How do I automatically lock the screen in NixOS? I've installed xautolock and slock. And tested sudo xautolock -time 1 -locker slock in the shell, which works fine. Can I make it work without sudo? It's a problem because these lines in configuration.nix: displayManager.sessionCommands = '' sudo xautolock -time 1 -locker slock ''; result in sudo: no tty present and no askpass program specified So it fails to start. signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Haskell: indexing all packages on Hackage with Hoogle
Just for what it's worth, I have in the past indexed everything, but it causes far too much noise in the search output. This is why the hoogle-local expression takes the approach of asking for a list of 'packages' to indicate what should be indexed. Well, it's certainly better than nothing. Is the setup process documented somewhere? signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Haskell: indexing all packages on Hackage with Hoogle
Has anyone tried that? Most of the guides suggest you to run the following command, which should download the necessary databases, but it fails for me. $ hoogle data all default hoogle: /nix/store/2qk57kvi2nfayicwg57wa20y0kvxcy0x-haskell-hoogle-ghc7.8.4-4.2.36-shared/share/x86_64-linux-ghc-7.8.4/hoogle-4.2.36/databases: changeWorkingDirectory: does not exist (No such file or directory) Also, I couldn't determine which packages will be indexed by briefly looking at the source. Does anyone know? signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Haskell: indexing all packages on Hackage with Hoogle
I often don't use hoogle, hack-nix can autotag sources you use for projects - that is always accurate. The usecase I have in mind is when I want to find out whether a certain thing exists on Hackage already or not. E.g., I need the Month data type; surely someone has already defined one, so I only need to find the right package. signature.asc Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Using a smartcard with GPG
Since NixOS is an unusual system, I’ve decided to ask here before talking to the GnuPG people. How can I access a smart card? 'pccardctl' (see https://github.com/NixOS/nixpkgs/pull/6172) detects it: $ /nix/store/dwibbrcls43c0bxkcj52qj6mi8xipd6a-pcmciautils-017/bin/pccardctl ls Socket 0 Bridge:[yenta_cardbus] (bus ID: :05:00.0) Socket 0 Device 0: [cm4040_cs] (bus ID: 0.0) $ /nix/store/dwibbrcls43c0bxkcj52qj6mi8xipd6a-pcmciautils-017/bin/pccardctl status Socket 0: 5.0V 16-bit PC Card Subdevice 0 (function 0) bound to driver cm4040_cs $ /nix/store/dwibbrcls43c0bxkcj52qj6mi8xipd6a-pcmciautils-017/bin/pccardctl ident Socket 0: product info: OMNIKEY, CardMan 4040, , manfid: 0x0223, 0x0200 I've tried adding the following lines to 'configuration.nix' as suggested in https://bugs.launchpad.net/ubuntu/+source/gnupg/+bug/107337, but it doesn't make a difference: services.udev.extraRules = '' SUBSYSTEM==cardman_4040, GROUP=scard, MODE=0660 ''; users.extraGroups = { sdcard = { }; }; users.extraGroups.sdcard.members = [ nikita ]; After switching to the new config and rebooting: $ ls -l /dev/cmx0 crw-rw 1 root root 248, 0 Feb 5 16:45 /dev/cmx0 $ gpg2 --card-edit scdaemon[2242]: error sending PC/SC OPEN request: Broken pipe scdaemon[2242]: error sending PC/SC OPEN request: Broken pipe gpg: selecting openpgp failed: Card error gpg: OpenPGP card not available: Card error With ‘sudo’: $ sudo gpg2 --card-status gpg: selecting openpgp failed: Card not present gpg: OpenPGP card not available: Card not present pgpG11_Vw2oIi.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Haskell: Using Nix with cabal.config
I’d like to build an application using the versions specified in a cabal.config file (cabal-install is included in the shell.nix file). Is there an easy way to do it? After talking to people on #nixos, I got the impression that having your own Nixpkgs branch is the only way if you want to share your environment with NixOS and plain Nix users. Parsing a cabal.config file and running cabal2nix on every package is not difficult. But where do I need to put the new recipes? For packages with the default.nix file, you just compare the versions and replace the existing recipe if they don’t match. For packages having multiple versions, you also need to change pkgs/top-level/haskell-packages.nix. The latter makes me a bit uncomfortable because it’s easy to make a mistake. I’d rather put all the new recipes in a different place, say, in the directory of my application, and somehow instruct Nix to use them first. Can it be done? Or is there a better way? pgplGiIqICpyB.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] environment.allowedLicenses ?
I actually think we should *remove* meta.license entirely (because it doesn't provide useful info to users and tends to be wrong or incomplete anyway), and replace it with attributes that have operational meaning: People who do care about the exact license of a package should use a tool like Ninka do extract the actual license, rather than depend on meta.license (since, as I said, it tends to be incomplete or wrong). How do the attributes solve this issue? One can specify an incorrect attribute, no? I don’t see a problem. If a Nix package specifies a wrong license, fix it. If you use a tool like cabal2nix and the problem is upstream, then send a patch upstream. I did this for yesod-markdown, no big deal. pgpnVvU4QOK2j.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Encrypted root: LUKS over LVM
# Do not modify this file! It was generated by ‘nixos-generate-config’ # and may be overwritten by future invocations. Please make changes # to /etc/nixos/configuration.nix instead. { config, pkgs, ... }: { imports = [ nixpkgs/nixos/modules/installer/scan/not-detected.nix ]; boot.initrd.availableKernelModules = [ uhci_hcd ehci_pci ata_piix ahci firewire_ohci usb_storage ]; boot.kernelModules = [ kvm-intel ]; boot.extraModulePackages = [ ]; fileSystems./ = { device = /dev/disk/by-uuid/UUID; # removed fsType = ext3; }; swapDevices = [ ]; nix.maxJobs = 2; } pgpiREbefpyWz.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Encrypted root: LUKS over LVM
That's odd. Do you have any idea why e2fsck is failing? Nope. What happens if you run e2fsck -n /dev/main/main after booting? # e2fsck -n /dev/main/main e2fsck 1.42.12 (29-Aug-2014) Warning! /dev/main/main is mounted. Warning: skipping journal recovery because doing a read-only filesystem check. /dev/main/main: clean, 73550/7577600 files, 862949/30286848 blocks pgpBd5eNWxdKu.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Encrypted root: LUKS over LVM
Yes, as James says, you should really mount /mnt first. Mounting /mnt after /mnt/boot means that /mnt/boot is seen empty. Thanks, this made it work. After changing “/dev/mapper/main” to “/dev/main/main” in the config file, I was able to boot. But now the following message appears during the boot process: /dev/main/main is mounted. e2fsck: Cannot continue, aborting. fsck on /dev/main/main failed. The workaround is to press ‘*’ twice, which allows it to boot, but there ought to be a better way. Ideas? pgpIhcPXdJzy9.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Encrypted root: LUKS over LVM
I forgot to say that adding ‘noCheck = true;’ doesn’t seem to work. pgpUuN3EzDKAd.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Encrypted root: LUKS over LVM
I’m trying to configure NixOS with LUKS over LVM as described in [1]. After partitioning the disk (see ‘partition-table.sfdisk’), I did the following: # mkfs.ext3 /dev/sda1 # cryptsetup luksFormat -i 5000 /dev/sda2 # cryptsetup luksOpen /dev/sda2 main # pvcreate /dev/mapper/main # vgcreate main /dev/mapper/main # lvcreate -n main --extent=100%FREE main # mkfs.ext3 /dev/main/main # mkdir /mnt/boot # mount /dev/sda1 /mnt/boot # mount /dev/main/main /mnt # nixos-generate-config --root /mnt Then I edited ‘configuration.nix’ (attached) according to the wiki page and ran ‘nixos-install’, which failed (see ‘nixos-install.log’). Is anything wrong with the config file? [1] https://nixos.org/wiki/Encrypted_Root_on_NixOS # partition table of /dev/sda unit: sectors /dev/sda1 : start= 2048, size= 260096, Id=83 /dev/sda2 : start= 262144, size=242305024, Id=83 /dev/sda3 : start=0, size=0, Id= 0 /dev/sda4 : start=0, size=0, Id= 0 # Edit this configuration file to define what should be installed on # your system. Help is available in the configuration.nix(5) man page # and in the NixOS manual (accessible by running ‘nixos-help’). { config, pkgs, ... }: { imports = [ # Include the results of the hardware scan. ./hardware-configuration.nix ]; # Use the GRUB 2 boot loader. boot.loader.grub.enable = true; boot.loader.grub.version = 2; # Define on which hard drive you want to install Grub. boot.loader.grub.device = /dev/sda; boot.initrd.luks.devices = [ { name = main; device = /dev/sda2; preLVM = true; } ]; fileSystems = [ { mountPoint =/; device = /dev/mapper/main; } { mountPoint = /boot; device = /dev/sda1; } ]; networking.hostName = hostname; # Define your hostname. # networking.wireless.enable = true; # Enables wireless. # Select internationalisation properties. i18n = { consoleFont = Lat2-Terminus; consoleKeyMap = us; defaultLocale = en_US.UTF-8; }; # List packages installed in system profile. To search by name, run: # $ nix-env -qaP | grep wget # environment.systemPackages = with pkgs; [ # wget # ]; # List services that you want to enable: # Enable the OpenSSH daemon. # services.openssh.enable = true; # Enable CUPS to print documents. # services.printing.enable = true; # Enable the X11 windowing system. services.xserver.enable = true; services.xserver.layout = us; services.xserver.xkbOptions = eurosign:e; # Enable the KDE Desktop Environment. # services.xserver.displayManager.kdm.enable = true; # services.xserver.desktopManager.kde4.enable = true; # Define a user account. Don't forget to set a password with ‘passwd’. users.extraUsers.guest = { name = user; isNormalUser = true; uid = 1000; }; } building the system configuration... copying NixOS/Nixpkgs sources... finalising the installation... updating GRUB 2 menu... installing the GRUB 2 boot loader on /dev/sda... Installing for i386-pc platform. You have a memory leak (not released memory pool): [0x1a78c30] dtree [0x1a78ed0] dtree Internal error: Unreleased memory pool(s) found. You have a memory leak (not released memory pool): [0x1a78c30] dtree [0x1a78ed0] dtree Internal error: Unreleased memory pool(s) found. You have a memory leak (not released memory pool): [0x1a78c30] dtree [0x1a78ed0] dtree Internal error: Unreleased memory pool(s) found. You have a memory leak (not released memory pool): [0x1a78c30] dtree [0x1a78ed0] dtree Internal error: Unreleased memory pool(s) found. You have a memory leak (not released memory pool): [0x1a78c30] dtree [0x1a78ed0] dtree Internal error: Unreleased memory pool(s) found. You have a memory leak (not released memory pool): [0x1a78c30] dtree [0x1a78ed0] dtree Internal error: Unreleased memory pool(s) found. You have a memory leak (not released memory pool): [0x1a7a410] dtree [0x1a78d90] dtree Internal error: Unreleased memory pool(s) found. You have a memory leak (not released memory pool): [0x1a7a410] dtree [0x1a78d90] dtree Internal error: Unreleased memory pool(s) found. You have a memory leak (not released memory pool): [0x1a7a410] dtree [0x1a78d90] dtree Internal error: Unreleased memory pool(s) found. /nix/store/75vh8l1fkh27mm4hyjs3j3l24qgbrs4s-grub-2.02-git-1de3a4/sbin/grub-install: error: attempt to install to encrypted disk without cryptodisk enabled. Set `GRUB_ENABLE_CRYPTODISK=y' in file `/nix/store/75vh8l1fkh27mm4hyjs3j3l24qgbrs4s-grub-2.02-git-1de3a4/etc/default/grub'.. /nix/store/w7rgpbyqfcz0xfjhmcn05sp6zig8gx8w-install-grub.pl: installation of GRUB on /dev/sda failed pgpxzOw7oblwv.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] Making a custom installation tarball
I’d like to make an installation tarball with a custom set of packages. I’ve been pointed to [1], which is a Hydra job. Is it possible without Hydra? Could anyone explain in detail what I need to do? (It’d be great to create a wiki page for this.) [1] https://github.com/NixOS/nixpkgs/blob/master/pkgs/top-level/make-tarball.nix ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Package archeology in nixpkgs
- NHC: can build it with HBC According to [1], it can be bootstrapped via C. If I remember correctly, I successfully built it this way in the past (outside of NixOS). How do people feel about this? I think it’s a great idea. I always wanted to try HBI, which “supports the full language at the command line.” [2] But I have no idea where to get the source. [1] http://www.haskell.org/nhc98/download.html [2] http://stackoverflow.com/questions/4084790/compilers-for-haskell/5918876 pgp_aVy7aiE0O.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Using several versions of GHC at once
I have committed a patch recently that fix building of cabal-install with older GHC versions. Maybe that changes makes a difference. If you have the chance, please try installing that package again with a recent version of Nixpkgs. It works, but I've tried too many things at the same time. So it's hard to tell what solved the problem. Anyway, thank you so much. I have another question. How does 'nix-env -i' determine which version of a package it should install? For example, there are two versions of the binary package in 'pkgs/development/libraries/haskell/binary': 0.6.0.0 and 0.7.1.0. However, nix-env -f /home/nixpkgs-github/default.nix \ -p ~/ghc-6.10.4 -iA pkgs.haskellPackages_ghc6104.binary installs 0.6.0.0, not the latest. Is it connected with compatibility issues? If so, how does this selection process work? Can I safely assume that the following versions are the latest that should work with GHC 6.10.4? - binary-0.6.0.0 - HUnit-1.2.0.3 - network-2.2.1.4 - stm-2.1.1.2 - mtl-1.1.0.2 - time-1.1.2.4 pgpGfB2dEN0SM.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Using several versions of GHC at once
Priorities can be assigned in the sources. Could you show an example? It seems these files [1,2] don't have any. [1] https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/libraries/haskell/binary/0.6.0.0.nix [2] https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/compilers/ghc/6.10.1.nix pgpbuoiIHtV20.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Using several versions of GHC at once
The way to go is to create a separate profile for every version of GHC that you want to use like so: $ nix-env -p ~/ghc-6.10.4 -iA nixpkgs.haskellPackages_ghc6104.ghc $ nix-env -p ~/ghc-7.6.3 -iA nixpkgs.haskellPackages_ghc762.ghc Now, you can add both of those profiles into your command search path: export PATH=$HOME/ghc-7.6.3/bin:$HOME/ghc-6.10.4/bin:$PATH Unversioned commands like ghc will refer to GHC 7.6.3. If you want to run an older version of GHC, then you'll have to invoke it explicitly as ghc-6.10.4. Thanks, it worked. Can I add the above to Nix Wiki? By the way, maybe it's the right time to choose a license [1]. [1] http://nixos.org/wiki/Nix_Wiki:Copyrights pgpWIY6Ayn8l8.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] mips64el: syntax error in 'replace-dependency.nix'
Are you doing chroot builds? No, '/etc/nix/nix.conf' is empty. Also, the following errors appeared after that error. [root@nixos:/]# ls sh: /run/current-system/sw/bin/ls: No such file or directory [root@nixos:/]# cd [root@nixos:~]# whoami sh: /run/current-system/sw/bin/whoami: No such file or directory ('cd' works.) I doubt that a different '/bin/sh' will help. This tarball worked in the past. Nikita pgpN4hOTmkmY1.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] mips64el: syntax error in 'replace-dependency.nix'
Hi, I'm trying to install NixOS in a chroot. I'm using a tarball (nixos-system-mips64el-linux.tar.xz) that I fetched several month ago. So, the problem is the following error message. # nix-env -i hello error: syntax error, unexpected $undefined, expecting '}', at `/nix/store/pax21mr1bmd7m7zlghb77hrsj3ay9jii-nixos-0.1pre4033_e844fed-96a834d/nixos/nixpkgs/pkgs/build-support/replace-dependency.nix:20:11' (use `--show-trace' to show detailed location information) Here is a line that raises the error: { drv, old-dependency, new-dependency }: When I was using this tarball in the past, it worked fine. Is there a new tarball? Nikita pgppvmyBl2PTf.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] [***SPAM***] HYDRA_DISALLOW_UNFREE=1 allows to install the Linux kernel from kernel.org
Hi, I've been told some time ago that it's possible to use NixOS without non-free packages if I run 'export HYDRA_DISALLOW_UNFREE=1'. Unfortunately, it allows to use a non-free version of the Linux kernel. Yes, I can change the corresponding recipe. But can this be done automatically? Also, are there any other non-free packages that can sneak in? Nikita P.S. The best solution would be to remove all non-free packages from the repos, but I understand that you won't agree. pgp0yNaunaup2.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] mips64el: syntax error in 'replace-dependency.nix'
The problem is not with the tarball per se, it's with nixpkgs. To fix the issue, you can either update your nix version to at least nix 1.2, or wait until https://github.com/NixOS/nixpkgs/commit/ 5626c5cdfb6de664881eb8b79dd54a8f4ca19b8f hits the nixpkgs channel so it will still work with older versions of nix. How should I update Nix? Will it work if I install it from sources? Is it necessary to use any special options with './configure'? Anyway, I'd like to know where I can download the tarball. I haven't found it here [1]. Nikita [1] http://hydra.nixos.org/project/nixos pgpAdGcFmnQOu.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
[Nix-dev] [***SPAM***] Re: HYDRA_DISALLOW_UNFREE=1 allows to install the Linux kernel from kernel.org
HYDRA_DISALLOW_UNFREE was designed for our buildfarm, where unfree means not legally distributable. Since the kernel is legal to distribute despite the binary firmware blobs (I assume that's your objection?), HYDRA_DISALLOW_UNFREE will block it. Linux, the kernel developed and distributed by Linus Torvalds et al, contains non-Free Software, i.e., software that does not respect your essential freedoms, and it induces you to install additional non-Free Software that it doesn't contain. [1] In general, there's no automatic way to detect what is free and what is not, especially considering people's different definitions. HYDRA_DISALLOW_UNFREE depends on packagers specifying the license when they add an unfree package. If someone were to take the time to add meta attributes to each package that is free by their standards (or to every one that is not), it would be pretty easy to then provide a way for them to ensure their system only has those packages, but that initial work is not trivial. You're right. I forgot to define the word free. Here is a definition [2] that I had in mind. Yes, it's not trivial, but still possible. There is a list of free distros [3]. Nikita [1] http://www.fsfla.org/ikiwiki/selibre/linux-libre/ [2] https://gnu.org/philosophy/free-sw.html [3] https://gnu.org/distros/free-distros.html pgpdWbE6yPdMI.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] mips64el: syntax error in 'replace-dependency.nix'
I built it and Nikita picked it thanks to OOB conversations :) The same way I distributed arm system tarballs on request. Ah, right. I forgot about that. Thanks. Nikita pgpWWuh4NDU9P.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] mips64el: syntax error in 'replace-dependency.nix'
I believe that if you do 'nix-env -iA nix' (note the 'A'), you'll be able to install the newer nix without hitting the issue in replace-dependency. # nix-env -iA nix error: attribute `nix' in selection path `nix' not found I've found a workaround here [1], but it didn't help. Do you have any other ideas? I have some Nix-related binaries in '/usr/local/bin' in a different chroot. Can I somehow reuse those? Nikita [1] http://nixos.org/irc/logs/log.20120311 pgpmTMKIe_ndU.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] mips64el: syntax error in 'replace-dependency.nix'
Ah, right, you'll need something like nix-env -iA nixos.nixpkgs.nix. If that path doesn't work (that's for the nixos channel, you may need something different), look for a directory named nixpkgs in ~/.nix-defexpr (or its subdirectories), and do nix-env -iA nix -f ~/.nix-defexpr/path/to/nixpkgs Thanks, the latter did the job. Nikita pgp4zb3rFoyAI.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] mips64el: syntax error in 'replace-dependency.nix'
Thanks, the latter did the job. Oh, it failed. [...] glibc-ports-2.13/sysdeps/z8000/mul_1.s glibc-ports-2.13/sysdeps/z8000/sub_n.s configure flags: --disable-static --prefix=/nix/store/zcfiac107h1nji9sdiv2m1dzpvvagrh5-glibc-2.13 -C --enable-add-ons --sysconfdir=/etc --localedir=/var/run/current-system/sw/lib/locale --with-headers=/nix/store/lk00b5xr85ahkjzvs3lw9wi1dzwc4q9a-linux-headers-2.6.35.14/include --disable-profile /nix/store/vv7mwqlqllys5sz231j47b71yaypdz3l-stdenv-linux-boot/setup: /tmp/nix-build-2wwhdpp5zkrj6a38va3xixm2yan1hrq6-glibc-2.13.drv-0/build/../glibc-2.13/configure: /bin/sh: bad interpreter: No such file or directory builder for `/nix/store/2wwhdpp5zkrj6a38va3xixm2yan1hrq6-glibc-2.13.drv' failed with exit code 126 cannot build derivation `/nix/store/c70lpv849qj3kngpcfzhkphg07xsj7bf-perl-5.14.2.drv': 1 dependencies couldn't be built cannot build derivation `/nix/store/pwq1czxhg9rlpchraqy5mki0v9xlszis-nix-1.3.drv': 1 dependencies couldn't be built error: build of `/nix/store/pwq1czxhg9rlpchraqy5mki0v9xlszis-nix-1.3.drv' failed Nikita pgpA0ZMFC_Yvj.pgp Description: PGP signature ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev