[cmpi-bindings/f17] Initial import (#798654)

vcrhonek vcrhonek at fedoraproject.org
Tue Mar 13 09:47:20 UTC 2012


commit 463f34d87098a97c122ec01de4263a5853870eaa
Author: Vitezslav Crhonek <vcrhonek at redhat.com>
Date:   Mon Mar 12 16:27:17 2012 +0100

    Initial import (#798654)

 cmpi-bindings-0.4.17-no-ruby-perl.patch  |   37 +++++++++++
 cmpi-bindings-0.4.17-sblim-sigsegv.patch |   17 +++++
 cmpi-bindings-0.4.17.tar.bz2             |  Bin 0 -> 2042880 bytes
 cmpi-bindings.spec                       |   98 ++++++++++++++++++++++++++++++
 sources                                  |    1 +
 5 files changed, 153 insertions(+), 0 deletions(-)
---
diff --git a/cmpi-bindings-0.4.17-no-ruby-perl.patch b/cmpi-bindings-0.4.17-no-ruby-perl.patch
new file mode 100644
index 0000000..3db6578
--- /dev/null
+++ b/cmpi-bindings-0.4.17-no-ruby-perl.patch
@@ -0,0 +1,37 @@
+diff -up cmpi-bindings-0.4.17/swig/CMakeLists.txt.orig cmpi-bindings-0.4.17/swig/CMakeLists.txt
+--- cmpi-bindings-0.4.17/swig/CMakeLists.txt.orig	2011-09-30 21:13:40.000000000 +0200
++++ cmpi-bindings-0.4.17/swig/CMakeLists.txt	2012-03-01 16:08:58.724392497 +0100
+@@ -4,11 +4,11 @@
+ 
+ enable_testing()
+ 
+-FIND_PACKAGE(Ruby)
+-IF (RUBY_LIBRARY AND RUBY_INCLUDE_PATH)
+-  MESSAGE(STATUS "Building Ruby...")
+-  ADD_SUBDIRECTORY(ruby)
+-ENDIF (RUBY_LIBRARY AND RUBY_INCLUDE_PATH)
++#FIND_PACKAGE(Ruby)
++#IF (RUBY_LIBRARY AND RUBY_INCLUDE_PATH)
++#  MESSAGE(STATUS "Building Ruby...")
++#  ADD_SUBDIRECTORY(ruby)
++#ENDIF (RUBY_LIBRARY AND RUBY_INCLUDE_PATH)
+ 
+ FIND_PACKAGE(PythonLibs)
+ IF (PYTHON_LIBRARY)
+@@ -21,9 +21,9 @@ IF (PYTHON_LIBRARY)
+   ENDIF (PYTHON_LINK_LIBS)
+ ENDIF (PYTHON_LIBRARY)
+ 
+-FIND_PACKAGE(Perl)
+-IF (PERL_EXECUTABLE)
+-  MESSAGE(STATUS "Building Perl...")
+-  ADD_SUBDIRECTORY(perl)
+-ENDIF (PERL_EXECUTABLE)
+-    
+\ No newline at end of file
++#FIND_PACKAGE(Perl)
++#IF (PERL_EXECUTABLE)
++#  MESSAGE(STATUS "Building Perl...")
++#  ADD_SUBDIRECTORY(perl)
++#ENDIF (PERL_EXECUTABLE)
++    
diff --git a/cmpi-bindings-0.4.17-sblim-sigsegv.patch b/cmpi-bindings-0.4.17-sblim-sigsegv.patch
new file mode 100644
index 0000000..1eff6c6
--- /dev/null
+++ b/cmpi-bindings-0.4.17-sblim-sigsegv.patch
@@ -0,0 +1,17 @@
+diff -up cmpi-bindings-0.4.17/swig/python/cmpi_pywbem_bindings.py.orig cmpi-bindings-0.4.17/swig/python/cmpi_pywbem_bindings.py
+--- cmpi-bindings-0.4.17/swig/python/cmpi_pywbem_bindings.py.orig	2012-03-01 17:05:31.878367281 +0100
++++ cmpi-bindings-0.4.17/swig/python/cmpi_pywbem_bindings.py	2012-03-01 17:06:34.718110137 +0100
+@@ -350,10 +350,10 @@ class BrokerCIMOMHandle(object):
+             allow_null_ns = False
+         else:
+             allow_null_ns = True
+-            if self.broker.name() == 'RequestHandler':
++#            if self.broker.name() == 'RequestHandler':
+                 # Check sblim bug #2185410.
+-                if instance.path is not None:
+-                    instance.path.namespace = None
++#                if instance.path is not None:
++#                    instance.path.namespace = None
+         inst = self.proxy.pywbem2cmpi_inst(instance, allow_null_ns)
+         rv = self.broker.deliverIndication(self.ctx, ns, inst)
+         return rv
diff --git a/cmpi-bindings-0.4.17.tar.bz2 b/cmpi-bindings-0.4.17.tar.bz2
new file mode 100644
index 0000000..d3a8baf
Binary files /dev/null and b/cmpi-bindings-0.4.17.tar.bz2 differ
diff --git a/cmpi-bindings.spec b/cmpi-bindings.spec
new file mode 100644
index 0000000..7cd1541
--- /dev/null
+++ b/cmpi-bindings.spec
@@ -0,0 +1,98 @@
+Name:           cmpi-bindings
+Version:        0.4.17
+Release:        2%{?dist}
+Summary:        Adapter to write and run CMPI-type CIM providers
+
+Group:          Development/Libraries
+License:        BSD
+URL:            http://github.com/kkaempf/cmpi-bindings
+# The source for this package was pulled from upstream's vcs.  Use the
+# following commands to generate the tarball:
+#  git clone https://github.com/kkaempf/cmpi-bindings.git cmpi-bindings-0.4.17
+#  tar -cJvf cmpi-bindings-0.4.17.tar.xz cmpi-bindings-0.4.17
+Source0:         %{name}-%{version}.tar.bz2
+
+#Patch0: don't build ruby and perl bingings
+Patch0:         cmpi-bindings-0.4.17-no-ruby-perl.patch
+#Patch1: removes workaround no longer needed
+Patch1:         cmpi-bindings-0.4.17-sblim-sigsegv.patch
+
+BuildRequires:  cmake gcc-c++ swig >= 1.3.34
+BuildRequires:  curl-devel pkgconfig sed
+BuildRequires:  sblim-cmpi-devel
+BuildRequires:  python2-devel
+
+%description
+CMPI-compliant provider interface for various languages via SWIG
+
+
+%package -n cmpi-bindings-pywbem
+Summary:        Adapter to write and run CMPI-type CIM providers in Python
+Group:          Development/Languages
+Requires:       pywbem
+ 
+%description -n cmpi-bindings-pywbem
+CMPI-compliant provider interface for Python
+
+
+%prep
+%setup -q
+%patch0 -p1
+%patch1 -p1
+# change hardcoded path from /usr/lib/pycim/ to something better
+sed -i 's@/usr/lib/pycim/@'`echo %{python_sitelib}/pycim/`'@' swig/python/cmpi_pywbem_bindings.py
+# let user know where the providers have to be placed
+cat > README.Fedora << EOS 
+Python provider interface expects the providers to be placed in:
+%{python_sitelib}/pycim/
+
+You can customize the path - edit line 428 in:
+%{python_sitelib}/cmpi_pywbem_bindings.py
+EOS
+
+
+%build
+mkdir build
+cd build
+cmake -DCMAKE_INSTALL_PREFIX=%_prefix \
+      -DLIB=%{_lib} \
+      -DCMAKE_VERBOSE_MAKEFILE=TRUE \
+      -DCMAKE_C_FLAGS_RELEASE:STRING="%{optflags}" \
+      -DCMAKE_CXX_FLAGS_RELEASE:STRING="%{optflags}" \
+      -DCMAKE_BUILD_TYPE=Release \
+      -DCMAKE_SKIP_RPATH=1 \
+      ..  
+make %{?_smp_mflags}
+
+
+%install
+rm -rf $RPM_BUILD_ROOT
+cd build
+mkdir -p $RPM_BUILD_ROOT%{_datadir}/cmpi
+make install DESTDIR=$RPM_BUILD_ROOT
+# create directory for providers
+mkdir -p $RPM_BUILD_ROOT%{python_sitelib}/pycim/
+
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+
+%files -n cmpi-bindings-pywbem
+%defattr(-,root,root,-)
+%doc README ANNOUNCE COPYING LICENSE.BSD README.Fedora
+%dir %{_libdir}/cmpi
+%{_libdir}/cmpi/libpyCmpiProvider.so
+%dir %{_datadir}/cmpi
+%{python_sitelib}/cmpi_pywbem_bindings.py*
+%{python_sitelib}/cmpi.py*
+%dir %{python_sitelib}/pycim/
+
+
+%changelog
+* Thu Mar 08 2012 Vitezslav Crhonek <vcrhonek at redhat.com> - 0.4.17-2
+- Create and own "pycim" directory
+- Add documentation and create README.Fedora
+
+* Thu Mar 01 2012 Vitezslav Crhonek <vcrhonek at redhat.com> - 0.4.17-1
+- Initial support (ruby and perl bindings are disabled)
diff --git a/sources b/sources
index e69de29..532159f 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+55020060b49225cce6fc651aec8e524f  cmpi-bindings-0.4.17.tar.bz2


More information about the scm-commits mailing list