Skip to content
This repository has been archived by the owner on Dec 30, 2022. It is now read-only.

Commit

Permalink
Makefile: Use CC instead of LD
Browse files Browse the repository at this point in the history
  • Loading branch information
noriyotcp committed Mar 29, 2018
1 parent 1fe71ec commit b26f132
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ sources:

$(KERNEL): musl build_dirs $(CRYSTAL_OS) $(OBJECTS) $(LIB)
mkdir -p $(KERNEL_DIR)
$(LD) --nmagic --output=$@ --script=$(LINKER) $(CRYSTAL_OS) $(OBJECTS) $(LIB) $(EXT_MUSL)/lib/libc.a
$(CC) -Xlinker --nmagic -T$(LINKER) $(CRYSTAL_OS) -o $(KERNEL) $(OBJECTS) $(LIB) -L$(EXT_MUSL)/lib

build/asm/%.o: asm/%.asm
$(NASM) -f elf64 $< -o $@
Expand All @@ -51,7 +51,7 @@ build/src/%.o: src/%.c
$(CC) $(CFLAGS) -c $< -o $@

$(CRYSTAL_OS): $(CRYSTAL_SOURCES)
crystal build src/kernel/main.cr --cross-compile --target $(TARGET) --prelude=empty --verbose
$(CRYSTAL) build src/kernel/main.cr --cross-compile -Dgc_none --prelude=empty --target $(TARGET) --verbose
mv -f main.o $@

$(LIB): $(SOURCES)
Expand Down

0 comments on commit b26f132

Please sign in to comment.