commit 14cbd9ec6d94715820267b465b0e3f90a3c4f944
parent c7d731b8dd883f1f3ccc84f72f33415b05c3c1c1
Author: mehdi-norouzi <mehdeenoroozi@gmail.com>
Date: Mon, 10 Feb 2025 23:10:39 +0330
add README and build.sh for each exercise
Diffstat:
5 files changed, 16 insertions(+), 5 deletions(-)
diff --git a/.gitignore b/.gitignore
@@ -2,3 +2,4 @@
*.o
tags
bin
+infix
diff --git a/build.sh b/build.sh
@@ -1,5 +0,0 @@
-#!/bin/sh
-
-mkdir -p bin
-as --64 -g -o ./bin/rpn.o ./stack/postfix/rpn.s && ld -m elf_x86_64 ./bin/rpn.o -o ./bin/rpn.elf
-as --64 -g -o ./bin/wcx64e.o ./wcx64/wcx64e.s && ld -m elf_x86_64 ./bin/wcx64e.o -o ./bin/wcx64e.elf
diff --git a/elfer/README.md b/elfer/README.md
@@ -0,0 +1,8 @@
+## Elf constructor
+Create executable files by putting bytes together.
+
+```
+./build.sh
+./bin/elfer-hello.elf
+./bin/hello.elf
+```
diff --git a/stack/postfix/build.sh b/stack/postfix/build.sh
@@ -0,0 +1,3 @@
+#!/bin/sh
+mkdir -p bin
+as --64 -g -o ./bin/rpn.o ./rpn.s && ld -m elf_x86_64 ./bin/rpn.o -o ./bin/rpn.elf
diff --git a/wcx64/build.sh b/wcx64/build.sh
@@ -0,0 +1,4 @@
+#!/bin/sh
+
+mkdir -p bin
+as --64 -g -o ./bin/wcx64e.o ./wcx64e.s && ld -m elf_x86_64 ./bin/wcx64e.o -o ./bin/wcx64e.elf