Re: Building in Visual Studio 2010
Raphaël Lemoine <[email protected]>
| Newsgroups | gmane.comp.lib.openal |
|---|---|
| Message-ID | <[email protected]> |
Hello again (note that I'm not a Windows programmer...), On Aug 23, 2010, at 9:19 PM, John Doe wrote: > Thanks. That worked. But just curious how can I link with the dll's instead? AFAIK, you can't. A DLL file is a *shared* library containing the code. A LIB file is a simple glue to this shared library. - If, for some reason, you don't want to use the LIB file, you can load the DLL yourself (LoadLibrary) and find the procs address (GetProcAddress). See http://msdn.microsoft.com/en-us/library/ms686944(v=VS.85).aspx for an example. - If you want to *statically* link with OpenAL, you can't use the DLL file. You must either get a *static* version of OpenAL, or compile OpenAL sources within your project. Raphaël > > 2010/8/23 Raphaël Lemoine <[email protected]> > Hello, > > On Aug 23, 2010, at 8:35 PM, John Doe wrote: > > > I apologize if this has been asked a million times before but there seems to be no way to search the mailing archives short of browsing through every thread. I have used OpenAL previously in a linux environment but I'm new to using it in a Visual Studio project. > > > > In Project Options in Visual Studio 2010 I have added C:\Windows\System32 to the VC++ library paths and added the include directories in the include paths also. I've also added OpenAl32.dll to Configuration Properties-->Linker-->Input-->Additional Dependencies. However when I try to build my project I keep getting the error: > > > > "C:\Windows\SysWOW64\OpenAL32.dll : fatal error LNK1107: invalid or corrupt file: cannot read at 0x2B0" > > > > You must add the LIB file to the dependencies, not the DLL file. > > > If I remove OpenAl32.dll from the Additional Dependencies option all I get is 'unresolved symbol' errors for the OpenAL function calls in my code. > > > > Can someone help me out with linking OpenAL in visual Studio 2010? > > > > Thanks > > Javad > > Regards, > > Raphaël > > > _______________________________________________ > > Openal mailing list > > [email protected] > > http://opensource.creative.com/mailman/listinfo/openal > > _______________________________________________ Openal mailing list [email protected] http://opensource.creative.com/mailman/listinfo/openal