wok-next annotate nvidia-96xx/receipt @ rev 20199
Up firmware (fix some multiline or empty descriptions), gettext, gtk-theme-blackbird, libmpd, libmpdclient, openbox & openbox-max (keep default Clearlooks theme), xfce4-icon-theme, xfce4-taskmanager, xfmpc. terminal -> xfce4-terminal, xfce4-ristretto -> ristretto (weird, but we agreed to call packages according to sources tarballs).
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Fri Nov 03 16:28:49 2017 +0200 (2017-11-03) |
parents | 6fab3264ba87 |
children | d247e85339a4 |
rev | line source |
---|---|
psychomaniak@18171 | 1 # SliTaz package receipt. |
psychomaniak@18171 | 2 |
psychomaniak@18171 | 3 PACKAGE="nvidia-96xx" |
psychomaniak@18171 | 4 VERSION="96.43.23" |
psychomaniak@18171 | 5 CATEGORY="network" |
psychomaniak@18171 | 6 MAINTAINER="psychomaniak@xakep.ru" |
psychomaniak@18171 | 7 LICENSE="other" |
psychomaniak@18171 | 8 SHORT_DESC="NVIDIA-legacy drivers (from Geforce MX200 to 7950) (non-free)" |
psychomaniak@18171 | 9 WEB_SITE="http://www.nvidia.com/" |
psychomaniak@18171 | 10 SOURCE="NVIDIA-Linux-x86-${VERSION}-pkg0" |
psychomaniak@18171 | 11 TARBALL="${SOURCE}.run" |
psychomaniak@18171 | 12 WGET_URL="http://download.nvidia.com/XFree86/Linux-x86/$VERSION/$TARBALL" |
psychomaniak@18171 | 13 RUN_OPTS="--extract-only" |
psychomaniak@18171 | 14 TAGS="drivers graphic video" |
psychomaniak@18852 | 15 PROVIDE="mesa" |
psychomaniak@18171 | 16 |
psychomaniak@18171 | 17 DEPENDS="linux xorg-server gtk+ cairo linux-agp linux-drm" |
psychomaniak@18171 | 18 BUILD_DEPENDS="linux-module-headers coreutils-file-summarize xz" |
psychomaniak@18171 | 19 |
psychomaniak@18171 | 20 # Rules to configure and make the package. |
psychomaniak@18171 | 21 |
psychomaniak@18171 | 22 compile_rules() |
psychomaniak@18171 | 23 { |
psychomaniak@18171 | 24 cd $src/usr/src/nv/ |
psychomaniak@18171 | 25 # Only use .unblocked_ioctl since 2.6.36 |
psychomaniak@18171 | 26 sed -i 's|\.ioctl|// &|' nv.c |
psychomaniak@18171 | 27 make SYSSRC="/usr/src/linux" module 2>&1 | sed s'/ERROR:/error:/' && |
psychomaniak@18171 | 28 xz nvidia.ko |
psychomaniak@18171 | 29 } |
al@18741 | 30 |
psychomaniak@18171 | 31 # Rules to gen a SliTaz package suitable for Tazpkg. |
psychomaniak@18171 | 32 genpkg_rules() |
psychomaniak@18171 | 33 { |
psychomaniak@18171 | 34 EXTRAVERSION=_${kvers} |
psychomaniak@18171 | 35 |
psychomaniak@18171 | 36 mkdir -p $fs/usr/share $fs/usr/lib/X11 $fs/usr/share/licenses/$PACKAGE |
psychomaniak@18171 | 37 mkdir -p $fs/lib/modules/$kvers-slitaz/kernel/drivers/video |
al@18741 | 38 mkdir -p $fs/usr/share/doc/$PACKAGE |
al@18741 | 39 |
psychomaniak@18171 | 40 # Compress and install module |
psychomaniak@18171 | 41 cp $src/usr/src/nv/nvidia.ko.xz \ |
psychomaniak@18171 | 42 $fs/lib/modules/$kvers-slitaz/kernel/drivers/video/ |
psychomaniak@18171 | 43 |
psychomaniak@18171 | 44 chown root $fs/lib/modules/$kvers-slitaz/kernel/drivers/video/nvidia.ko.xz |
psychomaniak@18171 | 45 chmod 0644 $fs/lib/modules/$kvers-slitaz/kernel/drivers/video/nvidia.ko.xz |
psychomaniak@18171 | 46 |
psychomaniak@18171 | 47 cp -a $src/LICENSE $fs/usr/share/licenses/$PACKAGE |
psychomaniak@18171 | 48 cp -a $src/usr/bin $fs/usr |
psychomaniak@18171 | 49 cp -a $src/nvidia-installer $fs/usr/bin |
psychomaniak@18171 | 50 cp -a $src/usr/lib/*.so* $fs/usr/lib/ |
psychomaniak@18171 | 51 cp -a $src/usr/lib/tls $fs/usr/lib/ |
psychomaniak@18171 | 52 cp -a $src/usr/share/pixmaps $fs/usr/share |
psychomaniak@18171 | 53 cp -a $src/usr/share/doc/* $fs/usr/share/doc/$PACKAGE/ |
psychomaniak@18171 | 54 cp -a $src/usr/X11R6/lib/* $fs/usr/lib/X11 |
psychomaniak@18171 | 55 |
psychomaniak@18171 | 56 # Links |
al@18741 | 57 for i in $(find $fs -iname *.so*); do |
al@18741 | 58 ln -s $(basename $i) $(dirname $i)/$(basename ${i/so.${VERSION}/so/}) |
al@18741 | 59 ln -s $(basename $i) $(dirname $i)/$(basename ${i/so.${VERSION}/so.1/}) |
psychomaniak@18171 | 60 done |
psychomaniak@18852 | 61 |
psychomaniak@18852 | 62 # exclude from files.list (for tazpkg's "find-depends") |
psychomaniak@18852 | 63 cd $fs/usr/lib |
psychomaniak@18852 | 64 for i in $(ls libGL.so*) ; do mv -f $i ${i//./-.-} ; done |
psychomaniak@18171 | 65 } |
psychomaniak@18171 | 66 |
psychomaniak@18171 | 67 pre_install() |
psychomaniak@18171 | 68 { |
al@18741 | 69 title 'PROPRIETARY LICENSE' |
al@18741 | 70 echo 'You are installing a package with proprietary license.' |
al@18741 | 71 echo 'You must accept the license.' |
al@18741 | 72 footer |
psychomaniak@18171 | 73 } |
psychomaniak@18171 | 74 |
psychomaniak@18171 | 75 post_install() |
psychomaniak@18171 | 76 { |
psychomaniak@18852 | 77 # Restore excluded from files.list (for tazpkg's "find-depends") |
psychomaniak@18852 | 78 cd $1/usr/lib |
psychomaniak@18852 | 79 for i in $(ls libGL.so*) ; do mv -f $i ${i//-.-/.} ; done |
psychomaniak@18852 | 80 |
al@18741 | 81 newline |
psychomaniak@18171 | 82 chroot "$1/" depmod -a ${EXTRAVERSION#_}-slitaz |
psychomaniak@18171 | 83 |
psychomaniak@18171 | 84 # correct .desktop file file |
pascal@18730 | 85 sed -i 's:__UTILS_PATH__/::' "$1/usr/share/applications/nvidia-settings.desktop" |
pascal@18730 | 86 sed -i 's:__PIXMAP_PATH__/::' "$1/usr/share/applications/nvidia-settings.desktop" |
psychomaniak@18171 | 87 |
al@18741 | 88 title 'NVIDIA LICENSE INFORMATION' |
psychomaniak@18171 | 89 echo "For installing this package, you have to accept the $PACKAGE license." |
al@18741 | 90 echo "The license is stored in /usr/share/licenses/$PACKAGE " |
psychomaniak@18171 | 91 echo -n "Would you like to read the license (y/N) : "; read anser |
al@18741 | 92 if [ "$anser" == 'y' ]; then |
al@18741 | 93 more /usr/share/licenses/"$PACKAGE"/LICENSE |
al@18741 | 94 echo |
psychomaniak@18171 | 95 fi |
al@18741 | 96 separator |
psychomaniak@18171 | 97 echo -n "Do you accept the license (y/N) : "; read anser |
al@18741 | 98 if [ "$anser" == 'N' ]; then |
al@18741 | 99 echo "You did not accept the license, Removing the pkg." |
al@18741 | 100 tazpkg remove "$PACKAGE" |
psychomaniak@18171 | 101 fi |
psychomaniak@18171 | 102 } |
psychomaniak@18171 | 103 |
psychomaniak@18171 | 104 TAZBB_NO_INSTALL="because this is not hardware neutral" |