]> git.sven.stormbind.net Git - sven/java-package.git/blobdiff - make-jpkg
update changelog for manpage updates
[sven/java-package.git] / make-jpkg
index 7173cb5ea7e2e219c7a1e32df8348b1ac7d28f39..0533b95d109a6c0b4719ba8230cebc8d641aa892 100755 (executable)
--- a/make-jpkg
+++ b/make-jpkg
@@ -15,8 +15,8 @@ lib_dir="/usr/share/java-package"
 [ "$J2SE_PACKAGE_LIBDIR" ] && lib_dir="$J2SE_PACKAGE_LIBDIR"
 
 # If a default has been set for either of the
-# environment variables, use it; otherwise, 
-# default to the name and email used by the 
+# environment variables, use it; otherwise,
+# default to the name and email used by the
 # Debian Java Maintainers project.
 if [ -z "$J2SE_PACKAGE_FULL_NAME" ]; then
     maintainer_name="Debian Java Maintainers"
@@ -31,6 +31,8 @@ else
 fi
 
 genchanges=""
+build_source=""
+jce_archive=""
 
 ### check for run in fakeroot
 
@@ -71,20 +73,24 @@ $program_name builds a Debian package from the given Java binary distribution FI
 
 Supported java binary distributions currently include:
   * Oracle (http://www.oracle.com/technetwork/java/javase/downloads) :
-    - The Java Development Kit (JDK), version 6 and 7
-    - The Java Runtime Environment (JRE), version 6 and 7
-    - The Java API Javadoc, version 6 and 7
+    - The Java Development Kit (JDK), version 6, 7 and 8
+    - The Java Runtime Environment (JRE), version 6, 7 and 8
+    - The Java API Javadoc, version 6, 7 and 8
   (Choose tar.gz archives or self-extracting archives, do _not_ choose the RPM!)
 
 The following options are recognized:
 
-  --full-name NAME   full name used in the maintainer field of the package
-  --email EMAIL      email address used in the maintainer field of the package
-  --changes          create a .changes file
-  --revision         add debian revision
+  --full-name NAME     full name used in the maintainer field of the package
+  --email EMAIL        email address used in the maintainer field of the package
+  --distribution       Define the distribution to use in the changelog
+  --changes            create a .changes file
+  --revision           add debian revision
+  --source             build a source package instead of a binary deb package
+  --with-system-certs  integrate with the system's keystore
+  --jce-policy FILE    Replace cryptography files with versions from FILE
 
-  --help             display this help and exit
-  --version          output version information and exit
+  --help               display this help and exit
+  --version            output version information and exit
 
 EOF
 }
@@ -113,6 +119,10 @@ while [[ $# -gt 0 && "x$1" == x--* ]]; do
     elif [[ "x$1" == x--help ]]; then
     print_usage
     exit 0
+    elif [[ "x$1" == x--jce-policy ]]; then
+    [ $# -le 1 ] && missing_argument "$1"
+    shift
+    jce_archive="$1"
     elif [[ "x$1" == x--full-name ]]; then
     [ $# -le 1 ] && missing_argument "$1"
     shift
@@ -121,12 +131,20 @@ while [[ $# -gt 0 && "x$1" == x--* ]]; do
     [ $# -le 1 ] && missing_argument "$1"
     shift
     maintainer_email="$1"
+    elif [[ "x$1" == x--distribution ]]; then
+    [ $# -le 1 ] && missing_argument "$1"
+    shift
+    distribution="$1"
     elif [[ "x$1" == x--revision ]]; then
     [ $# -le 1 ] && missing_argument "$1"
     shift
     revision="-${1}"
     elif [[ "x$1" == x--changes ]]; then
     genchanges="true"
+    elif [[ "x$1" == x--source ]]; then
+    build_source="true"
+    elif [[ "x$1" == x--with-system-certs ]]; then
+    create_cert_softlinks="true"
     else
     unrecognized_option "$1"
     fi
@@ -155,6 +173,9 @@ archive_name="$( basename "$archive" )"
 archive_dir="$( cd "$( dirname "$archive" )" ; pwd )"
 archive_path="$archive_dir/$archive_name"
 
+jce_name="$( basename "$jce_archive" )"
+jce_dir="$( cd "$( dirname "$jce_archive" )" ; pwd )"
+jce_path="$jce_dir/$jce_name"
 
 # error handling
 
@@ -200,11 +221,11 @@ echo -n "Creating temporary directory: "
 tmp="$( mktemp -d -t "$program_name.XXXXXXXXXX" )"
 echo "$tmp"
 
-debian_dir="$tmp/debian"
-install -d -m 755 "$debian_dir"
+package_dir="$tmp/package"
+install -d -m 755 "$package_dir"
 
-install_dir="$tmp/install"
-install -d -m 755 "$install_dir"
+debian_dir="$package_dir/debian"
+install -d -m 755 "$debian_dir"
 
 # load and execute plugins
 echo -n "Loading plugins:"
@@ -219,11 +240,14 @@ echo
 # get architecture information
 get_architecture
 
+# get browser plugin directories
+get_browser_plugin_dirs
+
 jvm_base="/usr/lib/jvm/"
 javadoc_base="/usr/share/doc/"
 
 j2se_found=
-for var in ${!j2se_detect_*}; do 
+for var in ${!j2se_detect_*}; do
     eval "\$$var"
     if [[ "$j2se_found" == "true" ]]; then
     break;
@@ -232,7 +256,8 @@ done
 echo
 
 if [[ -z "$j2se_found" ]]; then
-    echo "No matching packaging method was found for $archive_name. Please make sure you are using a tar.gz or self-extracting archive"
+    echo "No matching packaging method was found for $archive_name."
+    echo "Please make sure you are using a tar.gz or a self-extracting archive"
 fi