diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..33af3de --- /dev/null +++ b/.drone.yml @@ -0,0 +1,24 @@ +kind: pipeline +type: docker +name: default + +steps: + - name: build + image: simon987/ubuntu_ci + commands: + - ./ci/build.sh + - name: scp files + image: appleboy/drone-scp + settings: + host: + from_secret: SSH_HOST + port: + from_secret: SSH_PORT + user: + from_secret: SSH_USER + key: + from_secret: SSH_KEY + target: /files/sist2/${DRONE_REPO_NAME}_${DRONE_BRANCH}_${DRONE_BUILD_NUMBER}/ + source: + - ./sist2.gz + - ./sist2_debug.tar.gz \ No newline at end of file diff --git a/.teamcity/settings.kts b/.teamcity/settings.kts deleted file mode 100644 index 4aaae40..0000000 --- a/.teamcity/settings.kts +++ /dev/null @@ -1,69 +0,0 @@ -import jetbrains.buildServer.configs.kotlin.v2019_2.* -import jetbrains.buildServer.configs.kotlin.v2019_2.buildSteps.ExecBuildStep -import jetbrains.buildServer.configs.kotlin.v2019_2.buildSteps.exec -import jetbrains.buildServer.configs.kotlin.v2019_2.triggers.vcs -import jetbrains.buildServer.configs.kotlin.v2019_2.vcs.GitVcsRoot - -/* -The settings script is an entry point for defining a TeamCity -project hierarchy. The script should contain a single call to the -project() function with a Project instance or an init function as -an argument. - -VcsRoots, BuildTypes, Templates, and subprojects can be -registered inside the project using the vcsRoot(), buildType(), -template(), and subProject() methods respectively. - -To debug settings scripts in command-line, run the - - mvnDebug org.jetbrains.teamcity:teamcity-configs-maven-plugin:generate - -command and attach your debugger to the port 8000. - -To debug in IntelliJ Idea, open the 'Maven Projects' tool window (View --> Tool Windows -> Maven Projects), find the generate task node -(Plugins -> teamcity-configs -> teamcity-configs:generate), the -'Debug' option is available in the context menu for the task. -*/ - -version = "2019.2" - -project { - - vcsRoot(HttpsGithubComSimon987sist2refsHeadsMaster) - - buildType(Build) -} - -object Build : BuildType({ - name = "Build" - - artifactRules = """ - sist2 - sist2_scan - """.trimIndent() - - vcs { - root(HttpsGithubComSimon987sist2refsHeadsMaster) - } - - steps { - exec { - name = "Build" - path = "./ci/build.sh" - dockerImage = "simon987/general_ci" - dockerImagePlatform = ExecBuildStep.ImagePlatform.Linux - dockerPull = true - } - } - - triggers { - vcs { - } - } -}) - -object HttpsGithubComSimon987sist2refsHeadsMaster : GitVcsRoot({ - name = "https://github.com/simon987/sist2#refs/heads/master" - url = "https://github.com/simon987/sist2" -}) diff --git a/ci/build.sh b/ci/build.sh index c5f0e43..f9a1b08 100755 --- a/ci/build.sh +++ b/ci/build.sh @@ -4,14 +4,16 @@ VCPKG_ROOT="/vcpkg" rm *.gz +git submodule update --init --recursive + rm -rf CMakeFiles CMakeCache.txt -cmake -DSIST_DEBUG=off -DVCPKG_BUILD_TYPE=release -DCMAKE_TOOLCHAIN_FILE="${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" . -make -j 12 +cmake -DSIST_DEBUG=off -DCMAKE_TOOLCHAIN_FILE="${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" . +make -j 33 strip sist2 gzip -9 sist2 rm -rf CMakeFiles CMakeCache.txt -cmake -DSIST_DEBUG=on -DVCPKG_BUILD_TYPE=debug -DCMAKE_TOOLCHAIN_FILE="${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" . -make -j 12 +cmake -DSIST_DEBUG=on -DCMAKE_TOOLCHAIN_FILE="${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" . +make -j 33 cp /usr/lib/x86_64-linux-gnu/libasan.so.2.0.0 libasan.so.2 tar -czf sist2_debug.tar.gz sist2_debug libasan.so.2