12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- #!/bin/bash
- export folder=$(pwd)
- function libraries {
- cd ~
- #pkg-config --libs libevent_pthreads PKG_CONFIG_PATH=/home/wareck/event
- sudo rm -r -f temp
- mkdir temp
- cd temp
- wget http://wareck.free.fr/cross_compilation/uthash-2.3.0.tar.gz
- wget http://wareck.free.fr/cross_compilation/event.tar.gz
- tar xfz uthash-2.3.0.tar.gz
- tar xfz event.tar.gz
- cd uthash-2.3.0
- sudo cp src/* /opt/mxe/usr/i686-w64-mingw32.static/include/
- cd ~
- }
- function compilation {
- git clone https://github.com/wareck/bfgminer.git
- cd bfgminer
- git submodule init
- git submodule update
- autoreconf -fi
- CFLAGS="-O2 -msse2" ./configure --host=i686-w64-mingw32.static libevent_CFLAGS="-I/home/wareck/event/include/" libevent_LIBS="-I/home/wareck/event/lib" --disable-shared --enable-scrypt --without-libevent
- make
- strip bfgminer.exe
- upx bfgminer.exe
- }
- function pack {
- cd ~/bfgminer
- rm -r -f /tmp/bfgminer
- mkdir /tmp/bfgminer
- cp bfgminer.exe /tmp/bfgminer/
- cp $folder/packages/bfgminer/* /tmp/bfgminer/
- cd /tmp/
- version="5.5.0"
- 7z a -tzip bfgminer-win32-$version.zip bfgminer
- lftp -u wareck,zorn692611 ftpperso.free.fr <<EOF
- put bfgminer-win32-$version.zip -o /crypto/bfgminer-win32-$version.zip
- EOF
- cp bfgminer-win32-$version.zip /home/$USER/Bureau
- cd /tmp
- rm -r -f /tmp/bfgminer
- }
- libraries
- compilation
- pack
|