chore: comply with subject
This commit is contained in:
parent
8331a437c0
commit
bb43c3b95a
30
Makefile
30
Makefile
|
@ -1,5 +1,7 @@
|
|||
NAME = libasm
|
||||
|
||||
MAKE = make --no-print-directory
|
||||
|
||||
SRC = \
|
||||
ft_strlen.s \
|
||||
ft_strcpy.s \
|
||||
|
@ -7,34 +9,34 @@ SRC = \
|
|||
ft_write.s \
|
||||
ft_read.s \
|
||||
ft_strdup.s \
|
||||
ft_list_size.s \
|
||||
ft_list_push_front.s \
|
||||
ft_list_sort.s \
|
||||
ft_list_remove_if.s \
|
||||
ft_atoi_base.s \
|
||||
|
||||
SRCBONUS = \
|
||||
ft_list_size_bonus.s \
|
||||
ft_list_push_front_bonus.s \
|
||||
ft_list_sort_bonus.s \
|
||||
ft_list_remove_if_bonus.s \
|
||||
ft_atoi_base_bonus.s \
|
||||
|
||||
OBJ = $(SRC:.s=.o)
|
||||
OBJBONUS = $(SRCBONUS:.s=.o)
|
||||
|
||||
%.o:%.s
|
||||
nasm -f elf64 $< -o $@
|
||||
|
||||
all: $(NAME)
|
||||
|
||||
bonus: all
|
||||
bonus: $(OBJ) $(OBJBONUS)
|
||||
ar rcs libasm.a $(OBJ) $(OBJBONUS)
|
||||
|
||||
$(NAME): $(OBJ)
|
||||
ar rcs libasm.a $(OBJ)
|
||||
|
||||
test: $(NAME)
|
||||
gcc -Wall -Werror -Wextra -g ft_list_print.c main.c -L. -lasm -o libasm_unit_tests
|
||||
|
||||
clean:
|
||||
rm $(OBJ)
|
||||
rm -fv $(OBJ) $(OBJBONUS)
|
||||
|
||||
fclean:
|
||||
rm libasm.a
|
||||
rm libasm_unit_tests
|
||||
fclean: clean
|
||||
rm -fv libasm.a
|
||||
|
||||
re: fclean all
|
||||
|
||||
.PHONY: all test
|
||||
.PHONY: all bonus clean fclean re
|
||||
|
|
|
@ -1,9 +0,0 @@
|
|||
#include "libasm.h"
|
||||
#include <stdio.h>
|
||||
|
||||
void ft_list_print(t_list *begin_list) {
|
||||
while (begin_list) {
|
||||
printf("%s", (char *)begin_list->data);
|
||||
begin_list = begin_list->next;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue