Skip to content

Instantly share code, notes, and snippets.

@yangniao23
Created January 15, 2024 02:06
Show Gist options
  • Save yangniao23/d53b6b308a5be2c5d4dd7d4a7451dc87 to your computer and use it in GitHub Desktop.
Save yangniao23/d53b6b308a5be2c5d4dd7d4a7451dc87 to your computer and use it in GitHub Desktop.
リバーシ Makefile メモ
NAME = reversi
TARGET = $(NAME).exe
SRCS = cpu.c hashmap.c mapio.c mapmanager.c tools.c $(NAME).c
OBJS = $(SRCS:.c=.o)
CC = gcc
CFLAGS = -Wall -O3 -march=native
RM = del /F /Q
all: $(TARGET)
.c.o:
$(CC) $(CFLAGS) -o $@ -c $<
$(TARGET): $(OBJS)
$(CC) $(CFLAGS) -o $(TARGET) $(OBJS)
clean:
$(RM) $(TARGET) $(OBJS)
@yangniao23
Copy link
Author

黒丸,白丸を Shift-JIS にする必要がある
BCC102開発環境だと全角になって表示が崩れるので Windows Terminal で実行する

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment