dev-java/oracle-jre-bin: Trim the commercial fat
authorJames Le Cuirot <chewi@gentoo.org>
Mon, 23 Jan 2017 22:27:02 +0000 (22:27 +0000)
committerJames Le Cuirot <chewi@gentoo.org>
Mon, 23 Jan 2017 22:52:26 +0000 (22:52 +0000)
Package-Manager: Portage-2.3.3, Repoman-2.3.1

dev-java/oracle-jre-bin/metadata.xml
dev-java/oracle-jre-bin/oracle-jre-bin-1.8.0.121.ebuild

index 87c0c72cc0cffddf59b17e0676dff5226e6041ad..8442caf9ee0cfcacf40e42af40d806cb88b3df0e 100644 (file)
@@ -7,6 +7,7 @@
   </maintainer>
   <longdescription>Oracle Java SE Runtime Environment, Official Binary Distribution</longdescription>
   <use>
+    <flag name="commercial">Install features requiring a commercial license for production use</flag>
     <flag name="headless-awt">Don't install the X backend for AWT, needed by some GUIs (used to be X flag)</flag>
     <flag name="javafx">Install JavaFX libraries</flag>
     <flag name="jce">Install Java Cryptographic Extension Unlimited Strength Jurisdiction Policy Files</flag>
index e40a4da8edf9606ccb9d1a48fab35610cd3a800c..5808f5e700af15e78198135289c027ed3db09ac9 100644 (file)
@@ -35,7 +35,7 @@ SRC_URI="
 LICENSE="Oracle-BCLA-JavaSE"
 SLOT="1.8"
 KEYWORDS="~amd64 ~x86"
-IUSE="alsa cups +fontconfig headless-awt javafx jce nsplugin selinux"
+IUSE="alsa commercial cups +fontconfig headless-awt javafx jce nsplugin selinux"
 
 RESTRICT="fetch preserve-libs strip"
 QA_PREBUILT="*"
@@ -141,6 +141,10 @@ src_install() {
                rm -vf lib/*/libjsoundalsa.* || die
        fi
 
+       if ! use commercial; then
+               rm -vfr lib/jfr* || die
+       fi
+
        if use headless-awt ; then
                rm -vf lib/*/lib*{[jx]awt,splashscreen}* \
                   bin/{javaws,policytool} || die