{"id":15047997,"url":"https://github.com/abumq/residue-cpp","last_synced_at":"2025-04-10T01:12:16.496Z","repository":{"id":143885898,"uuid":"99283987","full_name":"abumq/residue-cpp","owner":"abumq","description":"Official C++ client library to interact with residue logging server seamlessly using network calls.","archived":false,"fork":false,"pushed_at":"2023-07-20T04:26:04.000Z","size":4442,"stargazers_count":4,"open_issues_count":0,"forks_count":4,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-10T01:12:07.114Z","etag":null,"topics":["cpp11","logging-library","remote-logging","residue-client"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/abumq.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-08-03T23:44:02.000Z","updated_at":"2024-04-05T22:30:49.000Z","dependencies_parsed_at":null,"dependency_job_id":"cbb22d63-fb42-4839-a637-c44b7b9016e9","html_url":"https://github.com/abumq/residue-cpp","commit_stats":null,"previous_names":["abumq/residue-cpp","zuhd-org/residue-cpp"],"tags_count":18,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abumq%2Fresidue-cpp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abumq%2Fresidue-cpp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abumq%2Fresidue-cpp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abumq%2Fresidue-cpp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/abumq","download_url":"https://codeload.github.com/abumq/residue-cpp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248137888,"owners_count":21053775,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cpp11","logging-library","remote-logging","residue-client"],"created_at":"2024-09-24T21:06:42.331Z","updated_at":"2025-04-10T01:12:16.468Z","avatar_url":"https://github.com/abumq.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"﷽\n\n# Residue C++ Client\nOfficial C++ client library with feature-rich API to interact with residue seamlessly. It uses [Easylogging++](https://github.com/abumq/easyloggingpp) to interact and take input from the user. Easylogging++ is highly efficient, well-tested library.\n\n [![Apache-2.0 license](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://github.com/abumq/residue-cpp/blob/master/LICENCE)\n\n## Getting Started\nThis library is based on single source file. It automatically includes `\u003cresidue/easylogging++.h\u003e` header and expect it to be available on developer's system. Please refer to documentation page to check the API.\n\nPlease refer to [samples directory](/samples/) to get started\n\n## Download Binary\nYou can download binary from [releases](https://github.com/abumq/residue-cpp/releases) page for your platform. They are standalone libraries with dependency on `libz` that usually comes with operating system distribution.\n\n * Download binaries archive for your platform\n * Download headers archive\n * Unzip binary archives and copy them to `/usr/local/lib/`\n * Unzip header archives and copy them to `/usr/local/include/residue/`\n\nFor ease, we have setup [`install.sh`](https://github.com/abumq/residue-cpp/blob/master/install.sh) that you can use to install it locall\n\n```\nsh -c \"$(curl -fsSL https://raw.githubusercontent.com/abumq/residue-cpp/master/install.sh)\"\n```\n\nYou should be ready to link your application against `libresidue`, both statically and dynamically.\n\nIf you use cmake, you may also be interested in [Residue CMake module](https://github.com/abumq/residue-cpp/blob/master/FindResidue.cmake)\n\n### Undefined Reference\n\nYou may need to define `-D_GLIBCXX_USE_CXX11_ABI=0` if you're using using gcc 5.1+ with pre-compiled binary. If you don't do it, you will get undefined references e.g,\n\n```\n/tmp/ccIYrKup.o: In function `Residue::connect(std::__cxx11::basic_string\u003cchar, std::char_traits\u003cchar\u003e, std::allocator\u003cchar\u003e \u003e const\u0026, int)':\nmain.cc:(.text._ZN7Residue7connectERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi[_ZN7Residue7connectERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi]+0x27): undefined reference to `Residue::connect_(std::__cxx11::basic_string\u003cchar, std::char_traits\u003cchar\u003e, std::allocator\u003cchar\u003e \u003e const\u0026, int, bool)'\n```\n\n[Learn more](https://gcc.gnu.org/onlinedocs/gcc-5.2.0/libstdc++/manual/manual/using_dual_abi.html)\n\n## Build From Source\nIf you do not wish to download binaries, you can build your own library using following steps.\n\n### Dependencies\n  * C++11 compiler (or higher)\n  * [Crypto++](https://www.cryptopp.com/) v5.6.5+ [with Pem Pack](https://github.com/noloader/cryptopp-pem)\n  * [zlib-devel](https://zlib.net/)\n\n### Get The Code\nYou can either [download code from master branch](https://github.com/abumq/residue-cpp/archive/master.zip) or clone it using `git`:\n\n```\ngit clone git@github.com:abumq/residue-cpp.git\n```\n\n### Build\nResidue C++ library uses the CMake toolchains to create makefiles.\n\nIn a nutshell, you will do:\n\n```\nmkdir build\ncd build\ncmake -Dtest=ON ..\nmake\n```\n\n### CMake Options\nYou can change following options in CMake (using `-D\u003coption\u003e=ON`)\n\n|    Option    | Description                     |\n| ------------ | ------------------------------- |\n| `test`       | Compile unit tests              |\n| `build_sample_app`      | Builds detailed-cmake sample           |\n| `special_edition`      | Build [special edition](https://github.com/abumq/residue/blob/master/docs/INSTALL.md#special-edition)           |\n\n### Run Tests\nPlease consider running unit test before you move on\n\n```\nmake test\n```\n\n### Install\nThe compilation process creates `libresidue` (static and shared) in build directory. Please see [Static Library](#static-library) section below before installing. You can install it in system-wide directory using:\n\n```\nmake install # Please read Static Library section below\n```\n\nIf the default path (`/usr/local/lib`) is not where you want things installed, then set the `CMAKE_INSTALL_PREFIX` option when running cmake. e.g,\n\n```\ncmake .. -DCMAKE_INSTALL_PREFIX=/usr/lib\n```\n\n### Setup\nMake sure you have all the dependencies installed. You can use following script to install them and then go back to the [Build](#build) section (tested on Ubuntu 14.04 (Trusty) 64-bit)\n\n```\n### Essentials\n## Essentials\nsudo apt-get install -y cmake build-essential libcurl-dev libz-dev\n    # sudo yum install -y cmake curl-devel zlib-devel # for rpm\n    # sudo yum groupinstall -y 'Development Tools'\n\n## Google Testing Library\nwget -O gtest.tar.gz https://github.com/google/googletest/archive/release-1.7.0.tar.gz\ntar xf gtest.tar.gz\ncd googletest-release-1.7.0\ncmake -DBUILD_SHARED_LIBS=ON .\nmake\ncp -a include/gtest /usr/local/include\ncp -a libgtest_main.* libgtest.* /usr/local/lib/\ncd ..\n\n## Crypto++\nwget https://raw.githubusercontent.com/abumq/abumq.github.io/master/downloads/cryptocpp.tar.gz\ntar xf cryptocpp.tar.gz\ncd cryptopp-CRYPTOPP_5_6_5\nwget https://raw.githubusercontent.com/abumq/abumq.github.io/master/downloads/pem_pack.zip\nunzip pem_pack.zip\n### IF ON MACOS ALSO DO\n### export CC=`which clang`\n### export CXX=`which clang++`\ncmake .\nmake\nsudo make install\n```\n\n### Static Library\nBy default, residue builds shared and static libraries. But static library only contains residue specific objects.\n\nYou can use following command to produce correct static library that is independent of any other library.\n\n```\nmkdir build\ncd build\nsh ../tools/package.sh linux 1.1.0 # specify version carefully to match with what's in CMakeLists.txt\n```\n\nThis will create:\n * `libresidue-1.1.0-x86_64-linux.tar.gz`\n * `libresidue-1.1.0-static-x86_64-linux.tar.gz`\n\nSecond one (`libresidue-1.1.0-static-x86_64-linux.tar.gz`) contains static library that is fully independent.\n\n### Strip\nYou can take advantage [`strip`](https://linux.die.net/man/1/strip) if you wish to link your application statically. This will reduce binary size significantly.\n\n## Build Matrix\n\n| Branch | Platform | Build Status |\n| -------- |:------------:|:------------:|\n| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `clang++` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/develop/1)](https://travis-ci.org/abumq/residue-cpp) |\n| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-4.9` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/develop/2)](https://travis-ci.org/abumq/residue-cpp) |\n| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-5` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/develop/3)](https://travis-ci.org/abumq/residue-cpp) |\n| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-6` | [![Build Status](https://travis-matrix-badges.herokuapp.com`/repos/abumq/residue-cpp/`branches/develop/4)](https://travis-ci.org/abumq/residue-cpp) |\n| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-7` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/develop/5)](https://travis-ci.org/abumq/residue-cpp) |\n| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `clang++` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/master/1)](https://travis-ci.org/abumq/residue-cpp) |\n| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-4.9` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/master/2)](https://travis-ci.org/abumq/residue-cpp) |\n| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-5` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/master/3)](https://travis-ci.org/abumq/residue-cpp) |\n| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-6` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/master/4)](https://travis-ci.org/abumq/residue-cpp) |\n| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-7` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/abumq/residue-cpp/branches/master/5)](https://travis-ci.org/abumq/residue-cpp) |\n\n## License\n\n```\nCopyright 2017-present @abumq (Majid Q.)\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabumq%2Fresidue-cpp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fabumq%2Fresidue-cpp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabumq%2Fresidue-cpp/lists"}