X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=openchange.spec;h=bcc3f1f05d8b14bf93ba9855210308cc273eb3c2;hb=6b063ab9b6cd76576373697bbad7180b9d077468;hp=4a85debaab90cecf87ddb3644c645237e919b210;hpb=503206d3f34ab457c05635871a658885f110303c;p=packages%2Fopenchange.git diff --git a/openchange.spec b/openchange.spec index 4a85deb..bcc3f1f 100644 --- a/openchange.spec +++ b/openchange.spec @@ -1,20 +1,37 @@ +# TODO +# - nagios plugin (see it's files section for details) # # Conditional build: %bcond_without apidocs # do not build and package API docs -# +%bcond_with mapiproxy # mapiproxy suite (disabled with Samba 4.4+) +%bcond_with mapitest # mapitest utility (disabled with Samba 4.4+) +%bcond_with python # build python package (requires disabled mapiproxy) + +%define cname VULCAN Summary: OpenChange - portable implementation of MS Exchange Server and Exchange protocols Summary(pl.UTF-8): OpenChange - przenośna implementacja serwera oraz protokołów MS Exchange Name: openchange Version: 2.3 -Release: 1 +Release: 61 License: GPL v3+ Group: Libraries -%define cname VULCAN +#Source0Download: https://github.com/openchange/openchange/releases Source0: https://github.com/openchange/openchange/archive/%{name}-%{version}-%{cname}.tar.gz # Source0-md5: 96c13c78c2bcbd7040f7848746284b9f -Patch0: %{name}-samba-private.patch +Patch0: disable-mapiproxy.patch Patch1: %{name}-link.patch -URL: http://www.openchange.org/ +Patch2: flex2.6.patch +Patch3: samba-4.2.patch +Patch4: fix-connection-args.patch +Patch5: samba-4.4.patch +Patch6: %{name}-covscan.patch +Patch7: %{name}-samba-4.10-macros.patch +Patch8: %{name}-libical.patch +Patch9: samba-4.11.patch +Patch10: samba-4.12.patch +Patch11: %{name}-nanomsg.patch +Patch12: samba-4.15.patch +URL: https://github.com/openchange BuildRequires: QtCore-devel >= 4.3.0 BuildRequires: QtGui-devel >= 4.3.0 BuildRequires: autoconf >= 2.57 @@ -28,24 +45,31 @@ BuildRequires: libmemcached-devel >= 1.0.18 BuildRequires: libpcap-devel BuildRequires: libstdc++-devel BuildRequires: mysql-devel -BuildRequires: nanomsg-devel >= 0.5 +BuildRequires: nanomsg-devel >= 1.0.0 BuildRequires: perl-base BuildRequires: pkgconfig >= 1:0.20 BuildRequires: popt-devel +%if %{with python} BuildRequires: python-devel >= 1:2.7 -BuildRequires: rpmbuild(macros) >= 1.219 -# with DCERCP multiplex and pending call support (upstream 4.1.18+ or 4.2.>1) -BuildRequires: samba-devel >= 4.2.1 -BuildRequires: samba-pidl >= 4.2.1 +BuildRequires: python-samba >= 4.2.2 +%endif +BuildRequires: rpm-build >= 4.6 +BuildRequires: rpmbuild(macros) >= 1.752 +# with DCERCP multiplex and pending call support (upstream 4.1.18+ or 4.2.2+) +# samba-4.10-macros patch requires samba-pidl 4.10+ +BuildRequires: samba-devel >= 4.10 +BuildRequires: samba-pidl >= 4.10 BuildRequires: sed >= 4.0 BuildRequires: subunit-devel BuildRequires: talloc-devel BuildRequires: tdb-devel BuildRequires: zlib-devel Requires: %{name}-libs = %{version}-%{release} -Requires: python-openchange = %{version}-%{release} +%{?with_python:Requires: python-openchange = %{version}-%{release}} BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) +%define _noautoreq_perl utils + %description OpenChange is a portable Open Source implementation of Microsoft Exchange server and Exchange protocols. It provides a complete @@ -87,6 +111,11 @@ Summary: Header files for OpenChange libraries Summary(pl.UTF-8): Pliki nagłówkowe bibliotek OpenChange Group: Development/Libraries Requires: %{name}-libs = %{version}-%{release} +Requires: ldb-devel +Requires: samba-devel >= 4.2.2 +Requires: talloc-devel +Requires: tevent-devel +Requires: zlib-devel %description devel Header files for OpenChange libraries. @@ -98,6 +127,7 @@ Pliki nagłówkowe bibliotek OpenChange. Summary: C++ interface to OpenChange MAPI library Summary(pl.UTF-8): Interfejs C++ do biblioteki OpenChange MAPI Group: Libraries +Requires: %{name}-libs = %{version}-%{release} %description c++ C++ interface to OpenChange MAPI library. @@ -110,6 +140,8 @@ Summary: Header files of C++ interface to OpenChange MAPI library Summary(pl.UTF-8): Pliki nagłówkowe interfejsu C++ do biblioteki OpenChange MAPI Group: Development/Libraries Requires: %{name}-c++ = %{version}-%{release} +Requires: %{name}-devel = %{version}-%{release} +Requires: libstdc++-devel %description c++-devel Header files of C++ interface to OpenChange MAPI library. @@ -121,6 +153,9 @@ Pliki nagłówkowe interfejsu C++ do biblioteki OpenChange MAPI. Summary: Qt interface to OpenChange MAPI library Summary(pl.UTF-8): Interfejs Qt do biblioteki OpenChange MAPI Group: Libraries +Requires: %{name}-c++ = %{version}-%{release} +Requires: QtCore >= 4.3.0 +Requires: QtGui >= 4.3.0 %description qt Qt interface to OpenChange MAPI library. @@ -133,6 +168,7 @@ Summary: Header files of Qt interface to OpenChange MAPI library Summary(pl.UTF-8): Pliki nagłówkowe interfejsu Qt do biblioteki OpenChange MAPI Group: Development/Libraries Requires: %{name}-qt = %{version}-%{release} +Requires: QtGui-devel >= 4.3.0 %description qt-devel Header files of Qt interface to OpenChange MAPI library. @@ -144,6 +180,7 @@ Pliki nagłówkowe interfejsu Qt do biblioteki OpenChange MAPI. Summary: API documentation for OpenChange libraries Summary(pl.UTF-8): Dokumentacja API bibliotek OpenChange Group: Documentation +BuildArch: noarch %description apidocs API documentation for OpenChange libraries. @@ -180,6 +217,17 @@ Wtyczka Nagiosa do sprawdzania usług Exchange/OpenChange. %setup -q -n %{name}-%{name}-%{version}-%{cname} %patch0 -p1 %patch1 -p1 +%patch2 -p1 +%patch3 -p1 +%patch4 -p1 +%patch5 -p1 +%patch6 -p1 +%patch7 -p1 +%patch8 -p1 +%patch9 -p1 +%patch10 -p1 +%patch11 -p1 +%patch12 -p1 # no switch for verbose mode, enable manually :/ %{__sed} -i -e 's/^ @\(\$(\(PIDL\|CC\|CXX\|MOC\)\)/ \1/' Makefile @@ -188,10 +236,12 @@ Wtyczka Nagiosa do sprawdzania usług Exchange/OpenChange. %{__aclocal} %{__autoconf} %{__autoheader} +# instead of calling automake (there is no Makefile.am) +cp -f /usr/share/automake/{compile,missing} . %configure \ --datadir=%{_datadir}/openchange \ --enable-openchange-qt4 \ - --enable-pyopenchange \ + %{?with_python:--enable-pyopenchange} \ --with-modulesdir=%{_libdir}/openchange/modules %{__make} @@ -220,7 +270,10 @@ cp -p qt/lib/*.h $RPM_BUILD_ROOT%{_includedir}/libqtmapi cp -a libqtmapi.so.*.* libqtmapi.so $RPM_BUILD_ROOT%{_libdir} # tests -%{__rm} $RPM_BUILD_ROOT%{_bindir}/{check_fasttransfer,openchange-testsuite,test_asyncnotif} +%{__rm} $RPM_BUILD_ROOT%{_bindir}/test_asyncnotif +%if %{without mapitest} +%{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/mapitest.1 +%endif /sbin/ldconfig -n $RPM_BUILD_ROOT%{_libdir} @@ -247,13 +300,21 @@ rm -rf $RPM_BUILD_ROOT %attr(755,root,root) %{_bindir}/exchange2mbox %attr(755,root,root) %{_bindir}/mapiprofile %attr(755,root,root) %{_bindir}/mapipropsdump -%attr(755,root,root) %{_bindir}/mapitest -%attr(755,root,root) %{_bindir}/ocnotify %attr(755,root,root) %{_bindir}/openchangeclient %attr(755,root,root) %{_bindir}/openchangemapidump %attr(755,root,root) %{_bindir}/openchangepfadmin %attr(755,root,root) %{_bindir}/rpcextract %attr(755,root,root) %{_bindir}/schemaIDGUID +%dir %{_datadir}/openchange +%dir %{_datadir}/openchange/setup +%{_datadir}/openchange/setup/profiles +%{_mandir}/man1/exchange2ical.1* +%{_mandir}/man1/exchange2mbox.1* +%{_mandir}/man1/mapiprofile.1* +%{_mandir}/man1/openchangeclient.1* +%{_mandir}/man1/openchangepfadmin.1* +%if %{with mapiproxy} +%attr(755,root,root) %{_bindir}/ocnotify %attr(755,root,root) %{_sbindir}/openchange_group %attr(755,root,root) %{_sbindir}/openchange_migrate %attr(755,root,root) %{_sbindir}/openchange_neworganization @@ -274,23 +335,19 @@ rm -rf $RPM_BUILD_ROOT %attr(755,root,root) %{_libdir}/openchange/modules/dcerpc_mapiproxy_server/exchange_ds_rfr.so %attr(755,root,root) %{_libdir}/openchange/modules/dcerpc_mapiproxy_server/exchange_emsmdb.so %attr(755,root,root) %{_libdir}/openchange/modules/dcerpc_mapiproxy_server/exchange_nsp.so -%dir %{_datadir}/openchange -%{_datadir}/openchange/mapitest -%dir %{_datadir}/openchange/setup %{_datadir}/openchange/setup/mapistore %{_datadir}/openchange/setup/openchangedb -%{_datadir}/openchange/setup/profiles %dir %{_datadir}/samba/setup/AD %{_datadir}/samba/setup/AD/oc_provision_*.ldif %{_datadir}/samba/setup/AD/provision_schema_basedn_modify.ldif %{_datadir}/samba/setup/AD/update_now.ldif %{_datadir}/samba/setup/AD/prefixMap.txt -%{_mandir}/man1/exchange2ical.1* -%{_mandir}/man1/exchange2mbox.1* -%{_mandir}/man1/mapiprofile.1* +%endif +%if %{with mapitest} +%attr(755,root,root) %{_bindir}/mapitest +%{_datadir}/openchange/mapitest %{_mandir}/man1/mapitest.1* -%{_mandir}/man1/openchangeclient.1* -%{_mandir}/man1/openchangepfadmin.1* +%endif %files libs %defattr(644,root,root,755) @@ -298,36 +355,40 @@ rm -rf $RPM_BUILD_ROOT %attr(755,root,root) %ghost %{_libdir}/libmapi.so.0 %attr(755,root,root) %{_libdir}/libmapiadmin.so.*.* %attr(755,root,root) %ghost %{_libdir}/libmapiadmin.so.0 +%attr(755,root,root) %{_libdir}/libocpf.so.*.* +%attr(755,root,root) %ghost %{_libdir}/libocpf.so.0 +%if %{with mapiproxy} %attr(755,root,root) %{_libdir}/libmapiproxy.so.*.* %attr(755,root,root) %ghost %{_libdir}/libmapiproxy.so.0 %attr(755,root,root) %{_libdir}/libmapiserver.so.*.* %attr(755,root,root) %ghost %{_libdir}/libmapiserver.so.0 %attr(755,root,root) %{_libdir}/libmapistore.so.*.* %attr(755,root,root) %ghost %{_libdir}/libmapistore.so.0 -%attr(755,root,root) %{_libdir}/libocpf.so.*.* -%attr(755,root,root) %ghost %{_libdir}/libocpf.so.0 +%endif %files devel %defattr(644,root,root,755) %attr(755,root,root) %{_libdir}/libmapi.so %attr(755,root,root) %{_libdir}/libmapiadmin.so -%attr(755,root,root) %{_libdir}/libmapiproxy.so -%attr(755,root,root) %{_libdir}/libmapiserver.so -%attr(755,root,root) %{_libdir}/libmapistore.so %attr(755,root,root) %{_libdir}/libocpf.so %{_includedir}/gen_ndr %{_includedir}/libmapi %{_includedir}/libmapiadmin %{_includedir}/libocpf +%{_pkgconfigdir}/libmapi.pc +%{_pkgconfigdir}/libmapiadmin.pc +%{_pkgconfigdir}/libocpf.pc +%if %{with mapiproxy} +%attr(755,root,root) %{_libdir}/libmapiproxy.so +%attr(755,root,root) %{_libdir}/libmapiserver.so +%attr(755,root,root) %{_libdir}/libmapistore.so %{_includedir}/mapistore %{_includedir}/libmapiproxy.h %{_includedir}/libmapiserver.h -%{_pkgconfigdir}/libmapi.pc -%{_pkgconfigdir}/libmapiadmin.pc %{_pkgconfigdir}/libmapiproxy.pc %{_pkgconfigdir}/libmapiserver.pc %{_pkgconfigdir}/libmapistore.pc -%{_pkgconfigdir}/libocpf.pc +%endif %files c++ %defattr(644,root,root,755) @@ -356,20 +417,25 @@ rm -rf $RPM_BUILD_ROOT %doc apidocs/html/* %endif +%if %{with python} %files -n python-openchange %defattr(644,root,root,755) %dir %{py_sitedir}/openchange %attr(755,root,root) %{py_sitedir}/openchange/mapi.so %attr(755,root,root) %{py_sitedir}/openchange/mapistore.so +%if %{with mapiproxy} %{py_sitedir}/openchange/*.py[co] %{py_sitedir}/openchange/migration %{py_sitedir}/openchange/tests %{py_sitedir}/openchange/utils %{py_sitedir}/openchange/web +%endif +%endif %files -n nagios-plugin-openchange %defattr(644,root,root,755) # R: perl, openchangeclient +# FIXME: use /usr/lib/nagios/plugins dir and make package noarch %attr(755,root,root) %{_libdir}/nagios/check_exchange # default profile database - should be /etc/... #%config(noreplace) %verify(not md5 mtime size) %{_libdir}/nagios/plugins/check_exchange.ldb