https://github.com/valkryst/c_pthread
A wrapper which simplifies the creation and destruction of POSIX threads.
https://github.com/valkryst/c_pthread
pthread pthreads pthreads-wrapper thread-library threading
Last synced: 10 months ago
JSON representation
A wrapper which simplifies the creation and destruction of POSIX threads.
- Host: GitHub
- URL: https://github.com/valkryst/c_pthread
- Owner: Valkryst
- License: apache-2.0
- Created: 2022-03-09T18:30:59.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2022-03-09T18:34:02.000Z (almost 4 years ago)
- Last Synced: 2025-02-17T11:34:12.043Z (about 1 year ago)
- Topics: pthread, pthreads, pthreads-wrapper, thread-library, threading
- Language: C
- Homepage:
- Size: 6.84 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE.md
Awesome Lists containing this project
README
The foci of this repository are the [thread.c](https://github.com/Valkryst/C_PThread/blob/main/src/thread.c)
and [thread.h](https://github.com/Valkryst/C_PThread/blob/main/src/thread.h)
files. They simplify the creation and destruction of [POSIX Threads](https://en.wikipedia.org/wiki/Pthreads).
## Compiling
Add `thread.c` and `thread.h` to your project, and add
[-pthread flag](https://stackoverflow.com/a/2127819/13279616) to your compile
flags.
See the provided [Makefile](https://github.com/Valkryst/C_PThread/blob/main/Makefile)
as a reference.
## Dependencies
For development purposes, `thread.c` depends on my
[C_Logging](https://github.com/Valkryst/C_Logging) library. By replacing all
calls to `printError` in `thread.c`, you can remove this dependency.