Skip to content

Repository files navigation

Stellar C++ SDK (cpp-stellar-sdk)

cpp-stellar-sdk is a C++ library for communicating with Stellar Horizon and Stellar RPC.

Developing

The project uses Dev Containers to provide a consistent development environment across systems.

Prerequisites

Getting Started

Clone the repository:

git clone https://github.com/irfanghat/cpp-stellar-sdk.git
cd cpp-stellar-sdk

Open the repository in VS Code. You should be prompted to reopen the workspace inside the Dev Container.

Alternatively, open the Command Palette and select:

Dev Containers: Reopen in Container

Wait for the container to build and initialize. Once it is ready, you can begin developing with the configured C++ toolchain and dependencies.

Add the following under .vscode/ (Linux Users):

settings.json

{
    "configurations": [
        {
            "name": "Linux",
            "includePath": [
                "${workspaceFolder}/include",
                "${workspaceFolder}/src",
                "${workspaceFolder}/build/xdr/generated",
                "/usr/local/include"
            ],
            "compilerPath": "/usr/bin/clang++",
            "cStandard": "c17",
            "cppStandard": "c++23",
            "intelliSenseMode": "linux-clang-x64",
            "compileCommands": "${workspaceFolder}/build/compile_commands.json"
        }
    ],
    "version": 4
}

c_cpp_settings.json

{
    "C_Cpp.default.compileCommands": "${workspaceFolder}/build/compile_commands.json"
}

Building the Project

Build the project using CMake and Ninja:

cmake -S . -B build -G Ninja
cmake --build build

License

Apache-2.0

About

A Stellar client library for C++.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages