wok-6.x view icedtea6-jdk/receipt @ rev 24235

updated perl-log-log4perl (1.49 -> 1.54)
author Hans-G?nter Theisgen
date Sun Jan 02 07:05:50 2022 +0100 (2022-01-02)
parents 3705d68ed8f3
children fff755dd0f58
line source
1 # SliTaz package receipt.
3 PACKAGE="icedtea6-jdk"
4 SOURCE="icedtea6"
5 VERSION="1.9.9"
6 CATEGORY="development"
7 SHORT_DESC="A Free Software harness for OpenJDK."
8 MAINTAINER="rcx@zoominternet.net"
9 LICENSE="GPL2"
10 TARBALL="$SOURCE-$VERSION.tar.gz"
11 WEB_SITE="http://www.iced-tea.org/"
12 WGET_URL="http://icedtea.wildebeest.org/download/source/$TARBALL"
14 DEPENDS="icedtea6-jre xorg xorg-libXtst xorg-libXp cups"
15 BUILD_DEPENDS="gcc+gcj autoconf automake m4 diffutils gawk cups-dev wget cpio \
16 coreutils-file-special coreutils-file-summarize alsa-lib-dev file patch perl \
17 zip unzip findutils bzip2 tar glib-dev fastjar rhino ecj apache-ant jpeg-dev \
18 xalan-xerces-j gtk+-dev giflib-dev libpng-dev xorg-dev xorg-libXtst-dev \
19 xorg-libXp-dev xorg-dev-proto nss nss-dev jdk6-jaxws jdk6-jaxp jdk6-jaf \
20 openjdk-6-src"
22 # Note to icedtea6 updaters,
23 # You should check version into receipts:
24 # * jdk6-jaxws (version: $openjdk_version)
25 # * jdk6-jaxp (version: $openjdk_version)
26 # * jdk6-jaf (version: $openjdk_version)
27 # * openjdk-6-src (version: $openjdk_version-$openjdk_date)
28 # Theses receipts allow to have source tarballs in SRC.
29 openjdk_version="b20"
30 openjdk_date="21_jun_2010"
31 EXTRA_SOURCE_FILES="jdk6-jaxws-$openjdk_version.zip \
32 jdk6-jaxp-$openjdk_version.zip jdk6-jaf-$openjdk_version.zip \
33 openjdk-6-src-$openjdk_version-$openjdk_date.tar.gz"
35 current_version()
36 {
37 wget -O - $(dirname $WGET_URL) 2>/dev/null | \
38 sed "/$SOURCE-[0-9]/!d;/tar/!d;/rc[0-9]/d;s|.*$SOURCE-\\(.*\\).tar.*\".*|\\1|" | sort -Vr | sed q
39 }
41 # Rules to configure and make the package.
42 compile_rules()
43 {
44 # Limit memory usage
45 ulimit -v $(awk '/MemTotal/ { print int(($2*80)/100) }' < /proc/meminfo)
47 local JVM_PREFIX
48 JVM_PREFIX="/usr/lib/jvm/java-icedtea"
50 # NOTE: This build does not seem to work with ECJ 3.5
51 local ECJ_VERSION
52 ECJ_VERSION="3.6"
54 find $src -name '*akefile*' \; | xargs sed -i sed -i 's|uname -m|echo i486|'
55 cd $src
56 mkdir drops
57 sed -i -e 's/mkdir -p drops/true/' -e 's/ jar xf/ fastjar xf/' Makefile*
59 # Check than all sources files are available, or exit.
60 REPO=http://icedtea.wildebeest.org/download/drops
61 if [ -x /usr/bin/cook ]; then
62 for i in jdk6-jaxws jdk6-jaxp jdk6-jaf; do
63 [ -s $SOURCES_REPOSITORY/$i-$openjdk_version.zip ] ||
64 wget -P $SOURCES_REPOSITORY $REPO/$i-$openjdk_version.zip
65 cp $SOURCES_REPOSITORY/$i-$openjdk_version.zip drops || return 1
66 done
67 # openjdk-6-src is in BUILD_DEPENDS and must be build like jdk6-* pkgs.
68 [ -s $SOURCES_REPOSITORY/openjdk-6-src-$openjdk_version-$openjdk_date.tar.gz ] ||
69 wget -P $SOURCES_REPOSITORY $REPO/openjdk-6-src-$openjdk_version-$openjdk_date.tar.gz
70 cp $SOURCES_REPOSITORY/openjdk-6-src-$openjdk_version-$openjdk_date.tar.gz .
71 else
72 report open-bloc
73 for i in jdk6-jaxws jdk6-jaxp jdk6-jaf openjdk-6-src; do
74 tazwok get-src $i
75 cp $SOURCES_REPOSITORY/$i-$openjdk_version.zip drops
76 done
77 cp $SOURCES_REPOSITORY/openjdk-6-src-$openjdk_version-$openjdk_date.tar.gz .
78 report step "Running compilation"
79 fi
81 mem=$(free | awk '/Mem:/ { printf "%d\n",$2/1024 }')
82 cat > slitaz.sh <<EOT
83 # disable currency timebomb
84 find -name GenerateCurrencyData.java | xargs sed -i 's|throw new RuntimeException("time is|System.err.println("time is|' 2> /dev/null
85 find -name CurrencyData.properties | xargs sed -i 's/TR=TRL.*/TR=TRY/' 2> /dev/null
86 # Busybox compatibility
87 #find -name Sanity.gmk | xargs sed -i 's/--sync -kP/-k/' Makefile
88 find -name Platform.gmk | xargs sed -i "s@MB_OF_MEMORY *:=.*free.*@MB_OF_MEMORY := $mem@" Makefile
89 EOT
90 sed -i -e 's|touch .*|&\n\tsh slitaz.sh|' \
91 -e 's/--check/-c/' \
92 -e 's/Bsymbolic/& -lgcj/' \
93 -e 's/ln -sfv/ln -sf/' Makefile*
94 aclocal
95 autoconf &&
96 automake --add-missing &&
97 {
98 ./configure \
99 --prefix=/usr \
100 --disable-plugin \
101 --disable-docs \
102 --with-ecj \
103 --with-ecj-jar=/usr/share/java/ecj-$ECJ_VERSION.jar \
104 --with-gcj \
105 --with-gcj-home=/usr/lib/jvm/java-gcj \
106 --with-xalan2-jar=/usr/share/java/xalan.jar \
107 --with-xalan2-serializer-jar=/usr/share/java/serializer.jar \
108 --with-xerces2-jar=/usr/share/java/xercesImpl.jar \
109 --with-rhino=/usr/share/java/js.jar \
110 --with-abs-install-dir=$JVM_PREFIX \
111 $CONFIGURE_ARGS || return 1
112 make -j 1 ARCH_PREFIX= 2>&1 | sed '/java_lang_ClassLoaderr.NativeLibrary/d'
113 } 2>&1 | sed 's/No such file/no such file/'
115 echo "Copying needed files to install dir..."
116 rm -rf $DESTDIR
118 local JVM_BUILDDIR
119 JVM_BUILDDIR=$src/openjdk.build/j2sdk-image
120 local JVM_DESTDIR
121 JVM_DESTDIR=${DESTDIR}$JVM_PREFIX
122 echo "OpenJDK build : source/openjdk.build/j2sdk-image"
123 echo "OpenJDK install : install/$JVM_PREFIX"
125 echo "Copying JDK files : bin/ lib/"
126 mkdir -p $JVM_DESTDIR
127 cp -a $JVM_BUILDDIR/bin $JVM_DESTDIR
128 cp -a $JVM_BUILDDIR/lib $JVM_DESTDIR
130 echo "Copying JRE files : bin/ lib/"
131 mkdir -p $JVM_DESTDIR/jre
132 cp -a $JVM_BUILDDIR/jre/bin $JVM_DESTDIR/jre
133 cp -a $JVM_BUILDDIR/jre/lib $JVM_DESTDIR/jre
135 # Delete duplicated executables from the JDK bin
136 echo "Deleting duplicated files..."
137 for jbin in $(ls -1 $JVM_DESTDIR/jre/bin) ; do
138 rm -f $JVM_DESTDIR/bin/$jbin
139 done
141 # Create symlinks for JDK binaries
142 echo "Creating symlinks for JDK binaries..."
143 mkdir -p $DESTDIR/usr/jdk-bin
144 for jbin in $(ls -1 $JVM_DESTDIR/bin) ; do
145 ln -s $JVM_PREFIX/bin/$jbin $DESTDIR/usr/jdk-bin/$jbin
146 done
148 # Create symlinks for JRE binaries
149 echo "Creating symlinks for JRE binaries..."
150 mkdir -p $DESTDIR/usr/jre-bin
151 for jbin in $(ls -1 $JVM_DESTDIR/jre/bin) ; do
152 ln -s $JVM_PREFIX/jre/bin/$jbin $JVM_DESTDIR/bin/$jbin
153 ln -s $JVM_PREFIX/jre/bin/$jbin $DESTDIR/usr/jre-bin
154 done
155 if [ ! -x /usr/bin/cook ]; then
156 report close-bloc
157 fi
158 }
160 # Rules to gen a SliTaz package suitable for Tazpkg.
161 genpkg_rules()
162 {
163 mkdir -p $fs/usr/lib/jvm/java-icedtea
164 cp -a $install/usr/lib/jvm/java-icedtea/bin $fs/usr/lib/jvm/java-icedtea
165 cp -a $install/usr/lib/jvm/java-icedtea/lib $fs/usr/lib/jvm/java-icedtea
166 }