diff options
Diffstat (limited to '')
-rw-r--r-- | premake5.lua | 31 |
1 files changed, 28 insertions, 3 deletions
diff --git a/premake5.lua b/premake5.lua index fd6da6ac..c7321dcb 100644 --- a/premake5.lua +++ b/premake5.lua @@ -17,6 +17,11 @@ newoption { description = "Build and use librw from this solution" } +newoption { + trigger = "with-opus", + description = "Build with opus" +} + if(_OPTIONS["with-librw"]) then Librw = "librw" else @@ -188,10 +193,23 @@ project "re3" includedirs { "eax" } - filter "platforms:*mss" - defines { "AUDIO_MSS" } - includedirs { "milessdk/include" } + if _OPTIONS["with-opus"] then + includedirs { "ogg/include" } + includedirs { "opus/include" } + includedirs { "opusfile/include" } + end + libdirs { "milessdk/lib" } + libdirs { "openal-soft/libs/Win32" } + libdirs { "mpg123/lib" } + libdirs { "libsndfile/lib" } + if _OPTIONS["with-opus"] then + filter "platforms:win*" + libdirs { "ogg/win32/VS2015/Win32/%{cfg.buildcfg}" } + libdirs { "opus/win32/VS2015/Win32/%{cfg.buildcfg}" } + libdirs { "opusfile/win32/VS2015/Win32/Release-NoHTTP" } + filter {} + end filter "platforms:*oal" defines { "AUDIO_OAL" } @@ -218,6 +236,13 @@ project "re3" filter "platforms:linux*oal" links { "openal", "mpg123", "sndfile", "pthread" } + + if _OPTIONS["with-opus"] then + filter {} + links { "libogg" } + links { "opus" } + links { "opusfile" } + end filter "platforms:*RW33*" staticruntime "on" |