If you or your organisation has found oab-java.sh useful please consider
donating to this project. It is nice to have the effort I've put into this
script recognised, I don't ask for much, it is at your discretion.
Usage
sudo ./oab-java.sh
Optional parameters
-7 : Build oracle-java7 packages instead of sun-java6
-c : Remove pre-existing packages from /var/local/oab/deb and sources from /var/local/oab/src.
-k : Use the specified existing key instead of generating one
-s : Skip building if the packages already exist
-t : Specify the Java version tag to use from the upstream Debian packaging script.
Build the Java packages applicable to your system.
Create local apt repository in /var/local/oab/deb for the newly built Java Packages.
Create a GnuPG signing key in /var/local/oab/gpg if none exists.
Sign the local apt repository using the local GnuPG signing key.
What gets installed?
This script will no longer try and directly install or upgrade any Java
packages, instead a local apt repository is created that hosts locally
built Java packages applicable to your system. It is up to you to install
or upgrade the Java packages you require using apt-get, aptitude or
synaptic, etc. For example, once this script has been run you can simply
install the JRE by executing the following from a shell.
sudo apt-get install sun-java6-jre
Or if you ran the script with the -7 option.
sudo apt-get install oracle-java7-jre
If you already have the "official" Ubuntu packages installed then you
can upgrade by executing the following from a shell.
sudo apt-get upgrade
The local apt repository is just that, local. It is not accessible
remotely and oab-java.sh will never enable that capability to ensure
compliance with Oracle's asinine license requirements.
By default, the script creates a temporary GPG keyring in the working
directory. In order to use the current user's GPG chain instead, specify
the key ID of an existing secret key. Run gpg -K to list available keys.
Known Issues
Building Java 7 on Ubuntu Lucid 10.04 is no longer supported as the upstream scripts
require debhelper>=8 which is not officially available for Lucid.
The Oracle download servers can be horribly slow. My script caches the downloads
so you only need download each file once.
What is 'oab'?
Because, O.A.B! ;-)
History
0.3.0
Fixed download Java7 JCE. Thanks to Michał Kowalczuk.
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
请发表评论