gem/oq-builders

Make the installer creation fully-automatic

Closed this issue · 2 comments

  • Setup a WINE prefix
  • Install NSIS
  • Clone this repo
  • Get requirements from OQ FTP
  • Download and extract Python msi
  • Install MinGW + GCC
  • Clone oq-*
  • Run python setup build --compiler=mingw32 and copy data from the build folders
  • Create the packages with NSIS
  • Run the installation in a clean WINE prefix

A skeleton:

export WINEPREFIX="$HOME/Wine/oqwin"

cd oq-hazardlib/
rm -Rf build/
wine python setup.py build --compiler=mingw32
cp -R build/lib.win32-2.7/openquake oq-installers/windows/nsis-installer/lib/
cp -R build/temp.win32-2.7/Release/speedups/* oq-installers/windows/nsis-installer/lib/openquake/hazardlib/geo/

cd oq-engine
rm -Rf build/
wine python setup.py build
cp -R build/lib/openquake/* oq-installers/windows/nsis-installer/lib/openquake/

cp oq-engine/openquake.cfg oq-installers/windows/nsis-installer/
cp oq-engine/README.md oq-installers/windows/nsis-installer/README.txt
unix2dos README.txt 

cp -R oq-engine/demos/* oq-installers/windows/nsis-installer/demos/
cd hazard/
for i in *; do zip -r $i.zip $i; done
cd risk/
for i in *; do zip -r $i.zip $i; done

wine $WINEPREFIX/drive_c/Program\ Files/NSIS/makensis.exe installer.nsi

Superseded.