Skip to content

Commit 3bc77c6

Browse files
authored
usage.md: add an explanation about header-only libs (#1073)
Add an explanation about header-only libraries in the `Install dependencies` section.
1 parent d0a85e7 commit 3bc77c6

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

docs/usage.md

+14-4
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,20 @@ Cabin uses a cache since we executed the command with no changes.
5252
5353
Like Cargo does, Cabin installs dependencies at build time. Cabin currently supports Git, path, and system dependencies. You can use two ways to add dependencies to your project: using the `cabin add` command and editing `cabin.toml` directly.
5454
55+
> [!WARNING]
56+
> - Cabin currently supports building a project with header-only dependencies.
57+
> - Building with build-required dependencies will be soon supported.
58+
59+
> [!NOTE]
60+
> A header-only library is a type of library where the entire functionality is contained within header files, and no additional compilation steps are required. This means you can directly include the library's headers in your project without needing to link against any compiled binaries.
61+
>
62+
> These libraries require the headers to be in the root or include/ directory. This ensures that the library's header files are accessible in a predictable location for easy inclusion in your project.
63+
>
64+
> Here are some links that can help you find header-only libraries:
65+
> - https://github.com/topics/single-header
66+
> - https://github.com/topics/header-only
67+
> - https://github.com/p-ranav/awesome-hpp
68+
5569
### `cabin add`
5670
5771
The `cabin add` command accepts the following arguments:
@@ -100,10 +114,6 @@ Downloaded ToruNiina/toml11 846abd9a49082fe51440aa07005c360f13a67bbf
100114
Finished debug target(s) in 0.70s
101115
```
102116
103-
> [!WARNING]
104-
> Cabin currently supports building a project with header-only dependencies.
105-
> Building with build-required dependencies will be soon supported.
106-
107117
## Unit tests
108118
109119
You can write unit tests in any source files within the `src` directory. Create a new file like:

0 commit comments

Comments
 (0)