build.gradle 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. evaluationDependsOn(':iZplPlugins:GameRadio')
  2. evaluationDependsOn(':iZplPlugins:WMP')
  3. evaluationDependsOn(':iZplPlugins:Editor')
  4. defaultTasks 'distZip'
  5. apply plugin: 'java'
  6. apply plugin: 'application'
  7. apply from: "$rootDir/utils/IO.gradle"
  8. version = '0.6.0.0'
  9. mainClassName = 'de.nplusc.izc.iZpl.Main'
  10. //'de.nplusc.izc.iZpl.Main'
  11. jar{
  12. manifest{
  13. attributes 'Implementation-Title': 'iZPlaylist',
  14. 'Implementation-Version': version,
  15. 'Main-Class': 'de.nplusc.izc.iZpl.Main'
  16. }
  17. }
  18. startScripts << {
  19. def startScriptDir = outputDir.getAbsolutePath()
  20. def winStartScript = startScriptDir + "/" + applicationName + ".bat"
  21. def winStartScriptCopy = startScriptDir + "/" + applicationName + "c.bat"
  22. def overwriteExistingFile = true
  23. copyFile(winStartScript, winStartScriptCopy, overwriteExistingFile)
  24. modifyFile(winStartScript) {
  25. // javaw.exe doesn't have a console
  26. if(it.contains("java.exe")){
  27. return it.replace("java.exe", "javaw.exe")
  28. }
  29. // Command that launches the app
  30. else if(it.startsWith("\"%JAVA_EXE%\" %DEFAULT_JVM_OPTS%")){
  31. return "start \"\" /b " + it
  32. }
  33. // Leave the line unchanged
  34. else{
  35. return it
  36. }
  37. }
  38. }
  39. distZip {
  40. // Include the additional start script
  41. into(project.name+"-"+project.version+"/bin/"){
  42. from(startScripts.outputDir)
  43. include '*c.bat'
  44. }
  45. into(project.name+"-"+project.version+"/plugins/"){
  46. from project(':iZplPlugins:GameRadio').jar
  47. from project(':iZplPlugins:WMP').jar
  48. from project(':iZplPlugins:Editor').jar
  49. }
  50. }
  51. sourceSets{
  52. main{
  53. resources{
  54. exclude '**/*.xcf'
  55. }
  56. }
  57. }
  58. dependencies{
  59. compile fileTree(dir: 'lib', include: '*.jar')
  60. compile "net.rubygrapefruit:native-platform:0.9"
  61. compile "commons-io:commons-io:2.+"
  62. compile 'org.apache.commons:commons-exec:1.3'
  63. compile "org.yaml:snakeyaml:1.14"
  64. compile "commons-net:commons-net:3.3"
  65. compile 'uk.co.caprica:vlcj:3.3.0'
  66. compile 'com.googlecode.mp4parser:isoparser:1.0-RC-1'
  67. compile 'de.schlichtherle.truezip:truezip-file:7.7.7'
  68. compile 'de.schlichtherle.truezip:truezip-driver-zip:7.7.7'
  69. compile 'de.schlichtherle.truezip:truezip-driver-file:7.7.7'
  70. compile 'de.schlichtherle.truezip:truezip-driver-tar:7.7.7'
  71. compile 'de.schlichtherle.truezip:truezip-kernel:7.7.7'
  72. compile 'de.schlichtherle.truezip:truezip-path:7.7.7'
  73. compile 'de.schlichtherle.truezip:truezip-driver-tzp:7.7.7'
  74. compile 'de.schlichtherle.truezip:truezip-driver-http:7.7.7'
  75. compile 'commons-cli:commons-cli:1.3-SNAPSHOT'
  76. compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.1'
  77. compile group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.1'
  78. compile group: 'org.apache.logging.log4j', name: 'log4j-iostreams', version: '2.1'
  79. compile group: 'org.apache.logging.log4j', name: 'log4j-slf4j-impl', version: '2.1'
  80. compile 'org.fusesource.jansi:jansi:1.11'
  81. compile 'org.jgrapht:jgrapht-core:0.9.0'
  82. compile(project(':ToolKit')) {
  83. transitive = false
  84. }
  85. }