wok-current view catalyst/receipt @ rev 4604
vlc: spin off libvlc & libvlc-dev
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Tue Dec 15 16:03:36 2009 +0100 (2009-12-15) |
parents | |
children | 39011a13b555 |
line source
1 # SliTaz package receipt.
3 PACKAGE="catalyst"
4 VERSION="9-11"
5 CATEGORY="network"
6 MAINTAINER="jozee@slitaz.org"
7 SHORT_DESC="AMD/ATI beta drivers (non-free) for Radeon brand cards "
8 WEB_SITE="http://www.ati.amd.com"
9 DEPENDS="xorg-server mesa"
10 BUILD_DEPENDS="linux xorg-server"
11 TARBALL="ati-driver-installer-$VERSION-x86.x86_64.run"
12 TAGS="drivers graphic video"
14 # Rules to configure and make the package.
16 compile_rules() {
18 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
19 WGET_URL="http://www2.ati.com/drivers/linux/$TARBALL"
21 [ -d $WOK/linux/taz ] || tazwok cook linux
23 cd $WOK/$PACKAGE
24 [ -f $TARBALL ] || wget $WGET_URL
26 chmod +x $TARBALL
27 [ -d $PACKAGE-$VERSION ] || sh $TARBALL --extract $PACKAGE-$VERSION
29 cd $src/common/lib/modules/fglrx/build_mod
30 cp $src/arch/x86/lib/modules/fglrx/build_mod/libfglrx_ip.a.GCC4 .
31 cp 2.6.x/Makefile .
32 make -C $WOK/linux/linux-$KERNEL_VERSION SUBDIRS="`pwd`" modules
33 }
35 # Rules to gen a SliTaz package suitable for Tazpkg.
36 genpkg_rules()
37 {
38 KERNEL_VERSION=`grep ^VERSION= $WOK/linux/receipt | cut -d "=" -f2 | sed -e 's/"//g'`
39 EXTRAVERSION=_$KERNEL_VERSION
41 mkdir -p $fs/usr/share/pixmaps \
42 $fs/usr/bin \
43 $fs/usr/lib/xorg/modules \
44 $fs/usr/share/licenses/$PACKAGE \
45 $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/video \
46 $fs/etc
48 # Compress and install module
49 lzma e $src/common/lib/modules/fglrx/build_mod/fglrx.ko \
50 $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/video/fglrx.ko.gz
51 chown root $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/video/fglrx.ko.gz
52 chmod 0644 $fs/lib/modules/$KERNEL_VERSION-slitaz/kernel/drivers/video/fglrx.ko.gz
54 cp -a $src/ATI_LICENSE.TXT $fs/usr/share/licenses/$PACKAGE
56 cp -a $src/x740/usr/X11R6/lib/modules $fs/usr/lib/xorg
58 cp -a $src/arch/x86/usr/lib/*.so $fs/usr/lib/
59 cp -a $src/arch/x86/usr/sbin $fs/usr
60 cp -a $src/arch/x86/usr/X11R6/bin/* $fs/usr/bin/
62 cp -a $src/arch/x86/usr/X11R6/lib/*.so* $fs/usr/lib
63 cp -a $src/arch/x86/usr/X11R6/lib/modules $fs/usr/lib/xorg
65 cp -a $src/common/etc $fs
66 chmod 755 $fs/etc/ati/authatieventsd.sh
67 cp -a $src/common/usr/sbin $fs/usr
69 cp -a $src/common/usr/share/icons/* $fs/usr/share/pixmaps
70 cp -a $src/common/usr/share/applications $fs/usr/share
71 cp -a $src/common/usr/share/doc $fs/usr/share
72 cp -a $src/common/usr/share/ati $fs/usr/share
73 cp -a $src/common/usr/X11R6/bin/* $fs/usr/bin
76 }
78 pre_install()
79 {
80 echo ""
81 echo -e "\033[1m PROPRIETARY LICENSE:\033[0m $2"
82 echo "================================================================================"
83 echo "You are installing a package with proprietary license."
84 echo "You must accept the license."
85 echo "================================================================================"
86 echo ""
88 }
90 post_install()
91 {
92 echo "Processing post-install commands..."
93 chroot "$1/" depmod -a ${EXTRAVERSION#_}-slitaz
95 ln -sf $1/usr/lib/xorg/modules/dri $1/usr/lib/dri
96 ln -sf $1/usr/lib/libfglrx_dm.so.1.0 $1/usr/lib/libfglrx_dm.so.1
97 ln -sf $1/usr/lib/libfglrx_pp.so.1.0 $1/usr/lib/libfglrx_pp.so.1
98 ln -sf $1/usr/lib/libfglrx_tvout.so.1.0 $1/usr/lib/libfglrx_tvout.so.1
99 ln -sf $1/usr/lib/libfglrx_gamma.so.1.0 $1/usr/lib/libfglrx_gamma.so.1
100 ln -sf $1/usr/lib/libGL.so.1.2 $1/usr/lib/libGL.so.1
101 ln -sf $1/usr/lib/libGL.so.1.2 $1/usr/lib/libGL.so
103 echo ""
104 echo -e "\033[1m ATI LICENSE INFORMATION:\033[0m $2"
105 echo "================================================================================"
106 echo "For installing this package, you have to accept the $PACKAGE license."
107 echo "The license is stored in /usr/share/licenses/$PACKAGE "
108 echo -n "Would you like to read the license (y/N) : "; read anser
109 if [ "$anser" = "y" ]; then
110 cat /usr/share/licenses/"$PACKAGE"/ATI_LICENSE.txt | more
111 echo ""
112 fi
113 echo "================================================================================"
114 echo -n "Do you accept the license (y/N) : "; read anser
115 if [ "$anser" = "N" ]; then
116 echo "You did not accept the license, Removing the pkg."
117 tazpkg remove "$PACKAGE"
118 fi
121 }
123 post_remove()
124 {
125 echo "Processing post-remove commands..."
126 depmod -a
127 }