Gentoo Archives: gentoo-commits

From: Guillaume Horel <guillaume.horel@×××××.com>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/sci:master commit in: sci-mathematics/scilab/files/, sci-mathematics/scilab/
Date: Sun, 29 Jun 2014 19:01:01
Message-Id: 1404068415.03814a8eb7cb48d814fc13210687f45bc32da2b0.guillaume_horel@gentoo
1 commit: 03814a8eb7cb48d814fc13210687f45bc32da2b0
2 Author: Guillaume Horel <guillaume.horel <AT> gmail <DOT> com>
3 AuthorDate: Sun Jun 29 18:58:59 2014 +0000
4 Commit: Guillaume Horel <guillaume.horel <AT> gmail <DOT> com>
5 CommitDate: Sun Jun 29 19:00:15 2014 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=03814a8e
7
8 sci-mathematics/scilab: support jdk1.8
9
10 Package-Manager: portage-2.2.10
11
12 ---
13 sci-mathematics/scilab/ChangeLog | 4 ++
14 .../scilab/files/scilab-5.5.0-jdk1.8.patch | 76 ++++++++++++++++++++++
15 sci-mathematics/scilab/scilab-5.5.0.ebuild | 3 +-
16 3 files changed, 82 insertions(+), 1 deletion(-)
17
18 diff --git a/sci-mathematics/scilab/ChangeLog b/sci-mathematics/scilab/ChangeLog
19 index cdfa696..53eed59 100644
20 --- a/sci-mathematics/scilab/ChangeLog
21 +++ b/sci-mathematics/scilab/ChangeLog
22 @@ -2,6 +2,10 @@
23 # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
24 # $Header: $
25
26 + 29 Jun 2014; Guillaume Horel <guillaume.horel@×××××.com>
27 + +files/scilab-5.5.0-jdk1.8.patch, scilab-5.5.0.ebuild:
28 + sci-mathematics/scilab: support jdk1.8
29 +
30 05 May 2014; Quentin Minster <quentin@×××××××.io> scilab-5.5.0.ebuild:
31 sci-mathematics/scilab: Fix minimum version dependency for jlatexmath
32
33
34 diff --git a/sci-mathematics/scilab/files/scilab-5.5.0-jdk1.8.patch b/sci-mathematics/scilab/files/scilab-5.5.0-jdk1.8.patch
35 new file mode 100644
36 index 0000000..856b1fd
37 --- /dev/null
38 +++ b/sci-mathematics/scilab/files/scilab-5.5.0-jdk1.8.patch
39 @@ -0,0 +1,76 @@
40 +diff -urN scilab-5.5.0-orig/build.incl.xml scilab-5.5.0/build.incl.xml
41 +--- scilab-5.5.0-orig/build.incl.xml 2014-06-29 14:31:51.791054076 -0400
42 ++++ scilab-5.5.0/build.incl.xml 2014-06-29 14:33:12.733269635 -0400
43 +@@ -84,17 +84,12 @@
44 + <target name="init">
45 + <!-- Check the version of Java. If it changes after the configure
46 + or if there is a mistake in the build system
47 +- -->
48 +- <fail message="JDK 1.6 or 1.7 required. Found ${ant.java.version}">
49 +- <condition>
50 +- <not>
51 +- <or>
52 +- <equals arg1="${ant.java.version}" arg2="1.6"/>
53 +- <equals arg1="${ant.java.version}" arg2="1.7"/>
54 +- </or>
55 +- </not>
56 +- </condition>
57 +- </fail>
58 ++ Note: all class names are the same as in m4/java.m4
59 ++ -->
60 ++ <available property="jdk1.6+" classname="java.util.ArrayDeque"/>
61 ++ <available property="jdk1.7+" classname="java.nio.file.Path"/>
62 ++ <available property="jdk1.8+" classname="java.util.stream.DoubleStream"/>
63 ++ <fail message="Require JDK 1.6 or higher. Found ${ant.java.version}" unless="jdk1.6+"/>
64 + <mkdir dir="${classes.dir}"/>
65 + <mkdir dir="${classes.test.dir}"/>
66 + <mkdir dir="${build.jar.dir}"/>
67 +diff -urN scilab-5.5.0-orig/configure.ac scilab-5.5.0/configure.ac
68 +--- scilab-5.5.0-orig/configure.ac 2014-06-29 14:32:03.700233944 -0400
69 ++++ scilab-5.5.0/configure.ac 2014-06-29 14:33:12.735269665 -0400
70 +@@ -805,7 +805,7 @@
71 + AC_JAVA_WITH_JDK
72 + AC_JAVA_DETECT_JVM
73 + case "$ac_java_jvm_version" in
74 +- 1.6 | 1.7)
75 ++ 1.6 | 1.7 | 1.8)
76 + ;;
77 + *)
78 + AC_MSG_ERROR([Wrong version of Java. Expected at least 1.6. Found $ac_java_jvm_version])
79 +diff -urN scilab-5.5.0-orig/m4/java.m4 scilab-5.5.0/m4/java.m4
80 +--- scilab-5.5.0-orig/m4/java.m4 2014-06-29 14:32:03.840236057 -0400
81 ++++ scilab-5.5.0/m4/java.m4 2014-06-29 14:33:12.736269680 -0400
82 +@@ -223,7 +223,7 @@
83 + #
84 + # VARIABLES SET:
85 + # JAVAC
86 +-# ac_java_jvm_version can be set to 1.4, 1.5, 1.6 or 1.7
87 ++# ac_java_jvm_version can be set to 1.4, 1.5, 1.6, 1.7, 1.8
88 + # ac_java_jvm_dir can be set to the jvm's root directory
89 + #
90 + # DEPENDS ON:
91 +@@ -307,6 +307,9 @@
92 + # The class java.nio.file.Path is new to 1.7
93 + AC_JAVA_TRY_COMPILE([import java.nio.file.Path;], , "no", ac_java_jvm_version=1.7)
94 +
95 ++ # The class java.util.stream.DoubleStream is new to 1.8
96 ++ AC_JAVA_TRY_COMPILE([import java.util.stream.DoubleStream;], , "no", ac_java_jvm_version=1.8)
97 ++
98 + if test "x$ac_java_jvm_version" = "x" ; then
99 + AC_MSG_ERROR([Could not detect Java version, 1.4 or newer is required])
100 + fi
101 +diff -urN scilab-5.5.0-orig/modules/javasci/Makefile.in scilab-5.5.0/modules/javasci/Makefile.in
102 +--- scilab-5.5.0-orig/modules/javasci/Makefile.in 2014-06-29 14:32:00.613187355 -0400
103 ++++ scilab-5.5.0/modules/javasci/Makefile.in 2014-06-29 14:34:15.638203989 -0400
104 +@@ -976,10 +976,10 @@
105 + @echo "This command is intended for maintainers to use"
106 + @echo "it deletes files that may require special tools to rebuild."
107 + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
108 +-@JAVASCI_FALSE@distclean-local:
109 + @JAVASCI_FALSE@install-data-local:
110 + @JAVASCI_FALSE@install-html-local:
111 + @JAVASCI_FALSE@clean-local:
112 ++@JAVASCI_FALSE@distclean-local:
113 + clean: clean-am
114 +
115 + clean-am: clean-generic clean-libtool clean-local \
116
117 diff --git a/sci-mathematics/scilab/scilab-5.5.0.ebuild b/sci-mathematics/scilab/scilab-5.5.0.ebuild
118 index 3ea9058..38ad3e4 100644
119 --- a/sci-mathematics/scilab/scilab-5.5.0.ebuild
120 +++ b/sci-mathematics/scilab/scilab-5.5.0.ebuild
121 @@ -117,7 +117,8 @@ src_prepare() {
122 "${FILESDIR}/${P}-gluegen.patch" \
123 "${FILESDIR}/${P}-fix-random-runtime-failure.patch" \
124 "${FILESDIR}/${P}-accessviolation.patch" \
125 - "${FILESDIR}/${P}-nogui.patch"
126 + "${FILESDIR}/${P}-nogui.patch" \
127 + "${FILESDIR}/${P}-jdk1.8.patch"
128
129 append-ldflags $(no-as-needed)