| 1 |
include ../config.mak |
| 2 |
include ../suffixes-rule |
| 3 |
|
| 4 |
CFLAGS+=-I.. -I../IMdkit/include |
| 5 |
GCIN_MODULE=intcode-module.so |
| 6 |
|
| 7 |
ifeq ($(USE_ANTHY),Y) |
| 8 |
GCIN_MODULE+=anthy-module.so |
| 9 |
CFLAGS+=-DGCIN_MODULE=1 |
| 10 |
endif |
| 11 |
|
| 12 |
ifeq ($(USE_CHEWING),Y) |
| 13 |
GCIN_MODULE+=chewing-module.so |
| 14 |
CHEWING_DATADIR=$(shell pkg-config --variable=datadir chewing) |
| 15 |
CFLAGS += -DCHEWING_DATADIR=\"$(CHEWING_DATADIR)\" |
| 16 |
endif |
| 17 |
|
| 18 |
all: $(GCIN_MODULE) |
| 19 |
|
| 20 |
anthy_module_so = anthy.pico |
| 21 |
anthy-module.so: $(anthy_module_so) |
| 22 |
$(CCLD) $(SO_FLAGS) -o $@ $(anthy_module_so) $(LDFLAGS) -lanthy |
| 23 |
|
| 24 |
intcode_module_so = intcode.pico win-int.pico |
| 25 |
intcode-module.so: $(intcode_module_so) |
| 26 |
$(CCLD) $(SO_FLAGS) -o $@ $(intcode_module_so) $(LDFLAGS) |
| 27 |
|
| 28 |
chewing_module_obj = chewing-conf.pico |
| 29 |
chewing_module_so = chewing.pico gcin-setup-chewing.pico |
| 30 |
chewing-module.so: $(chewing_module_obj) $(chewing_module_so) |
| 31 |
$(CCLD) $(SO_FLAGS) -o $@ $(chewing_module_obj) $(chewing_module_so) $(LDFLAGS) $(shell pkg-config --cflags --libs chewing) |
| 32 |
|
| 33 |
install: |
| 34 |
install $(GCIN_MODULE) $(gcinlibdir) |
| 35 |
|
| 36 |
clean: |
| 37 |
rm -f *.pico *.so *.o .depend |
| 38 |
.depend: |
| 39 |
$(CCX) $(CFLAGS) -MM *.cpp > $@ |
| 40 |
|
| 41 |
include .depend |