Skip to content

Smithsonian/smax

Repository files navigation

Build Status Static Analysis API documentation

CfA logo

SMA-X

SMA-X is a realtime structured database for information sharing on distributed systems.

This is a meta repository, offering a collection of SMA-X related repositories in one place as git submodules. As such it helps ensure that all components are in a well-defined and compatible state, and it simplifies the build by having dependencies in one place.

Author: Attila Kovacs

Last Updated: 26 September 2024


Prerequisites

The core components of SMA-X do not have non-standard dependencies.

However, the smax-postgres application (built via the services target) has build and runtime dependencies on the following software:

  • PostgreSQL installation and development files (libpq.so and lipq.fe.h).
  • Popt development libraries (libpopt-devin Debian, or popt-devel in RPM distros)
  • (optional) TimescaleDB extensions.
  • (optional) systemd development files (libsystemd.so and sd-daemon.h).

Building

You can configure the build by defining the relevant environment variables prior to invoking make. The following build variables can be configured:

  • PGDIR: Root directory of a specific PostgreSQL installation to build against (not set by default).

  • SYSTEMD: Sets whether to compile with systemd integration (needs libsystemd.so and sd-daemon.h). Default is 1 (enabled).

  • CC: The C compiler to use (default: gcc).

  • CPPFLAGS: C preprocessor flags, such as externally defined compiler constants.

  • CFLAGS: Flags to pass onto the C compiler (default: -Os -Wall -std=c99). Note, -Iinclude will be added automatically.

  • LDFLAGS: Extra linker flags (default: not set). Note, -lm -pthread -lsmax -lredisx -lxchange -lpq -lpopt will be added automatically.

  • BUILD_MODE: You can set it to debug to enable debugging features: it will initialize the global xDebug variable to TRUE and add -g to CFLAGS.

  • CHECKEXTRA: Extra options to pass to cppcheck for the make check target

After configuring, you can simply run make, which will build bin/smax-postgres, and user documentation. You may also build other make target(s). (You can use make help to get a summary of the available make targets).

Now you may build it all by:

  $ make

Or, you may build selected targets, such as share libraries (shared), static libraries (static), executables (tools) and/or API documentation (dox).


Copyright (C) 2024 Attila Kovács

About

Meta-repo for SMA-X software in one place

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published