view java/jdc/Makefile @ 20:77ca609422f1

- first working build of new java binding
author cslag
date Wed, 30 Mar 2016 02:40:56 +0200
parents 3bfef07b0cd9
children 40a2c4198016
line wrap: on
line source

# should be .jnilib on os x, .dll on windows, etc. @@@
SO=libjdc.so

build: $(SO)

clean:
	rm org_dyncall_DC.h || true
	rm org/dyncall/DC.class || true
	rm $(SO) || true

$(SO): org_dyncall_DC.h org_dyncall_DC.c
	# @@@ support different compilers @@@ esp. on windows
	$(CC) -shared -fPIC -o $@ org_dyncall_DC.c

org_dyncall_DC.h: org/dyncall/DC.class
	javah org.dyncall.DC

org/dyncall/DC.class:
	cd org/dyncall/ && javac DC.java

.PHONY: build clean