wineoss.drv: Enable compilation with long types.
Signed-off-by: Eric Pouech <eric.pouech@gmail.com> Signed-off-by: Andrew Eikum <aeikum@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
ed1b8cc19e
commit
7219e6ecb4
|
@ -1,4 +1,3 @@
|
|||
EXTRADEFS = -DWINE_NO_LONG_TYPES
|
||||
MODULE = wineoss.drv
|
||||
UNIXLIB = wineoss.so
|
||||
IMPORTS = uuid ole32 user32 advapi32
|
||||
|
|
|
@ -57,7 +57,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(midi);
|
|||
|
||||
static void notify_client(struct notify_context *notify)
|
||||
{
|
||||
TRACE("dev_id = %d msg = %d param1 = %04lX param2 = %04lX\n",
|
||||
TRACE("dev_id = %d msg = %d param1 = %04IX param2 = %04IX\n",
|
||||
notify->dev_id, notify->msg, notify->param_1, notify->param_2);
|
||||
|
||||
DriverCallback(notify->callback, notify->flags, notify->device, notify->msg,
|
||||
|
@ -78,7 +78,7 @@ DWORD WINAPI OSS_midMessage(UINT wDevID, UINT wMsg, DWORD_PTR dwUser,
|
|||
struct notify_context notify;
|
||||
UINT err;
|
||||
|
||||
TRACE("(%04X, %04X, %08lX, %08lX, %08lX);\n",
|
||||
TRACE("(%04X, %04X, %08IX, %08IX, %08IX);\n",
|
||||
wDevID, wMsg, dwUser, dwParam1, dwParam2);
|
||||
|
||||
params.dev_id = wDevID;
|
||||
|
@ -108,7 +108,7 @@ DWORD WINAPI OSS_modMessage(UINT wDevID, UINT wMsg, DWORD_PTR dwUser,
|
|||
struct notify_context notify;
|
||||
UINT err;
|
||||
|
||||
TRACE("(%04X, %04X, %08lX, %08lX, %08lX);\n",
|
||||
TRACE("(%04X, %04X, %08IX, %08IX, %08IX);\n",
|
||||
wDevID, wMsg, dwUser, dwParam1, dwParam2);
|
||||
|
||||
params.dev_id = wDevID;
|
||||
|
@ -150,7 +150,7 @@ static DWORD WINAPI notify_thread(void *p)
|
|||
LRESULT CALLBACK OSS_DriverProc(DWORD_PTR dwDevID, HDRVR hDriv, UINT wMsg,
|
||||
LPARAM dwParam1, LPARAM dwParam2)
|
||||
{
|
||||
TRACE("(%08lX, %p, %08X, %08lX, %08lX)\n",
|
||||
TRACE("(%08IX, %p, %08X, %08IX, %08IX)\n",
|
||||
dwDevID, hDriv, wMsg, dwParam1, dwParam2);
|
||||
|
||||
switch(wMsg) {
|
||||
|
|
|
@ -42,7 +42,7 @@ DWORD WINAPI OSS_auxMessage(UINT wDevID, UINT wMsg, DWORD_PTR dwUser,
|
|||
struct aux_message_params params;
|
||||
UINT err;
|
||||
|
||||
TRACE("(%04X, %04X, %08lX, %08lX, %08lX);\n",
|
||||
TRACE("(%04X, %04X, %08IX, %08IX, %08IX);\n",
|
||||
wDevID, wMsg, dwUser, dwParam1, dwParam2);
|
||||
|
||||
params.dev_id = wDevID;
|
||||
|
|
|
@ -272,7 +272,7 @@ static void set_device_guid(EDataFlow flow, HKEY drv_key, const WCHAR *key_name,
|
|||
lr = RegCreateKeyExW(HKEY_CURRENT_USER, drv_key_devicesW, 0, NULL, 0, KEY_WRITE,
|
||||
NULL, &drv_key, NULL);
|
||||
if(lr != ERROR_SUCCESS){
|
||||
ERR("RegCreateKeyEx(drv_key) failed: %u\n", lr);
|
||||
ERR("RegCreateKeyEx(drv_key) failed: %lu\n", lr);
|
||||
return;
|
||||
}
|
||||
opened = TRUE;
|
||||
|
@ -281,14 +281,14 @@ static void set_device_guid(EDataFlow flow, HKEY drv_key, const WCHAR *key_name,
|
|||
lr = RegCreateKeyExW(drv_key, key_name, 0, NULL, 0, KEY_WRITE,
|
||||
NULL, &key, NULL);
|
||||
if(lr != ERROR_SUCCESS){
|
||||
ERR("RegCreateKeyEx(%s) failed: %u\n", wine_dbgstr_w(key_name), lr);
|
||||
ERR("RegCreateKeyEx(%s) failed: %lu\n", wine_dbgstr_w(key_name), lr);
|
||||
goto exit;
|
||||
}
|
||||
|
||||
lr = RegSetValueExW(key, guidW, 0, REG_BINARY, (BYTE*)guid,
|
||||
sizeof(GUID));
|
||||
if(lr != ERROR_SUCCESS)
|
||||
ERR("RegSetValueEx(%s\\guid) failed: %u\n", wine_dbgstr_w(key_name), lr);
|
||||
ERR("RegSetValueEx(%s\\guid) failed: %lu\n", wine_dbgstr_w(key_name), lr);
|
||||
|
||||
RegCloseKey(key);
|
||||
exit:
|
||||
|
@ -318,7 +318,7 @@ static void get_device_guid(EDataFlow flow, const char *device, GUID *guid)
|
|||
RegCloseKey(key);
|
||||
return;
|
||||
}
|
||||
ERR("Invalid type for device %s GUID: %u; ignoring and overwriting\n",
|
||||
ERR("Invalid type for device %s GUID: %lu; ignoring and overwriting\n",
|
||||
wine_dbgstr_w(key_name), type);
|
||||
}
|
||||
RegCloseKey(dev_key);
|
||||
|
@ -505,7 +505,7 @@ static ULONG WINAPI AudioClient_AddRef(IAudioClient3 *iface)
|
|||
ACImpl *This = impl_from_IAudioClient3(iface);
|
||||
ULONG ref;
|
||||
ref = InterlockedIncrement(&This->ref);
|
||||
TRACE("(%p) Refcount now %u\n", This, ref);
|
||||
TRACE("(%p) Refcount now %lu\n", This, ref);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -515,7 +515,7 @@ static ULONG WINAPI AudioClient_Release(IAudioClient3 *iface)
|
|||
ULONG ref;
|
||||
|
||||
ref = InterlockedDecrement(&This->ref);
|
||||
TRACE("(%p) Refcount now %u\n", This, ref);
|
||||
TRACE("(%p) Refcount now %lu\n", This, ref);
|
||||
if(!ref){
|
||||
IAudioClient3_Stop(iface);
|
||||
IMMDevice_Release(This->parent);
|
||||
|
@ -553,15 +553,15 @@ static void dump_fmt(const WAVEFORMATEX *fmt)
|
|||
TRACE(")\n");
|
||||
|
||||
TRACE("nChannels: %u\n", fmt->nChannels);
|
||||
TRACE("nSamplesPerSec: %u\n", fmt->nSamplesPerSec);
|
||||
TRACE("nAvgBytesPerSec: %u\n", fmt->nAvgBytesPerSec);
|
||||
TRACE("nSamplesPerSec: %lu\n", fmt->nSamplesPerSec);
|
||||
TRACE("nAvgBytesPerSec: %lu\n", fmt->nAvgBytesPerSec);
|
||||
TRACE("nBlockAlign: %u\n", fmt->nBlockAlign);
|
||||
TRACE("wBitsPerSample: %u\n", fmt->wBitsPerSample);
|
||||
TRACE("cbSize: %u\n", fmt->cbSize);
|
||||
|
||||
if(fmt->wFormatTag == WAVE_FORMAT_EXTENSIBLE){
|
||||
WAVEFORMATEXTENSIBLE *fmtex = (void*)fmt;
|
||||
TRACE("dwChannelMask: %08x\n", fmtex->dwChannelMask);
|
||||
TRACE("dwChannelMask: %08lx\n", fmtex->dwChannelMask);
|
||||
TRACE("Samples: %04x\n", fmtex->Samples.wReserved);
|
||||
TRACE("SubFormat: %s\n", wine_dbgstr_guid(&fmtex->SubFormat));
|
||||
}
|
||||
|
@ -656,7 +656,7 @@ static HRESULT WINAPI AudioClient_Initialize(IAudioClient3 *iface,
|
|||
stream_handle stream;
|
||||
unsigned int i;
|
||||
|
||||
TRACE("(%p)->(%x, %x, %s, %s, %p, %s)\n", This, mode, flags,
|
||||
TRACE("(%p)->(%x, %lx, %s, %s, %p, %s)\n", This, mode, flags,
|
||||
wine_dbgstr_longlong(duration), wine_dbgstr_longlong(period), fmt, debugstr_guid(sessionguid));
|
||||
|
||||
if(!fmt)
|
||||
|
@ -677,7 +677,7 @@ static HRESULT WINAPI AudioClient_Initialize(IAudioClient3 *iface,
|
|||
AUDCLNT_SESSIONFLAGS_DISPLAY_HIDEWHENEXPIRED |
|
||||
AUDCLNT_STREAMFLAGS_SRC_DEFAULT_QUALITY |
|
||||
AUDCLNT_STREAMFLAGS_AUTOCONVERTPCM)){
|
||||
FIXME("Unknown flags: %08x\n", flags);
|
||||
FIXME("Unknown flags: %08lx\n", flags);
|
||||
return E_INVALIDARG;
|
||||
}
|
||||
|
||||
|
@ -1147,7 +1147,7 @@ static HRESULT WINAPI AudioClient_InitializeSharedAudioStream(IAudioClient3 *ifa
|
|||
{
|
||||
ACImpl *This = impl_from_IAudioClient3(iface);
|
||||
|
||||
FIXME("(%p)->(0x%x, %u, %p, %s)\n", This, flags, period_frames, format, debugstr_guid(session_guid));
|
||||
FIXME("(%p)->(0x%lx, %u, %p, %s)\n", This, flags, period_frames, format, debugstr_guid(session_guid));
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
@ -1240,7 +1240,7 @@ static HRESULT WINAPI AudioRenderClient_ReleaseBuffer(
|
|||
ACImpl *This = impl_from_IAudioRenderClient(iface);
|
||||
struct release_render_buffer_params params;
|
||||
|
||||
TRACE("(%p)->(%u, %x)\n", This, written_frames, flags);
|
||||
TRACE("(%p)->(%u, %lx)\n", This, written_frames, flags);
|
||||
|
||||
params.stream = This->stream;
|
||||
params.written_frames = written_frames;
|
||||
|
@ -1548,7 +1548,7 @@ static ULONG WINAPI AudioSessionControl_AddRef(IAudioSessionControl2 *iface)
|
|||
AudioSessionWrapper *This = impl_from_IAudioSessionControl2(iface);
|
||||
ULONG ref;
|
||||
ref = InterlockedIncrement(&This->ref);
|
||||
TRACE("(%p) Refcount now %u\n", This, ref);
|
||||
TRACE("(%p) Refcount now %lu\n", This, ref);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -1557,7 +1557,7 @@ static ULONG WINAPI AudioSessionControl_Release(IAudioSessionControl2 *iface)
|
|||
AudioSessionWrapper *This = impl_from_IAudioSessionControl2(iface);
|
||||
ULONG ref;
|
||||
ref = InterlockedDecrement(&This->ref);
|
||||
TRACE("(%p) Refcount now %u\n", This, ref);
|
||||
TRACE("(%p) Refcount now %lu\n", This, ref);
|
||||
if(!ref){
|
||||
if(This->client){
|
||||
EnterCriticalSection(&g_sessions_lock);
|
||||
|
@ -2239,7 +2239,7 @@ static ULONG WINAPI AudioSessionManager_AddRef(IAudioSessionManager2 *iface)
|
|||
SessionMgr *This = impl_from_IAudioSessionManager2(iface);
|
||||
ULONG ref;
|
||||
ref = InterlockedIncrement(&This->ref);
|
||||
TRACE("(%p) Refcount now %u\n", This, ref);
|
||||
TRACE("(%p) Refcount now %lu\n", This, ref);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -2248,7 +2248,7 @@ static ULONG WINAPI AudioSessionManager_Release(IAudioSessionManager2 *iface)
|
|||
SessionMgr *This = impl_from_IAudioSessionManager2(iface);
|
||||
ULONG ref;
|
||||
ref = InterlockedDecrement(&This->ref);
|
||||
TRACE("(%p) Refcount now %u\n", This, ref);
|
||||
TRACE("(%p) Refcount now %lu\n", This, ref);
|
||||
if(!ref)
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
return ref;
|
||||
|
@ -2263,7 +2263,7 @@ static HRESULT WINAPI AudioSessionManager_GetAudioSessionControl(
|
|||
AudioSessionWrapper *wrapper;
|
||||
HRESULT hr;
|
||||
|
||||
TRACE("(%p)->(%s, %x, %p)\n", This, debugstr_guid(session_guid),
|
||||
TRACE("(%p)->(%s, %lx, %p)\n", This, debugstr_guid(session_guid),
|
||||
flags, out);
|
||||
|
||||
hr = get_audio_session(session_guid, This->device, 0, &session);
|
||||
|
@ -2290,7 +2290,7 @@ static HRESULT WINAPI AudioSessionManager_GetSimpleAudioVolume(
|
|||
AudioSessionWrapper *wrapper;
|
||||
HRESULT hr;
|
||||
|
||||
TRACE("(%p)->(%s, %x, %p)\n", This, debugstr_guid(session_guid),
|
||||
TRACE("(%p)->(%s, %lx, %p)\n", This, debugstr_guid(session_guid),
|
||||
flags, out);
|
||||
|
||||
hr = get_audio_session(session_guid, This->device, 0, &session);
|
||||
|
|
|
@ -531,7 +531,7 @@ static HRESULT setup_oss_device(AUDCLNT_SHAREMODE share, int fd,
|
|||
}
|
||||
free(closest);
|
||||
|
||||
TRACE("returning: %08x\n", ret);
|
||||
TRACE("returning: %08x\n", (unsigned)ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
@ -397,12 +397,13 @@ static UINT midi_init(void)
|
|||
FIXME("Synthesizer supports MIDI in. Not yet supported.\n");
|
||||
|
||||
TRACE("SynthOut[%d]\tOSS info: synth type=%d/%d capa=%x\n",
|
||||
i, sinfo.synth_type, sinfo.synth_subtype, sinfo.capabilities);
|
||||
i, sinfo.synth_type, sinfo.synth_subtype, (unsigned)sinfo.capabilities);
|
||||
}
|
||||
|
||||
TRACE("SynthOut[%d]\tname='%s' techn=%d voices=%d notes=%d chnMsk=%04x support=%d\n",
|
||||
i, wine_dbgstr_w(dest->caps.szPname), dest->caps.wTechnology,
|
||||
dest->caps.wVoices, dest->caps.wNotes, dest->caps.wChannelMask, dest->caps.dwSupport);
|
||||
dest->caps.wVoices, dest->caps.wNotes, dest->caps.wChannelMask,
|
||||
(unsigned)dest->caps.dwSupport);
|
||||
}
|
||||
|
||||
/* find how many MIDI devices are there in the system */
|
||||
|
@ -492,10 +493,10 @@ static UINT midi_init(void)
|
|||
TRACE("OSS info: midi[%d] dev-type=%d capa=%x\n"
|
||||
"\tMidiOut[%d] name='%s' techn=%d voices=%d notes=%d chnMsk=%04x support=%d\n"
|
||||
"\tMidiIn [%d] name='%s' support=%d\n",
|
||||
i, minfo.dev_type, minfo.capabilities,
|
||||
i, minfo.dev_type, (unsigned)minfo.capabilities,
|
||||
synth_devs + i, wine_dbgstr_w(dest->caps.szPname), dest->caps.wTechnology,
|
||||
dest->caps.wVoices, dest->caps.wNotes, dest->caps.wChannelMask, dest->caps.dwSupport,
|
||||
i, wine_dbgstr_w(src->caps.szPname), src->caps.dwSupport);
|
||||
dest->caps.wVoices, dest->caps.wNotes, dest->caps.wChannelMask, (unsigned)dest->caps.dwSupport,
|
||||
i, wine_dbgstr_w(src->caps.szPname), (unsigned)src->caps.dwSupport);
|
||||
}
|
||||
|
||||
wrapup:
|
||||
|
@ -1115,7 +1116,7 @@ static UINT midi_out_long_data(WORD dev_id, MIDIHDR *hdr, UINT hdr_size, struct
|
|||
if (data[0] != 0xF0 || data[hdr->dwBufferLength - 1] != 0xF7)
|
||||
WARN("The allegedly system exclusive buffer is not correct\n\tPlease report with MIDI file\n");
|
||||
|
||||
TRACE("dwBufferLength=%u !\n", hdr->dwBufferLength);
|
||||
TRACE("dwBufferLength=%u !\n", (unsigned)hdr->dwBufferLength);
|
||||
TRACE(" %02X %02X %02X ... %02X %02X %02X\n",
|
||||
data[0], data[1], data[2], data[hdr->dwBufferLength - 3],
|
||||
data[hdr->dwBufferLength - 2], data[hdr->dwBufferLength - 1]);
|
||||
|
|
Loading…
Reference in New Issue