xorg-server: fglrxCompat -> abiCompat
Allows it to be used for fglrx (1.17) and amdgpu-pro (1.18)
This commit is contained in:
parent
47c166fe05
commit
905627c7c5
@ -21,6 +21,8 @@ in
|
|||||||
|
|
||||||
config = mkIf enabled {
|
config = mkIf enabled {
|
||||||
|
|
||||||
|
nixpkgs.config.xorg.abiCompat = "1.18";
|
||||||
|
|
||||||
services.xserver.drivers = singleton
|
services.xserver.drivers = singleton
|
||||||
{ name = "amdgpu"; modules = [ package ]; libPath = [ package ]; };
|
{ name = "amdgpu"; modules = [ package ]; libPath = [ package ]; };
|
||||||
|
|
||||||
|
@ -18,7 +18,7 @@ in
|
|||||||
|
|
||||||
config = mkIf enabled {
|
config = mkIf enabled {
|
||||||
|
|
||||||
nixpkgs.config.xorg.fglrxCompat = true;
|
nixpkgs.config.xorg.abiCompat = "1.17";
|
||||||
|
|
||||||
services.xserver.drivers = singleton
|
services.xserver.drivers = singleton
|
||||||
{ name = "fglrx"; modules = [ ati_x11 ]; libPath = [ "${ati_x11}/lib" ]; };
|
{ name = "fglrx"; modules = [ ati_x11 ]; libPath = [ "${ati_x11}/lib" ]; };
|
||||||
|
@ -393,10 +393,11 @@ in
|
|||||||
};
|
};
|
||||||
|
|
||||||
xorgserver = with xorg; attrs_passed:
|
xorgserver = with xorg; attrs_passed:
|
||||||
# exchange attrs if fglrxCompat is set
|
# exchange attrs if abiCompat is set
|
||||||
let
|
let
|
||||||
attrs = if !args.fglrxCompat then attrs_passed else
|
attrs = with args;
|
||||||
with args; {
|
if (args.abiCompat == null) then attrs_passed
|
||||||
|
else if (args.abiCompat == "1.17") then {
|
||||||
name = "xorg-server-1.17.4";
|
name = "xorg-server-1.17.4";
|
||||||
builder = ./builder.sh;
|
builder = ./builder.sh;
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
@ -405,7 +406,16 @@ in
|
|||||||
};
|
};
|
||||||
buildInputs = [pkgconfig dri2proto dri3proto renderproto libdrm openssl libX11 libXau libXaw libxcb xcbutil xcbutilwm xcbutilimage xcbutilkeysyms xcbutilrenderutil libXdmcp libXfixes libxkbfile libXmu libXpm libXrender libXres libXt ];
|
buildInputs = [pkgconfig dri2proto dri3proto renderproto libdrm openssl libX11 libXau libXaw libxcb xcbutil xcbutilwm xcbutilimage xcbutilkeysyms xcbutilrenderutil libXdmcp libXfixes libxkbfile libXmu libXpm libXrender libXres libXt ];
|
||||||
meta.platforms = stdenv.lib.platforms.unix;
|
meta.platforms = stdenv.lib.platforms.unix;
|
||||||
};
|
} else if (args.abiCompat == "1.18") then {
|
||||||
|
name = "xorg-server-1.18.4";
|
||||||
|
builder = ./builder.sh;
|
||||||
|
src = fetchurl {
|
||||||
|
url = mirror://xorg/individual/xserver/xorg-server-1.18.4.tar.bz2;
|
||||||
|
sha256 = "1j1i3n5xy1wawhk95kxqdc54h34kg7xp4nnramba2q8xqfr5k117";
|
||||||
|
};
|
||||||
|
buildInputs = [pkgconfig dri2proto dri3proto renderproto libdrm openssl libX11 libXau libXaw libxcb xcbutil xcbutilwm xcbutilimage xcbutilkeysyms xcbutilrenderutil libXdmcp libXfixes libxkbfile libXmu libXpm libXrender libXres libXt ];
|
||||||
|
meta.platforms = stdenv.lib.platforms.unix;
|
||||||
|
} else throw "unsupported xorg abiCompat: ${args.abiCompat}";
|
||||||
|
|
||||||
in attrs //
|
in attrs //
|
||||||
(let
|
(let
|
||||||
|
@ -10769,7 +10769,7 @@ with pkgs;
|
|||||||
python = python2; # Incompatible with Python 3x
|
python = python2; # Incompatible with Python 3x
|
||||||
udev = if stdenv.isLinux then udev else null;
|
udev = if stdenv.isLinux then udev else null;
|
||||||
libdrm = if stdenv.isLinux then libdrm else null;
|
libdrm = if stdenv.isLinux then libdrm else null;
|
||||||
fglrxCompat = config.xorg.fglrxCompat or false; # `config` because we have no `xorg.override`
|
abiCompat = config.xorg.abiCompat or null; # `config` because we have no `xorg.override`
|
||||||
} // { inherit xlibsWrapper; } );
|
} // { inherit xlibsWrapper; } );
|
||||||
|
|
||||||
xwayland = callPackage ../servers/x11/xorg/xwayland.nix { };
|
xwayland = callPackage ../servers/x11/xorg/xwayland.nix { };
|
||||||
|
Loading…
x
Reference in New Issue
Block a user