From 0f3246e90a80c8100b485407ba6f8258deae45a1 Mon Sep 17 00:00:00 2001 From: f1ori Date: Fri, 3 Jul 2009 21:57:05 +0000 Subject: [PATCH] * fix debian package * add Class containing buildvariables git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@6171 6c8d7289-2bf4-0310-a012-ef5d649a1542 --- build.xml | 17 +++++++++---- debian/control | 2 +- debian/rules | 1 - .../de/anomic/yacy/yacyBuildProperties.java | 24 +++++++++++++++++++ 4 files changed, 37 insertions(+), 7 deletions(-) create mode 100644 source/de/anomic/yacy/yacyBuildProperties.java diff --git a/build.xml b/build.xml index 8fcd0ea07..236902f87 100644 --- a/build.xml +++ b/build.xml @@ -55,7 +55,9 @@ + + @@ -144,10 +146,13 @@ + + + @@ -193,14 +198,16 @@ - + + + + diff --git a/debian/control b/debian/control index 3258db581..d78a9aea2 100644 --- a/debian/control +++ b/debian/control @@ -2,7 +2,7 @@ Source: yacy Section: network Priority: extra Maintainer: root -Build-Depends: ant, sun-java5-jdk, debhelper (>= 5), m4 +Build-Depends: ant, sun-java5-jdk | openjdk-6-jdk, debhelper (>= 5), m4 Standards-Version: 3.7.2 Package: yacy diff --git a/debian/rules b/debian/rules index ac23ab944..cb2cfa196 100755 --- a/debian/rules +++ b/debian/rules @@ -32,7 +32,6 @@ install: ant installonlinux -DDESTDIR=$(CURDIR)/debian/yacy mkdir -p $(CURDIR)/debian/yacy/usr/share/java/yacy/ cp lib/*.jar $(CURDIR)/debian/yacy/usr/share/java/yacy/ - cp libx/*.jar $(CURDIR)/debian/yacy/usr/share/java/yacy/ #cp -r classes $(CURDIR)/debian/yacy/usr/share/java/yacy/ diff --git a/source/de/anomic/yacy/yacyBuildProperties.java b/source/de/anomic/yacy/yacyBuildProperties.java new file mode 100644 index 000000000..4bd0339e4 --- /dev/null +++ b/source/de/anomic/yacy/yacyBuildProperties.java @@ -0,0 +1,24 @@ +package de.anomic.yacy; +/** + * Properties set when compiling this release/version + */ +public class yacyBuildProperties { + private yacyBuildProperties() { + } + + public static String getSVNVersion() { + return "@REPL_REVISION_NR@"; + } + + public static String getVersion() { + return "@VERSION@"; + } + + /** + * determines, if this release was compiled and installed + * by a package manager + */ + public static boolean isPkgManager() { + return "@REPL_PKGMANAGER@".equals("true"); + } +}