Fixing the aircrack-ng build, so it doesn't depend on any profile

and points, as usual, only to the store for its dependencies.

svn path=/nixpkgs/trunk/; revision=13965
This commit is contained in:
Lluís Batlle i Rossell
2009-02-02 21:57:18 +00:00
parent db6973610c
commit 95f38fc409
3 changed files with 8 additions and 28 deletions

View File

@@ -1,17 +0,0 @@
diff --git a/src/osdep/linux.c b/src/osdep/linux.c
index 9f3b1ef..ba7e584 100644
--- a/src/osdep/linux.c
+++ b/src/osdep/linux.c
@@ -235,7 +235,11 @@ static char * wiToolsPath(const char * tool)
"/bin",
"/usr/bin",
"/usr/local/bin",
- "/tmp"
+ "/tmp",
+ "/var/run/current-system/sw/bin",
+ "/var/run/current-system/sw/sbin",
+ "/root/.nix-profile/bin",
+ "/root/.nix-profile/sbin"
};
nbelems = sizeof(paths) / sizeof(char *);

View File

@@ -1,4 +1,4 @@
{stdenv, fetchurl, libpcap, openssl, zlib}:
{stdenv, fetchurl, libpcap, openssl, zlib, wirelesstools}:
stdenv.mkDerivation {
name = "aircrack-ng-1.0-rc2";
@@ -10,9 +10,10 @@ stdenv.mkDerivation {
buildInputs = [libpcap openssl zlib];
patches = [ ./add-paths.patch ];
postPatch = "sed -e 's@^prefix.*@prefix = '$out@ -i common.mak";
patchPhase = ''
sed -e 's@^prefix.*@prefix = '$out@ -i common.mak
sed -e 's@/usr/local/bin@'${wirelesstools}@ -i src/osdep/linux.c
'';
meta = {
description = "Wireless encryption crackign tools";