diff --git a/slf4j.changes b/slf4j.changes index 2b3dd6c..bc12e2a 100644 --- a/slf4j.changes +++ b/slf4j.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Sep 19 14:22:54 UTC 2013 - mvyskocil@suse.com + +- self-provide osgi(slf4j.api) symbol + ------------------------------------------------------------------- Fri Sep 13 10:51:12 UTC 2013 - mvyskocil@suse.com diff --git a/slf4j.spec b/slf4j.spec index 81654a5..824dac3 100644 --- a/slf4j.spec +++ b/slf4j.spec @@ -45,6 +45,9 @@ BuildRequires: log4j Requires: cal10n Requires: java Requires: javapackages-tools +# this is ugly hack, which creates package wich requires the same, +# however slf4j is not splitted between -api and -impl, but pom files are modeled as it was +Provides: osgi(slf4j.api) BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -87,6 +90,15 @@ sed -i -e "s|ant<|org.apache.ant<|g" integration/pom.xml %{_bindir}/find -name "*.css" -o -name "*.js" -o -name "*.txt" | \ %{_bindir}/xargs -t %{__perl} -pi -e 's/\r$//g' +# The general pattern is that the API package exports API classes and does +# # not require impl classes. slf4j was breaking that causing "A cycle was +# # detected when generating the classpath slf4j.api, slf4j.nop, slf4j.api." +# # The API bundle requires impl package, so to avoid cyclic dependencies +# # during build time, it is necessary to mark the imported package as an +# # optional one. +# # Reported upstream: http://bugzilla.slf4j.org/show_bug.cgi?id=283 +sed -i "/Import-Package/s/.$/;resolution:=optional&/" slf4j-api/src/main/resources/META-INF/MANIFEST.MF + %build export CLASSPATH=$(build-classpath log4j \ commons-logging \