Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/outscale/osc-sdk-c
C SDK for Outscale
https://github.com/outscale/osc-sdk-c
Last synced: 7 days ago
JSON representation
C SDK for Outscale
- Host: GitHub
- URL: https://github.com/outscale/osc-sdk-c
- Owner: outscale
- License: bsd-3-clause
- Created: 2022-12-01T14:24:01.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2024-08-13T14:17:45.000Z (3 months ago)
- Last Synced: 2024-08-14T16:46:11.140Z (3 months ago)
- Language: C
- Homepage:
- Size: 1.76 MB
- Stars: 1
- Watchers: 4
- Forks: 2
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
[![Project Incubating](https://docs.outscale.com/fr/userguide/_images/Project-Incubating-blue.svg)](https://docs.outscale.com/en/userguide/Open-Source-Projects.html)
# Outscale SDK for C
Welcome to Outscale SDK for C.
## Dependency
json-c and libcurl (7.75 and after)
## How to use the SDK?
Simply grab the C source and add it to your project, you need to include json-c and curl (version > 7.75) to your code.
See [examples](examples/) folder to jump straight into the code!
Here's an explication of the Makefile rule compiling example 1:```
${CC} examples/example1.c ./osc_sdk.c -I./ `pkg-config --cflags json-c` -lcurl -ljson-c -o example1 -Wall -Wno-unused-function -g
```
- `-I` specify include path (where to find `osc_sdk.h`). If osc_sdk.h was in the same directory than `example0.c` it wouldn't be needed.
- `-lcurl -ljson-c` specify curl and json-c libraries.
- `-Wno-unused-function` because osc-sdk.c is compiled with the example, and not all functions are used
- `pkg-config --cflags json-c` to find json-c cflags
- `-Wall` for more warning
- `-g` for debug symbole`example0.c` is similar, but use an archive, so it can compile in ansi C (`-std=c89`)
## Notes
You need libcurl to a version superior to 7.75 (again it's important).
json-c have deprecated ANSI C in favor to C99 and C11, if you want to continue using C89 you might stick to current or old versions.
**Interface is not stable yet, please be aware that some breaking change can still exist until 1.x.**
SDK itself is generated from Outscale's [COGNAC](https://github.com/outscale/COGNAC) using [osc-api](https://github.com/outscale/osc-api) description.
# Contributing
Check [contributing documentation](CONTRIBUTING.md).
# License
> Copyright Outscale SAS
>
> BSD-3-ClauseThis project is compliant with [REUSE](https://reuse.software/).