diff --git a/.azure-pipelines.yml b/.azure-pipelines.yml index d4ffcb60c..6c71a8080 100644 --- a/.azure-pipelines.yml +++ b/.azure-pipelines.yml @@ -54,81 +54,3 @@ stages: test_cmd: -c "import tiledbvcf; print(tiledbvcf.version)" steps: - template: ci/build-images.yml - - - stage: BuildNativeLibs - condition: or(eq(variables.isMain, true), eq(variables.isRefTag, true)) - jobs: - - job: Linux_OSX - strategy: - matrix: - linux: - imageName: 'ubuntu-24.04' - python.version: '3.x' - CXX: g++ - BUILD_PYTHON_API: ON - mac: - imageName: 'macOS-13' - python.version: '3.7' - CXX: clang++ - BUILD_PYTHON_API: ON - #SDKROOT: '/Applications/Xcode_10.3.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk' - MACOSX_DEPLOYMENT_TARGET: '11' - - pool: - vmImage: $(imageName) - steps: - - task: UsePythonVersion@0 - inputs: - versionSpec: '$(python.version)' - architecture: 'x64' - - script: printenv - displayName: 'Print Env' - - template: ci/native_libs-linux_osx.yml - - - stage: GitHubRelease - condition: eq(variables.isRefTag, true) - jobs: - - job: All_OS - strategy: - matrix: - ubuntu_18: - imageName: 'ubuntu-24.04' - pool: - vmImage: $(imageName) - - steps: - - download: current - patterns: '**/*.tar.gz' - - - bash: | - unset SYSTEM - set +e - ci/collect-nativelibs.sh - displayName: 'Collect Native Libraries' - - - task: ArchiveFiles@2 - inputs: - rootFolderOrFile: '$(Build.BinariesDirectory)' - includeRootFolder: false - archiveType: 'tar' # Options: zip, 7z, tar, wim - tarCompression: 'gz' # Optional. Options: gz, bz2, xz, none - archiveFile: $(Build.ArtifactStagingDirectory)/tiledb-vcf-jar-$(Build.SourceBranchName).tar.gz - replaceExistingArchive: true - verbose: true # Optional - condition: succeeded() - - - task: PublishBuildArtifacts@1 - inputs: - pathtoPublish: $(Build.ArtifactStagingDirectory)/tiledb-vcf-jar-$(Build.SourceBranchName).tar.gz - artifactName: libraries - condition: succeeded() - - - task: GithubRelease@0 - displayName: 'GitHub Release' - inputs: - gitHubConnection: 'TileDB-Inc-Release' - repositoryName: TileDB-Inc/TileDB-VCF - tag: $(Build.SourceBranchName) - action: "edit" - isDraft: true - assets: $(Build.BinariesDirectory)/jars/*.jar diff --git a/ci/native_libs-linux_osx.yml b/ci/native_libs-linux_osx.yml deleted file mode 100755 index 4faca691a..000000000 --- a/ci/native_libs-linux_osx.yml +++ /dev/null @@ -1,129 +0,0 @@ -steps: - - bash: | - set -e pipefail - - # Install htslib dependencies - if [[ "$AGENT_OS" == "Linux" ]]; then - sudo apt-get update && sudo apt-get install -y automake autoconf libbz2-dev liblzma-dev - fi - - # Install bcftools (only required for running the CLI tests) - version=1.16 - if [[ "$AGENT_OS" == "Linux" ]]; then - pushd /tmp - wget https://github.com/samtools/bcftools/releases/download/${version}/bcftools-${version}.tar.bz2 - tar xfj bcftools-${version}.tar.bz2 - cd bcftools-${version} - ./configure --prefix=/usr - make -j2 - sudo make install - popd - else - brew install bcftools automake - fi - - # Install some extra dependencies to speed up the core TileDB build - if [[ "$AGENT_OS" == "Linux" ]]; then - sudo apt-get install -y libssl-dev libbz2-dev liblz4-dev libtbb-dev libcurl4-openssl-dev zlib1g-dev - fi - displayName: 'Install dependencies' - - - bash: | - # azure bash does not treat intermediate failure as error - # https://github.com/Microsoft/azure-pipelines-yaml/issues/135 - set -e pipefail - - # Azure sets "SYSTEM=build" for unknown reasons, which breaks the OpenSSL configure script (in TileDB itself) - # - openssl configure uses ENV{SYSTEM} if available: - # https://github.com/openssl/openssl/blob/6d745d740d37d680ff696486218b650512bbbbc6/config#L56 - # - error description: - # https://developercommunity.visualstudio.com/content/problem/602584/openssl-build-error-when-using-pipelines.htm - unset SYSTEM - - # Configure and build TileDB-VCF - mkdir -p $BUILD_REPOSITORY_LOCALPATH/libtiledbvcf/build - cd $BUILD_REPOSITORY_LOCALPATH/libtiledbvcf/build - cmake -DCMAKE_INSTALL_PREFIX=$BUILD_REPOSITORY_LOCALPATH/dist .. - - make -j4 - make -j4 -C libtiledbvcf tiledb_vcf_unit - - make install-libtiledbvcf - - displayName: 'Build and test TileDB-VCF' - - - bash: | - set -e pipefail - pushd $BUILD_REPOSITORY_LOCALPATH/apis/java - - ./gradlew assemble - - export LD_LIBRARY_PATH=$BUILD_REPOSITORY_LOCALPATH/apis/java/build/resources/main/lib:$LD_LIBRARY_PATH - - displayName: 'Build and test TileDB-VCF Java API' - - - bash: | - echo "Testing" - ls - echo "listing JNI" - ls $BUILD_REPOSITORY_LOCALPATH/dist/lib - - echo "listing 2" - ls $BUILD_REPOSITORY_LOCALPATH/apis/java/build/install/lib - - - if [[ ( "$AGENT_OS" == "Linux" ) ]]; then - cp $BUILD_REPOSITORY_LOCALPATH/libtiledbvcf/build/externals/install/lib/*.so* $BUILD_BINARIESDIRECTORY - cp $BUILD_REPOSITORY_LOCALPATH/dist/lib/*.so* $BUILD_BINARIESDIRECTORY - cp $BUILD_REPOSITORY_LOCALPATH/apis/java/build/install/lib/*.so* $BUILD_BINARIESDIRECTORY - fi - - if [[ ( "$AGENT_OS" == "Darwin" ) ]]; then - cp $BUILD_REPOSITORY_LOCALPATH/dist/lib/*.dylib $BUILD_BINARIESDIRECTORY - cp $BUILD_REPOSITORY_LOCALPATH/apis/java/build/install/lib/*.dylib $BUILD_BINARIESDIRECTORY - fi - - displayName: 'Test' - - - script: | - echo $sourceVersion - commitHash=${sourceVersion:0:7} - echo $commitHash - echo "##vso[task.setvariable variable=commitHash]$commitHash" ## Set variable for using in other tasks. - env: { sourceVersion: $(Build.SourceVersion) } - displayName: Git Hash 7-digit - - - bash: | - git describe --tags > $BUILD_REPOSITORY_LOCALPATH/version.txt - displayName: 'Capture version' - - - task: ArchiveFiles@2 - inputs: - rootFolderOrFile: '$(Build.BinariesDirectory)' - includeRootFolder: false - archiveType: 'tar' # Options: zip, 7z, tar, wim - tarCompression: 'gz' # Optional. Options: gz, bz2, xz, none - archiveFile: $(Build.ArtifactStagingDirectory)/tiledb-vcf-$(Agent.OS)-$(Build.SourceBranchName)-$(commitHash).tar.gz - replaceExistingArchive: true - verbose: true # Optional - condition: succeeded() - - - task: PublishBuildArtifacts@1 - inputs: - pathtoPublish: $(Build.ArtifactStagingDirectory)/tiledb-vcf-$(Agent.OS)-$(Build.SourceBranchName)-$(commitHash).tar.gz - artifactName: libraries - condition: succeeded() - - - bash: | - set -e pipefail - # Display log files if the build failed - echo "Dumping log files for failed build" - echo "----------------------------------" - for f in $(find $BUILD_REPOSITORY_LOCALPATH/libtiledbvcf/build -name *.log); - do echo "------" - echo $f - echo "======" - cat $f - done; - condition: failed() # only run this job if the build step failed - displayName: "Print log files (failed build only)"