diff --git a/build.gradle b/build.gradle index fa641fe643..83764a2d3f 100644 --- a/build.gradle +++ b/build.gradle @@ -234,11 +234,17 @@ subprojects { subProject -> // need to be here (temporarily). classesDir = sourceSets.main.output.classesDir classpath = configurations.runtime + + instruction 'Import-Package', + // Temporarily support JTA 1.1 -- Karaf and other frameworks still + // use it. Without this, the plugin generates [1.2,2). + 'javax.transaction;version="[1.1,2)"', + '*' instruction 'Export-Package', exportPackages.toArray(new String[0]) instruction 'Private-Package', privatePackages.toArray(new String[0]) - instruction 'Bundle-Vendor', 'Hibernate.org' + instruction 'Bundle-Vendor', 'Hibernate.org' instruction 'Implementation-Url', 'http://hibernate.org' instruction 'Implementation-Version', version instruction 'Implementation-Vendor', 'Hibernate.org' diff --git a/hibernate-c3p0/hibernate-c3p0.gradle b/hibernate-c3p0/hibernate-c3p0.gradle index 3d19fe5db2..20e36fcf19 100644 --- a/hibernate-c3p0/hibernate-c3p0.gradle +++ b/hibernate-c3p0/hibernate-c3p0.gradle @@ -13,6 +13,5 @@ dependencies { jar { manifest { instruction 'Bundle-Description', 'Hibernate ORM C3P0' - instruction 'Bundle-SymbolicName', 'org.hibernate.c3p0' } } \ No newline at end of file diff --git a/hibernate-core/hibernate-core.gradle b/hibernate-core/hibernate-core.gradle index d8bcdefb68..9477a03594 100644 --- a/hibernate-core/hibernate-core.gradle +++ b/hibernate-core/hibernate-core.gradle @@ -40,7 +40,6 @@ manifest.mainAttributes( jar { manifest { instruction 'Bundle-Description', 'Hibernate ORM Core' - instruction 'Bundle-SymbolicName', 'org.hibernate.core' instruction 'Import-Package', 'javax.security.auth;resolution:=optional', @@ -49,6 +48,13 @@ jar { 'javax.validation.constraints;resolution:=optional', 'javax.validation.groups;resolution:=optional', 'javax.validation.metadata;resolution:=optional', + // TODO: Shouldn't have to explicitly list this, but the plugin + // generates it with a [1.0,2) version. + 'javax.persistence;version="2.1.0"', + // Temporarily support JTA 1.1 -- Karaf and other frameworks still + // use it. Without this, the plugin generates [1.2,2). + // build.gradle adds javax.transaction for all modules + 'javax.transaction.xa;version="[1.1,2)"', '*' // TODO: Uncomment once EntityManagerFactoryBuilderImpl no longer diff --git a/hibernate-ehcache/hibernate-ehcache.gradle b/hibernate-ehcache/hibernate-ehcache.gradle index 0f867673eb..676a0e864c 100644 --- a/hibernate-ehcache/hibernate-ehcache.gradle +++ b/hibernate-ehcache/hibernate-ehcache.gradle @@ -8,6 +8,5 @@ dependencies { jar { manifest { instruction 'Bundle-Description', 'Hibernate ORM EHCache' - instruction 'Bundle-SymbolicName', 'org.hibernate.ehcache' } } \ No newline at end of file diff --git a/hibernate-entitymanager/hibernate-entitymanager.gradle b/hibernate-entitymanager/hibernate-entitymanager.gradle index 4fd6703f9b..d3556ad55e 100644 --- a/hibernate-entitymanager/hibernate-entitymanager.gradle +++ b/hibernate-entitymanager/hibernate-entitymanager.gradle @@ -27,7 +27,6 @@ dependencies { jar { manifest { instruction 'Bundle-Description', 'Hibernate ORM JPA Entity Manager' - instruction 'Bundle-SymbolicName', 'org.hibernate.entitymanager' // A cdi-api OSGi bundle does not currently exist. For now, explicitly // ignore its packages. This will only cause issues if an app tries @@ -39,6 +38,14 @@ jar { // occurs. instruction 'Import-Package', '!javax.enterprise*', + 'javax.enterprise.context.spi;resolution:=optional', + 'javax.enterprise.inject.spi;resolution:=optional', + // TODO: Shouldn't have to explicitly list the JPA packages, but + // the plugin generates them with [1.0,2) versions. + 'javax.persistence;version="2.1.0"', + 'javax.persistence.criteria;version="2.1.0"', + 'javax.persistence.metamodel;version="2.1.0"', + 'javax.persistence.spi;version="2.1.0"', '*' } } diff --git a/hibernate-envers/hibernate-envers.gradle b/hibernate-envers/hibernate-envers.gradle index 9421a029b5..c3f9a6ec7e 100644 --- a/hibernate-envers/hibernate-envers.gradle +++ b/hibernate-envers/hibernate-envers.gradle @@ -52,6 +52,5 @@ generateSources.dependsOn generateJpaMetamodelClasses jar { manifest { instruction 'Bundle-Description', 'Hibernate ORM Envers' - instruction 'Bundle-SymbolicName', 'org.hibernate.envers' } } \ No newline at end of file diff --git a/hibernate-infinispan/hibernate-infinispan.gradle b/hibernate-infinispan/hibernate-infinispan.gradle index a679910470..ae6adca46a 100644 --- a/hibernate-infinispan/hibernate-infinispan.gradle +++ b/hibernate-infinispan/hibernate-infinispan.gradle @@ -44,6 +44,5 @@ artifacts.archives sourcesTestJar jar { manifest { instruction 'Bundle-Description', 'Hibernate ORM Infinispan' - instruction 'Bundle-SymbolicName', 'org.hibernate.infinispan' } } \ No newline at end of file diff --git a/hibernate-osgi/hibernate-osgi.gradle b/hibernate-osgi/hibernate-osgi.gradle index af99af5fd7..fa45f92e6f 100644 --- a/hibernate-osgi/hibernate-osgi.gradle +++ b/hibernate-osgi/hibernate-osgi.gradle @@ -8,6 +8,12 @@ jar { manifest { instruction 'Bundle-Activator', 'org.hibernate.osgi.HibernateBundleActivator' instruction 'Bundle-Description', 'Hibernate ORM OSGi' - instruction 'Bundle-SymbolicName', 'org.hibernate.osgi' + + instruction 'Import-Package', + // TODO: Shouldn't have to explicitly list this, but the plugin + // generates it with a [1.0,2) version. + 'javax.persistence;version="2.1.0"', + 'javax.persistence.spi;version="2.1.0"', + '*' } } diff --git a/hibernate-proxool/hibernate-proxool.gradle b/hibernate-proxool/hibernate-proxool.gradle index c6b0bcb133..77c3788721 100644 --- a/hibernate-proxool/hibernate-proxool.gradle +++ b/hibernate-proxool/hibernate-proxool.gradle @@ -7,6 +7,5 @@ dependencies { jar { manifest { instruction 'Bundle-Description', 'Hibernate ORM Proxool' - instruction 'Bundle-SymbolicName', 'org.hibernate.proxool' } } \ No newline at end of file diff --git a/hibernate-testing/hibernate-testing.gradle b/hibernate-testing/hibernate-testing.gradle index 28a3dd3a76..5c067e6a19 100644 --- a/hibernate-testing/hibernate-testing.gradle +++ b/hibernate-testing/hibernate-testing.gradle @@ -13,6 +13,5 @@ dependencies { jar { manifest { instruction 'Bundle-Description', 'Hibernate ORM Testing' - instruction 'Bundle-SymbolicName', 'org.hibernate.testing' } } \ No newline at end of file