#!/usr/bin/make -f

export VERSION = $(shell head -1 debian/changelog | cut -f2 -d\( | cut -f1 -d\) | cut -f1 -d\-)

include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/ant.mk
include /usr/share/cdbs/1/rules/simple-patchsys.mk

include /usr/share/gcj/debian_defaults
ifneq (,$(filter $(DEB_HOST_ARCH), $(gcj_native_archs)))
  with_gcj_native := yes
endif

#JAVA_HOME := /usr/lib/jvm/default-java
#JAVA_HOME := /usr/lib/jvm/java-gcj
JAVA_HOME := /usr/lib/jvm/java-6-sun
ANT_HOME := /usr/share/ant

DEB_JARS := $(ANT_HOME)/lib/ant-nodeps.jar commons-logging commons-discovery commons-codec ibatis axis postgresql-jdbc3

DEB_ANT_BUILD_TARGET := compile javadocs
DEB_ANT_INSTALL_TARGET := 

ifeq ($(with_gcj_native),yes)
install/openpts-core-gcj:: install/openpts-core
	[ -d debian/openpts-core/usr/share/java ] || dh_install -popenpts-core
	dh_nativejava -popenpts-core-gcj
endif






