Compare commits

...

3 Commits

Author SHA1 Message Date
4f2537b58f add: re rule 2024-08-29 16:20:03 +02:00
93a824ab30 add: debug flag asm 2024-08-29 16:19:20 +02:00
2062a09d21 fix: test rule makefile 2024-08-29 16:15:52 +02:00

View File

@ -6,10 +6,10 @@ SRC := $(wildcard $(SRCDIR)/*.asm)
OBJ := $(patsubst $(SRCDIR)/%.asm,$(OBJDIR)/%.o,$(SRC))
CC = gcc
CFLAGS =
CFLAGS = -g
AS = nasm
ASFLAGS = -f elf64
ASFLAGS = -f elf64 -g
AR = ar
ARFLAGS =
@ -23,9 +23,8 @@ $(OBJDIR)/%.o: $(SRCDIR)/%.asm
all : $(NAME)
test : $(NAME)
$(CC) $(CFLAGS) test/test.c $(NAME) -o $(BUILDDIR)/test
$(CC) $(CFLAGS) test/test.c $(BUILDDIR)/$(NAME) -o $(BUILDDIR)/test
$(BUILDDIR)/test
rm -rf $(BUILDDIR)/test
clean :
rm -rf $(OBJDIR)
@ -37,4 +36,6 @@ $(NAME) : $(OBJ)
mkdir -p $(BUILDDIR)
$(AR) -rc $(BUILDDIR)/$(NAME) $(OBJ)
.PHONY: clean fclean test all
re: fclean all
.PHONY: clean fclean test all re