debian swirl logo

Back to the packages list jts

#!/usr/bin/make -f
# debian/rules file for jts (uses cdbs)

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

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

JAVA_HOME := /usr/lib/jvm/default-java
JAVA_CMD := /usr/bin/java
ANT_HOME := /usr/share/ant

DEB_JARS := $(ANT_HOME)/lib/ant-launcher.jar
DEB_ANT_BUILDFILE := debian/build.xml
DEB_ANT_BUILD_TARGET := all
DEB_PATCHDIRS = debian/patches
DEB_PATCH_SUFFIX = .diff

install/libjts-java::
		install -m 644 target/jts.jar debian/libjts-java/usr/share/java/jts-$(UPSTREAM_VERSION).jar
		ln -s jts-$(UPSTREAM_VERSION).jar debian/libjts-java/usr/share/java/jts.jar

#
# Custom rule to create a clean tarball
#

download-upstream:
		-mkdir $(CURDIR)/upstream
		wget -O $(CURDIR)/upstream/jts-$(UPSTREAM_VERSION).zip \
		http://downloads.sourceforge.net/project/jts-topo-suite/jts/$(UPSTREAM_VERSION)/jts-$(UPSTREAM_VERSION).zip?use_mirror= garr

create-orig-tar: download-upstream
		cd $(CURDIR)/upstream && unzip -u -d jts-$(UPSTREAM_VERSION) jts-$(UPSTREAM_VERSION).zip && \
			rm -rf jts-$(UPSTREAM_VERSION)/lib && rm -rf jts-$(UPSTREAM_VERSION)/doc/javadoc && \
			find jts-$(UPSTREAM_VERSION)/doc -name "*.pdf" -delete && \
			tar czvf jts_$(UPSTREAM_VERSION).orig.tar.gz jts-$(UPSTREAM_VERSION) && \
			rm -rf jts-$(UPSTREAM_VERSION) jts-$(UPSTREAM_VERSION).zip
			-mkdir $(CURDIR)/../tarballs
			mv $(CURDIR)/upstream/jts_$(UPSTREAM_VERSION).orig.tar.gz $(CURDIR)/../tarballs/.
			rmdir $(CURDIR)/upstream

.PHONY: download-upstream create-orig-tar

Builds:

libjts-java-doc
documentation for the jts topology suite
libjts-java
jts topology suite