[Nix-dev] /bin in chroot builds

Anders F Björklund afb at algonet.se
Wed Apr 21 12:58:14 CEST 2010


Sander van der Burg wrote:

> On {Free,Open,Net,...}BSD similar problems arise, since /bin/sh is  
> not bash either. I fixed this by manually symlinking /bin/sh to  
> bash on BSD, but ideally we should do this differently.

Yeah, I also noticed that nixpkgs stdenv assumes that /bin/bash  
exists...

shell = "/bin/bash";

I modified that to use the (impure) version of bash (installed from  
ports):

shell = if system == "i686-freebsd" || system == "x86_64-freebsd"  
then "/usr/local/bin/bash" else "/bin/bash";


And installation of aterm broke in a similar fashion, but the simplest
workaround was to call "bash ./configure" rather than just ./configure:

	 @${REINPLACE_CMD} -e 's|\./configure|bash ./configure|' \
		${WRKSRC}/externals/Makefile


It's a bashist world.

--anders




More information about the nix-dev mailing list