groovy-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pa...@apache.org
Subject groovy git commit: GROOVY-8766: Add manifest capability entries for OSGi spifly (closes #790)
Date Wed, 07 Nov 2018 11:36:45 GMT
Repository: groovy
Updated Branches:
  refs/heads/GROOVY_2_5_X 62c72a773 -> 3e4173039


GROOVY-8766: Add manifest capability entries for OSGi spifly (closes #790)


Project: http://git-wip-us.apache.org/repos/asf/groovy/repo
Commit: http://git-wip-us.apache.org/repos/asf/groovy/commit/3e417303
Tree: http://git-wip-us.apache.org/repos/asf/groovy/tree/3e417303
Diff: http://git-wip-us.apache.org/repos/asf/groovy/diff/3e417303

Branch: refs/heads/GROOVY_2_5_X
Commit: 3e41730392c8f2735ffeff6a5a8c8c2ad86369ae
Parents: 62c72a7
Author: Benjamin Graf <benjamin.graf@gmx.net>
Authored: Thu Aug 30 20:28:53 2018 +0200
Committer: Paul King <paulk@asert.com.au>
Committed: Wed Nov 7 21:36:32 2018 +1000

----------------------------------------------------------------------
 gradle/assemble.gradle | 11 +++++++++++
 1 file changed, 11 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/groovy/blob/3e417303/gradle/assemble.gradle
----------------------------------------------------------------------
diff --git a/gradle/assemble.gradle b/gradle/assemble.gradle
index 0494394..5828420 100644
--- a/gradle/assemble.gradle
+++ b/gradle/assemble.gradle
@@ -140,6 +140,17 @@ ext.subprojectOsgiManifest = {
     instruction '-nouses', 'true'
     instruction 'Export-Package', "*;version=${groovyBundleVersion}"
     instruction 'Fragment-Host', 'groovy'
+    def folder = new File( "${projectDir}/subprojects/${symbolicName}/src/main/resources/META-INF/services"
)
+    if( folder.exists() ) {
+        if (folder.listFiles().count { it.name ==~ /^(?!(org.codehaus.groovy.transform.ASTTransformation)$).*$/
} > 0) {
+            instruction 'Require-Capability', 'osgi.extender;filter:="(osgi.extender=osgi.serviceloader.registrar)"'
+            instruction 'Require-Capability', 'osgi.extender;filter:="(osgi.extender=osgi.serviceloader.processor)"'
+            folder.eachFileMatch(~/^(?!(org.codehaus.groovy.transform.ASTTransformation)$).*$/)
{
+                instruction 'Require-Capability', "osgi.serviceloader;filter:=\"(osgi.serviceloader=${it.name})\";cardinality:=multiple"
+                instruction 'Provide-Capability', "osgi.serviceloader;osgi.serviceloader=\"${it.name}\""
+            }
+        }
+    }
     classpath = sourceSets.main.runtimeClasspath
 }
 


Mime
View raw message