Am Montag, 9. Juli 2012 13:20:38 UTC+2 schrieb Lukas Eder: Hi Aaron, > > > [ERROR] Error in manifest for org.jooq:jooq:jar:2.4.0 : The default > package > > '.' is not permitted by the Import-Package syntax. > > This can be caused by compile errors in Eclipse because Eclipse creates > > valid class files regardless of compile errors. > > The following package(s) import from the default package [org.jooq, > > org.jooq.conf, org.jooq.impl, org.jooq.util.h2] > > That sounds weird. I don't see any place in org.jooq.util.h2 for > instance, where a default package could be referenced. > > > Removing the odd "*" import solves the problem for me but looking at git > > blame, this code wasn't changed for some time and I could compile > > 2.4.0-SNAPSHOT last week without problem :-/ >
Look into jOOQ/jOOQ/pom.xml; there you'll find a line with a single "*" inside of a Import-Package element. This causes the problem. Instead of importing anything (including classes what you already define in your code), you should really give a list of packages to import. That said, I get this error when I run Maven from the command line. m2e works (unless you try Run as... > Maven install). > In fact, I had weird issues too, yesterday, when changing version > numbers from 2.4.0-SNAPSHOT to 2.4.0 in my pom.xml files in Eclipse. > The issues I had were NoClassDefFoundError and similar ones when > executing the pre-configured .launch targets. > Maybe it's related to downgrading the maven-bundle-plugin from 2.2.0-SNAPSHOT to 2.1.0. Also note that m2e and Maven (command line) don't always agree. Eclipse and Maven are only 95% compatible. If in doubt, always try to build once from the command line. > I'm using Eclipse Juno now, along with M2E: > http://m2eclipse.sonatype.org/sites/m2e/ (not the one from the > standard Eclipse site). I could solve the problem by removing contents > from the various .classpath files and adding the same contents again. > ... I don't think that's a good idea. This version is pretty old (end of April). Try to upgrade from the official site because the plug-ins there have been tested to work well together. > I suspect, there is either a bug in various possible combinations of > Eclipse / M2E, or a bug in jOOQ's combination of Eclipse .classpath / > pom.xml specifications. Note, I started having some problems since the > introduction of a parent pom.xml. Maybe that is somehow related? > m2e isn't the most stable of plug-ins :-( This is because Maven is pretty slow sometimes (response times aren't an issue for command line tools), so m2e needs heavy caching that sometimes gets out of sync. On top of that, there is a slight mismatch how Eclipse and Maven see the world (Maven has two distinct classpaths for main and test while Eclipse uses the same for both). It's not perfect :-( Regards, A. Digulla
