Skip to content

Commit

Permalink
Add suffix rules to Makefile and rename prompt.c to glados.c
Browse files Browse the repository at this point in the history
  • Loading branch information
TornadoCookie committed Jun 27, 2023
1 parent de5d14c commit 2d647d4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 16 deletions.
20 changes: 4 additions & 16 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,14 @@ LINUXCC=gcc
WIN32CC=x86_64-w64-mingw32-gcc
CFLAGS=-Wall -Werror

glados: prompt.c notes apply
$(LINUXCC) $< -o $@ $(CFLAGS)

notes: notes.c
$(LINUXCC) $^ -o $@ $(CFLAGS)

apply: apply.c
%:%.c
$(LINUXCC) $^ -o $@ $(CFLAGS)

glados.exe: prompt.c notes.exe apply.exe
$(WIN32CC) $< -o $@ $(CFLAGS)

notes.exe: notes.c
$(WIN32CC) $^ -o $@ $(CFLAGS)

apply.exe: apply.c
%.exe:%.c
$(WIN32CC) $^ -o $@ $(CFLAGS)

linux: glados
windows: glados.exe
linux: glados notes apply
windows: glados.exe notes.exe apply.exe

clean:
rm -f apply glados notes
Expand Down
File renamed without changes.

0 comments on commit 2d647d4

Please sign in to comment.