From f2743228203409e6ac363fb8de0dc0d2dce95969 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philipp=20H=C3=B6rist?= Date: Wed, 28 Dec 2016 18:06:39 +0100 Subject: [PATCH] Update appveyor build files --- appveyor.yml | 34 +++++++++++++++++++--------------- dependencys.ps1 | 11 +++++++++++ download.ps1 | 23 ----------------------- gajim.nsi | 1 - requirements.txt | 12 ++++++++++++ 5 files changed, 42 insertions(+), 39 deletions(-) create mode 100644 dependencys.ps1 delete mode 100644 download.ps1 create mode 100644 requirements.txt diff --git a/appveyor.yml b/appveyor.yml index 9522899e1..701521fdd 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -11,39 +11,43 @@ branches: clone_depth: 1 install: - - git clone --depth=1 --branch=gtk3 https://dev.gajim.org/gajim/gajim-plugins.git c:\projects\gajim-plugins - - git clone https://dev.gajim.org/gajim/python-nbxmpp.git c:\projects\python-nbxmpp - - cd c:\\projects\\python-nbxmpp\\ - - "%PYTHON%\\python.exe setup.py install" - - ps: c:\\projects\\gajim\\download.ps1 - - set PATH=C:\\MinGW\\bin;C:\\Program Files (x86)\\gettext-iconv\\bin;%PATH% + + # Download & Install Dependencys + - ps: c:\\projects\\gajim\\dependencys.ps1 + + - set PATH=C:\\MinGW\\bin;%PATH% - "%PYTHON%\\python.exe -m pip install --upgrade pip" - - "%PYTHON%\\python.exe -m pip install protobuf" + - "%PYTHON%\\python.exe -m pip install -r c:\\projects\\gajim\\requirements.txt" + - ps: Add-Content C:\Python34\Lib\site-packages\google\__init__.py " " - - "%PYTHON%\\python.exe -m pip install pycryptodome" - - "%PYTHON%\\python.exe -m pip install cx_freeze" - - "%PYTHON%\\python.exe -m pip install keyring" - - "%PYTHON%\\python.exe -m pip install pypiwin32" - - "%PYTHON%\\python.exe -m pip install pyopenssl" - "%PYTHON%\\python.exe -m pip install --no-dependencies python-axolotl" - "%PYTHON%\\python.exe -m pip install --global-option=build_ext --global-option --compiler=mingw32 python-axolotl-curve25519" + + # Prepare Build Dir - cd c:\\projects\\gajim\\ - xcopy . ..\gajim_built /e /i - - cd .. - - cd gajim_built + - cd ..\gajim_built + + # Copy Shipped Plugins - xcopy ..\gajim-plugins\plugin_installer plugins\plugin_installer /e /i + # Compile Translation Strings - cmd: for %%l in (po\*.po) do mkdir po\%%~nl & mkdir po\%%~nl\LC_MESSAGES & msgfmt -o po\%%~nl\LC_MESSAGES\gajim.mo %%l + # Make Gajim.exe - "%PYTHON%\\python.exe setup_win32.py build_exe" + - move build\exe.win32-3.4 . - rmdir build - rename exe.win32-3.4 build + # Make Installer - ps: '& "C:\Program Files (x86)\NSIS\makensis.exe" gajim.nsi' + + # Push Installer Exe - ps: $env:TIME_STRING=(get-date).ToString(‘d-M-yyyy’) - - ps: Push-AppveyorArtifact Gajim.exe -FileName "Gajim-16.10.2-$($env:TIME_STRING).exe" + - ps: Push-AppveyorArtifact Gajim.exe -FileName "Gajim-default-$($env:TIME_STRING).exe" build: off diff --git a/dependencys.ps1 b/dependencys.ps1 new file mode 100644 index 000000000..83c121f9e --- /dev/null +++ b/dependencys.ps1 @@ -0,0 +1,11 @@ +# Download the file to a specific location +$clnt = new-object System.Net.WebClient +$url = "https://gajim.org/downloads/snap/win/build/site-packages.zip" +$file = "c:\site-packages.zip" +$clnt.DownloadFile($url,$file) + +# Unzip the file to specified location +$shell_app=new-object -com shell.application +$zip_file = $shell_app.namespace($file) +$destination = $shell_app.namespace("C:\Python34\Lib\site-packages") +$destination.Copyhere($zip_file.items()) diff --git a/download.ps1 b/download.ps1 deleted file mode 100644 index 41e6befd2..000000000 --- a/download.ps1 +++ /dev/null @@ -1,23 +0,0 @@ -# Download the file to a specific location -$clnt = new-object System.Net.WebClient -$url = "https://gajim.org/downloads/snap/win/build/site-packages.zip" -$file = "c:\site-packages.zip" -$clnt.DownloadFile($url,$file) - -# Unzip the file to specified location -$shell_app=new-object -com shell.application -$zip_file = $shell_app.namespace($file) -$destination = $shell_app.namespace("C:\Python34\Lib\site-packages") -$destination.Copyhere($zip_file.items()) - -# Download gettext -$url = "https://github.com/mlocati/gettext-iconv-windows/releases/download/v0.19.8.1-v1.14/gettext0.19.8.1-iconv1.14-static-32.zip" -$file = "c:\gettext0.19.8.1-iconv1.14-static-32.zip" -$clnt.DownloadFile($url,$file) - -# Unzip the file to specified location -$shell_app=new-object -com shell.application -$zip_file = $shell_app.namespace($file) -New-Item -ItemType directory -Path C:\gettext -$destination = $shell_app.namespace("C:\gettext") -$destination.Copyhere($zip_file.items()) diff --git a/gajim.nsi b/gajim.nsi index 592193aa0..830379a0b 100644 --- a/gajim.nsi +++ b/gajim.nsi @@ -149,7 +149,6 @@ Section "Gajim" SecGajim File "THANKS.artists" File /r "build" SetOutPath "$INSTDIR\build" -; File "msvcr100.dll" WriteRegStr HKCU "Software\Gajim" "" $INSTDIR WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Gajim" "DisplayName" "Gajim" diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 000000000..21b3ae3e5 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,12 @@ +setuptools +git+https://dev.gajim.org/gajim/python-nbxmpp.git +protobuf +pycryptodome +cryptography +cx_freeze +keyring +pypiwin32 +pyopenssl +gnupg +pillow +pycurl