1 # 2 # spec file for package SUNWdbus-bindings 3 # 4 # includes module(s): dbus_glib, dbus_python 5 # 6 # Copyright 2008 Sun Microsystems, Inc. 7 # This file and all modifications and additions to the pristine 8 # package are under the same license as the package itself. 9 # 10 # Owner: yippi 11 # bugdb: bugzilla.freedesktop.org 12 # 13 %include Solaris.inc 14 15 %ifarch amd64 sparcv9 16 %include arch64.inc 17 %use dbus_glib_64 = dbus-glib.spec 18 %define _libdir %{_basedir}/lib 19 %use dbus_python_64 = dbus-python.spec 20 %endif 21 22 %include base.inc 23 %use dbus_glib = dbus-glib.spec 24 %use dbus_python = dbus-python.spec 25 26 Name: SUNWdbus-bindings 27 Summary: Simple IPC library based on messages 28 Version: %{default_pkg_version} 29 Source: %{name}-manpages-0.1.tar.gz 30 SUNW_BaseDir: %{_basedir} 31 SUNW_Copyright: %{name}.copyright 32 BuildRoot: %{_tmppath}/%{name}-%{version}-build 33 %include default-depend.inc 34 Requires: SUNWdbus 35 Requires: SUNWgnome-base-libs 36 Requires: SUNWlxml 37 Requires: SUNWlexpt 38 Requires: SUNWPython-extra 39 BuildRequires: SUNWdbus-devel 40 BuildRequires: SUNWgnome-base-libs-devel 41 BuildRequires: SUNWlxml 42 BuildRequires: SUNWsfwhea 43 BuildRequires: SUNWPython-extra 44 BuildRequires: SUNWpython-setuptools 45 46 %package devel 47 Summary: %{summary} - development files 48 SUNW_BaseDir: %{_basedir} 49 %include default-depend.inc 50 Requires: SUNWgnome-base-libs 51 52 %prep 53 rm -rf %name-%version 54 mkdir %name-%version 55 56 %ifarch amd64 sparcv9 57 mkdir %name-%version/%_arch64 58 %dbus_glib_64.prep -d %name-%version/%_arch64 59 %dbus_python_64.prep -d %name-%version/%_arch64 60 %endif 61 62 mkdir %name-%version/%{base_arch} 63 %dbus_glib.prep -d %name-%version/%{base_arch} 64 %dbus_python.prep -d %name-%version/%{base_arch} 65 66 cd %{_builddir}/%name-%version 67 gzcat %SOURCE0 | tar xf - 68 69 %build 70 PKG_CONFIG_DISABLE_UNINSTALLED= 71 unset PKG_CONFIG_DISABLE_UNINSTALLED 72 %if %cc_is_gcc 73 export EXTRA_CFLAGS="-I/usr/sfw/include" 74 %else 75 export EXTRA_CFLAGS="-xc99 -D_REENTRANT -I/usr/sfw/include -D__EXTENSIONS__" 76 %endif 77 # Put /usr/ccs/lib first in the PATH so that cpp is picked up from there 78 # note: I didn't put /usr/lib in the PATH because there's too much other 79 # stuff in there 80 # 81 export PATH=/usr/ccs/lib:$PATH 82 83 %ifarch amd64 sparcv9 84 export PYTHON=%{_bindir}/%{_arch64}/python 85 export EXTRA_LDFLAGS="-L/usr/sfw/lib/%{_arch64} -R/usr/sfw/lib/%{_arch64} -lexpat" 86 export PKG_CONFIG_PATH=../dbus-glib-%{dbus_glib.version}:/usr/lib/%{_arch64}/pkgconfig 87 %dbus_glib_64.build -d %name-%version/%_arch64 88 %dbus_python_64.build -d %name-%version/%_arch64 89 %endif 90 91 export PKG_CONFIG_PATH=../dbus-glib-%{dbus_glib.version} 92 export EXTRA_LDFLAGS="-L/usr/sfw/lib -R/usr/sfw/lib -lexpat" 93 export PYTHON=%{_bindir}/python 94 %dbus_glib.build -d %name-%version/%{base_arch} 95 %dbus_python.build -d %name-%version/%{base_arch} 96 97 %install 98 rm -rf $RPM_BUILD_ROOT 99 %ifarch amd64 sparcv9 100 %dbus_glib_64.install -d %name-%version/%_arch64 101 %dbus_python_64.install -d %name-%version/%_arch64 102 %endif 103 104 %dbus_glib.install -d %name-%version/%{base_arch} 105 %dbus_python.install -d %name-%version/%{base_arch} 106 107 # Remove dbus-bash-completion.sh, a bash autocompletion script in the 108 # %{_sysconfdir}/profile.d dir. We don't ship such files. It is the only file 109 # under %{_sysconfdir} so remove the entire structure. 110 # rm/rmdir used instead of 'rm -r' so that files added under %{_sysconfdir} are 111 # found, via build failure. 112 rm $RPM_BUILD_ROOT%{_libexecdir}/dbus-bash-completion-helper 113 %ifarch amd64 sparcv9 114 rm $RPM_BUILD_ROOT%{_libexecdir}/%{_arch64}/dbus-bash-completion-helper 115 %endif 116 rm $RPM_BUILD_ROOT%{_sysconfdir}/profile.d/dbus-bash-completion.sh 117 rmdir $RPM_BUILD_ROOT%{_sysconfdir}/profile.d 118 rmdir $RPM_BUILD_ROOT%{_sysconfdir} 119 120 rm -rf $RPM_BUILD_ROOT%{_mandir} 121 cd %{_builddir}/%name-%version/sun-manpages 122 make install DESTDIR=$RPM_BUILD_ROOT 123 124 %{?pkgbuild_postprocess: %pkgbuild_postprocess -v -c "%{version}:%{jds_version}:%{name}:$RPM_ARCH:%(date +%%Y-%%m-%%d):%{support_level}" $RPM_BUILD_ROOT} 125 126 %clean 127 rm -rf $RPM_BUILD_ROOT 128 129 %if %(test -f /usr/sadm/install/scripts/i.manifest && echo 0 || echo 1) 130 %iclass manifest -f i.manifest 131 %endif 132 133 %files 134 %defattr (-, root, bin) 135 %dir %attr (0755, root, bin) %{_bindir} 136 %{_bindir}/* 137 %dir %attr (0755, root, bin) %{_libdir} 138 %{_libdir}/lib*.so* 139 %{_libdir}/python* 140 %dir %attr (0755, root, sys) %{_datadir} 141 %{_datadir}/dbus-1 142 %doc %{base_arch}/dbus-glib-%{dbus_glib.version}/AUTHORS 143 %doc %{base_arch}/dbus-glib-%{dbus_glib.version}/README 144 %doc(bzip2) %{base_arch}/dbus-glib-%{dbus_glib.version}/COPYING 145 %doc(bzip2) %{base_arch}/dbus-glib-%{dbus_glib.version}/ChangeLog 146 %doc(bzip2) %{base_arch}/dbus-glib-%{dbus_glib.version}/NEWS 147 %doc %{base_arch}/dbus-python-%{dbus_python.version}/AUTHORS 148 %doc %{base_arch}/dbus-python-%{dbus_python.version}/README 149 %doc(bzip2) %{base_arch}/dbus-python-%{dbus_python.version}/COPYING 150 %doc(bzip2) %{base_arch}/dbus-python-%{dbus_python.version}/ChangeLog 151 %doc(bzip2) %{base_arch}/dbus-python-%{dbus_python.version}/NEWS 152 %dir %attr (0755, root, other) %{_datadir}/doc 153 %dir %attr(0755, root, bin) %{_mandir} 154 %dir %attr(0755, root, bin) %{_mandir}/man3 155 %{_mandir}/man3/* 156 %ifarch amd64 sparcv9 157 %dir %attr (0755, root, bin) %{_libdir}/%{_arch64} 158 %{_libdir}/%{_arch64}/lib*.so* 159 %endif 160 161 %files devel 162 %defattr (-, root, bin) 163 %dir %attr (0755, root, bin) %{_libdir} 164 %dir %attr (0755, root, other) %{_libdir}/pkgconfig 165 %{_libdir}/pkgconfig/* 166 %dir %attr (0755, root, bin) %{_includedir} 167 %{_includedir}/* 168 %dir %attr (0755, root, sys) %{_datadir} 169 %dir %attr (0755, root, other) %{_datadir}/doc 170 %dir %attr (0755, root, other) %{_datadir}/doc/dbus-python 171 %{_datadir}/doc/dbus-python/* 172 %{_datadir}/gtk-doc 173 %ifarch amd64 sparcv9 174 %dir %attr (0755, root, bin) %{_libdir}/%{_arch64} 175 %dir %attr (0755, root, other) %{_libdir}/%{_arch64}/pkgconfig 176 %{_libdir}/%{_arch64}/pkgconfig/*.pc 177 %endif 178 179 %changelog 180 * Sun Sep 14 2008 - brian.cameron@sun.com 181 - Add new copyright files. 182 * Thu Mar 27 2008 - brian.cameron@sun.com 183 - Add SUNW_Copyright 184 * Tue Nov 20 2007 - brian.cameron@sun.com 185 - Add libdbus-glib-1.3 manpage. 186 * Fri Sep 28 2007 - laca@sun.com 187 - convert to new style multi-ISA build 188 - delete SUNWxwrtl dep 189 * Sat Feb 25 2007 - dougs@truemail.co.th 190 - updated to include 64-bit build RFE: #6480511 191 * Fri Jan 26 2007 - damien.carbery@sun.com 192 - Set PKG_CONFIG vars in %build because dbus-python use autofoo/configure/make 193 process rather than setup.py. 194 * Thu Jan 25 2007 - damien.carbery@sun.com 195 - Add %{_datadir}/doc to devel pkg, because of new dbus-python tarball. 196 * Thu Dec 21 2006 - brian.cameron@sun.com 197 - Remove references to SUNWdbus-bindings-root since we do not 198 build this package. 199 * Thu Sep 21 2006 - brian.cameron@sun.com 200 - Created. 201 202