Clojure

Build Clojure with Maven 2

Details

  • Type: Enhancement Enhancement
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Completed
  • Affects Version/s: Backlog
  • Fix Version/s: Release 1.3
  • Component/s: None
  • Labels:
    None
  • Patch:
    Code and Test
  • Approval:
    Ok

Description

See Common Contrib Build wiki page and the lengthy clojure-dev discussion

For examples of the CI/release process under Hudson, see clojure-testbuild

  1. 0681-patch-10.patch
    04/Jan/11 4:03 PM
    30 kB
    Stuart Halloway
  2. 0681-patch-11.patch
    05/Jan/11 7:18 AM
    35 kB
    Stuart Halloway
  3. maven-build-1.diff.gz
    26/Nov/10 2:05 PM
    891 kB
    Stuart Sierra
  4. maven-build-2.diff.gz
    26/Nov/10 2:09 PM
    891 kB
    Stuart Sierra
  5. maven-build-3.diff.gz
    29/Nov/10 6:28 PM
    8 kB
    Stuart Sierra
  6. maven-build-4.diff.gz
    01/Dec/10 8:05 AM
    8 kB
    Stuart Sierra
  7. maven-build-5.diff.gz
    01/Dec/10 8:59 AM
    8 kB
    Stuart Sierra
  8. maven-build-6.diff.gz
    03/Dec/10 9:39 AM
    9 kB
    Stuart Sierra
  9. maven-build-7.diff.gz
    03/Dec/10 4:13 PM
    9 kB
    Stuart Sierra
  10. maven-build-8.diff.gz
    09/Dec/10 5:14 PM
    9 kB
    Stuart Sierra
  11. maven-build-9.diff.gz
    17/Dec/10 4:10 PM
    9 kB
    Stuart Sierra

Activity

Hide
Stuart Halloway added a comment -

Patch 11 is basically patch 10 + the correct pom.xml from patch 9.

Show
Stuart Halloway added a comment - Patch 11 is basically patch 10 + the correct pom.xml from patch 9.
Hide
Stuart Halloway added a comment -

Patch 10 is bad. The pom file from patch 9 was lost, and my local environment didn't notice somehow. Will test and resubmit a patch 11 that is basically patch 10 with the correct pom.xml from patch 9.

Grumble.

Show
Stuart Halloway added a comment - Patch 10 is bad. The pom file from patch 9 was lost, and my local environment didn't notice somehow. Will test and resubmit a patch 11 that is basically patch 10 with the correct pom.xml from patch 9. Grumble.
Hide
Stuart Halloway added a comment -

Patch 10 merely updates patch 9 to apply to current master. (A test namespace had changed. The list of test files has always been hard-coded and fragile, but that's a patch for another day.)

I tested all the Ant and Maven commands documented in the reademe, and everything looks sensible.

Show
Stuart Halloway added a comment - Patch 10 merely updates patch 9 to apply to current master. (A test namespace had changed. The list of test files has always been hard-coded and fragile, but that's a patch for another day.) I tested all the Ant and Maven commands documented in the reademe, and everything looks sensible.
Hide
Stuart Sierra added a comment -

Reported issues should be fixed, although I cannot reproduce the warning messages.

What version of Maven produced those warnings?

Show
Stuart Sierra added a comment - Reported issues should be fixed, although I cannot reproduce the warning messages. What version of Maven produced those warnings?
Hide
Stuart Sierra added a comment -

Patch maven-build-9.diff.gz replaces previous patches.

Differences from previous patches:

  • Adds plugin coordinates to fix the warnings reported by Stu Halloway
  • Avoids compiling the test sources twice
  • Correctly sets POM version to 1.3.0-master-SNAPSHOT
Show
Stuart Sierra added a comment - Patch maven-build-9.diff.gz replaces previous patches. Differences from previous patches:
  • Adds plugin coordinates to fix the warnings reported by Stu Halloway
  • Avoids compiling the test sources twice
  • Correctly sets POM version to 1.3.0-master-SNAPSHOT
Hide
Stuart Halloway added a comment -

Can you please run down two small issues:

(1) I get a warning on the maven build:

[WARNING] 
[WARNING] Some problems were encountered while building the effective model for org.clojure:clojure:jar:1.3.0-testbuild10-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 52, column 15
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-surefire-plugin is missing. @ line 181, column 15
[WARNING] 
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING] 
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]

(2) The version is set to 1.3.0-testbuild10-SNAPSHOT. Am I supposed to change this by hand-editing the pom?

Show
Stuart Halloway added a comment - Can you please run down two small issues: (1) I get a warning on the maven build:
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for org.clojure:clojure:jar:1.3.0-testbuild10-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 52, column 15
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-surefire-plugin is missing. @ line 181, column 15
[WARNING] 
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING] 
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]
(2) The version is set to 1.3.0-testbuild10-SNAPSHOT. Am I supposed to change this by hand-editing the pom?
Hide
Stuart Sierra added a comment -

To elaborate: patch "maven-build-8" avoids both clojure-maven-plugin and bootstrap load order by using maven-ant-plugin and Ant to drive the Clojure steps in the build.

We still need to address these issues, but that may take a long time, and we want to move forward with releases to public repositories.

Show
Stuart Sierra added a comment - To elaborate: patch "maven-build-8" avoids both clojure-maven-plugin and bootstrap load order by using maven-ant-plugin and Ant to drive the Clojure steps in the build. We still need to address these issues, but that may take a long time, and we want to move forward with releases to public repositories.
Hide
Stuart Sierra added a comment -

Patch "maven-build-8" answers those questions by postponing them.

This patch is ready to test and apply.

Show
Stuart Sierra added a comment - Patch "maven-build-8" answers those questions by postponing them. This patch is ready to test and apply.
Hide
Stuart Sierra added a comment -

Patch maven-build-8.diff.gz replaces previous patches.

This version uses a hybrid Maven + Ant build process. For local development, only Ant is needed. The POM does not depend on anything outside of the standard Maven toolchain and the Sonatype open-source deployment configuration.

Show
Stuart Sierra added a comment - Patch maven-build-8.diff.gz replaces previous patches. This version uses a hybrid Maven + Ant build process. For local development, only Ant is needed. The POM does not depend on anything outside of the standard Maven toolchain and the Sonatype open-source deployment configuration.
Hide
Stuart Sierra added a comment -

Patch maven-build-7.diff.gz replaces previous patches.

This patch adds back in a simplified build.xml for local development using Ant only.

The Ant build.xml script reads the project version number from pom.xml, so pom.xml remains the definitive project description.

Show
Stuart Sierra added a comment - Patch maven-build-7.diff.gz replaces previous patches. This patch adds back in a simplified build.xml for local development using Ant only. The Ant build.xml script reads the project version number from pom.xml, so pom.xml remains the definitive project description.
Hide
Stuart Sierra added a comment -

Patch maven-build-6.diff.gz replaces previous patches.

This updates to clojure-maven-plugin version 1.3.7; README updates.

Show
Stuart Sierra added a comment - Patch maven-build-6.diff.gz replaces previous patches. This updates to clojure-maven-plugin version 1.3.7; README updates.
Hide
Stuart Sierra added a comment - - edited

Finally got a successful staging release

Unfortunately, the JAR file is misnamed. This is a clojure-maven-plugin bug that will be fixed in the next release.

Show
Stuart Sierra added a comment - - edited Finally got a successful staging release Unfortunately, the JAR file is misnamed. This is a clojure-maven-plugin bug that will be fixed in the next release.
Hide
Stuart Sierra added a comment -

Patch maven-build-5.diff.gz replaces previous patches.

This fixes a few more testing issues.

Show
Stuart Sierra added a comment - Patch maven-build-5.diff.gz replaces previous patches. This fixes a few more testing issues.
Hide
Stuart Sierra added a comment -

Patch maven-build-4.diff.gz replaces previous patches.

This works around compilation-order issues by using a bootstrap script to compile namespaces in the correct order.

Show
Stuart Sierra added a comment - Patch maven-build-4.diff.gz replaces previous patches. This works around compilation-order issues by using a bootstrap script to compile namespaces in the correct order.
Hide
Stuart Sierra added a comment -

Updated patch replaces previous patches.

This does minimal file/directory renaming while preserving the same functionality as the previous patches.

But an older problem has resurfaced: the nondeterministic load-order sometimes causes compilation to fail. For example, on Hudson

Show
Stuart Sierra added a comment - Updated patch replaces previous patches. This does minimal file/directory renaming while preserving the same functionality as the previous patches. But an older problem has resurfaced: the nondeterministic load-order sometimes causes compilation to fail. For example, on Hudson
Hide
Stuart Halloway added a comment -

Maven is capable of using the directory structure we already have. It seems this patch is doing two things: getting us onto maven, and reorganizing the project. Is there any reason these can't be considered separately?

Show
Stuart Halloway added a comment - Maven is capable of using the directory structure we already have. It seems this patch is doing two things: getting us onto maven, and reorganizing the project. Is there any reason these can't be considered separately?
Hide
Stuart Sierra added a comment -

Replaces previous patch.

  • fixed SCM URLs in pom.xml
Show
Stuart Sierra added a comment - Replaces previous patch.
  • fixed SCM URLs in pom.xml

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: