about summary refs log tree commit diff
path: root/Makefile
diff options
context:
space:
mode:
authorPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2021-04-17 10:28:11 +0200
committerPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2021-04-17 10:28:11 +0200
commitb1ddaa81f28b8bbc62d6d50526e0935b173099eb (patch)
treee606c194f8eecdedf3f710ed097cadfe97d60122 /Makefile
downloadmd2html-b1ddaa81f28b8bbc62d6d50526e0935b173099eb.tar.gz
md2html-b1ddaa81f28b8bbc62d6d50526e0935b173099eb.zip
Init
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile14
1 files changed, 14 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..f0d9e30
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,14 @@
+CC=gcc
+CC_OPTS=-g -Os -static -nostdlib -nostdinc -fno-pie -no-pie -mno-red-zone -fno-omit-frame-pointer -pg -mnop-mcount
+INCLUDE=-fuse-ld=bfd -Wl,-T,ape/ape.lds -include ape/cosmopolitan.h ape/crt.o ape/ape.o ape/cosmopolitan.a
+
+all: cat.com
+
+cat.com.dbg: cat.c
+	$(CC) $(CC_OPTS) cat.c -o cat.com.dbg $(INCLUDE)
+
+cat.com: cat.com.dbg
+	objcopy -S -O binary cat.com.dbg cat.com
+
+clean:
+	rm cat.com cat.com.dbg