diff --git a/Makefile b/Makefile index 5eb56d9..56bc1fc 100644 --- a/Makefile +++ b/Makefile @@ -1,22 +1,15 @@ -ifdef UNAME_S -UNAME_S := $(UNAME_S) -else +ifndef UNAME_S UNAME_S := $(shell uname -s) endif -ifdef UNAME_P -UNAME_P := $(UNAME_P) -else +ifndef UNAME_P UNAME_P := $(shell uname -p) endif -ifdef UNAME_M -UNAME_M := $(UNAME_M) -else +ifndef UNAME_M UNAME_M := $(shell uname -m) endif - # Mac OS + Arm can report x86_64 # ref: https://github.com/ggerganov/whisper.cpp/issues/66#issuecomment-1282546789 ifeq ($(UNAME_S),Darwin) @@ -93,7 +86,7 @@ main: examples/main/main.cpp ggml.o whisper.o ./main -h ggml.o: ggml.c ggml.h - $(CC) $(CFLAGS) -c ggml.c -o ggml.o + $(CC) $(CFLAGS) -c ggml.c -o ggml.o whisper.o: whisper.cpp whisper.h $(CXX) $(CXXFLAGS) -c whisper.cpp -o whisper.o