Skip to content

Commit

Permalink
Removed redundant link option --oformat binary
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffreyc2017 committed Jul 16, 2024
1 parent c3719dc commit af0adef
Show file tree
Hide file tree
Showing 79 changed files with 675 additions and 675 deletions.
4 changes: 2 additions & 2 deletions projects/21_day/harib18b/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,12 +98,12 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@ -T $(HRB_LDS)


hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)



Expand Down
6 changes: 3 additions & 3 deletions projects/21_day/harib18c/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,17 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@ -T $(HRB_LDS)


hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)


crack1.hrb: crack1.c
$(CC) $(APP_CFLAGS) -c crack1.c -o crack1.obj
$(LD) $(APP_LDFLAGS) --oformat binary crack1.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) crack1.obj -o $@ -T $(HRB_LDS)


haribote.img: ipl10.bin haribote.sys \
Expand Down
6 changes: 3 additions & 3 deletions projects/21_day/harib18d/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,17 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@ -T $(HRB_LDS)


hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)


crack1.hrb: crack1.c
$(CC) $(APP_CFLAGS) -c crack1.c -o crack1.obj
$(LD) $(APP_LDFLAGS) --oformat binary crack1.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) crack1.obj -o $@ -T $(HRB_LDS)


haribote.img: ipl10.bin haribote.sys \
Expand Down
6 changes: 3 additions & 3 deletions projects/21_day/harib18e/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,17 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@ -T $(HRB_LDS)


hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)


crack1.hrb: crack1.c
$(CC) $(APP_CFLAGS) -c crack1.c -o crack1.obj
$(LD) $(APP_LDFLAGS) --oformat binary crack1.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) crack1.obj -o $@ -T $(HRB_LDS)


haribote.img: ipl10.bin haribote.sys \
Expand Down
6 changes: 3 additions & 3 deletions projects/21_day/harib18f/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,17 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@ -T $(HRB_LDS)


hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)


crack1.hrb: crack1.c
$(CC) $(APP_CFLAGS) -c crack1.c -o crack1.obj
$(LD) $(APP_LDFLAGS) --oformat binary crack1.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) crack1.obj -o $@ -T $(HRB_LDS)


crack2.hrb: crack2.nas
Expand Down
6 changes: 3 additions & 3 deletions projects/21_day/harib18g/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,15 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@

hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@

crack1.hrb: crack1.c a_nask.obj
$(CC) $(APP_CFLAGS) -c crack1.c -o crack1.obj
$(LD) $(APP_LDFLAGS) --oformat binary crack1.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) crack1.obj a_nask.obj -o $@

crack2.hrb: crack2.nas
$(NASM) $(NASM_FLAGS) -f bin -o $@ $< -l crack2.lst
Expand Down
6 changes: 3 additions & 3 deletions projects/22_day/harib19a/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,15 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@

hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@

crack1.hrb: crack1.c a_nask.obj
$(CC) $(APP_CFLAGS) -c crack1.c -o crack1.obj
$(LD) $(APP_LDFLAGS) --oformat binary crack1.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) crack1.obj a_nask.obj -o $@

crack2.hrb: crack2.nas
$(NASM) $(NASM_FLAGS) -f bin -o $@ $< -l crack2.lst
Expand Down
6 changes: 3 additions & 3 deletions projects/22_day/harib19b/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,15 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@

hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@

bug1.hrb: a_nask.obj bug1.c
$(CC) $(APP_CFLAGS) -c bug1.c -o bug1.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug1.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) bug1.obj a_nask.obj -o $@

haribote.img: ipl10.bin haribote.sys \
hello.hrb hello2.hrb a.hrb hello3.hrb bug1.hrb
Expand Down
10 changes: 5 additions & 5 deletions projects/22_day/harib19c/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,23 +98,23 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@

hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@

bug1.hrb: a_nask.obj bug1.c
$(CC) $(APP_CFLAGS) -c bug1.c -o bug1.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug1.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) bug1.obj a_nask.obj -o $@

bug2.hrb: bug2.c
$(CC) $(APP_CFLAGS) -c bug2.c -o bug2.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug2.obj -o $@
$(LD) $(APP_LDFLAGS) bug2.obj -o $@

bug3.hrb: a_nask.obj bug3.c
$(CC) $(APP_CFLAGS) -c bug3.c -o bug3.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug3.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) bug3.obj a_nask.obj -o $@

haribote.img: ipl10.bin haribote.sys \
hello.hrb hello2.hrb a.hrb hello3.hrb bug1.hrb bug2.hrb bug3.hrb
Expand Down
12 changes: 6 additions & 6 deletions projects/22_day/harib19d/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,27 +98,27 @@ a_nask.obj: a_nask.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@

hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@

hello4.hrb: a_nask.obj hello4.c
$(CC) $(APP_CFLAGS) -c hello4.c -o hello4.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello4.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) hello4.obj a_nask.obj -o $@

bug1.hrb: a_nask.obj bug1.c
$(CC) $(APP_CFLAGS) -c bug1.c -o bug1.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug1.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) bug1.obj a_nask.obj -o $@

bug2.hrb: bug2.c
$(CC) $(APP_CFLAGS) -c bug2.c -o bug2.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug2.obj -o $@
$(LD) $(APP_LDFLAGS) bug2.obj -o $@

bug3.hrb: a_nask.obj bug3.c
$(CC) $(APP_CFLAGS) -c bug3.c -o bug3.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug3.obj a_nask.obj -o $@
$(LD) $(APP_LDFLAGS) bug3.obj a_nask.obj -o $@

haribote.img: ipl10.bin haribote.sys \
hello.hrb hello2.hrb a.hrb hello3.hrb bug1.hrb bug2.hrb bug3.hrb \
Expand Down
14 changes: 7 additions & 7 deletions projects/22_day/harib19e/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -95,33 +95,33 @@ hello2.hrb: hello2.nas

a.hrb: a_nask.obj a.c
$(CC) $(APP_CFLAGS) -c a.c -o a.obj
$(LD) $(APP_LDFLAGS) --oformat binary a.obj a_nask.obj -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) a.obj a_nask.obj -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

hello3.hrb: a_nask.obj hello3.c
$(CC) $(APP_CFLAGS) -c hello3.c -o hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) hello3.obj a_nask.obj -o $@ -T $(HRB_LDS)

hello4.hrb: a_nask.obj hello4.c
$(CC) $(APP_CFLAGS) -c hello4.c -o hello4.obj
$(LD) $(APP_LDFLAGS) --oformat binary hello4.obj a_nask.obj -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) hello4.obj a_nask.obj -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

hello5.hrb: hello5.nas
# In order to use the app.lds for linking, split the nasm command into two steps commands.
# $(NASM) $(NASM_FLAGS) -f bin -o $@ $< -l hello5.lst
$(NASM) $(NASM_FLAGS) -f elf32 -o hello5.obj $< -l hello5.lst
$(LD) $(APP_LDFLAGS) --oformat binary hello5.obj -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) hello5.obj -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

bug1.hrb: a_nask.obj bug1.c
$(CC) $(APP_CFLAGS) -c bug1.c -o bug1.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug1.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) bug1.obj a_nask.obj -o $@ -T $(HRB_LDS)

bug2.hrb: bug2.c
$(CC) $(APP_CFLAGS) -c bug2.c -o bug2.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug2.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) bug2.obj -o $@ -T $(HRB_LDS)

bug3.hrb: a_nask.obj bug3.c
$(CC) $(APP_CFLAGS) -c bug3.c -o bug3.obj
$(LD) $(APP_LDFLAGS) --oformat binary bug3.obj a_nask.obj -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) bug3.obj a_nask.obj -o $@ -T $(HRB_LDS)

haribote.img: ipl10.bin haribote.sys \
hello.hrb hello2.hrb a.hrb hello3.hrb bug1.hrb bug2.hrb bug3.hrb \
Expand Down
16 changes: 8 additions & 8 deletions projects/22_day/harib19f/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -97,49 +97,49 @@ a.obj: a.c
$(CC) $(APP_CFLAGS) -c $< -o $@

a.hrb: a_nask.obj a.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

hello3.obj: hello3.c
$(CC) $(APP_CFLAGS) -c $< -o $@

hello3.hrb: a_nask.obj hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ -T $(HRB_LDS)

hello4.obj: hello4.c
$(CC) $(APP_CFLAGS) -c $< -o $@

hello4.hrb: a_nask.obj hello4.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

hello5.obj: hello5.nas
$(NASM) $(NASM_FLAGS) -f elf32 -o hello5.obj $< -l hello5.lst

hello5.hrb: hello5.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

winhelo.obj: winhelo.c
$(CC) $(APP_CFLAGS) -c winhelo.c -o winhelo.obj

winhelo.hrb: a_nask.obj winhelo.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

bug1.obj: bug1.c
$(CC) $(APP_CFLAGS) -c $< -o $@

bug1.hrb: a_nask.obj bug1.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ -T $(HRB_LDS)

bug2.obj: bug2.c
$(CC) $(APP_CFLAGS) -c $< -o $@

bug2.hrb: bug2.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ -T $(HRB_LDS)

bug3.obj: bug3.c
$(CC) $(APP_CFLAGS) -c $< -o $@

bug3.hrb: a_nask.obj bug3.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ -T $(HRB_LDS)

haribote.img: ipl10.bin haribote.sys \
hello.hrb hello2.hrb a.hrb hello3.hrb bug1.hrb bug2.hrb bug3.hrb \
Expand Down
12 changes: 6 additions & 6 deletions projects/22_day/harib19g/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -97,37 +97,37 @@ a.obj: a.c
$(CC) $(APP_CFLAGS) -c $< -o $@

a.hrb: a_nask.obj a.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

hello3.obj: hello3.c
$(CC) $(APP_CFLAGS) -c $< -o $@

hello3.hrb: a_nask.obj hello3.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ -T $(HRB_LDS)

hello4.obj: hello4.c
$(CC) $(APP_CFLAGS) -c $< -o $@

hello4.hrb: a_nask.obj hello4.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

hello5.obj: hello5.nas
$(NASM) $(NASM_FLAGS) -f elf32 -o hello5.obj $< -l hello5.lst

hello5.hrb: hello5.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

winhelo.obj: winhelo.c
$(CC) $(APP_CFLAGS) -c $< -o $@

winhelo.hrb: a_nask.obj winhelo.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS)

winhelo2.obj: winhelo2.c
$(CC) $(APP_CFLAGS) -c $< -o $@

winhelo2.hrb: a_nask.obj winhelo2.obj
$(LD) $(APP_LDFLAGS) --oformat binary $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS) -Map $(basename $@).map -e STACK_SIZE=1024
$(LD) $(APP_LDFLAGS) $^ -o $@ --defsym=STACK_SIZE=1024 -T $(HRB_LDS) -Map $(basename $@).map -e STACK_SIZE=1024

haribote.img: ipl10.bin haribote.sys \
hello.hrb hello2.hrb a.hrb hello3.hrb hello4.hrb hello5.hrb \
Expand Down
Loading

0 comments on commit af0adef

Please sign in to comment.