From: colin AT bird DOT fu DOT is DOT saga-u DOT ac DOT jp (Colin Peters) Subject: RE: libwinmm.a 27 Mar 1997 00:42:53 -0800 Approved: cygnus DOT gnu-win32 AT cygnus DOT com Distribution: cygnus Message-ID: <01BC39F2.3CDCBF60.cygnus.gnu-win32@gbird0> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Original-To: "'George Kechriotis'" Original-Cc: "'GNU-Win32'" Original-Sender: owner-gnu-win32 AT cygnus DOT com George Kechriotis[SMTP:george2 AT ccs DOT neu DOT edu] wrote: >I'm trying to compile a code that uses the waveInGetNumDevs >call (multimedia). I checked in libwinmm.a and it seems that >this function is there. However when I compile the code >it can not resolve the function call. I tried gcc -lwinmm >but no luck either. Has anyone tried something similar? -lwinmm is the right option, but you need to have the correct prototype for waveInGetNumDevs. Unfortunately the current win32-api headers do not include that. The prototype is: UINT WINAPI waveInGetNumDevs (); Seems pretty simple, but in the win32-api include file base.h (included from windows.h) WINAPI is set (indirectly) to __attribute__ ((stdcall)), which is important for telling gcc how to properly mangle the name to get the name actually in libwinmm.a (doing an nm libwinmm.a | grep waveInGetNumDevs shows you the mangled form, with an @0 at the end). Eventually I, you, or someone is going to end up writing a complete version of mmsystem.h with this and the other definitions for multi-media under Win32, but it hasn't happened yet (unfortunately). Colin. -- Colin Peters - colin AT bird DOT fu DOT is DOT saga-u DOT ac DOT jp -- Saga University Dept. of Information Science -- http://www.fu.is.saga-u.ac.jp/~colin/index.html -- http://www.geocities.com/Tokyo/Towers/6162/ - For help on using this list, send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".