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