Files
archived-hidapi/testgui/Makefile.mac
Alan Ott bab22b7ac1 Convert to Cocoa for event handling on the Test GUI on Mac
Carbon is no good on 10.5 and later on 64-bit. Github user
dportabella found a workaround in Cocoa[1], and I added code
to make it handle the events from the dock, like the carbon
version did.

[1] https://github.com/signal11/hidapi/issues/14
2011-09-13 10:48:39 +08:00

41 lines
851 B
Makefile

###########################################
# Simple Makefile for HIDAPI test program
#
# Alan Ott
# Signal 11 Software
# 2010-07-03
###########################################
all: testgui
CC=gcc
CXX=g++
COBJS=../mac/hid.o
CPPOBJS=test.o
OBJCOBJS=mac_support_cocoa.o
OBJS=$(COBJS) $(CPPOBJS) $(OBJCOBJS)
CFLAGS=-I../hidapi -Wall -g -c `fox-config --cflags`
LIBS=`fox-config --libs` -framework IOKit -framework CoreFoundation -framework Cocoa
testgui: $(OBJS)
g++ -Wall -g $^ $(LIBS) -o testgui
./copy_to_bundle.sh
#cp TestGUI.app/Contents/MacOS/testgui TestGUI.app/Contents/MacOS/tg
#cp start.sh TestGUI.app/Contents/MacOS/testgui
$(COBJS): %.o: %.c
$(CC) $(CFLAGS) $< -o $@
$(CPPOBJS): %.o: %.cpp
$(CXX) $(CFLAGS) $< -o $@
$(OBJCOBJS): %.o: %.m
$(CXX) $(CFLAGS) -x objective-c++ $< -o $@
clean:
rm $(OBJS) testgui
.PHONY: clean