blob: 2f3cc9700e108b3bffab6047408cbacc1257dae1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
# This package compiles and stages only the Jar
SUMMARY = "JDT Core Batch Compiler - Jar only"
HOMEPAGE = "http://www.eclipse.org/"
LICENSE = "EPL-1.0"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/EPL-1.0;md5=57f8d5e2b3e98ac6e088986c12bf94e6"
DEPENDS = "classpath-initial-native fastjar-native jikes-initial-native virtual/java-initial-native"
INC_PR = "r5"
inherit java native
S = "${WORKDIR}"
JAR = "ecj-bootstrap-${PV}.jar"
do_unpackpost[dirs] = "${B}"
do_unpackpost() {
mkdir -p source
mkdir -p build
# Remove crap.
rm -f about.html build.xml
rm -rf META-INF
# Move source into separate subdir.
if [ -d org -a ! -d source/org ]; then
mv org source/
fi
# Remove stuff unneeded for the bootstrap compiler.
rm -rf source/org/eclipse/jdt/internal/compiler/apt
rm -rf source/org/eclipse/jdt/internal/compiler/tool
rm -rf source/org/eclipse/jdt/internal/antadapter
rm -f source/org/eclipse/jdt/core/JDTCompilerAdapter.java
# Make a copy of the remaining source to get the embedded
# resources.
cp -R source/org build/
# Remove source code and other stuff.
find build -depth \( -name '*.java' -o -name '*.html' \) -delete
}
addtask unpackpost after do_unpack before do_patch
do_compile() {
# Compiling in place is done because the sources contain
# property files which need to be available at runtime.
find source -name '*.java' -print0 \
| LC_ALL=C sort -z \
| xargs -0 -n25 -P ${BB_NUMBER_THREADS} \
jikes-initial -d build -source 1.4 -sourcepath source
fastjar -c -C build . -f ${JAR}
}
do_compile[vardepsexclude] += "BB_NUMBER_THREADS"
do_install() {
oe_jarinstall ${JAR} ecj-bootstrap.jar
}
|