Libft is a custom implementation of the standard C library functions. This project is part of the 42 curriculum and aims to help students understand the inner workings of common C functions by re-implementing them from scratch.
- Introduction
- Installation
- Quick start
- Usage
- Known issues and limitations
- Getting help
- Contributing
- License
- Acknowledgments
Libft is a project that involves creating a library of standard C functions. The goal is to re-implement functions from the standard C library, as well as some additional utility functions that are commonly used in C programming. This project helps students at 42 understand how these functions work under the hood and gain a deeper understanding of C programming.
To use Libft, you need to have a C compiler installed on your system. The following instructions will guide you through the installation process:
-
Clone the repository:
git clone https://github.com/yourusername/libft.git cd libft
-
Compile the library:
make
-
The compiled library
libft.a
will be created in the root directory of the project.
To use Libft in your project, follow these steps:
-
Include the header file in your source code:
#include "libft.h"
-
Link the compiled library when compiling your project:
gcc -o your_program your_program.c -L. -lft
Libft provides a variety of functions that can be used in your C programs. Here are some examples:
-
String manipulation functions:
char *str = ft_strdup("Hello, world!"); ft_strcpy(dest, src);
-
Memory management functions:
void *mem = ft_memalloc(size); ft_memdel(&mem);
-
List manipulation functions:
t_list *list = ft_lstnew(content, content_size); ft_lstadd(&list, new);
Libft also includes additional utility functions such as:
ft_atoi
ft_isalpha
ft_strsplit
ft_putchar_fd
- And many more...
Refer to the header file libft.h
for a complete list of available functions and their descriptions.
None are known at this time.
If you encounter any issues or have questions, you can open an issue on the GitHub repository.
Contributions are welcome! Please read the CONTRIBUTING.md file for guidelines on how to contribute to this project.
This project is licensed under the terms of the Creative Commons 1.0 Universal license (CC0).
This project is part of the 42 curriculum. Special thanks to the 42 community for their support and resources.