Commit e235dbb9 authored by Drew's avatar Drew

Use caroline 0.1

parent c04f6554
Pipeline #2316 failed with stage
in 4 minutes and 45 seconds
......@@ -14,3 +14,4 @@ DerivedData
*.hmap
*.ipa
*.xcuserstate
external
......@@ -7,43 +7,43 @@ before_script:
- git submodule update --init --recursive
variables:
XCSBOT: "fc03b092ecd597b3488984a34d029eec"
XCSBOT_IOS: "8398cace692793b0b9d5ab1fe0964301"
docker_tag: "naoh"
cli_executable: "NaOH"
GITLAB_PROJECT_ID: "9"
FRAMEWORK_NAME: "NaOH"
testMac:
type: test
script:
- atpm fetch
- xcodebuild -scheme NaOH clean test
tags:
- xc7
- atpm
testiOSSim64:
type: test
script:
- atpm fetch
- xcodebuild -scheme NaOHiOSTestHostApp -configuration Debug -destination "platform=iOS Simulator,name=iPhone 6" clean test
tags:
- xc7
- atpm
testiOSSim64:
type: test
script:
- atpm fetch
- xcodebuild -scheme NaOHiOSTestHostApp -configuration Debug -destination "platform=iOS Simulator,name=iPhone 4s" clean test
tags:
- xc7
- atpm
iosDeviceTest:
type: test
script:
- atpm fetch
- xcodebuild -scheme NaOHiOSTestHostApp -configuration Debug -destination "platform=iOS,name=Dca's iPod touch" clean test
tags:
- xc7
- iosDevice
- atpm
archiveiOS:
type: package
......@@ -82,12 +82,14 @@ archiveMac:
atbuildMac:
type: test
script:
- atpm fetch
- atbuild check
tags:
- osx
- atbuild
- openswift
- atpm
artifacts:
paths:
......@@ -97,12 +99,11 @@ atbuildMac:
linux:
type: test
script:
- apt-get install --no-install-recommends xz-utils curl git ca-certificates -y
- curl -L https://github.com/AnarchyTools/atbuild/releases/download/0.10.0/atbuild-0.10.0-linux.tar.xz | tar xJ
- cp atbuild-*/atbuild /usr/local/bin/atbuild
- apt-get update && apt-get install --no-install-recommends xz-utils curl git ca-certificates atpm atbuild caroline-static-tool -y
- atpm fetch
- atbuild check
image: drewcrawford/swift:latest
image: drewcrawford/buildbase:latest
tags:
- autoscale-linux
Versions/A/Modules
\ No newline at end of file
Versions/A/Resources
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>CarolineCore</string>
<key>CFBundleIdentifier</key>
<string>com.sealedabstract.CarolineCore</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>CarolineCore</string>
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>0.1</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright © 2016 Drew Crawford. All rights reserved.</string>
<key>NSPrincipalClass</key>
<string></string>
</dict>
</plist>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>files</key>
<dict>
<key>Resources/Info.plist</key>
<data>
4dnTEPxqiWKT9tyY0Gt+vg6apug=
</data>
</dict>
<key>files2</key>
<dict>
<key>Modules/CarolineCore.swiftmodule/x86_64.swiftdoc</key>
<dict>
<key>hash</key>
<data>
cO5ljYt66nB+Q+s9/ONHgk4d49Y=
</data>
<key>hash2</key>
<data>
0Ks7fhdzlDEY/OEvaBKPeVonSebgUVn2LnFwKXyuokE=
</data>
</dict>
<key>Modules/CarolineCore.swiftmodule/x86_64.swiftmodule</key>
<dict>
<key>hash</key>
<data>
FqN6Dgjay0/Ro//0jGZBw4cFWXE=
</data>
<key>hash2</key>
<data>
QR2yvxOnkJrYtvNqcE0RqYG2xnWfXR++qp7Evcfa9b8=
</data>
</dict>
<key>Resources/Info.plist</key>
<dict>
<key>hash</key>
<data>
4dnTEPxqiWKT9tyY0Gt+vg6apug=
</data>
<key>hash2</key>
<data>
1S3P6pAuSjjAjbd56lkd8B+qRc/qbZPh39Rd7KsoVnQ=
</data>
</dict>
</dict>
<key>rules</key>
<dict>
<key>^Resources/</key>
<true/>
<key>^Resources/.*\.lproj/</key>
<dict>
<key>optional</key>
<true/>
<key>weight</key>
<real>1000</real>
</dict>
<key>^Resources/.*\.lproj/locversion.plist$</key>
<dict>
<key>omit</key>
<true/>
<key>weight</key>
<real>1100</real>
</dict>
<key>^version.plist$</key>
<true/>
</dict>
<key>rules2</key>
<dict>
<key>.*\.dSYM($|/)</key>
<dict>
<key>weight</key>
<real>11</real>
</dict>
<key>^(.*/)?\.DS_Store$</key>
<dict>
<key>omit</key>
<true/>
<key>weight</key>
<real>2000</real>
</dict>
<key>^(Frameworks|SharedFrameworks|PlugIns|Plug-ins|XPCServices|Helpers|MacOS|Library/(Automator|Spotlight|LoginItems))/</key>
<dict>
<key>nested</key>
<true/>
<key>weight</key>
<real>10</real>
</dict>
<key>^.*</key>
<true/>
<key>^Info\.plist$</key>
<dict>
<key>omit</key>
<true/>
<key>weight</key>
<real>20</real>
</dict>
<key>^PkgInfo$</key>
<dict>
<key>omit</key>
<true/>
<key>weight</key>
<real>20</real>
</dict>
<key>^Resources/</key>
<dict>
<key>weight</key>
<real>20</real>
</dict>
<key>^Resources/.*\.lproj/</key>
<dict>
<key>optional</key>
<true/>
<key>weight</key>
<real>1000</real>
</dict>
<key>^Resources/.*\.lproj/locversion.plist$</key>
<dict>
<key>omit</key>
<true/>
<key>weight</key>
<real>1100</real>
</dict>
<key>^[^/]+$</key>
<dict>
<key>nested</key>
<true/>
<key>weight</key>
<real>10</real>
</dict>
<key>^embedded\.provisionprofile$</key>
<dict>
<key>weight</key>
<real>20</real>
</dict>
<key>^version\.plist$</key>
<dict>
<key>weight</key>
<real>20</real>
</dict>
</dict>
</dict>
</plist>
FROM drewcrawford/swift:latest
FROM drewcrawford/buildbase:latest
#install atbuild
RUN apt-get update && apt-get install git --no-install-recommends xz-utils -y
ADD https://github.com/AnarchyTools/atbuild/releases/download/0.10.0/atbuild-0.10.0-linux.tar.xz /atbuild.tar.xz
RUN tar xf atbuild.tar.xz && cp atbuild-*/atbuild /usr/local/bin/atbuild
RUN apt-get update && apt-get install atbuild atpm caroline-static-tool
WORKDIR NaOH
#provide some relief for caching
#these lines can actually be commented out, but make the build process more cacheable
#speeding up build times in common cases
WORKDIR NaOH
# libsodium
ADD libsodium /NaOH/libsodium
RUN libsodium/build.sh
ADD . /NaOH
RUN atpm fetch
RUN atbuild check --use-overlay linux
\ No newline at end of file
This diff is collapsed.
......@@ -71,8 +71,10 @@ public struct CryptoBoxPublicKey: PublicKey {
}
}
@available(iOS 9.3, *)
extension CryptoBoxPublicKey: Equatable { }
@available(iOS 9.3, *)
public func == (a: CryptoBoxPublicKey, b: CryptoBoxPublicKey) -> Bool {
return a.bytes == b.bytes
}
......
......@@ -11,7 +11,7 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#if !ATBUILD
import XCTest
import CarolineCore
@testable import NaOHTests
......@@ -48,4 +48,3 @@ class CarolineEngineTests: XCTestCase {
}
}
}
#endif
// Copyright (c) 2016 Drew Crawford.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
import XCTest
import CarolineCore
@testable import NaOHiOSTestHostAppTests
class CarolineEngineTests: XCTestCase {
func testAllCarolineTests() {
let allTests: [CarolineTest] = [
ChaCha20(),
KeyTest(),
ZeroImport(),
Crypto(),
OverwriteKey(),
CryptoBoxKey(),
HumanReadable(),
KeyLoadSave(),
PublicKeyLoadSave(),
EncryptTest(),
DecryptTest(),
BadDecrypt(),
Integer192BitTests(),
CryptoBox(),
CryptoBoxOpen(),
GenerateKey(),
DeriveKey(),
TestSign(),
TestVerify(),
TestBadVerify(),
GenericHash(),
MemCmpTest()
]
let engine = CarolineCoreEngine()
if !engine.testAll(allTests) {
XCTFail("Caroline tests failed")
}
}
}
;; Anarchy Tools Package Manager lock file
;;
;; If you want to pin a package to a git commit add a ':pin'
;; line to that package definition. This will override all version
;; information the build files specify.
;;
;; You may override the repository URL for a package by specifying
;; it in an ':override-url' line. This is very handy if you develop
;; the dependency in parallel to the package that uses it
(lock-file
:packages [
{
:url "https://code.sealedabstract.com/drewcrawford/Caroline.git"
:payloads [
{
:key "git"
:used-commit "563b3f590527c8e2bf47116bb6beb68878600f74"
:pin false
}
]
}
{
:url "https://code.sealedabstract.com/drewcrawford/Caroline/raw/master/manifest.atpkg"
:payloads [
{
:key "core-osx-swift-2.2"
:pin false
:used-url "https://code.sealedabstract.com/drewcrawford/Caroline/uploads/7838c42eef7efd10d8844c39545edc5f/CarolineCore-0.1-dev-osx.tar.xz"
:used-version "0.1-dev"
:sha-sum "d490c780d81bb06d60937ca291968b7fdf2e5b6bfd5a94fdf4ee308ca3a76076"
}
{
:key "core-ios-swift-2.2"
:pin false
:used-url "https://code.sealedabstract.com/drewcrawford/Caroline/uploads/4991c30a2fc4e942a0c6fdb87676d297/CarolineCore-0.1-ios.tar.xz"
:used-version "0.1-dev"
:sha-sum "d12055ca2f21f93660a74d7319514e0a282a31ab62c3ccc6b2ceb8278c611282"
}
]
}
]
)
......@@ -3,13 +3,16 @@
:external-packages [
{
:url "git@code.sealedabstract.com:drewcrawford/Caroline.git"
:branch "master"
:url "https://code.sealedabstract.com/drewcrawford/Caroline.git"
:version [">=0.1"]
}
{
:version [">=0.1"]
:channels ["core-osx-swift-2.2" "core-ios-swift-2.2"]
:url "https://code.sealedabstract.com/drewcrawford/Caroline/raw/master/manifest.atpkg"
}
]
:import-packages ["external/Caroline/build.atpkg"]
:overlays {
:link {
:link-options ["-Xlinker" "user/libsodium/libsodium/src/libsodium/.libs/libsodium.a"]
......@@ -45,7 +48,7 @@
:gen-tests {
:tool "shell"
:script "/Users/drew/Code/Caroline/bin/caroline_static_tool --core ${collect_sources:build-tests} > NaOHTests/main.swift"
:script "caroline-static-tool --core ${collect_sources:build-tests} > NaOHTests/main.swift"
}
:build-tests {
......@@ -55,7 +58,7 @@
:output-type "executable"
:dependencies ["default"]
:compile-options ["-I" "libsodium/"]
:link-with ["NaOH.a" "CarolineCore.a"]
:link-with-product ["NaOH.a" "CarolineCore.a"]
:use-overlays ["link"]
:link-options ["-Xlinker" "-ObjC"]
:dependencies ["Caroline.core" "gen-tests" "default"]
......
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