wok view erlang/receipt @ rev 9288

erlang: get patch from slitaz mirror
author Pascal Bellard <pascal.bellard@slitaz.org>
date Wed Mar 16 21:28:31 2011 +0100 (2011-03-16)
parents 33ac204404ee
children c8b38336a4fe
line source
1 # SliTaz package receipt.
3 PACKAGE="erlang"
4 VERSION="R14B"
5 CATEGORY="development"
6 SHORT_DESC="Erlang programming language."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 SOURCE="otp_src"
9 TARBALL="${SOURCE}_$VERSION.tar.gz"
10 WEB_SITE="http://$PACKAGE.org/"
11 WGET_URL="${WEB_SITE}download/$TARBALL"
12 DEPENDS="ncurses libunixODBC"
13 BUILD_DEPENDS="perl ncurses-dev openssl-dev xorg-dev flex m4 java-jdk"
15 # Rules to configure and make the package.
16 compile_rules()
17 {
18 patch=${SOURCE}_${VERSION}_OTP-7738.patch
19 cd $src
20 [ -f $SOURCES_REPOSITORY/$patch ] && cp $SOURCES_REPOSITORY/$patch .
21 if [ ! -f $patch ]; then
22 wget http://mirror.slitaz.org/sources/packages/${patch:0:1}/$patch
23 cp $patch $SOURCES_REPOSITORY
24 fi
25 if [ ! -f done.$patch ]; then
26 patch -p1 < $patch || return 1
27 touch done.$patch
28 fi
29 export LANG=C
30 sed -i 's|./Install|sh -x Install|' Makefile*
31 ./configure --prefix=/usr --infodir=/usr/share/info \
32 --sysconfdir=/etc --mandir=/usr/share/man $CONFIGURE_ARGS &&
33 make -j 1 &&
34 make -j 1 INSTALL_PREFIX=$DESTDIR install || return 1
35 for i in _pkg/usr/lib/erlang/*/bin/erl _pkg/usr/lib/erlang/bin/erl \
36 _pkg/usr/lib/erlang/*/bin/start _pkg/usr/lib/erlang/bin/start
37 do
38 sed -i 's|^ROOTDIR=.*$|ROOTDIR=/usr/lib/erlang|' $i
39 done
40 for i in _pkg/usr/bin/* ; do
41 ln -sf $(readlink $i | sed 's|.*/_pkg||') $i
42 done
43 }
45 # Rules to gen a SliTaz package suitable for Tazpkg.
46 genpkg_rules()
47 {
48 cp -a $_pkg/usr $fs
49 }