Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!

aircrack-ng-cuda-svn

By: mrbit on Oct 29th, 2012  |  syntax: Bash  |  size: 1.83 KB  |  views: 188  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1.  # Contributor: yannsen <ynnsen@gmail.com>
  2.     pkgname=aircrack-ng-cuda-svn
  3.     pkgver=1550
  4.     pkgrel=5
  5.     pkgdesc="Wifi security suite - WEP / WPA crack tools -- supports CUDA"
  6.     arch=('i686' 'x86_64')
  7.     url="http://www.aircrack-ng.org"
  8.     license=('GPL2')
  9.     depends=('openssl' 'wireless_tools' 'autoconf' 'libtool' 'cuda>=2.2' 'sqlite3')
  10.     makedepends=(subversion)
  11.     provides=(aircrack-ng)
  12.     conflicts=(aircrack-ng)
  13.     source=()
  14.     md5sums=()
  15.      
  16.     _svntrunk="http://trac.aircrack-ng.org/svn/branch/aircrack-ng-cuda/"
  17.     _svnmod=aircrack-ng-cuda
  18.      
  19.     build() {
  20.       cd $startdir/src
  21.       msg "Connecting to SVN server...."
  22.       if [ -d $_svnmod/.svn ]; then
  23.         (cd $_svnmod && svn up -r $pkgver)
  24.       else
  25.         svn co $_svntrunk --config-dir ./ -r $pkgver $_svnmod
  26.       fi
  27.      
  28.       msg "SVN checkout done or server timeout"
  29.       msg "Starting make..."
  30.      
  31.       if [ -d "${srcdir}/${_svnmod}-build" ]; then
  32.         rm -rf "${srcdir}/${_svnmod}-build"
  33.       fi
  34.      
  35.       svn export $_svnmod $_svnmod-build
  36.       cd $_svnmod-build
  37.      # setting the right location of nvcc
  38.   sed -i "s/#NVCCFLAGS/NVCCFLAGS/" src/Makefile || return 1
  39.      
  40.      if  test "$CARCH" == x86_64; then
  41.     sed -i "s|lib -lcuda -lcudart|opt/cuda/lib64 -lcuda -lcudart -lstdc++|" src/Makefile || return 1
  42.   else
  43.     sed -i "s|lib -lcuda -lcudart|opt/cuda/lib -lcuda -lcudart -lstdc++|" src/Makefile || return 1
  44.   fi
  45.  
  46.       sed -i s#/bin/nvcc#/opt/cuda/bin/nvcc#g src/Makefile || return 1
  47.       sed -i "s/--compiler-options -fno-strict-aliasing --host-compilation=C/--compiler-options -fno-strict-aliasing --host-compilation=C --compiler-options -fpermissive/" src/Makefile || return 1
  48.      
  49.       # BUILD
  50.       make prefix=/usr CUDA=true sqlite=true DESTDIR=$startdir/pkg/ install  || return 1
  51. }