This is a C implementation (a bit hacky) that provides an useful interface to create, delete and modify the internal dynamically allocated c array to use it like a C++ Vector
π Homepage
- Table of Contents
- Direct Download
- Build From Source π¨
- Usage
- Author
- π€ Contributing
- π License
build from source it is fun
OR
git clone https://github.com/Kushal-Chandar/C-Vector.git
mkdir build
cd build
cmake -S .. -B .
make sure your are in build directory, if you are getting errors
ninja
Requires Cmake and Ninja added to path
Run install.sh in the project root folder
If you don't have git bash or have errors while running the install.sh.
Run the following commands in windows powershell.
mkdir c_vector
mkdir c_vector/lib
cp build/libc_vector.a c_vector/lib/
cp -r include c_vector
Copy the contents in c_vector/include and c_vector/lib to a folder where your compiler searches for includes and directories.
Example:
-
copy contents of c_vector/include to path/to/mingw64/include
-
copy contents of c_vector/lib to path/to/mingw64/lib
and Compile with
gcc file.c -lc_vector
OR
Compile with
gcc file.c -I"path to c_vector/include/c_implementations without quotes" -L"path to c_vector/lib/libc_vector.a without quotes" -lc_vector
lookup how to specify include directories for your compiler
π Check examples and Reference
π€ Kushal Chandar
I have implemented basic and most common data-types
- Github: @Kushal-Chandar
- LinkedIn: @Kushal Chandar
Contributions, issues and feature requests are welcome!
Feel free to check issues page.
Copyright Β© 2022 Kushal Chandar.
This project is GPLv3 licensed.