Well, I use something easier - change all hw:x to hw (default ALSA card). And select this default using ALSA_CARD environment variable. Patch against current CVS follows.
Index: audio.c =================================================================== RCS file: /home/wine/wine/dlls/winmm/winealsa/audio.c,v retrieving revision 1.8 diff -u -r1.8 audio.c --- audio.c 25 Oct 2002 19:09:02 -0000 1.8 +++ audio.c 8 Dec 2002 22:33:18 -0000 @@ -217,13 +217,13 @@ } \ } while(0)
- EXIT_ON_ERROR( snd_ctl_open(&ctl,"hw:0",0) , "ctl open failed" ); + EXIT_ON_ERROR( snd_ctl_open(&ctl,"hw",0) , "ctl open failed" ); EXIT_ON_ERROR( snd_ctl_card_info(ctl, cardinfo), "card info failed"); EXIT_ON_ERROR( snd_ctl_elem_list(ctl, elemlist), "elem list failed");
nCtrls = snd_ctl_elem_list_get_count(elemlist);
- EXIT_ON_ERROR( snd_hctl_open(&hctl,"hw:0",0), "hctl open failed"); + EXIT_ON_ERROR( snd_hctl_open(&hctl,"hw",0), "hctl open failed"); EXIT_ON_ERROR( snd_hctl_load(hctl), "hctl load failed" );
elem=snd_hctl_first_elem(hctl); @@ -405,7 +405,7 @@ wwo = &WOutDev[0];
/* FIXME: use better values */ - wwo->device = "hw:0,0"; + wwo->device = "hw"; wwo->caps.wMid = 0x0002; wwo->caps.wPid = 0x0104; strcpy(wwo->caps.szPname, "SB16 Wave Out");