I describe here a ground-up set of steps to get shinpei0208/gdev to compile and load on
Ubuntu 11.04 with a GeForce GTX 550 Ti (NVC0) card.
1.) Install Ubuntu 11.04 Server. Run apt-get upgrade and apt-get dist-upgrade
(ending up running kernel 2.6.38-15-server)
2.) Download the mainline kernel source using the procedure described here
(stop after step 3): https://wiki.ubuntu.com/KernelTeam/GitKernelBuild
3.) Checkout the v3.3 version of the kernel source tree:
linux$ git checkout -f v3.3
4.) Proceed with kernel build procedure. Run 'make localmodconfig' prior to step 6
to cull unused modules.
5.) In menuconfig, make sure DRM is enabled under Device Drivers -> Graphics Support.
Also, make sure that Nouveau is set to build as a module
(under Device Drivers -> Staging Drivers).
6.) Proceed with the kernel build steps. Install the built packages.
Step 12 is redundant.
7.) Boot the newly built 3.3 kernel.
7a.) If you want to run pscnv instead of patching nouveau, add blacklist entries for
'nouveau' and 'ttm' in /etc/modprobe.d/blacklist.conf to prevent nouveau from
loading at boot time.
8.) Install the CUDA toolkit from Nvidia (this gives you the nvcc compiler
- not the proprietary driver).
9.) Pull down gdev:
$ git clone git://github.com/shinpei0208/gdev.git
10.) Pull down envytools:
$ git clone git://github.com/pathscale/envytools.git
11.) Install envytools deps:
$ sudo apt-get install cmake libxml2 libxml2-dev libpciaccess-dev flex bison pkg-config
12.) Install envytools per directions in gdev Readme.md
From this point on, the instructions in the gdev Readme will mostly work.
A few remaining issues with the build system that require some tweaking are mentioned below.
I have yet to get the pscnv driver to work. I'm able to compile it, but it fails at
Until I get past the pscnv issue, the only driver I've been able to get to work is the
nouveau driver from the kernel v3.3 source tree (patched with gdev-nouveau.patch from
Gdev Module: must copy gdev_interface.h to build directory for build to succeed.
Cuda Driver API (kcuda): - need to add '-I /usr/include' to Makefile EXTRA_CLFAGS
(after running cmake to generate the Makefile)
actually, the file that wants to include sys/errno.h above can be compiled in either kernel or user context. I've patched the file in question to properly include the right file.