source: npl/X/drv_nvidia/drv_nvidia.SlackBuild.dis

Last change on this file was c5c522c, checked in by Edwin Eefting <edwin@datux.nl>, 8 years ago

initial commit, transferred from cleaned syn3 svn tree

  • Property mode set to 100755
File size: 2.0 KB
Line 
1#!/bin/bash
2#Gebruik deze file als voorbeeld. Plaats de source tar.gz file in de zelfde directory als deze slackbuild
3#Met de NEED en DEP opties is het mogelijk om build dependencies aan te geven.
4#Voor de meeste packages hoeft er verder niks aan de variabellen veranderd te worden.
5##################################### Build dependency info:
6
7#DEP:linux_src
8#DEP:xorg_proto
9#DEP:xorg_xserver
10#DEP:linux
11
12#######Essential package info.
13#Change these if autodetection fails.
14
15#Name of the Syn-3 package that we are going to create
16NAME=`basename $0|sed 's/.SlackBuild//'`
17
18#Architecture that the created binaries run on.
19#Use noarch for scripts.
20ARCH=`uname -m`
21
22VER=`echo *run | cut -f4 -d-` || exit 1
23
24
25########Build and create the pacakge.
26#Uncomment the stuff that you dont want or need
27
28sh NVIDIA-Linux-*.run -x || exit 1
29cd NVIDIA* || exit 1
30
31#compile and install kernel module
32pushd kernel || exit 1
33make IGNORE_CC_MISMATCH=1 SYSSRC=/usr/src/linux module || exit 1
34mkdir -p /tmp/pkg/lib/modules/`uname -r`/video || exit 1
35cp nvidia.ko /tmp/pkg/lib/modules/`uname -r`/video || exit 1
36popd
37
38
39mkdir -p /tmp/pkg/usr/lib
40cp libvdpau* /tmp/pkg/usr/lib || exit 1
41cp libcuda* /tmp/pkg/usr/lib || exit 1
42
43mkdir -p /tmp/pkg/usr/X11/lib/xorg/modules/extensions
44cp libXvMCNVIDIA.so* /tmp/pkg/usr/X11/lib || exit 1
45cp libgl*so* /tmp/pkg/usr/X11/lib/xorg/modules/extensions || exit 1
46cp libGL*so* /tmp/pkg/usr/X11/lib/xorg/modules/extensions || exit 1
47
48mkdir -p /tmp/pkg/usr/X11/lib/xorg/modules/drivers
49cp nvidia_drv.so /tmp/pkg/usr/X11/lib/xorg/modules/drivers || exit 1
50
51mkdir -p /tmp/pkg/usr/bin
52cp nvidia-settings /tmp/pkg/usr/bin || exit 1
53chmod +x /tmp/pkg/usr/bin/*
54
55#symlinkje
56pushd /tmp/pkg/usr/X11/lib/xorg/modules
57ln -s libnvidia-wfb.so.* libwfb.so || exit 1
58popd
59
60cd ..
61
62#strip bins and other stuff
63syn3_strip /tmp/pkg || exit 1
64
65#move development stuff and create seperate development package
66#syn3_move_dev /tmp/pkg /tmp/pkgdev || exit 1
67#syn3_makepkg /tmp/pkgdev $NAME""_dev $VER $ARCH || exit 1
68
69#make main package
70syn3_makepkg /tmp/pkg $NAME $VER $ARCH || exit 1
71
72
Note: See TracBrowser for help on using the repository browser.