Code Monkey home page Code Monkey logo

dyod_sose23's Introduction

OpossumDB

Have a look at our contributor guidelines.

Dependencies

You can install the dependencies on your own or use the install_dependencies.sh script (recommended), which installs all of the therein listed dependencies and submodules. The install script was tested under macOS Monterey and Ubuntu 22.04 (apt-get).

See dependencies.md for a detailed list of dependencies to use with brew install or apt-get install, depending on your platform. As compilers, we generally use the most recent version of gcc and clang. Older versions may work, but are neither tested nor supported.

Building and Tooling

It is highly recommended to perform out-of-source builds, i.e., creating a separate directory for the build. Advisable names for this directory would be cmake-build-{debug,release}, depending on the build type. Within this directory call cmake .. to configure the build. Subsequent calls to CMake, e.g., when adding files to the build will not be necessary, the generated Makefiles will take care of that.

Compiler choice

CMake will default to your system's default compiler. To use a different one, call like cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ .. in a clean build directory.

If you use macOS, you will have to add the path to your brew clang version: cmake -DCMAKE_C_COMPILER=$(brew --prefix llvm)/bin/clang -DCMAKE_CXX_COMPILER=$(brew --prefix llvm)/bin/clang++ ...

Build

Simply call make -j*, where * denotes the number of threads to use.

Usually debug binaries are created. To configure a build directory for a release build make sure it is empty and call CMake like cmake -DCMAKE_BUILD_TYPE=Release.

Lint

./scripts/lint.sh (Google's cpplint is used.)

Format

./scripts/format.sh (clang-format is used.)

Test

Calling make opossumTest from the build directory builds all available tests. Run tests from the root directory, e.g., ./cmake-build-debug/opossumTest.

Coverage

After building opossumCoverage, ./scripts/coverage.sh <build dir> will print a summary to the command line and create detailed html reports at ./coverage/index.html

Supports only clang on macOS.

Address/UndefinedBehavior Sanitizers

cmake -DENABLE_ADDR_UB_SANITIZATION=ON will generate Makefiles with AddressSanitizer and Undefined Behavior options. Compile and run them as normal - if any issues are detected, they will be printed to the console. It will fail on the first detected error and will print a summary. To convert addresses to actual source code locations, make sure llvm-symbolizer is installed (included in the llvm package) and is available in $PATH. To specify a custom location for the symbolizer, set $ASAN_SYMBOLIZER_PATH to the path of the executable. This seems to work out of the box on macOS - If not, make sure to have llvm installed. The binary can be executed with LSAN_OPTIONS=suppressions=asan-ignore.txt ./<YourBuildDirectory>/opossumTest.

cmake -DENABLE_THREAD_SANITIZATION=ON will work as above but with the ThreadSanitizer. Some sanitizers are mutually exclusive, which is why we use two configurations for this.

Naming convention for gtest macros:

We use the schema TEST(ModuleNameClassNameTest, TestName), e.g., TEST(OperatorsGetTableTest, RowCount) (same for fixtures Test_F()).

If you want to test a single module, class, or test, you have to execute the test binary and use the gtest_filter option:

  • Testing the storage module: ./build/opossumTest --gtest_filter="Storage*"
  • Testing the table class: ./build/opossumTest --gtest_filter="StorageTableTest*"
  • Testing the RowCount test: ./build/opossumTest --gtest_filter="StorageTableTest.RowCount"

Maintainers

  • Daniel Lindner
  • Marcel Weisgut
  • Martin Boissier

Contact: [email protected]

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.