Hi, I tried using the ati_nonfree driver, but it crashed with a segfault on my machine. So I updated that driver to version 11-6-x86. Unfortunately, that version doesn't seem to work either. I reckon it's because I mis-configured it somehow. Anyway, attached below are the patches for the update, just in case someone else is using ati_nonfree.
Take care, Peter
>From cdfd9701af6f1ef88956d47c3be226dd31df1039 Mon Sep 17 00:00:00 2001 From: Peter Simons <[email protected]> Date: Thu, 14 Jul 2011 11:38:50 +0200 Subject: [PATCH 1/3] linux/ati-drivers: updated to version 11-6-x86 --- pkgs/os-specific/linux/ati-drivers/builder.sh | 2 +- pkgs/os-specific/linux/ati-drivers/default.nix | 20 ++++++++++---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/pkgs/os-specific/linux/ati-drivers/builder.sh b/pkgs/os-specific/linux/ati-drivers/builder.sh index 1fd6234..3799b03 100644 --- a/pkgs/os-specific/linux/ati-drivers/builder.sh +++ b/pkgs/os-specific/linux/ati-drivers/builder.sh @@ -148,7 +148,7 @@ GCC_MAJOR="`gcc --version | grep -o -e ") ." | head -1 | cut -d " " -f 2`" # what are those files used for? cp -r common/etc $out - DIR_DEPENDING_ON_XORG_VERSION=x750_64a + DIR_DEPENDING_ON_XORG_VERSION=xpic_64a cp -r $DIR_DEPENDING_ON_XORG_VERSION/usr/X11R6/$lib_arch/* $out/lib/xorg t=$out/lib/modules/${kernelVersion}/kernel/drivers/misc diff --git a/pkgs/os-specific/linux/ati-drivers/default.nix b/pkgs/os-specific/linux/ati-drivers/default.nix index 248e24c..d39ce2a 100644 --- a/pkgs/os-specific/linux/ati-drivers/default.nix +++ b/pkgs/os-specific/linux/ati-drivers/default.nix @@ -14,14 +14,14 @@ # The gentoo ebuild contains much more magic.. -let lib = stdenv.lib; - inherit (lib) concatStringsSep; +let + version = "11-6-x86"; + lib = stdenv.lib; in # http://wiki.cchtml.com/index.php/Main_Page -stdenv.mkDerivation rec { +stdenv.mkDerivation { name = "ati-drivers-${version}"; - version = "10-11-x86"; builder = ./builder.sh; @@ -29,9 +29,9 @@ stdenv.mkDerivation rec { src = assert stdenv.system == "x86_64-linux"; - fetchurl { - url = https://a248.e.akamai.net/f/674/9206/0/www2.ati.com/drivers/linux/ati-driver-installer-10-11-x86.x86_64.run; - sha256 = "1z33w831ayx1j5lm9d1xv6whkmzsz9v8li3s8c96hwnwki6zpimr"; + fetchurl { + url = "http://www2.ati.com/drivers/linux/ati-driver-installer-${version}.x86_64.run"; + sha256 = "12miyi46v70i4f7n1vvcscavfjn0r1h5vww7zl9gyq5y6qnjfkfc"; }; buildInputs = [xlibs.libXext xlibs.libX11 @@ -39,8 +39,8 @@ stdenv.mkDerivation rec { patchelf ]; inherit kernel glibc /* glibc only used for setting interpreter */; - - LD_LIBRARY_PATH = concatStringsSep ":" + + LD_LIBRARY_PATH = lib.concatStringsSep ":" [ "${xorg.libXrandr}/lib" "${xorg.libXrender}/lib" "${xorg.libXext}/lib" @@ -53,7 +53,7 @@ stdenv.mkDerivation rec { description = "ati drivers"; homepage = http://support.amd.com/us/gpudownload/Pages/index.aspx; license = "unfree"; - maintainers = [stdenv.lib.maintainers.marcweber]; + maintainers = [lib.maintainers.marcweber lib.maintainers.simons]; platforms = [ "x86_64-linux" ]; }; -- 1.7.6
>From 0db4c80b25581938bd1fa92c5963a3315f3f4f2d Mon Sep 17 00:00:00 2001 From: Peter Simons <[email protected]> Date: Thu, 14 Jul 2011 11:42:37 +0200 Subject: [PATCH 2/3] linux/ati-drivers: fglrx_gamma is no longer part of the distribution The code for building fglrx_gamma had been disabled before, because it didn't link. Now, the source code isn't even included anymore, so that code (and the dependencies that were added because of that tool) is obsolete. --- pkgs/os-specific/linux/ati-drivers/builder.sh | 13 ------------- pkgs/os-specific/linux/ati-drivers/default.nix | 3 --- 2 files changed, 0 insertions(+), 16 deletions(-) diff --git a/pkgs/os-specific/linux/ati-drivers/builder.sh b/pkgs/os-specific/linux/ati-drivers/builder.sh index 3799b03..4a52634 100644 --- a/pkgs/os-specific/linux/ati-drivers/builder.sh +++ b/pkgs/os-specific/linux/ati-drivers/builder.sh @@ -190,19 +190,6 @@ GCC_MAJOR="`gcc --version | grep -o -e ") ." | head -1 | cut -d " " -f 2`" -o $out/bin/fgl_glxgears -Wall fgl_glxgears.c ) - true || ( # build and install - - # doesn't build undefined reference to `FGLRX_X11SetGamma' - # wich should be contained in -lfglrx_gamma - - cd programs/fglrx_gamma - gcc -fPIC -I${libXxf86vm}/include \ - -I${xf86vidmodeproto}/include \ - -I$out/X11R6/include \ - -L$out/lib \ - -Wall -lm -lfglrx_gamma -lX11 -lXext -o fglrx_xgamma fglrx_xgamma.c - ) - { # copy binaries and wrap them: BIN=$TMP/arch/$arch/usr/X11R6/bin cp $BIN/* $out/bin diff --git a/pkgs/os-specific/linux/ati-drivers/default.nix b/pkgs/os-specific/linux/ati-drivers/default.nix index d39ce2a..acb88f9 100644 --- a/pkgs/os-specific/linux/ati-drivers/default.nix +++ b/pkgs/os-specific/linux/ati-drivers/default.nix @@ -1,6 +1,5 @@ {stdenv, fetchurl , kernel, xlibs, which, imake , mesa # for fgl_glxgears -, libXxf86vm, xf86vidmodeproto # for fglrx_gamma , xorg, makeWrapper, glibc, patchelf }: @@ -25,8 +24,6 @@ stdenv.mkDerivation { builder = ./builder.sh; - inherit libXxf86vm xf86vidmodeproto; - src = assert stdenv.system == "x86_64-linux"; fetchurl { -- 1.7.6
>From e029b65a6760bd401e520460ba16d1a4f5e7bacd Mon Sep 17 00:00:00 2001 From: Peter Simons <[email protected]> Date: Thu, 14 Jul 2011 11:42:55 +0200 Subject: [PATCH 3/3] linux/ati-drivers: stripped trailing whitespace --- pkgs/os-specific/linux/ati-drivers/builder.sh | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/pkgs/os-specific/linux/ati-drivers/builder.sh b/pkgs/os-specific/linux/ati-drivers/builder.sh index 4a52634..f2dae23 100644 --- a/pkgs/os-specific/linux/ati-drivers/builder.sh +++ b/pkgs/os-specific/linux/ati-drivers/builder.sh @@ -84,16 +84,16 @@ do done if [ ! -e $src_file ]; then - echo "Warning: x86 compat.h not found in kernel headers" - echo "neither arch/x86/include/asm/compat.h nor include/asm-x86_64/compat.h" - echo "could be found in $kernelBuild or $linuxsources" - echo "" + echo "Warning: x86 compat.h not found in kernel headers" + echo "neither arch/x86/include/asm/compat.h nor include/asm-x86_64/compat.h" + echo "could be found in $kernelBuild or $linuxsources" + echo "" else if [ `cat $src_file | grep -c arch_compat_alloc_user_space` -gt 0 ] then COMPAT_ALLOC_USER_SPACE=arch_compat_alloc_user_space fi - echo "file $src_file says: COMPAT_ALLOC_USER_SPACE=$COMPAT_ALLOC_USER_SPACE" + echo "file $src_file says: COMPAT_ALLOC_USER_SPACE=$COMPAT_ALLOC_USER_SPACE" fi @@ -182,7 +182,7 @@ GCC_MAJOR="`gcc --version | grep -o -e ") ." | head -1 | cut -d " " -f 2`" ( # build and install fgl_glxgears - cd fgl_glxgears; + cd fgl_glxgears; gcc -DGL_ARB_texture_multisample=1 -g \ -I$mesa/include \ -I$out/include \ -- 1.7.6
_______________________________________________ nix-dev mailing list [email protected] https://mail.cs.uu.nl/mailman/listinfo/nix-dev
