Skip to content

Commit

Permalink
11-readme-clean-up
Browse files Browse the repository at this point in the history
* Added instructions to build sigfn in README
* Added instructiosnt to run unit tests in README
  • Loading branch information
a6guerre committed Dec 22, 2024
1 parent 027ba9f commit 00c69ab
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,22 @@ Bind callback functions to OS signals in C and C++.
SigFn should work in any system with the standard C library,
which provides the `<signal.h>` header.

## Building Unit Tests
```bash
cd <sigfn_root_dir>
mkdir build && cd build
cmake .. -DSIGFN_TESTS=ON
make
```

## Running Unit Tests
```bash
cd <signfn_root_dir>/build/tests
./unit <unit-test-name>
# e.g.
./unit sigfn_handle
```

## Usage

SigFn usage is similar to the `os/signal` package from Golang.
Expand Down Expand Up @@ -113,4 +129,4 @@ int main(int argc, const char **argv)
}
return 0;
}
```
```

0 comments on commit 00c69ab

Please sign in to comment.