Guidance on building command-line tools from source

23 views
Skip to first unread message

Dan Wlodarski

unread,
Jul 18, 2016, 11:20:44 PM7/18/16
to Membrane SOA Model
Looking to build (and possibly customize) a command-line Java JAR from the Membrane SOA source. I know it's possible to build Groovy source into Java executables. When a groovy project has dependencies, as this project does, it's simply a matter of knowing the groovy source compile order. However, attempting to derive this build order would be a tremendous time investment. So I turned to the build scripts included with the github repo. Unfortunately, neither the Maven nor the Docker builders produce anything resembling Java class files for the source under the "distribution" directory. This is where the command line groovy scripts live.

Any insight into what is necessary to build the command line executables from source is appreciated.

Thomas Bayer

unread,
Jul 19, 2016, 5:58:48 AM7/19/16
to soa-...@googlegroups.com

Hi,

the project builds the soa-model Jar with Java class files from Groovy source code. See:

 

http://search.maven.org/#search%7Cga%7C1%7Csoa-model

 

Just add the content of  the groovy-all to your jar.

 

Cheers,

Thomas

 

 

Am 19.07.16, 05:20 schrieb "Dan Wlodarski" <soa-...@googlegroups.com im Auftrag von dan.wl...@gmail.com>:

 

Looking to build (and possibly customize) a command-line Java JAR from the Membrane SOA source. I know it's possible to build Groovy source into Java executables. When a groovy project has dependencies, as this project does, it's simply a matter of knowing the groovy source compile order. However, attempting to derive this build order would be a tremendous time investment. So I turned to the build scripts included with the github repo. Unfortunately, neither the Maven nor the Docker builders produce anything resembling Java class files for the source under the "distribution" directory. This is where the command line groovy scripts live.

Any insight into what is necessary to build the command line executables from source is appreciated.

--
You received this message because you are subscribed to the Google Groups "Membrane SOA Model" group.
To unsubscribe from this group and stop receiving emails from it, send an email to soa-model+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/soa-model/269ec103-4399-4781-a2a5-fbd4a1a15e23%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Dan Wlodarski

unread,
Jul 19, 2016, 10:57:34 AM7/19/16
to Membrane SOA Model
Thomas:

Thanks tremendously for your quick reply! However, my Maven-fu is clearly weak; weaker than I'd thought.

I've forked the soa-model Github repository, cloned my fork locally, and imported the repo as an existing Maven project into Eclipse Mars. When I clean and build, however, I still see no executable JAR as a final target. I could just jar the classes that the build produced, I suppose, but the main class I need -- WSDLDiffCLI under the distribution source -- doesn't get compiled to bytecode. Am I missing some Maven build setting?

Thanks again!

Thomas Bayer

unread,
Jul 19, 2016, 12:19:00 PM7/19/16
to soa-...@googlegroups.com

Hi,

have a look at the target folder using File explorer.

 

Cheers,

Thomas

 

Am 19.07.16, 16:57 schrieb "Dan Wlodarski" <soa-...@googlegroups.com im Auftrag von dan.wl...@gmail.com>:

--

You received this message because you are subscribed to the Google Groups "Membrane SOA Model" group.
To unsubscribe from this group and stop receiving emails from it, send an email to soa-model+...@googlegroups.com.

Dan Wlodarski

unread,
Jul 19, 2016, 3:54:01 PM7/19/16
to Membrane SOA Model
Some progress made!

Eclipse Mars is now importing and verifying/installing soa-model/distribution/pom.xml as a Maven project. However, the resulting soa-model-distribution-1.5.4.jar in the target directory returns a "no main manifest attribute" error when run as an executable jar.

Again, thanks for all the help!


On Tuesday, July 19, 2016 at 12:19:00 PM UTC-4, Thomas Bayer wrote:

Hi,

have a look at the target folder using File explorer.

 

Cheers,

Thomas

 

Thomas Bayer

unread,
Jul 20, 2016, 2:46:28 AM7/20/16
to soa-...@googlegroups.com

Hi,

it is no executable jar. You have to add a main class and a manifest:

 

http://stackoverflow.com/questions/5258159/how-to-make-an-executable-jar-file

 

Feel free to generate a pull-request in case you add a main.

 

Cheers,

Thomas

 

 

Am 19.07.16, 21:54 schrieb "Dan Wlodarski" <soa-...@googlegroups.com im Auftrag von dan.wl...@gmail.com>:

--

You received this message because you are subscribed to the Google Groups "Membrane SOA Model" group.
To unsubscribe from this group and stop receiving emails from it, send an email to soa-model+...@googlegroups.com.

Reply all
Reply to author
Forward
0 new messages