GConf.spec
author dermotm
Mon, 24 Jul 2006 12:30:39 +0000
branchgnome-2-10
changeset 19949 94f49bf19351
parent 19719 d184ca39d269
permissions -rw-r--r--
access control test #4

#
# spec file for package GConf
#
# Copyright (c) 2005 Sun Microsystems, Inc.
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#
Name:         GConf
License:      LGPL
Group:        System/Libraries/GNOME
Provides:     GConf
Version:      2.10.0
Release:      1
Distribution: Java Desktop System
Vendor:       Sun Microsystems, Inc.
Summary:      GNOME Configuration Framework
Source:       http://ftp.gnome.org/pub/GNOME/sources/GConf/2.10/GConf-%{version}.tar.bz2
Source1:      gconftool-2.1.gz
Source2:      libgconf-2.3.gz
Patch1:       GConf-01-apoc-path-update.diff
Patch2:       GConf-02-daemon-hanged-solaris.diff
Patch3:       GConf-03-g11n-locale-alias.diff
URL:	      http://www.gnome.org
BuildRoot:    %{_tmppath}/%{name}-%{version}-build
Docdir:	      %{_defaultdocdir}/doc
Autoreqprov:  on
Prereq:       /sbin/ldconfig

%define gtk2_version 2.4.0
%define libxml2_version 2.6.7
%define ORBit2_version 2.10.1
%define gtk_doc_version 1.1
%define popt_version 1.7

Requires: gtk2 >= %{gtk2_version}
Requires: libxml2 >= %{libxml2_version}
Requires: ORBit2 >= %{ORBit2_version}
Requires: popt >= %{popt_version}
BuildRequires: gtk2-devel >= %{gtk2_version}
BuildRequires: libxml2-devel >= %{libxml2_version}
BuildRequires: ORBit2-devel >= %{ORBit2_version}
BuildRequires: popt-devel >= %{popt_version}
BuildRequires: gtk-doc >= %{gtk_doc_version}

%description
GConf is the Configuration Framework for the GNOME Desktop.

%package devel
Summary:      GNOME Configuration Framework Development Libraries
Group:        Development/Libraries/GNOME
Requires:     %{name} = %{version}
Requires:     libxml2-devel >= %{libxml2_version}
Requires:     ORBit2-devel >= %{ORBit2_version}
Requires:     gtk2-devel >= %{gtk2_version}

%description devel
GConf is the Configuration Framework for the GNOME Desktop.

%prep
%setup -q
%patch1 -p1
%patch2 -p1
%patch3 -p1

%ifos solaris
%ifarch amd64 sparcv9
cd ..
cp -rp GConf-%{version} GConf-%{version}-64
%endif
%endif


%build
%ifos linux
if [ -x /usr/bin/getconf ]; then
  CPUS=`getconf _NPROCESSORS_ONLN`
fi
%else
  CPUS=`/usr/sbin/psrinfo | grep on-line | wc -l | tr -d ' '`
%endif
if test "x$CPUS" = "x" -o $CPUS = 0; then
  CPUS=1
fi

CONFLAGS="--prefix=%{_prefix} --mandir=%{_mandir}"

%ifos solaris
%ifarch amd64 sparcv9
cd ../GConf-%version-64

export CFLAGS="$CFLAGS64"
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH64"
export LDFLAGS="$LDFLAGS64"
export CC=${CC64:-$CC}
save_PATH="$PATH"
ccdir=`dirname $CC`
export PATH=$ccdir:$PATH

autoconf
./configure $CONFLAGS					\
            --bindir=%{_bindir}/%{_arch64}		\
            --libdir=%{_libdir}/%{_arch64}		\
            --libexecdir=%{_libexecdir}/%{_arch64}	\
            --sysconfdir=%{_sysconfdir}/%{_arch64}	\
	    --disable-gtk-doc

# For some reason using -j $CPUS breaks the build on my machine with
# 2 processors, so just using make
#
make

cd ../GConf-%version

export PKG_CONFIG_PATH="$PKG_CONFIG_PATH32"
export LDFLAGS="$LDFLAGS32"
export CFLAGS="$CFLAGS32"
export RPM_OPT_FLAGS="$CFLAGS"
export CC=${CC32:-$CC}
export PATH="$save_PATH"

%endif
%endif

autoconf
CFLAGS="$RPM_OPT_FLAGS"			\
./configure $CONFLAGS			\
	    --sysconfdir=%{_sysconfdir}	\
	    --libexecdir=%{_libexecdir}	\
	    --enable-gtk-doc

# For some reason using -j $CPUS breaks the build on my machine with
# 2 processors, so just using make
#
make

%install

%ifos solaris
%ifarch amd64 sparcv9
cd ../GConf-%version-64
make install DESTDIR=$RPM_BUILD_ROOT
cd ../GConf-%version
%endif
%endif

make DESTDIR=$RPM_BUILD_ROOT install 
install -d $RPM_BUILD_ROOT%{_mandir}/man1
install -d $RPM_BUILD_ROOT%{_mandir}/man3
install --mode=0644 %SOURCE1 $RPM_BUILD_ROOT%{_mandir}/man1
install --mode=0644 %SOURCE2 $RPM_BUILD_ROOT%{_mandir}/man3
#Copy zh_HK from zh_TW
#Fixes bug 4930405
install -d $RPM_BUILD_ROOT%{_datadir}/locale/zh_HK/LC_MESSAGES
install --mode=0644 $RPM_BUILD_ROOT%{_datadir}/locale/zh_TW/LC_MESSAGES/*.mo $RPM_BUILD_ROOT%{_datadir}/locale/zh_HK/LC_MESSAGES/
rm $RPM_BUILD_ROOT%{_libdir}/GConf/2/*.la
rm $RPM_BUILD_ROOT%{_libdir}/GConf/2/*.a
rm $RPM_BUILD_ROOT%{_libdir}/*.la
rm $RPM_BUILD_ROOT%{_libdir}/*.a

%clean
rm -rf $RPM_BUILD_ROOT

%post 
/sbin/ldconfig

%postun 
/sbin/ldconfig

%files
%defattr(-, root, root)
%{_datadir}/locale/*/LC_MESSAGES/*.mo
%{_bindir}/*
%{_libexecdir}/*
%{_libdir}/GConf/2/*.so*
%{_libdir}/libgconf-2*so.*
%{_sysconfdir}/gconf/2/path
%{_mandir}/man1/*
%dir %{_sysconfdir}/gconf/gconf.xml.defaults
%dir %{_sysconfdir}/gconf/gconf.xml.mandatory

%files devel
%defattr(-, root, root)
%{_includedir}/gconf/2/gconf/*.h
%{_libdir}/libgconf-2*.so
%{_libdir}/pkgconfig/*.pc
%{_datadir}/aclocal/*.m4
%{_datadir}/gtk-doc/*
%{_datadir}/sgml/*
%{_datadir}/gtk-doc/html/gconf
%{_mandir}/man3/*

%changelog
* Wed Jun 15 2005 - [email protected]
- add patch pkgconfig.diff that add gconf-2.0 to the pkgconfig deps
- run autoconf

* Wed May 11 2005 - [email protected]
- Remove building with multiple processors, since that is breaking
  the build on Solaris.

* Fri May 06 2005 - [email protected]
- Bump to 2.10.0

* Tue Feb 15 2005 - [email protected]
- Add patch to fix such that defaults don't get
  installed for all locales since we always
  fallback to C locale values

* Fri Oct 29 2004 - [email protected]
- use $CC64 for the 64-bit build if defined

* Sat Oct  2 2004 - [email protected]
- Create 64bit libraries for Solaris

* Fri Sep 24 2004 - [email protected]
- Added GConf-06-g11n-potfiles.diff 

* Mon Aug 30 2004 - [email protected]
- updated GConf-02-g11n-potfiles.diff

* Wed Aug 18 2004 - [email protected]
- added --enable-gtk-doc.

* Wed Aug 11 2004 - [email protected]
- Removed GConf-05-use-global-lock.diff as it is backwards incomptaible in a 
  heterogeneous environment. While the goal of the project is to allow 
  concurrent login which has in effect achieved by not having any lock at all.

* Thu Aug 02 2004 - [email protected]
- create GConf-06-g11n-locale-alias.diff to fix bug #5042863,
  the orignal patch is from the bugzilla.gnome.org #100378

* Thu Jul 08 2004 - [email protected]
- Updated l10n content to GConf-l10n-po-1.2.tar.bz2

* Thu Jul 08 2004 - [email protected]
- ported to rpm4/suse91

* Wed Jul 07 2004 - [email protected]
- added "-j $CPUS" to make to speed up builds

* Fri Jun 11 2004 - [email protected]
- Create a patch GConf-05-use-global-lock.diff as we want to use orbit ip
  to resolve to a single gconf daemon per user.

* Thu Jun 03 2004 - [email protected]
- Added GConf-04-daemon-hanged-solaris.diff as the signal handler
  is calling non-reentrant code as gconf_log(). SO removed the calls
  to these signals, though much of these messages are not that important.

* Wed May 19 2004 - [email protected]
- added GConf-03-apoc-path-update.diff.

* Wed May 12 2004 - [email protected]
- Updated l10n content to GConf-l10n-po-1.1.tar.bz2

* Thu Apr 06 2004 - [email protected]
- Updtaed to 2.6.1 tarball.

* Fri Apr 02 2004 - [email protected]
- Updtaed to 2.6.0 tarball.

* Mon Mar 29 2004 - [email protected]
- Updated l10n content to GConf-l10n-po-1.0.tar.bz2

* Fri Mar 19 2004 - [email protected]
- Bump to 2.5.90 and merge the potfile patches.

* Thu Mar 11 2004 - [email protected]
- added GConf-03-g11n-potfiles.diff

* Wed Feb 11 2004 - <[email protected]>
- Bump to 2.5.1, l10n to 0.7, port 02-fix-potfiles patch

* Mon Dec 15 2003 - <[email protected]>
- Add back the man page stuff, and the backend 
  notification patch

* Mon Oct 06 2003 - <[email protected]> 2.4.0.1-1
- Update to 2.4.0.1-1.
- Remove dump/load and local locks patches.

* Tue Aug 19 2003 - <[email protected]>
- add GConf-02-sanity-check.diff patch, fixes 4908212

* Thu Aug 14 2003 - <[email protected]>
- move lib*.so to -devel, remove *.a, *.la

* Fri Aug 01 2003 - <[email protected]> 2.2.1-1
- Upgrade to 2.2.1

* Wed Jul 09 2003 - <[email protected]>
- add in sun po files

* Fri May 30 2003 - <[email protected]>
- Make sure gconf.xml.mandatory gets created

* Fri May 30 2003 - <[email protected]>
- Add patches required by gnome-panel-2.3.1
- Install .la files

* Thu May 07 2003 - <[email protected]>
- Create new spec file for GConf