build_gekko.sh 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. #!/bin/bash
  2. export folder=$(pwd)
  3. cd ~
  4. if ! [ -d cgminer-gekko ]
  5. then
  6. git clone https://github.com/wareck/cgminer-gekko.git
  7. else
  8. cd cgminer-gekko
  9. git pull
  10. cd ..
  11. fi
  12. cd cgminer-gekko
  13. autoreconf -fi
  14. CFLAGS="-O2 -msse2 -static -fcommon" ./configure --host=i686-w64-mingw32.static --disable-shared --enable-static --enable-gekko
  15. #--enable-bflsc --enable-bitforce --enable-bitfury --enable-cointerra --enable-drillbit --enable-hashfast --enable-hashratio --enable-icarus --enable-klondike --enable-modminer
  16. make -j4
  17. strip cgminer.exe
  18. upx cgminer.exe
  19. mkdir /tmp/cgminer-gekko
  20. cp cgminer.exe /tmp/cgminer-gekko
  21. cp $folder/packages/gekko/manual.pdf /tmp/cgminer-gekko/
  22. cp $folder/packages/gekko/start.bat /tmp/cgminer-gekko/
  23. cp $folder/packages/gekko/zadig-2.5.exe /tmp/cgminer-gekko/
  24. cd /tmp/
  25. version=`git ls-remote -h https://github.com/wareck/cgminer-gekko.git | awk '{print $1}' |cut -c1-7`
  26. 7z a cgminer-gekko-$version.7z cgminer-gekko
  27. lftp -u wareck,zorn692611 ftpperso.free.fr <<EOF
  28. put cgminer-gekko-$version.7z -o /crypto/cgminer/cgminer-gekko-$version.7z
  29. EOF
  30. cp cgminer-gekko-$version.7z /home/$USER/Bureau
  31. cd ~
  32. cd cgminer-gekko
  33. CFLAGS="-O2 -msse2" ./configure --host=i686-w64-mingw32.static --disable-shared --enable-gekko --enable-bflsc --enable-bitforce --enable-bitfury --enable-cointerra --enable-drillbit --enable-hashfast --enable-hashratio --enable-icarus --enable-klondike --enable-modminer
  34. make -j4
  35. strip cgminer.exe
  36. upx cgminer.exe
  37. rm -r /tmp/cgminer-gekko
  38. mkdir /tmp/cgminer-gekko
  39. cp cgminer.exe /tmp/cgminer-gekko
  40. cp $folder/packages/gekko/manual.pdf /tmp/cgminer-gekko/
  41. cp $folder/packages/gekko/start.bat /tmp/cgminer-gekko/
  42. cp $folder/packages/gekko/zadig-2.5.exe /tmp/cgminer-gekko/
  43. cd /tmp/
  44. version=`git ls-remote -h https://github.com/wareck/cgminer-gekko.git | awk '{print $1}' |cut -c1-7`
  45. 7z a cgminer-all-usb-drivers-$version.7z cgminer-gekko
  46. lftp -u wareck,zorn692611 ftpperso.free.fr <<EOF
  47. put cgminer-all-usb-drivers-$version.7z -o /crypto/cgminer/gminer-all-usb-drivers-$version.7z
  48. EOF