[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] [libvirt-php 2/2] Added libvirt-php.obs.spec



* libvirt-php.obs.spec: this file should works for Fedora 14,
  openSuSE 11.3, and SLES 11 SP1 on openSuSE Build Service or
  localhost.
* Makefile.am: added EXTRA_DIST = libvirt-php.obs.spec
---
 Makefile.am          |    2 +
 aclocal.m4           |    4 +-
 libvirt-php.obs.spec |   80 ++++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 84 insertions(+), 2 deletions(-)
 create mode 100644 libvirt-php.obs.spec

diff --git a/Makefile.am b/Makefile.am
index d229a00..eac6726 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1 +1,3 @@
 SUBDIRS = src docs
+
+EXTRA_DIST = libvirt-php.obs.spec
diff --git a/aclocal.m4 b/aclocal.m4
index 4bb6f78..a1fa316 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -13,8 +13,8 @@
 
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.66],,
-[m4_warning([this file was generated for autoconf 2.66.
+m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],,
+[m4_warning([this file was generated for autoconf 2.65.
 You have another version of autoconf.  It may work, but is not guaranteed to.
 If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically `autoreconf'.])])
diff --git a/libvirt-php.obs.spec b/libvirt-php.obs.spec
new file mode 100644
index 0000000..2e3ab59
--- /dev/null
+++ b/libvirt-php.obs.spec
@@ -0,0 +1,80 @@
+%define 	req_libvirt_version 0.6.2
+%if 0%{?suse_version} || 0%{?sles_version} 
+%define		php_confdir %{_sysconfdir}/php5/conf.d
+%define		php_extdir 	%{_libdir}/php5/extensions
+%else
+%define		php_confdir %{_sysconfdir}/php.d 
+%define		php_extdir  %{_libdir}/php/modules
+%endif
+
+Name:		libvirt-php
+Version:	0.4
+Release:	1%{?dist}%{?extra_release}
+Summary:	PHP language binding for Libvirt
+
+%if 0%{?suse_version} || 0%{?sles_version} 
+Group:		Development/Libraries/PHP
+%else
+Group:		Development/Libraries
+%endif
+License:	PHP
+URL:		http://libvirt.org/
+Source0:	http://libvirt.org/sources/libvirt-php-%{version}.tar.gz
+BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root
+
+BuildRequires:	php-devel
+BuildRequires:	libvirt-devel >= %{req_libvirt_version}
+BuildRequires:	libxml2-devel
+%if 0%{?suse_version} || 0%{?sles_version} 
+BuildRequires:	xhtml-dtd
+%else
+BuildRequires:	xhtml1-dtds
+%endif
+Requires:	libvirt >= %{req_libvirt_version}
+%if 0%{?suse_version} || 0%{?sles_version} 
+Requires:	php5
+%else
+Requires:	php
+%endif
+
+%description
+PHP language bindings for Libvirt API. 
+For more details see: http://phplibvirt.cybersales.cz/ http://www.libvirt.org/ http://www.php.net/
+
+%package -n libvirt-php-doc
+Summary:	Document of libvirt-php
+Group:		Development/Libraries/PHP
+Requires:	libvirt-php = %{version}
+
+%description -n libvirt-php-doc
+PHP language bindings for Libvirt API. 
+For more details see: http://phplibvirt.cybersales.cz/ http://www.libvirt.org/ http://www.php.net/
+
+This package contain the document for libvirt-php.
+
+%prep
+%setup -q -n libvirt-php-%{version}
+
+%build
+%configure
+./configure --with-html-dir=%{_datadir}/doc --with-html-subdir=%{name}-%{version}/html
+make %{?_smp_mflags}
+
+%install
+make install DESTDIR=%{buildroot}
+
+%clean
+rm -rf %{buildroot}
+
+%files
+%defattr(-,root,root,-)
+%{php_extdir}/libvirt-php.so
+%config(noreplace) %{php_confdir}/libvirt-php.ini
+
+%files -n libvirt-php-doc
+%defattr(-,root,root,-)
+%doc
+%{_datadir}/doc/%{name}-%{version}/html
+
+%changelog
+
-- 
1.7.1


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]