Commit 31f67d7f authored by Jeremy Bokobza's avatar Jeremy Bokobza Committed by GitHub

Merge pull request #177 from bokobza/master

Fix OS X build
parents 683fa278 dbabc700
......@@ -48,13 +48,14 @@ To skip a build, for example if you've made very minor changes, include the text
If you want the :sparkles: latest :sparkles: (unstable :bomb:) version of the Breeze app, you can get it here:
| | x86 Release | x64 Release |
|:---|----------------:|------------------:|
|**Windows 7**| [download][7] | [download][8] |
|**Windows 10**| [download][9] | [download][10] |
|**Ubuntu 14.04**| - | [download][11] |
|**OS X 10.11**| - | [download][12] |
|**OS X 10.12**| - | [download][13] |
| | x86 Release | x64 Release | Notes |
|:---|----------------:|------------------:|------------------:|
|**Windows 7**| [download][7] | [download][8] | continuous build - up to date with commits |
|**Windows 10**| [download][9] | [download][10] | continuous build - up to date with commits |
|**Ubuntu 14.04**| - | coming soon | manual build |
|**Ubuntu 16.04**| - | coming soon | manual build |
|**OS X 10.11**| - | [download][13] | continuous build - up to date with commits |
|**OS X 10.12**| - | [download][14] | continuous build - up to date with commits |
[7]: https://ci.appveyor.com/api/projects/stratis/breeze/artifacts/breeze_out/breeze-win7-x86-Release.zip?job=Environment%3A%20win_runtime%3Dwin7-x86
......@@ -62,7 +63,8 @@ If you want the :sparkles: latest :sparkles: (unstable :bomb:) version of the Br
[9]: https://ci.appveyor.com/api/projects/stratis/breeze/artifacts/breeze_out/breeze-win10-x86-Release.zip?job=Environment%3A%20win_runtime%3Dwin10-x86
[10]: https://ci.appveyor.com/api/projects/stratis/breeze/artifacts/breeze_out/breeze-win10-x64-Release.zip?job=Environment%3A%20win_runtime%3Dwin10-x64
[11]: https://github.com/stratisproject/Breeze/releases/download/cd-unstable/breeze-ubuntu.14.04-x64-Release.zip
[12]: https://github.com/stratisproject/Breeze/releases/download/cd-unstable/breeze-osx.10.11-x64-Release.zip
[13]: https://github.com/stratisproject/Breeze/releases/download/cd-unstable/breeze-osx.10.12-x64-Release.zip
[12]: https://github.com/stratisproject/Breeze/releases/download/cd-unstable/breeze-ubuntu.14.04-x64-Release.zip
[13]: https://github.com/stratisproject/Breeze/releases/download/cd-unstable/breeze-osx.10.11-x64-Release.zip
[14]: https://github.com/stratisproject/Breeze/releases/download/cd-unstable/breeze-osx.10.12-x64-Release.zip
......@@ -23,24 +23,31 @@ clone_folder: c:\projects\breeze
configuration:
# - Debug
- Release
build:
parallel: true
environment:
matrix:
- win_runtime: win7-x64
arch: x64
plat: win32
- win_runtime: win7-x86
arch: ia32
plat: win32
- win_runtime: win10-x64
arch: x64
plat: win32
- win_runtime: win10-x86
arch: ia32
plat: win32
hosts:
api.nuget.org: 93.184.221.200
init:
- ps: |
$env:log_prefix = "[$env:win_runtime][$env:configuration]"
if($env:win_runtime -ilike "*x86")
{
$env:arch = "ia32"
}
else
{
$env:arch = "x64"
}
$env:app_output_name = "breeze-$env:win_runtime-$env:configuration"
$env:api_output_name = "api-$env:win_runtime-$env:configuration"
......@@ -79,12 +86,13 @@ build_script:
Write-Host "$env:log_prefix running 'npm run'" -foregroundcolor "magenta"
npm run build:prod
Write-Host "$env:log_prefix packaging breeze" -foregroundcolor "magenta"
node package.js --platform=win32 --arch=$env:arch --path=$env:APPVEYOR_BUILD_FOLDER\breeze_out
node package.js --platform=$env:plat --arch=$env:arch --path=$env:APPVEYOR_BUILD_FOLDER\breeze_out
Write-Host "$env:log_prefix copying the Breeze api into the app" -foregroundcolor "magenta"
New-Item -Path $env:APPVEYOR_BUILD_FOLDER\breeze_out\breeze-ui-win32-$env:arch\resources\app\assets\daemon -ItemType directory
xcopy /s $env:APPVEYOR_BUILD_FOLDER\dotnet_out\$env:win_runtime\* $env:APPVEYOR_BUILD_FOLDER\breeze_out\breeze-ui-win32-$env:arch\resources\app\assets\daemon\
New-Item -Path $env:APPVEYOR_BUILD_FOLDER\breeze_out\breeze-ui-$env:plat-$env:arch\resources\app\assets\daemon -ItemType directory
xcopy /s $env:APPVEYOR_BUILD_FOLDER\dotnet_out\$env:win_runtime\* $env:APPVEYOR_BUILD_FOLDER\breeze_out\breeze-ui-$env:plat-$env:arch\resources\app\assets\daemon\
Write-Host "$env:log_prefix zipping the result" -foregroundcolor "magenta"
7z a $env:APPVEYOR_BUILD_FOLDER\breeze_out\$env:app_output_name.zip $env:APPVEYOR_BUILD_FOLDER\breeze_out\breeze-ui-win32-$env:arch
7z a $env:APPVEYOR_BUILD_FOLDER\breeze_out\$env:app_output_name.zip $env:APPVEYOR_BUILD_FOLDER\breeze_out\breeze-ui-$env:plat-$env:arch
Write-Host "[$env:configuration][$env:win_runtime] FINISHED dotnet build" -foregroundcolor "magenta"
if ($LastExitCode -ne 0) { $host.SetShouldExit($LastExitCode) }
......
......@@ -3,6 +3,13 @@
# exit if error
set -o errexit
if [ "$TRAVIS_OS_NAME" = "osx" ]
then
dotnet_resources_path_in_app=$TRAVIS_BUILD_DIR/breeze_out/breeze-ui-$os_platform-$arch/breeze-ui.app/contents/resources/app/assets/daemon
else
dotnet_resources_path_in_app=$TRAVIS_BUILD_DIR/breeze_out/breeze-ui-$os_platform-$arch/resources/app/assets/daemon
fi
# define a few variables
app_output_name="breeze-$os_identifier-$arch-$configuration"
api_output_name="api-$os_identifier-$arch-$configuration"
......@@ -17,6 +24,7 @@ echo "Architecture:" $arch
echo "Configuration:" $configuration
echo "App output name:" $app_output_name
echo "Api output name:" $api_output_name
echo "dotnet resources path in app:" $dotnet_resources_path_in_app
dotnet --info
......@@ -59,8 +67,8 @@ node package.js --platform=$os_platform --arch=$arch --path=$TRAVIS_BUILD_DIR/br
# copy api libs into app
echo $log_prefix copying the Breeze api into the app
mkdir -p $TRAVIS_BUILD_DIR/breeze_out/breeze-ui-$os_platform-$arch/resources/app/assets/daemon/
cp -r $TRAVIS_BUILD_DIR/dotnet_out/$TRAVIS_OS_NAME/* $TRAVIS_BUILD_DIR/breeze_out/breeze-ui-$os_platform-$arch/resources/app/assets/daemon/
mkdir -p $dotnet_resources_path_in_app
cp -r $TRAVIS_BUILD_DIR/dotnet_out/$TRAVIS_OS_NAME/* $dotnet_resources_path_in_app
# zip result
echo $log_prefix zipping the app into $TRAVIS_BUILD_DIR/breeze_out/$app_output_name.zip
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment