Changes between Version 15 and Version 16 of Installation


Ignore:
Timestamp:
Dec 9, 2013, 12:44:30 AM (4 years ago)
Author:
Erich Seifert
Comment:

Updated installation instructions from Maven to Gradle

Legend:

Unmodified
Added
Removed
Modified
  • Installation

    v15 v16  
    66== Requirements ==
    77
    8 - [http://www.oracle.com/technetwork/java/javase/downloads/index.html Java Runtime Environment (JRE)] of at least version 5.
    9 - To build GRAL from source code a [http://www.oracle.com/technetwork/java/javase/downloads/index.html JDK] and [http://maven.apache.org/ Maven] 3 are required.
     8- [http://www.oracle.com/technetwork/java/javase/downloads/index.html Java Runtime Environment (JRE)] of at least version 6.
     9- To build GRAL from source code a [http://www.oracle.com/technetwork/java/javase/downloads/index.html JDK] and [http://www.gradle.org/ Gradle] 1.9 are required.
    1010
    1111== Recommended packages ==
    1212
    13 - [http://trac.erichseifert.de/vectorgraphics2d/ VectorGraphics2D library] for exporting vector file formats (included in binary package)
     13- [http://trac.erichseifert.de/vectorgraphics2d/ VectorGraphics2D library] for exporting vector file formats (included in download)
    1414
    1515= Building GRAL from source code =
    1616
    1717The source package contains all files necessary to build GRAL from scratch using
    18 the [http://maven.apache.org/ Maven] software project management and
    19 comprehension tool. Like {{{Makefile}}} files the {{{pom.xml}}} files are used by
    20 Maven to execute certain steps for generating various distribution or
    21 documentation files.
     18the [http://www.gradle.org/ Gradle] sbuild automation tool. Like {{{Makefile}}}
     19files the {{{build.gradle}}} files are used by Gradle to execute certain steps,
     20so called ''tasks'', for generating various distribution or documentation files.
    2221
    23 Before you can build GRAL from source code you have to checkout and install
    24 [http://trac.erichseifert.de/vectorgraphics2d/wiki/Installation VectorGraphics2D]
    25 to your local Maven repository. It's a dependency for GRAL's vector file export.
    26 
    27 Next, you have to get the GRAL source from the [wiki:Download] page or from the
     22First, you have to get the GRAL source from the [wiki:Download] page or from the
    2823git repository using the {{{git clone}}} command:
    2924{{{
    3025#!sh
    3126$ git clone git://erichseifert.de/gral.git GRAL
     27}}}
     28
     29To see what tasks can be performed change to the directory of the GRAL project
     30and execute the following command:
     31{{{
     32#!sh
     33$ gradle tasks
    3234}}}
    3335
     
    3941{{{
    4042#!sh
    41 $ mvn install
     43$ gradle build
    4244}}}
    4345
    44 This will generate a JAR archive named {{{gral-core}}} in the {{{gral-core/target}}} path.
    45 This JAR file can be added to the class path of your application.
     46This will generate a JAR archive named {{{gral-core}}} in the
     47{{{gral-core/build/libs}}} path. This JAR file can be added to the class path of
     48your application.
    4649
    4750== Building a JAR file of the examples ==
     
    5255{{{
    5356#!sh
    54 $ mvn install
     57$ gradle build
    5558}}}
    5659
    57 This will generate a JAR archive for the examples in the {{{gral-examples/target}}} path
    58 which can be used together with the library core to run the example applications.
    59 Finally, to run an application just call java with a suitable class path:
     60This will generate a JAR archive for the examples in the
     61{{{gral-examples/build/libs}}} path which can be used together with the library
     62core to run the example applications. Finally, to run an application just call
     63{{{java}}} with a suitable class path:
    6064{{{
    6165#!sh
    62 $ java -cp gral-core/src/main/resources:gral-core/target/gral-core-<version>.jar:gral-examples/target/gral-examples-<version>.jar de.erichseifert.gral.examples.xyplot.MemoryUsage
     66$ java -cp gral-core/src/main/resources:gral-core/build/libs/gral-core-<version>.jar:gral-examples/build/libs/gral-examples-<version>.jar de.erichseifert.gral.examples.xyplot.MemoryUsage
    6367}}}
    6468
     
    7074{{{
    7175#!sh
    72 $ mvn clean package assembly:assembly
     76$ gradle distTar distZip
    7377}}}
    7478
    75 This will create a target directory containing the following files in the {{{target}}} directory:
     79This will create {{build/distributions}} directories in {{{gral-core}}} and
     80{{{gral-examples}}} containing the following files:
    7681
    77 - {{{GRAL-<version>-bin.tar.bz2}}} and {{{GRAL-<version>-bin.zip}}} – ready-to-include JAR files for GRAL and all its dependencies
    78 - {{{GRAL-<version>-doc.tar.bz2}}} and {{{GRAL-<version>-doc.zip}}} – !JavaDoc API documentation for GRAL
    79 - {{{GRAL-<version>-src.tar.bz2}}} and {{{GRAL-<version>-src.zip}}} – Source code and resources including the complete Maven project
    80 
    81 === Building with !ProGuard ===
    82 
    83 To get a shrinked/obfuscated build of GRAL or one of its modules using !ProGuard
    84 you need to execute:
    85 {{{
    86 #!sh
    87 $ mvn -Pproguard clean package assembly:assembly
    88 }}}
    89 
    90 On Mac OS X systems Java libraries are stored differently. So, to get a smaller
    91 JAR of GRAL or one of its modules on Mac OS X execute:
    92 {{{
    93 #!sh
    94 $ mvn -Pmacosx,proguard clean package assembly:assembly
    95 }}}
    96 
    97 '''Important''' Please note, that ProGuard is only available for Java versions up to 6, so you can't use ProGuard with Java 7 (JDK 1.7) or higher at the moment.
     82- {{{gral-core-<version>.tar.bz2}}} and {{{gral-core-<version>.zip}}} –
     83  JAR files for GRAL and all its dependencies, !JavaDoc API documentation, and
     84  the source code and resources including the complete Gradle project
     85- {{{gral-examples-<version>.tar.bz2}}} and {{{gral-examples-<version>.zip}}} –
     86  Example applications and JAR files for GRAL and all its dependencies, the
     87  source code and resources to build the examples including the complete Gradle
     88  project
    9889
    9990== Building the documentation ==
    10091
    101 The GRAL Maven project offers two sources for documentation:
     92The GRAL Gradle project offers two sources for documentation:
    10293
    103 The first one is the standard Maven site containing a project overview and
    104 various information like the !JavaDocs, test results, etc. To build the HTML
    105 Maven site in the {{{target/site}}} directory just execute:
     94The first one are the standard Gradle reports containing various project
     95informations like the !JavaDocs, test results, etc. To build the Gradle reports
     96just execute in the project directory:
    10697
    10798{{{
    10899#!sh
    109 $ mvn site
     100$ gradle report
    110101}}}
    111102
    112 The second is a book-like documentation in form of a !DocBook file.
    113 To build an HTML file of the !DocBook file in the {{{target/docbook}}}
    114 directory execute:
    115 
    116 {{{
    117 #!sh
    118 $ mvn docbook:transform
    119 }}}
     103The second is a book-like documentation in form of a !reStructured Text file
     104which can be found in the {{{doc}}} directory:
    120105
    121106= Using GRAL in an IDE =
    122107
    123 The Maven project can also be used in your favorite development environment like
    124 Eclipse or !NetBeans. For further information look at the following descriptions
    125 on the Maven website:
     108The Gradle project can also be used in several development environments, like
     109Eclipse or IDEA. For further information look at the following descriptions on
     110the Gradle website:
    126111
    127  - [http://maven.apache.org/netbeans-module.html Maven Eclipse integration]
    128  - [http://maven.apache.org/eclipse-plugin.html Maven NetBeans integration]
     112 - [http://www.gradle.org/docs/current/userguide/eclipse_plugin.html Gradle Eclipse integration]
     113 - [http://www.gradle.org/docs/current/userguide/idea_plugin.html Gradle IDEA integration]
    129114
    130 Once you have installed an appropriate Maven plug-in for your IDE you will be
     115Once you have installed an appropriate Gradle plug-in for your IDE you will be
    131116able to import the GRAL project found in this folder.