blob: c3b7f56c26b178e26ec5db52620d23addab3addb [file] [log] [blame]
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +01001image: gcc
2
3build-and-test:
4 stage: build
Marc Kupietzc8ea6502022-04-13 11:50:46 +02005 cache:
6 - key: one-key-to-rule-them-all
7 paths:
8 - rocksdb-5.11.3/
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +01009 before_script:
10 - pwd
11 - source `find .. -name section_helper.sh`
12
13 - start_section install_linux_packages "Installing missing Linux packages"
14 - apt update && apt -y install cmake libgflags-dev libsnappy-dev zlib1g-dev libbz2-dev liblz4-dev libzstd-dev libomp-dev
15 - end_section install_linux_packages
16
Marc Kupietzcf7224b2022-04-10 17:12:20 +020017 script:
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +010018 - start_section install_rocksdb_static "Building and installing rocksdb-static"
19 - curl -L https://github.com/facebook/rocksdb/archive/refs/tags/v5.11.3.tar.gz | tar zx
20 - cd rocksdb-5.11.3
Marc Kupietzc8ea6502022-04-13 11:50:46 +020021 - export PROCS=$(nproc)
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +010022 - make -j $PROCS static_lib DISABLE_WARNING_AS_ERROR=1 WARNING_FLAGS=-w
23 - make install-static DISABLE_WARNING_AS_ERROR=1 WARNING_FLAGS=-w
24 - end_section install_rocksdb_static
25
26 - start_section install_rocksdb_shared "Building and installing rocksdb-shared"
27 - make -j $PROCS shared_lib DISABLE_WARNING_AS_ERROR=1 WARNING_FLAGS=-w
28 - make install-shared DISABLE_WARNING_AS_ERROR=1 WARNING_FLAGS=-w
Marc Kupietz3e003e02022-04-10 17:11:32 +020029 - ldconfig
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +010030 - cd ..
31 - end_section rocksdb_shared
32
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +010033 - start_section install_collocatordb "Building and installing collocatordb"
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +010034 - mkdir -p build
35 - cd build
36 - cmake ..
37 - make
38 - make install
Marc Kupietz3e003e02022-04-10 17:11:32 +020039 - ldconfig
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +010040 - ctest --extra-verbose
Marc Kupietzcf7224b2022-04-10 17:12:20 +020041 - cd ..
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +010042 - end_section install_collocatordb
43
44 artifacts:
45 paths:
Marc Kupietzcf7224b2022-04-10 17:12:20 +020046 - "build/*.a"
47 - "build/*.so*"
Marc Kupietza0557a02022-04-10 17:27:21 +020048# - "rocksdb-5.11.3/*.a"
49# - "rocksdb-5.11.3/*.so*"
Marc Kupietz7cf5d8a2021-03-22 17:52:52 +010050