Ensure GitLab CI does clean builds.
This commit is contained in:
parent
835acf45eb
commit
e4e2aaad95
@ -6,9 +6,10 @@ build_project:
|
|||||||
stage: build
|
stage: build
|
||||||
script:
|
script:
|
||||||
- "( brew bundle )"
|
- "( brew bundle )"
|
||||||
- "( ./lib/bin/build_libsodium-macos )"
|
- "( ./lib/bin/build_libsodium-macos clean && ./lib/bin/build_libsodium-macos )"
|
||||||
|
- "( ./lib/bin/build_libjson-c-macos clean && ./lib/bin/build_libjson-c-macos )"
|
||||||
- "( cd ./platform-independent/c/cli && ./clean && targets=all ./build && ./mpw-tests && ./mpw-cli-tests )"
|
- "( cd ./platform-independent/c/cli && ./clean && targets=all ./build && ./mpw-tests && ./mpw-cli-tests )"
|
||||||
- "( cd ./gradle && ./gradlew --info clean test )"
|
- "( cd ./gradle && ./gradlew --stacktrace clean test )"
|
||||||
- "( xcodebuild -workspace platform-darwin/MasterPassword.xcworkspace -configuration 'Test' -scheme 'MasterPassword iOS' -sdk iphonesimulator clean build )"
|
- "( xcodebuild -workspace platform-darwin/MasterPassword.xcworkspace -configuration 'Test' -scheme 'MasterPassword iOS' -sdk iphonesimulator clean build )"
|
||||||
- "( xcodebuild -workspace platform-darwin/MasterPassword.xcworkspace -configuration 'Test' -scheme 'MasterPassword macOS' clean build )"
|
- "( xcodebuild -workspace platform-darwin/MasterPassword.xcworkspace -configuration 'Test' -scheme 'MasterPassword macOS' clean build )"
|
||||||
tags:
|
tags:
|
||||||
|
@ -1,29 +1,27 @@
|
|||||||
rootProject.name = 'masterpassword'
|
rootProject.name = 'masterpassword'
|
||||||
|
|
||||||
def local = new Properties();
|
def local = new Properties()
|
||||||
try {
|
def localFile = file( 'local.properties' )
|
||||||
local.load(file('local.properties').newDataInputStream())
|
localFile.exists() && local.load( localFile.newDataInputStream() )
|
||||||
} catch (FileNotFoundException ignored) {
|
|
||||||
}
|
|
||||||
|
|
||||||
include 'masterpassword-core'
|
include 'masterpassword-core'
|
||||||
project(':masterpassword-core').projectDir = new File( '../platform-independent/c/core' )
|
project( ':masterpassword-core' ).projectDir = new File( '../platform-independent/c/core' )
|
||||||
|
|
||||||
include 'masterpassword-algorithm'
|
include 'masterpassword-algorithm'
|
||||||
project(':masterpassword-algorithm').projectDir = new File( '../platform-independent/java/algorithm' )
|
project( ':masterpassword-algorithm' ).projectDir = new File( '../platform-independent/java/algorithm' )
|
||||||
|
|
||||||
include 'masterpassword-model'
|
include 'masterpassword-model'
|
||||||
project(':masterpassword-model').projectDir = new File( '../platform-independent/java/model' )
|
project( ':masterpassword-model' ).projectDir = new File( '../platform-independent/java/model' )
|
||||||
|
|
||||||
include 'masterpassword-tests'
|
include 'masterpassword-tests'
|
||||||
project(':masterpassword-tests').projectDir = new File( '../platform-independent/java/tests' )
|
project( ':masterpassword-tests' ).projectDir = new File( '../platform-independent/java/tests' )
|
||||||
|
|
||||||
include 'masterpassword-gui'
|
include 'masterpassword-gui'
|
||||||
project(':masterpassword-gui').projectDir = new File( '../platform-independent/java/gui' )
|
project( ':masterpassword-gui' ).projectDir = new File( '../platform-independent/java/gui' )
|
||||||
|
|
||||||
//if (local.containsKey('sdk.dir')) {
|
if (local.containsKey( 'sdk.dir' ) && file( local.getProperty( 'sdk.dir' ) ).exists()) {
|
||||||
include 'masterpassword-android'
|
include 'masterpassword-android'
|
||||||
project(':masterpassword-android').projectDir = new File( '../platform-android' )
|
project( ':masterpassword-android' ).projectDir = new File( '../platform-android' )
|
||||||
//} else {
|
} else {
|
||||||
// logger.warn( "Skipping masterpassword-android since sdk.dir is not defined in local.properties." )
|
logger.warn( "Skipping masterpassword-android since sdk.dir is not defined in local.properties." )
|
||||||
//}
|
}
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# Your build script should simply source this script, optionally override any build hooks and then invoke `build`.
|
# Your build script should simply source this script, optionally override any build hooks and then invoke `build`.
|
||||||
# The build product should be available under `build-<platform>~/out`, under the library path.
|
# The build product should be available under `build-<platform>~/out`, under the library path.
|
||||||
#
|
#
|
||||||
# Hook lifecycle:
|
# Hook lifecycle:
|
||||||
# - build
|
# - build
|
||||||
# - initialize
|
# - initialize
|
||||||
@ -187,7 +187,7 @@ _target_build() {
|
|||||||
|
|
||||||
if [[ $platform = windows ]]; then
|
if [[ $platform = windows ]]; then
|
||||||
# I cannot for the life of me figure out how to pass this command directly into cmd.
|
# I cannot for the life of me figure out how to pass this command directly into cmd.
|
||||||
printf '"%%VSINSTALLDIR%%\Common7\Tools\VsMSBuildCmd.bat" && msbuild /t:Rebuild /p:Configuration=Release;Platform=%s;OutDir=%s' "$arch" "$(cygpath -w "${prefix##$PWD/}/$arch/")" > .build.bat
|
printf '"%%VSINSTALLDIR%%\Common7\Tools\VsMSBuildCmd.bat" && msbuild /t:Rebuild /p:Configuration=ReleaseDLL;Platform=%s;OutDir=%s' "$arch" "$(cygpath -w "${prefix##$PWD/}/$arch/")" > .build.bat
|
||||||
cmd //c .build.bat
|
cmd //c .build.bat
|
||||||
rm -f .build.bat
|
rm -f .build.bat
|
||||||
else
|
else
|
||||||
@ -280,6 +280,7 @@ _build() {
|
|||||||
'ios') archs=( 'i386' 'x86_64' 'armv7' 'armv7s' 'arm64' ) ;;
|
'ios') archs=( 'i386' 'x86_64' 'armv7' 'armv7s' 'arm64' ) ;;
|
||||||
'android') archs=( 'arm' 'arm64' 'x86' 'x86_64' ) ;;
|
'android') archs=( 'arm' 'arm64' 'x86' 'x86_64' ) ;;
|
||||||
'windows') archs=( 'Win32' 'x64' ) ;;
|
'windows') archs=( 'Win32' 'x64' ) ;;
|
||||||
|
*) archs=( 'i386' 'x86_64' ) ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -354,4 +355,3 @@ _build() {
|
|||||||
|
|
||||||
finalize "$prefix" "$platform" "${archs[@]}"
|
finalize "$prefix" "$platform" "${archs[@]}"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -64,11 +64,11 @@ library {
|
|||||||
}
|
}
|
||||||
|
|
||||||
archive.dependsOn project.tasks.maybeCreate( "build_libsodium-${system}", Exec.class ).configure {
|
archive.dependsOn project.tasks.maybeCreate( "build_libsodium-${system}", Exec.class ).configure {
|
||||||
commandLine 'bash', "$rootDir/../lib/bin/build_libsodium-${system}"
|
commandLine 'bash', '-x', "$rootDir/../lib/bin/build_libsodium-${system}"
|
||||||
privateHeaders.from "$rootDir/../lib/libsodium/src/libsodium/include"
|
privateHeaders.from "$rootDir/../lib/libsodium/src/libsodium/include"
|
||||||
}
|
}
|
||||||
archive.dependsOn project.tasks.maybeCreate( "build_libjson-c-${system}", Exec.class ).configure {
|
archive.dependsOn project.tasks.maybeCreate( "build_libjson-c-${system}", Exec.class ).configure {
|
||||||
commandLine 'bash', "$rootDir/../lib/bin/build_libjson-c-${system}"
|
commandLine 'bash', '-x', "$rootDir/../lib/bin/build_libjson-c-${system}"
|
||||||
privateHeaders.from "$rootDir/../lib/libjson-c/build-${system}~/out"
|
privateHeaders.from "$rootDir/../lib/libjson-c/build-${system}~/out"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user