SUNWavahi-bridge-dsd.spec
author laca
Mon, 14 Jul 2008 09:46:17 +0000
branchgnome-2-22
changeset 12466 cc05ce1b1d3e
parent 12167 04331385b57c
child 12616 c6e1e47aae28
permissions -rw-r--r--
2008-07-14 Laszlo (Laca) Peter <[email protected]> * indiana/indiana-branded.speclist: add SUNWevolution-exchange.spec because of its optional dependency on Berkeley DB * SUNWgnome-media.spec: s/CBEbison/SUNWbison/

#
# spec file for package SUNWavahi-bridge-dsd
#
# includes module(s): avahi
#
# Copyright (c) 2006 Sun Microsystems, Inc.
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#
# Owner: padraig
#

%include Solaris.inc

%use avahi = avahi.spec 

Name:                    SUNWavahi-bridge-dsd
Summary:                 Avahi client and bridge to SUNWdsd.
Version:                 %{avahi.version}
SUNW_BaseDir:            %{_basedir}
BuildRoot:               %{_tmppath}/%{name}-%{version}-build
SUNW_copyright:          %{name}.copyright
Source1:        avahi-bridge-dsd.xml
Source2:        svc-avahi-bridge-dsd

%include default-depend.inc
BuildRequires:  SUNWgnome-base-libs-devel
BuildRequires:  SUNWgnome-python-libs-devel
BuildRequires:  SUNWdbus-bindings-devel
Requires:       SUNWgnome-base-libs
Requires:       SUNWgnome-python-libs
Requires:       SUNWdbus-bindings
Requires:       SUNWavahi-bridge-dsd-root
Requires:       SUNWlibdaemon
Requires:       SUNWlexpt
Requires:       SUNWdsdr

%package root
Summary:                 %{summary} - / filesystem
SUNW_BaseDir:            /
%include default-depend.inc

%package devel
Summary:                 %{summary} - development files
SUNW_BaseDir:            %{_prefix}
%include default-depend.inc

%prep
rm -rf %name-%version
mkdir %name-%version
%avahi.prep -d %name-%version

%build
PKG_CONFIG_DISABLE_UNISTALLED=
unset PKG_CONFIG_DISABLE_UNISTALLED
export PKG_CONFIG_PATH=../avahi-%{avahi.version}:%{_pkg_config_path}
export CFLAGS="%optflags -I/usr/sfw/include"
export RPM_OPT_FLAGS="$CFLAGS"
export LDFLAGS="%_ldflags -ldns_sd -lsocket -lnsl -L/usr/sfw/lib -R/usr/sfw/lib -lexpat"

%avahi.build -d %name-%version

%install
%avahi.install -d %name-%version
mkdir -p $RPM_BUILD_ROOT/var/svc/manifest/system
chmod -R 755 $RPM_BUILD_ROOT/var/svc
cp %SOURCE1 $RPM_BUILD_ROOT/var/svc/manifest/system/
mkdir -p $RPM_BUILD_ROOT/lib/svc/method
chmod -R 755 $RPM_BUILD_ROOT/lib
cp %SOURCE2 $RPM_BUILD_ROOT/lib/svc/method/

mv $RPM_BUILD_ROOT%{_sbindir}/avahi-daemon $RPM_BUILD_ROOT%{_sbindir}/avahi-daemon-bridge-dsd
%if %option_with_indiana_branding
rm -rf $RPM_BUILD_ROOT%{_datadir}/applications
%endif

%{?pkgbuild_postprocess: %pkgbuild_postprocess -v -c "%{version}:%{jds_version}:%{name}:$RPM_ARCH:%(date +%%Y-%%m-%%d):%{support_level}" $RPM_BUILD_ROOT}

%clean
rm -rf $RPM_BUILD_ROOT

%if %(test -f /usr/sadm/install/scripts/i.manifest && echo 0 || echo 1)
%iclass manifest -f i.manifest
%endif

%files
%defattr (-, root, bin)
%dir %attr (0755, root, bin) %{_bindir}
%{_bindir}/*
%dir %attr (0755, root, bin) %{_sbindir}
%{_sbindir}/avahi-daemon-bridge-dsd
%dir %attr (0755, root, bin) %{_libdir}
%{_libdir}/libavahi*.so*
%dir %attr (0755, root, sys) %{_datadir}
%{_datadir}/avahi/service-types*
%if %option_with_sun_branding
%dir %attr (0755, root, other) %{_datadir}/applications
%{_datadir}/applications/avahi-discover.desktop
%{_datadir}/applications/bssh.desktop
%{_datadir}/applications/bvnc.desktop
%endif
%{_datadir}/avahi/interfaces/avahi-discover.glade
%{_datadir}/avahi/introspection/Server.introspect
%{_datadir}/avahi/introspection/EntryGroup.introspect
%{_datadir}/avahi/introspection/DomainBrowser.introspect
%{_datadir}/avahi/introspection/ServiceBrowser.introspect
%{_datadir}/avahi/introspection/ServiceTypeBrowser.introspect
%{_datadir}/avahi/introspection/ServiceResolver.introspect
%{_datadir}/avahi/introspection/AddressResolver.introspect
%{_datadir}/avahi/introspection/HostNameResolver.introspect
%{_datadir}/avahi/introspection/RecordBrowser.introspect
%{_datadir}/avahi/avahi-service.dtd
%dir %attr (0755, root, bin) %{_mandir}
%{_mandir}/man1/*
%attr (-, root, bin) %{_libdir}/python*

%files root
%defattr (-, root, bin)
%dir %attr (0755, root, sys) %{_sysconfdir}
%config %{_sysconfdir}/*
%dir %attr (0755, root, sys) /var
%dir %attr (0755, root, sys) /var/svc
%dir %attr (0755, root, sys) /var/svc/manifest
%dir %attr (0755, root, sys) /var/svc/manifest/system
%class(manifest) %attr (0444, root, sys) /var/svc/manifest/system/avahi-bridge-dsd.xml
%attr (0555, root, bin) /lib/svc/method/svc-avahi-bridge-dsd


%files devel
%defattr (-, root, bin)
%dir %attr (0755, root, bin) %{_libdir}
%dir %attr (0755, root, other) %{_libdir}/pkgconfig
%{_libdir}/pkgconfig/*
%dir %attr (0755, root, bin) %{_includedir}
%{_includedir}/*


%changelog
* Wed Oct 31 2007 - [email protected]
- Add Build/Requires SUNWdbus-bindings/-devel as the dbus python module is used.

* Wed Oct 31 2007 - [email protected]
- Remove references to /usr/lib/mdns from LDFLAGS as the dir doesn't exist.

* Fri Sep 07 2007 - [email protected]
- Add Build/Requires SUNWgnome-base-libs/-devel for glib.
- Add Build/Requires SUNWgnome-python-libs/-devel for gtk Python module.

* Wed Jun 28 2007 - [email protected]
- Initial spec file created.