1
1
mirror of https://github.com/harelba/q.git synced 2024-10-03 22:39:52 +03:00
q/create-windows-setup-instructions

77 lines
1.9 KiB
Plaintext

# Alpha version - process is working, instructions not fully tested for minor details yet.
Instructions for creating a windows package for q:
The installation is based on a wine docker container.
mkdir -p dist/windows
pushd dist/windows
fetch all files from https://github.com/harelba/packages-for-q/tree/master/artifactory-for-packaging into that folder.
tar xvzf PyInstaller-2.1.tar.gz
Fix pyinstaller to work around a bug by running the following command (use gsed for osx or sed for linux):
gsed -i '1587s/^.*$/ if tpl[2] in ["BINARY", "DATA"]:/' ./PyInstaller-2.1/PyInstaller/build.py
popd
d=`pwd`
cid1=`docker run -d -v ${d}:/q -e VNC_PASSWORD=newPW -p 5900:5900 suchja/x11server`
cid2=`docker run -d --rm -i --link ${cid1}:xserver --volumes-from ${cid1} suchja/wine:latest /bin/bash`
sleep 1
function kill_container {
tmp=`docker kill ${cid1} ${cid2}`
}
trap kill_container EXIT
docker exec -it ${cid2} /bin/bash
inside the docker container prompt:
export DISPLAY=xserver:0
wine wineboot --init
cd ~/.wine/dosdevices/
ln -s /q "q:"
wine msiexec /i q:\\dist\\windows\\python-2.7.13.msi /q
wine q:\\dist\\windows\\pywin32-219.win32-py2.7.exe
mkdir ~/.wine/drive_c/q-build-environment
cp -r /q/dist/windows/PyInstaller-2.1 ~/.wine/drive_c/q-build-environment/
cd /q/dist
wine q:\\dist\\windows\\nsis-2.46-setup.exe - install to c:\q-build-environment\nsis
wine c:\\python27\\python.exe c:\\q-build-environment\\PyInstaller-2.1\\pyinstaller.py -F --distpath=win_output --workpath=win_build q:\\bin\\q
### Don't forget to change the version in the command below:
wine c:\\q-build-environment\\nsis\\makensis.exe -DVERSION=1.6.2.0 q:\\dist\\q-TextAsData-with-path.nsi
run the installation file and check that the install works properly:
wine setup.exe
move the installation to the packages folder:
mv /q/dist/setup.exe /q/packages/setup-q-<version>.exe
exit from the docker container