[Nix-dev] Video Driver Name Mismatch
Nicolas Pierron
nicolas.b.pierron at gmail.com
Thu Jan 22 11:58:46 CET 2009
Hi John,
On Thu, Jan 22, 2009 at 06:58, John Altobelli <acocaracha at gmail.com> wrote:
> I would still like to see the video cards each separated because
> organization wise it would make more sense to me. However, as I am
> still getting accustomed to everything nix, I respect the opinions of
> those who have spent a lot longer than I with it.
If you want to create a Service & Device Specific Configuration (SDSC)
you can do that easily.
I suggest you to create the following files inside the
"configurations" repository:
# content of /hardware/video/card/GenericLatestATI.nix
{pkgs, config, ...}:
{
services = {
xserver = {
package = # comming from misc/raskin/raskin.nix
(pkgs.xorg // {
xf86videoati = pkgs.xorgReplacements.xf86videoati {
suffix = "git";
src = "" + /root/build/xf86-video-ati ;
};
});
};
};
}
# content of /hardware/video/card/MyVideoCardName.nix
{
require = [
(import ./GenericLatestATI.nix)
];
# put here options specific to this hardware.
}
and add the following lines inside your configuration.nix like in the
previous file:
require = [
(import ./PathToConfigurations/hardware/video/card/MyVideoCardName.nix)
];
With this system, you can create SDSCs and include them with the
"require" attribute. This feature allow you to split your
configuration.nix file and share SDSCs with the community. As example
you can find my laptop configuration in
configurations/trunk/computer/compaq/presario/2144EA/default.nix ,
which means that if somebody else have the same Laptop as I then
he/she does not have to worried about the PCMCIA support.
There are still some issue because we cannot easily override options
setting currently. Thus a person which has modified his laptop a bit
cannot use the generic configuration, but I am working on this problem
which is also an issue for live-CD.
--
Nicolas Pierron
http://www.linkedin.com/in/nicolasbpierron
- If you are doing something twice then you should try to do it once.
More information about the nix-dev
mailing list