Marc Kupietz | 7cf5d8a | 2021-03-22 17:52:52 +0100 | [diff] [blame] | 1 | image: gcc |
| 2 | |
| 3 | build-and-test: |
| 4 | stage: build |
| 5 | before_script: |
| 6 | - pwd |
| 7 | - source `find .. -name section_helper.sh` |
| 8 | |
| 9 | - start_section install_linux_packages "Installing missing Linux packages" |
| 10 | - apt update && apt -y install cmake libgflags-dev libsnappy-dev zlib1g-dev libbz2-dev liblz4-dev libzstd-dev libomp-dev |
| 11 | - end_section install_linux_packages |
| 12 | |
Marc Kupietz | cf7224b | 2022-04-10 17:12:20 +0200 | [diff] [blame] | 13 | script: |
Marc Kupietz | 7cf5d8a | 2021-03-22 17:52:52 +0100 | [diff] [blame] | 14 | - start_section install_rocksdb_static "Building and installing rocksdb-static" |
| 15 | - curl -L https://github.com/facebook/rocksdb/archive/refs/tags/v5.11.3.tar.gz | tar zx |
| 16 | - cd rocksdb-5.11.3 |
| 17 | - export PROCS=$(cat /proc/cpuinfo | grep -c processor) |
| 18 | - make -j $PROCS static_lib DISABLE_WARNING_AS_ERROR=1 WARNING_FLAGS=-w |
| 19 | - make install-static DISABLE_WARNING_AS_ERROR=1 WARNING_FLAGS=-w |
| 20 | - end_section install_rocksdb_static |
| 21 | |
| 22 | - start_section install_rocksdb_shared "Building and installing rocksdb-shared" |
| 23 | - make -j $PROCS shared_lib DISABLE_WARNING_AS_ERROR=1 WARNING_FLAGS=-w |
| 24 | - make install-shared DISABLE_WARNING_AS_ERROR=1 WARNING_FLAGS=-w |
Marc Kupietz | 3e003e0 | 2022-04-10 17:11:32 +0200 | [diff] [blame] | 25 | - ldconfig |
Marc Kupietz | 7cf5d8a | 2021-03-22 17:52:52 +0100 | [diff] [blame] | 26 | - cd .. |
| 27 | - end_section rocksdb_shared |
| 28 | |
Marc Kupietz | 7cf5d8a | 2021-03-22 17:52:52 +0100 | [diff] [blame] | 29 | - start_section install_collocatordb "Building and installing collocatordb" |
Marc Kupietz | 7cf5d8a | 2021-03-22 17:52:52 +0100 | [diff] [blame] | 30 | - mkdir -p build |
| 31 | - cd build |
| 32 | - cmake .. |
| 33 | - make |
| 34 | - make install |
Marc Kupietz | 3e003e0 | 2022-04-10 17:11:32 +0200 | [diff] [blame] | 35 | - ldconfig |
Marc Kupietz | 7cf5d8a | 2021-03-22 17:52:52 +0100 | [diff] [blame] | 36 | - ctest --extra-verbose |
Marc Kupietz | cf7224b | 2022-04-10 17:12:20 +0200 | [diff] [blame] | 37 | - cd .. |
Marc Kupietz | 7cf5d8a | 2021-03-22 17:52:52 +0100 | [diff] [blame] | 38 | - end_section install_collocatordb |
| 39 | |
| 40 | artifacts: |
| 41 | paths: |
Marc Kupietz | cf7224b | 2022-04-10 17:12:20 +0200 | [diff] [blame] | 42 | - "build/*.a" |
| 43 | - "build/*.so*" |
Marc Kupietz | a0557a0 | 2022-04-10 17:27:21 +0200 | [diff] [blame] | 44 | # - "rocksdb-5.11.3/*.a" |
| 45 | # - "rocksdb-5.11.3/*.so*" |
Marc Kupietz | 7cf5d8a | 2021-03-22 17:52:52 +0100 | [diff] [blame] | 46 | |