llvm-project/lldb/packages/Python/lldbsuite/test/macosx/find-app-in-bundle/Makefile

22 lines
485 B
Makefile

SRCDIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))/
CC ?= clang
ifeq "$(ARCH)" ""
ARCH = x86_64
endif
CFLAGS ?= -g -O0 -arch $(ARCH)
all: TestApp.app/Contents/MacOS/TestApp
TestApp.app/Contents/MacOS/TestApp: $(SRCDIR)/main.c
$(CC) $(CFLAGS) -o TestApp $<
rm -rf TestApp.app
cp -r $(SRCDIR)/TestApp.app .
mv TestApp TestApp.app/Contents/MacOS/TestApp
mv TestApp.dSYM TestApp.app.dSYM
clean:
rm -rf TestApp.app/Contents/MacOS/TestApp TestApp.app.dSYM