pkglib_LTLIBRARIES = bindings/java/libmegajava.la

bindings_java_libmegajava_la_LIBADD = $(top_builddir)/src/libmega.la
bindings_java_libmegajava_la_DEPENDENCIES = $(top_builddir)/src/libmega.la
bindings_java_libmegajava_la_CPPFLAGS = -I@JAVA_INCLUDE_DIR@ -I@JAVA_INCLUDE_DIR_LINUX@ -I$(top_srcdir)/include
nodist_bindings_java_libmegajava_la_SOURCES = bindings/java/megaapi_wrap.cpp
bindings_java_libmegajava_la_SOURCES = $(top_srcdir)/bindings/megaapi.i

CLEANFILES += bindings/java/megaapi_wrap.cpp
CLEANFILES += bindings/java/megaapi_wrap.h
CLEANFILES += bindings/java/nz/mega/sdk/java_mega.h
CLEANFILES += bindings/java/nz/mega/sdk/mega.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaAccountBalance.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaAccountDetails.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaAccountPurchase.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaAccountSession.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaAccountTransaction.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaApi.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaError.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaGfxProcessor.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaGlobalListener.java
CLEANFILES += bindings/java/nz/mega/sdk/megaJNI.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaListener.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaLogger.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaNode.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaNodeList.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaPricing.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaProxy.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaRequest.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaRequestListener.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaShare.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaShareList.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaTransfer.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaTransferListener.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaTransferList.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaTreeProcessor.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaUser.java
CLEANFILES += bindings/java/nz/mega/sdk/MegaUserList.java

bindings/java/megaapi_wrap.cpp: $(top_srcdir)/bindings/megaapi.i
	$(SWIG) -java -package nz.mega.sdk -outdir $(top_srcdir)/bindings/java/nz/mega/sdk -I$(top_srcdir)/include -o $@ $(top_srcdir)/bindings/megaapi.i
