Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

CppMicroServices/ds-annotation

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DSAnnotation

DSAnnotation is a modular Clang-based tooling pipeline that scans C++ translation units for Declarative Services annotations and emits a merged OSGi-style manifests compatible for CppMicroServices Declarative Services.

Project layout

include/dsannotation/
  core/           # Domain models (Component, Reference, Error, Result)
  parsing/        # AST visitor + parser interfaces/implementations
  serialization/  # Manifest builder, merger, writer abstractions
  support/        # Error reporting, filesystem, syntax helpers
  config/         # Runtime configuration objects
src/
  core/           # Concrete domain types
  parsing/        # Parsing pipeline implementations
  serialization/  # JSON generation & manifest merge
  support/        # Platform services (filesystem, checks)
app/
  main.cpp        # Composition root & Clang tool wiring
tests/
  ...             # GoogleTest unit coverage

##Requirements Being a clang tool it obviously depends on the LLVM clang. However, to achieve the AST parsing, it requires a few more clang, libclang-dev and LLVM libraries which might not come in pre-released LLVM zips.

In unix the following packages should give you everything:

apt-get install clang llvm libclang-dev

However, on windows you might need to build LLVM from source, to get all the dependencies.

Build

cmake -S . -B build 
cmake --build build --config Release

The top-level CMakeLists.txt exposes:

  • dsannotation_core, dsannotation_support, dsannotation_parsing, dsannotation_serialization – structured static libraries
  • dsannotation – CLI executable
  • dsannotation_tests – GoogleTest suite (see below)

Running the tool

build\dsannotation.exe --help
build\dsannotation.exe -p path\to\compilation_database -i path\to\existing\manifest.json -o out\dir source.cpp

Output is written to ParserConfig::outputDirectory / ParserConfig::outputFileName (default manifest.json). Existing manifests are merged so custom bundle metadata is preserved.

Tests

cmake --build build --target dsannotation_tests
ctest --test-dir build -C Release

Additional unit tests are being added under tests/ and linked against the modular libraries.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.