Advertisement

How to build alure (utility of OpenAL Soft) from source

Started by October 20, 2017 02:01 PM
1 comment, last by 123iamking 7 years, 1 month ago

I just recently start using OpenAL soft (actually not really use, I'm still struggle with setting this up).

Setup OpenAL soft - Passed

First, I grab the source of OpenAL soft, I just run CMake for this and build, here the CMake result.


Using DirectX SDK directory: C:/Program Files (x86)/Microsoft DirectX SDK (June 2010)/
Could NOT find ALSA (missing:  ALSA_LIBRARY ALSA_INCLUDE_DIR) 
Could NOT find OSS (missing:  OSS_INCLUDE_DIR) 
Could NOT find AudioIO (missing:  AUDIOIO_INCLUDE_DIR) 
Could NOT find SoundIO (missing:  SOUNDIO_LIBRARY SOUNDIO_INCLUDE_DIR) 
Could NOT find QSA (missing:  QSA_LIBRARY QSA_INCLUDE_DIR) 
Could NOT find PortAudio (missing:  PORTAUDIO_LIBRARY PORTAUDIO_INCLUDE_DIR) 
Could NOT find PulseAudio (missing:  PULSEAUDIO_LIBRARY PULSEAUDIO_INCLUDE_DIR) 
Could NOT find JACK (missing:  JACK_LIBRARY JACK_INCLUDE_DIR) 
CMake Warning at utils/alsoft-config/CMakeLists.txt:13 (find_package):
  By not providing "FindQt5Widgets.cmake" in CMAKE_MODULE_PATH this project
  has asked CMake to find a package configuration file provided by
  "Qt5Widgets", but CMake did not find one.

  Could not find a package configuration file provided by "Qt5Widgets" with
  any of the following names:

    Qt5WidgetsConfig.cmake
    qt5widgets-config.cmake

  Add the installation prefix of "Qt5Widgets" to CMAKE_PREFIX_PATH or set
  "Qt5Widgets_DIR" to a directory containing one of the above files.  If
  "Qt5Widgets" provides a separate development package or SDK, be sure it has
  been installed.


Found unsuitable Qt version "" from NOTFOUND
Could NOT find SDL2 (missing:  SDL2_LIBRARY SDL2_INCLUDE_DIR) 

Building OpenAL with support for the following backends:
     WinMM, DirectSound, MMDevApi, WaveFile, Null

Building with support for CPU extensions:
    Default, SSE, SSE2, SSE3, SSE4.1

Installing sample configuration

Installing HRTF definitions

Installing AmbDec presets

Building utility programs

Building test programs

Building example programs
Configuring done
Generating done

So I see that I have no Qt & SDL2 for my OpenAL-soft, hope that ok (I don't even know what it for, as long as the I can build OpenAL-soft, I don't really care)

So setup OpenAL-soft seem easy.

Setup alure - failed

I got trouble when I setup alure,

I setup CMake like this:


OPENAL_INCLUDE_DIR = E:/Source/openal-soft/include/AL
OPENAL_LIBRARY = E:/Source/_build/openal-soft/Release

And I get the CMake result like this:


Found OpenAL: E:/Source/_build/openal-soft/Release  
Could NOT find OGG (missing:  OGG_LIBRARY OGG_INCLUDE_DIR) 
Could NOT find SndFile (missing:  SNDFILE_LIBRARY SNDFILE_INCLUDE_DIR) 
Could NOT find MPG123 (missing:  MPG123_LIBRARY MPG123_INCLUDE_DIR) 
Could NOT find PhysFS (missing:  PHYSFS_LIBRARY PHYSFS_INCLUDE_DIR) 
Could NOT find DUMB (missing:  DUMB_LIBRARY DUMB_INCLUDE_DIR) 
Configuring done
WARNING: Target "alure2" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure2" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure2" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure2" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure2_s" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure2_s" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure2_s" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure2_s" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-play" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-play" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-play" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-play" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-enum" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-enum" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-enum" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-enum" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-hrtf" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-hrtf" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-hrtf" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-hrtf" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-reverb" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-reverb" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-reverb" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-reverb" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-stream" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-stream" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-stream" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "alure-stream" requests linking to directory "E:/Source/_build/openal-soft/Release".  Targets may link only to libraries.  CMake is dropping the item.
Generating done

So there are a lot of warnings. I lookup this warning and seem that this is just about the CMake programming inside the file CMakeLists.txt, for the meantime, I'll ignore it.

Then I open the alure solution (alure.sln) with Visual Studio and build. Unfortunately, I got compile error


Severity	Code	Description	Project	File	Line	Suppression State
Error	C3861	'strcasecmp': identifier not found	alure-hrtf	E:\Source\alure\examples\alure-hrtf.cpp	49	
Error	C3861	'strcasecmp': identifier not found	alure-hrtf	E:\Source\alure\examples\alure-hrtf.cpp	69	
Error	C3861	'strcasecmp': identifier not found	alure-reverb	E:\Source\alure\examples\alure-reverb.cpp	178	
Error	C3861	'strcasecmp': identifier not found	alure-reverb	E:\Source\alure\examples\alure-reverb.cpp	185	
Error	C4576	a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax	alure2	e:\source\alure\src\auxeffectslot.h	31	
Error	C4576	a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax	alure2_s	e:\source\alure\src\auxeffectslot.h	31	
Error	C4576	a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax	alure2	e:\source\alure\src\auxeffectslot.h	31	
Error	C4576	a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax	alure2_s	e:\source\alure\src\auxeffectslot.h	31	
Error	C4576	a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax	alure2	e:\source\alure\src\auxeffectslot.h	31	
Error	C4576	a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax	alure2_s	e:\source\alure\src\auxeffectslot.h	31	
Error	LNK1104	cannot open file 'Debug\alure2.lib'	alure-enum	E:\Source\_build\alure\LINK	1	
Error	LNK1104	cannot open file 'Debug\alure2.lib'	alure-stream	E:\Source\_build\alure\LINK	1	
Error	LNK1104	cannot open file 'Debug\alure2.lib'	alure-play	E:\Source\_build\alure\LINK	1	

I try to lookup the error:


//Error: a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax

//Cause by code:
void addSourceSend(Source source, ALuint send)
    { mSourceSends.emplace_back((SourceSend){source, send}); }

But I can't find any clue, and the syntax of this code is really weird.

So how can I build alure from source? Please help me :(

A minor confuse about OpenAL soft

This is a little off topic, but I can't help asking. there is the text inside the ReadMe.txt of the package: openal-soft-1.18.2-bin.zip  that I find confusing:

Quote

Note that it is still expected to install the OpenAL redistributable provided
by Creative Labs (at http://openal.org/), as that will provide the "router"
OpenAL32.dll that applications talk to, and may provide extra drivers for the
user's system. The DLLs provided here will simply add additional devices for
applications to select from. If you do not wish to use the redistributable,
then rename soft_oal.dll to OpenAL32.dll (note: even the 64-bit DLL should be
named OpenAL32.dll). Just be aware this will prevent other system-installed
OpenAL implementations from working.

I thought OpenAL soft is stand-alone package, but here is the note about OpenAL redistributable. So if I build OpenAL-soft from source, should I concern about this? And if I need, what I should do with this? My guess is: require the users to install OpenAL redistributable from Creative Labs.

 

Thanks for reading :)

On 10/20/2017 at 9:01 PM, 123iamking said:

Setup alure - failed

Ok, Let's fix one thing at a time now.

On 10/20/2017 at 9:01 PM, 123iamking said:

I setup CMake like this:



OPENAL_INCLUDE_DIR = E:/Source/openal-soft/include/AL
OPENAL_LIBRARY = E:/Source/_build/openal-soft/Release

...

So there are a lot of warnings. I lookup this warning and seem that this is just about the CMake programming inside the file CMakeLists.txt, for the meantime, I'll ignore it.

About this, The 'OPENAL_LIBRARY' is wrong, thus there are warnings in the CMake result. The OPENAL_LIBRARY expects the OpenAL.lib file's full path, not the directory. So the right setup should be like this:


OPENAL_INCLUDE_DIR = E:/Source/openal-soft/include/AL
OPENAL_LIBRARY = E:/Source/_build/openal-soft/Release/OpenAL32.lib

About the build error:

On 10/20/2017 at 9:01 PM, 123iamking said:

'strcasecmp': identifier not found

According to this article, just add define strcasecmp to fix:


#define strcasecmp _stricmp

 

On 10/20/2017 at 9:01 PM, 123iamking said:

a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax alure2 e:\source\alure\src\auxeffectslot.h 31

Just pull the latest commit, then this error get fix. One note: should get the alure git from its homepage.

On 10/20/2017 at 9:01 PM, 123iamking said:

cannot open file 'Debug\alure2.lib'

Of course this is too obvious how to fix, after build the project alure2 successfully, this error will be gone.

This topic is closed to new replies.

Advertisement