make_environement.sh 1.1 KB

123456789101112131415161718192021
  1. #!/bin/bash
  2. sudo apt-get update
  3. sudo apt-get upgrade -y
  4. sudo apt-get install -y lzip build-essential git autoconf autopoint bison flex gperf libtool libtool-bin python ruby scons unzip intltool p7zip-full libgtk2.0-dev libssl-dev -y
  5. sudo apt-get install -y lftp zip pv pixz
  6. cd /opt
  7. sudo git clone https://github.com/mxe/mxe.git
  8. export MXE_DIR=/opt/mxe
  9. export MXE_TARGETS='i686-w64-mingw32.static'
  10. sudo make -j 4 -C $MXE_DIR MXE_TARGETS="$MXE_TARGETS" curl pthreads pdcurses ncurses libusb1
  11. export MXE_TARGETS='i686-w64-mingw32.shared'
  12. sudo make -j 4 -C $MXE_DIR MXE_TARGETS="$MXE_TARGETS" curl pthreads pdcurses ncurses libusb1 jansson libevent libmicrohttpd
  13. echo 'export PATH=/opt/mxe/usr/bin:$PATH' >> ~/.profile
  14. echo 'export PKG_CONFIG_PATH=/opt/mxe/usr/i686-w64-mingw32.static/lib/pkgconfig/' >> ~/.profile
  15. echo 'export PKG_CONFIG_PATH=/opt/mxe/usr/i686-w64-mingw32.shared/lib/pkgconfig/' >> ~/.profile
  16. export PATH=/opt/mxe/usr/bin:$PATH
  17. export PKG_CONFIG_PATH=/opt/mxe/usr/i686-w64-mingw32.static/lib/pkgconfig/
  18. export PKG_CONFIG_PATH=/opt/mxe/usr/i686-w64-mingw32.shared/lib/pkgconfig/
  19. cd ~
  20. echo "environement ok"