Skip to content

Latest commit

 

History

History
77 lines (64 loc) · 3.06 KB

DEVELOPMENT.md

File metadata and controls

77 lines (64 loc) · 3.06 KB

VSAG Developer Guide

Welcome to the developer guide for VSAG! This guide is designed to provide both new and experienced contributors with a comprehensive resource for understanding the project's codebase, development processes, and best practices.

Whether you're an open-source enthusiast looking to make your first contribution or a seasoned developer seeking insights into the project's architecture, the guide aims to streamline your onboarding process and empower you to contribute effectively.

Let's dive in and explore how you can become an integral part of our vibrant open-source community!

Development Environment

There are two ways to build and develop the VSAG project now.

Use Docker(recommended)

Docker Pulls Docker Image Size

docker pull vsaglib/vsag:ubuntu

or Install Dependencies

# for Debian/Ubuntu
$ ./scripts/deps/install_deps_ubuntu.sh

# for CentOS/AliOS
$ ./scripts/deps/install_deps_centos.sh

VSAG Build Tool

VSAG project use the Unix Makefiles to compile, package and install the library. Here is the commands below:

Usage: make <target>

Targets:
help:                    ## Show the help.
##
## ================ development ================
debug:                   ## Build vsag with debug options.
test:                    ## Build and run unit tests.
asan:                    ## Build with AddressSanitizer option.
test_asan: asan          ## Run unit tests with AddressSanitizer option.
tsan:                    ## Build with ThreadSanitizer option.
test_tsan: tsan          ## Run unit tests with ThreadSanitizer option.
clean:                   ## Clear build/ directory.
##
## ================ integration ================
fmt:                     ## Format codes.
cov:                     ## Build unit tests with code coverage enabled.
test_parallel: debug     ## Run all tests parallel (used in CI).
test_asan_parallel: asan ## Run unit tests parallel with AddressSanitizer option.
test_tsan_parallel: tsan ## Run unit tests parallel with ThreadSanitizer option.
##
## ================ distribution ================
release:                 ## Build vsag with release options.
distribution:            ## Build vsag with distribution options.
libcxx:                  ## Build vsag using libc++.
pyvsag:                  ## Build pyvsag wheel.
clean-release:           ## Clear build-release/ directory.
install:                 ## Build and install the release version of vsag.

Project Structure

  • cmake/: cmake util functions
  • docker/: the dockerfile to build develop and ci image
  • docs/: the design documents
  • examples/: cpp and python example codes
  • extern/: third-party libraries
  • include/: export header files
  • mockimpl/: the mock implementation that can be used in interface test
  • python/: the pyvsag package and setup tools
  • python_bindings/: the python bindings
  • scripts/: useful scripts
  • src/: the source codes and unit tests
  • tests/: the functional tests
  • tools/: the tools