diff options
Diffstat (limited to 'Source/Applications/PaperWork/Makefile')
-rw-r--r-- | Source/Applications/PaperWork/Makefile | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/Source/Applications/PaperWork/Makefile b/Source/Applications/PaperWork/Makefile new file mode 100644 index 0000000..fe8d564 --- /dev/null +++ b/Source/Applications/PaperWork/Makefile @@ -0,0 +1,31 @@ +.PHONY: clean, mrproper + +CXX = g++ +CXXFLAGS = -nostartfiles -nostdlib -ffreestanding -fno-exceptions -fno-rtti -I ../../Library/Common -I ../../Library/Interface -I ../../Library/Userland -D THIS_IS_MELON_USERLAND + +LD = ld +LDFLAGS = -T ../../Library/Link.ld -L ../../Library + +Objects = main.o +OutFile = PaperWork + +all: $(OutFile) + echo "* Done with $(OutFile)." + +rebuild: mrproper all + +$(OutFile): $(Objects) + echo "* Linking $@..." + $(LD) $(LDFLAGS) $^ -o $@ + +%.o: %.cpp + echo "* Compiling $<..." + $(CXX) $(CXXFLAGS) -c $< -o $@ + +clean: + echo "* Removing object files..." + rm -rf *.o + +mrproper: clean + echo "* Removing applications..." + rm -rf $(OutFile) |