Skip to content
This repository was archived by the owner on Feb 4, 2020. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,3 +85,41 @@ test_script:
& codecov --no-color -X gcov -F integrationtests -e PYTHON_INSTALL

if ($testsExitCode -ne 0) {exit $testsExitCode}

on_success:
# Creates executable with PyInstaller
- pip install pyinstaller
- pyinstaller clcache.py
- for /F %%i in ('python -c "import clcache; print(clcache.VERSION)"') do set CLCACHE_VERSION=%%i
- "echo Version: %CLCACHE_VERSION"
- move dist\clcache clcache-%CLCACHE_VERSION%

# Build the Chocolatey package
- sed -i "s/{VERSION}/%CLCACHE_VERSION%/g" clcache.nuspec
- choco pack

# Test the compiled extension
- cd clcache-%CLCACHE_VERSION%
- clcache.exe --help
- clcache.exe -s
- cd ..

# Test the chocolatey package
- ps: ls clcache.${env:CLCACHE_VERSION}.nupkg
- choco install "clcache.%CLCACHE_VERSION%.nupkg" --version=%CLCACHE_VERSION%
- C:\ProgramData\chocolatey\bin\clcache.exe --help
- C:\ProgramData\chocolatey\bin\clcache.exe -s

# Publish artifacts
- cd clcache-%CLCACHE_VERSION%
- 7z a -y clcache-%CLCACHE_VERSION%.zip
- move clcache-%CLCACHE_VERSION%.zip ..
- cd ..
- echo PYTHON_INSTALL=%PYTHON_INSTALL%
# Disable for Python 3.5, because of PyInstaller problems on older Windows
- if not [%PYTHON_INSTALL%]==["C:\Python35"] set PUBLISH=1
- sha256sum clcache.%CLCACHE_VERSION%.nupkg clcache-%CLCACHE_VERSION%.zip
- sha256sum clcache.%CLCACHE_VERSION%.nupkg clcache-%CLCACHE_VERSION%.zip > SHA256SUM
- if "%PUBLISH%"=="1" appveyor PushArtifact clcache.%CLCACHE_VERSION%.nupkg
- if "%PUBLISH%"=="1" appveyor PushArtifact clcache-%CLCACHE_VERSION%.zip
- if "%PUBLISH%"=="1" appveyor PushArtifact SHA256SUM
32 changes: 32 additions & 0 deletions clcache.nuspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Do not remove this test for UTF-8: if �O� doesn�t appear as greek uppercase omega letter enclosed in quotation marks, you should use an editor that supports UTF-8, not this one. -->
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd">
<metadata>
<id>clcache</id>
<title>clcache</title>
<version>{VERSION}</version>
<authors>Frerich Raabe</authors>
<owners>frerich,tadeu</owners> <!-- also known as package mantainers -->
<summary>Compiler cache for Microsoft Visual Studio</summary>
<description>
A little Python script which attempts to avoid unnecessary recompilation by reusing previously cached object files if possible. It is meant to be called instead of the original 'cl.exe' executable. The script analyses the command line to decide whether source code is to be compiled. If so, a cache will be queried for a previously stored object file.

This package contains an executable generated by `pyinstaller`, and is meant to facilitate the usage of `clcache.py` in a portable way. It is specially useful when needing to use `clcache.py` in environments with Python 2, since newer versions of `clcache.py` supports only Python 3.3+.
</description>
<projectUrl>https://github.com/frerich/clcache</projectUrl>
<packageSourceUrl>https://github.com/frerich/clcache</packageSourceUrl>
<projectSourceUrl>https://github.com/frerich/clcache</projectSourceUrl>
<tags>clcache clcache.py ccache compiler</tags>
<copyright>
Copyright (c)
2010, 2011, 2012, 2013, 2016 froglogic GmbH
2016 Simon Warta (Kullo GmbH)
2016 Tim Blechmann
</copyright>
<licenseUrl>https://github.com/frerich/clcache/blob/master/LICENSE</licenseUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
</metadata>
<files>
<file src="clcache-{VERSION}\**" target="clcache-{VERSION}" />
</files>
</package>