mpt-openmpt123.lua 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. project "openmpt123"
  2. uuid "2879F62E-9E2F-4EAB-AE7D-F60C194DD5CB"
  3. language "C++"
  4. location ( "../../build/" .. mpt_projectpathname )
  5. vpaths { ["*"] = "../../" }
  6. mpt_projectname = "openmpt123"
  7. dofile "../../build/premake/premake-defaults-EXE.lua"
  8. dofile "../../build/premake/premake-defaults.lua"
  9. warnings "Extra"
  10. local extincludedirs = {
  11. "../..",
  12. "../../include/flac/include",
  13. "../../include/portaudio/include",
  14. }
  15. filter { "action:vs*" }
  16. includedirs ( extincludedirs )
  17. filter { "not action:vs*" }
  18. sysincludedirs ( extincludedirs )
  19. filter {}
  20. includedirs {
  21. "../..",
  22. "../../src",
  23. "../../openmpt123",
  24. "$(IntDir)/svn_version",
  25. "../../build/svn_version",
  26. }
  27. files {
  28. "../../src/mpt/base/*.hpp",
  29. "../../src/mpt/detect/*.hpp",
  30. "../../src/mpt/string/*.hpp",
  31. "../../openmpt123/*.cpp",
  32. "../../openmpt123/*.hpp",
  33. }
  34. defines { }
  35. filter { "action:vs*", "kind:SharedLib or ConsoleApp or WindowedApp" }
  36. resdefines {
  37. "MPT_BUILD_VER_FILENAME=\"" .. mpt_projectname .. ".exe\"",
  38. "MPT_BUILD_VER_FILEDESC=\"" .. mpt_projectname .. "\"",
  39. }
  40. filter { "action:vs*", "kind:SharedLib or ConsoleApp or WindowedApp" }
  41. resincludedirs {
  42. "$(IntDir)/svn_version",
  43. "../../build/svn_version",
  44. "$(ProjDir)/../../build/svn_version",
  45. }
  46. files {
  47. "../../libopenmpt/libopenmpt_version.rc",
  48. }
  49. filter { "action:vs*", "kind:SharedLib" }
  50. resdefines { "MPT_BUILD_VER_DLL" }
  51. filter { "action:vs*", "kind:ConsoleApp or WindowedApp" }
  52. resdefines { "MPT_BUILD_VER_EXE" }
  53. filter {}
  54. characterset "Unicode"
  55. links {
  56. "libopenmpt",
  57. "flac",
  58. "portaudio",
  59. "ksuser",
  60. "winmm",
  61. }
  62. filter {}
  63. filter { "action:vs*" }
  64. linkoptions { "wsetargv.obj" }
  65. filter {}
  66. filter { "configurations:*Shared" }
  67. defines { "LIBOPENMPT_USE_DLL" }
  68. filter { "not configurations:*Shared" }
  69. filter {}
  70. prebuildcommands { "..\\..\\build\\svn_version\\update_svn_version_vs_premake.cmd $(IntDir)" }