85b6971f83dd36e86f892ee1a9d3d136ecd2986e
[sven/java-package.git] / lib / jdk.sh
1
2 j2sdk_control() {
3     j2se_control
4     java_browser_plugin="java-browser-plugin, "
5     depends="\${shlibs:Depends}"
6     if [ "${DEB_BUILD_ARCH:0:3}" = "arm" ]; then
7         # ARM is only softfloat ATM so if building on armhf
8         # force the dependencies to pickup cross platform fu
9         if [ "${DEB_BUILD_ARCH}" == "armhf" ]; then
10             depends="libc6-armel, libsfgcc1, libsfstdc++6"
11         fi
12         # No browser on ARM yet
13         java_browser_plugin=""
14     fi
15     cat << EOF
16 Package: $j2se_package
17 Architecture: any
18 Depends: $depends
19 Recommends: netbase, libx11-6 | xlibs, libasound2, libgtk1.2, libstdc++5
20 Provides: java-virtual-machine, java-runtime, java2-runtime, java${j2se_release}-runtime, java$((${j2se_release}-1))-runtime, java$((${j2se_release}-2))-runtime, $java_browser_plugin java-compiler, java2-compiler, java-runtime-headless, java2-runtime-headless, java${j2se_release}-runtime-headless, java$((${j2se_release}-1))-runtime-headless, java$((${j2se_release}-2))-runtime-headless, java-sdk, java2-sdk, java$((${j2se_release}-2))-sdk, java$((${j2se_release}-1))-sdk, java${j2se_release}-sdk
21 Replaces: ${j2se_package}debian
22 Description: $j2se_title
23  The Java(TM) SE JDK is a development environment for building
24  applications, applets, and components that can be deployed on the
25  Java(TM) platform.
26  .
27  The Java(TM) SE JDK software includes tools useful for developing and
28  testing programs written in the Java programming language and running
29  on the Java platform. These tools are designed to be used from the
30  command line. Except for appletviewer, these tools do not provide a
31  graphical user interface.
32  .
33  This package has been automatically created with java-package ($version).
34 EOF
35 }
36
37 # build debian package
38 j2sdk_run() {
39     echo
40     diskfree "$j2se_required_space"
41     read_maintainer_info
42     j2se_package="$j2se_vendor-java$j2se_release-jdk"
43     j2se_name="jdk-$j2se_release-$j2se_vendor-$j2se_arch"
44     local target="$install_dir$jvm_base$j2se_name"
45     install -d -m 755 "$( dirname "$target" )"
46     extract_bin "$archive_path" "$j2se_expected_min_size" "$target"
47     rm -rf "$target/.systemPrefs"
48     echo "7" > "$debian_dir/compat"
49     j2se_readme > "$debian_dir/README.Debian"
50     j2se_changelog > "$debian_dir/changelog"
51     j2sdk_control > "$debian_dir/control"
52     j2se_copyright > "$debian_dir/copyright"
53     j2se_install_scripts
54     install -d "$target/debian"
55     j2se_info > "$target/debian/info"
56     eval "$j2se_jinfo" > "$install_dir$jvm_base.$j2se_name.jinfo"
57     j2se_build
58 }