[FELIX-4659] The maven bundle plugin incorrectly reports cardinality on service references in the generated generic requirements
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1628630 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/bundleplugin/src/main/resources/org/apache/felix/bundleplugin/scr.xsl b/bundleplugin/src/main/resources/org/apache/felix/bundleplugin/scr.xsl
index bc9caf0..46cee16 100644
--- a/bundleplugin/src/main/resources/org/apache/felix/bundleplugin/scr.xsl
+++ b/bundleplugin/src/main/resources/org/apache/felix/bundleplugin/scr.xsl
@@ -62,9 +62,15 @@
//scr12:component/reference">
<xsl:value-of select="'Require-Capability: osgi.service;effective:=active;'" />
<xsl:choose>
- <xsl:when test="@cardinality = '0..1' or @cardinality = '0..n'">
+ <xsl:when test="@cardinality = '0..1'">
<xsl:value-of select="'resolution:=optional;'" />
</xsl:when>
+ <xsl:when test="@cardinality = '0..n'">
+ <xsl:value-of select="'resolution:=optional;cardinality:=multiple;'" />
+ </xsl:when>
+ <xsl:when test="@cardinality = '1..n'">
+ <xsl:value-of select="'cardinality:=multiple;'" />
+ </xsl:when>
</xsl:choose>
<xsl:choose>
<xsl:when test="@target">