diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..ff30b9d --- /dev/null +++ b/Makefile @@ -0,0 +1,75 @@ +# **************************************************************************** # +# # +# ::: :::::::: # +# Makefile :+: :+: :+: # +# +:+ +:+ +:+ # +# By: TheRed +#+ +:+ +#+ # +# +#+#+#+#+#+ +#+ # +# Created: 2024/09/27 14:52:58 by TheRed #+# #+# # +# Updated: 2024/09/27 14:52:58 by TheRed ### ########.fr # +# # +# **************************************************************************** # + +BLACK =  +RED =  +GREEN =  +YELLOW =  +BLUE =  +MAGENTA =  +CYAN =  +WHITE =  + +RESET =  + +LINE_CLR = \33[2K\r + +NAME := RT + +SRCS_DIR := srcs + +OBJS_DIR := .objs + +ALL_SRCS := RT.cpp \ + + +SRCS := $(ALL_SRCS:%=$(SRCS_DIR)/%) + + +OBJS := $(addprefix $(OBJS_DIR)/, $(SRCS:%.cpp=%.o)) + +CC := g++ + +IFLAGS := -Ofast -I./includes -L./lib -lglfw3 -lopengl32 -lgdi32 -lcglm + +RM := del /f /s /q + +MAKEFLAGS += --no-print-directory + +DIR_DUP = if not exist "$(@D)" mkdir "$(@D)" + +# RULES ********************************************************************** # + +all: $(NAME) + +$(NAME): $(OBJS) $(HEADERS) + @$(CC) -o $(NAME) $(OBJS) $(IFLAGS) + @echo $(WHITE) $(NAME): PROJECT COMPILED !$(RESET) & echo: + +$(OBJS_DIR)/%.o: %.cpp + @$(DIR_DUP) + @echo $(WHITE) $(NAME): $(WHITE)$<$(RESET) $(GREEN)compiling...$(RESET) + @$(CC) -c $^ $(IFLAGS) -o $@ + + +fclean: + @echo $(WHITE)$(NAME):$(RED) cleaned.$(RESET) + @del /f /s /q $(NAME).exe + @rmdir /S /Q "$(OBJS_DIR)" + +re: + @$(MAKE) fclean + @$(MAKE) all + +# **************************************************************************** # + +.PHONY: all clean fclean dclean re bonus \ No newline at end of file diff --git a/includes/RT.h b/includes/RT.h new file mode 100644 index 0000000..b4c08b7 --- /dev/null +++ b/includes/RT.h @@ -0,0 +1,18 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* RT.h :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: TheRed +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2024/09/27 14:52:10 by TheRed #+# #+# */ +/* Updated: 2024/09/27 14:52:10 by TheRed ### ########.fr */ +/* */ +/* ************************************************************************** */ + +#ifndef RT_H +# define RT_H + +# include + +#endif \ No newline at end of file diff --git a/lib/libcglm.a b/lib/libcglm.a new file mode 100644 index 0000000..454a59c Binary files /dev/null and b/lib/libcglm.a differ diff --git a/lib/libglfw3.a b/lib/libglfw3.a new file mode 100644 index 0000000..fee383d Binary files /dev/null and b/lib/libglfw3.a differ diff --git a/srcs/RT.cpp b/srcs/RT.cpp new file mode 100644 index 0000000..49fa310 --- /dev/null +++ b/srcs/RT.cpp @@ -0,0 +1,19 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* RT.c :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: TheRed +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2024/09/27 14:51:49 by TheRed #+# #+# */ +/* Updated: 2024/09/27 14:51:49 by TheRed ### ########.fr */ +/* */ +/* ************************************************************************** */ + +#include "RT.h" + +int main(void) +{ + std::cout << "Hello World!" << std::endl; + return (0); +} \ No newline at end of file