jimv (1) [Avatar] Offline
#1
I've downloaded the source, set my environmental vars, but when I try to run ./install.sh, I get the following:

./install.sh
[INFO] Scanning for projects...
[ERROR] The build could not read 2 projects -> [Help 1]
[ERROR]
[ERROR] The project ajia:common-aspectj:1.0-SNAPSHOT (/Users/jevogel2/Downloads/Manning ePubs/AspectJInActionSecondEdition-sources-1/common/workspace/common-aspectj/pom.xml) has 1 error
[ERROR] Non-resolvable parent POM: Could not find artifact ajia:common-java:pom:1.0-SNAPSHOT and 'parent.relativePath' points at wrong local POM @ line 5, column 10 -> [Help 2]
[ERROR]
[ERROR] The project ajia:CommonPointcuts:1.0-SNAPSHOT (/Users/jevogel2/Downloads/Manning ePubs/AspectJInActionSecondEdition-sources-1/common/workspace/CommonPointcuts/pom.xml) has 1 error
[ERROR] Non-resolvable parent POM: Could not find artifact ajia:common-aspectj:pom:1.0-SNAPSHOT and 'parent.relativePath' points at wrong local POM @ line 6, column 13 -> [Help 2]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException
[ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException


I've also imported section 3.3JoinPointDemonstrationExample into eclipse, and I get a very similiar error:

Project build error: Non-resolvable parent POM: Could not find artifact ajia:common-aspectj:pom:1.0-SNAPSHOT and 'parent.relativePath' points at wrong local POM

Any suggestions/help appreciated!!
Thanks
Jim
andreeeas (2) [Avatar] Offline
#2
Re: Problem installing source
Bet you're using Maven Version >= 3. I got the same error and got rid of it by simply installing Maven Version 2.2.1. Now it works like a charm. Seems there are some compatibility issues between 2 and 3 when it comes to defining parent poms.
swag (1) [Avatar] Offline
#3
I solved this problem by going into the pom.xml files in the affected projects (common-aspectj and CommonPointcuts) and changing the artifactID to:

<artifactId>common-ajia</artifactId>

Now you can use Maven 3.0 or later

Edit: Seems like this code is too old, there are several other problems when trying to build it. Even rolling back to Maven 2.xx didn't help. Oh well.