ORBit2.spec
author dcarbery
Mon, 23 Oct 2006 12:46:17 +0000
branchgnome-2-14
changeset 19195 352a4716f1f3
parent 19132 c11987d914f1
permissions -rw-r--r--
2006-10-23 Damien Carbery <[email protected]> * docs/ssa/*: Remove these, as they're now up on the JDS project pages under 'Tasks/Single Sys Admin'.


# spec file for package ORBit2
#
# 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:         ORBit2
License:      LGPL
Group:        System/Libraries
Provides:     ORBit2 
Summary:      High-performance CORBA Object Request Broker
Version:      2.14.0
Release:      3
Distribution: Java Desktop System
Vendor:       Sun Microsystems, Inc.
Source:       http://ftp.gnome.org/pub/GNOME/sources/ORBit2/2.14/ORBit2-%{version}.tar.bz2
Source1:      orbit-idl-2.1.gz
Source2:      orbit2-config.1.gz
Source3:      libORBit-2.3.gz
Source4:      libORBitCosNaming-2.3.gz
Source5:      orbitrc
Patch1:	      ORBit-01-no-static.diff
Patch2:	      ORBit-02-uninstalled_pc.diff
Patch3:	      ORBit-03-dhcp-hostname.diff
Patch4:       ORBit-04-gcc-Werror.diff
Patch5:       ORBit-05-signal-broadcast.diff
Patch6:       ORBit-06-localonly.diff
BuildRoot:    %{_tmppath}/%{name}-%{version}-build
URL:          http://www.gnome.org/projects/ORBit2
DocDir:	      %{_defaultdocdir}/doc
Autoreqprov:  on
Prereq:	      /sbin/ldconfig

%define libIDL_version 0.8.2
%define popt_version 1.6.4
%define gtk_doc_version 1.1
%define linc_version 1.1.1

Requires:      libIDL >= %{libIDL_version}
Requires:      popt >= %{popt_version}
BuildRequires: libIDL-devel >= %{libIDL_version}
BuildRequires: popt-devel >= %{popt_version}
BuildRequires: gtk-doc >= %{gtk_doc_version}

Obsoletes:	linc < %{linc_version}
Provides:	linc = %{linc_version}
Obsoletes:	linc-devel < %{linc_version}
Provides:	linc-devel = %{linc_version}

%description
ORBit is a high-performance CORBA (Common Object Request Broker
Architecture) ORB (object request broker). It allows programs to
send requests and receive replies from other programs, regardless
of the locations of the two programs. CORBA is an architecture that
enables communication between program objects, regardless of the
programming language they're written in or the operating system they
run on.

%package devel
Summary:      High-performance CORBA Object Request Broker
Group:        Development/Libraries
Provides:     ORBit2-devel
Autoreqprov:  on
Requires:     %name = %version 
Requires:     libIDL-devel >= %{libIDL_version}

%description devel
ORBit is a high-performance CORBA (Common Object Request Broker
Architecture) ORB (object request broker). It allows programs to
send requests and receive replies from other programs, regardless
of the locations of the two programs. CORBA is an architecture that
enables communication between program objects, regardless of the
programming language they're written in or the operating system they
run on.

%prep
%setup -q
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1

%ifos solaris
%ifarch amd64 sparcv9
cd ..
cp -rp ORBit2-%{version} ORBit2-%{version}-64
cd ORBit2-%{version}
%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}"

%ifos solaris
%ifarch amd64 sparcv9
CPUS=$(($CPUS*4))

cd ../ORBit2-%version-64

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

libtoolize --copy --force
gtkdocize
aclocal $ACLOCAL_FLAGS -I %{_datadir}/aclocal
automake -a -c -f
autoconf

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

make -j $CPUS

cd ../ORBit2-%version

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

%endif
%endif


libtoolize --copy --force
gtkdocize
aclocal $ACLOCAL_FLAGS -I %{_datadir}/aclocal
automake -a -c -f
autoconf
CFLAGS="$RPM_OPT_FLAGS"			\
./configure $CONFLAGS			\
	    --sysconfdir=%{_sysconfdir}	\
	    --enable-gtk-doc
make -j $CPUS

%install

%ifos solaris
%ifarch amd64 sparcv9
cd ../ORBit2-%version-64
make install DESTDIR=$RPM_BUILD_ROOT
rm -f $RPM_BUILD_ROOT%{_bindir}/%{_arch64}/orbit2-config
cd ../ORBit2-%version
%endif
%endif

make DESTDIR=$RPM_BUILD_ROOT install
install -d $RPM_BUILD_ROOT%{_mandir}/man1
install -d $RPM_BUILD_ROOT%{_mandir}/man3
install -d $RPM_BUILD_ROOT%{_sysconfdir}
install --mode=0644 %SOURCE1 $RPM_BUILD_ROOT%{_mandir}/man1
install --mode=0644 %SOURCE2 $RPM_BUILD_ROOT%{_mandir}/man1
install --mode=0644 %SOURCE3 $RPM_BUILD_ROOT%{_mandir}/man3
install --mode=0644 %SOURCE4 $RPM_BUILD_ROOT%{_mandir}/man3
install --mode=0644 %SOURCE5 $RPM_BUILD_ROOT%{_sysconfdir}/orbitrc
AFILES=" libORBit-2 libORBit-imodule-2 libORBitCosNaming-2 orbit-2.0/Everything_module"
pushd $RPM_BUILD_ROOT%{_libdir}
for i in $AFILES; do
       rm $i.a
       rm $i.la
done
popd


%clean
rm -rf $RPM_BUILD_ROOT

%post
/sbin/ldconfig

%postun
/sbin/ldconfig

%files
%defattr(-, root, root)
%{_libdir}/libORBit*.so.*
%{_libdir}/orbit-2.0/Every*so*
%{_bindir}/ior-decode-2
%{_bindir}/typelib-dump
%{_bindir}/linc-cleanup-sockets
%{_sysconfdir}/orbitrc

%files devel
%defattr(-, root, root)
%{_includedir}/orbit-2.0
%{_bindir}/orbit-idl-2
%{_bindir}/orbit2-config
%{_libdir}/libname-server-2.a
%{_libdir}/libORBit*.so
%{_libdir}/pkgconfig/*.pc
%{_datadir}/idl/orbit-2.0/*.idl
%{_datadir}/aclocal/*.m4
%{_datadir}/gtk-doc/html/ORBit2
%{_mandir}/man1/*
%{_mandir}/man3/*

%changelog
* Tue Aug  1 2006 - [email protected]
- Add patch 6 so LocalOnly mode works on Solaris.  This patch causes
  the linc library to not use getaddrinfo() and getaddrname(), which
  do not seem to work on Solaris.  The fallback code that uses
  gethostbyname() and gethostbyaddr() seem to work better.  Might be
  good to fix the getaddrinfo(), getaddrname() code to work on 
  Solaris, though not sure if this is really necessary.

* Tue June 2 2006 - [email protected]
- Add patch, ORBIT-05-signal-broadcast.diff.

* Tue Mar 14 2006 - [email protected]
- Bump to 2.14.0.

* Thu Feb  9 2006 - [email protected]
- Remove upstream patch, ORBit-05-illegal_cast.diff.

* Wed Feb  8 2006 - [email protected]
- Bump to 2.13.3.

* Wed Dec 21 2005 - [email protected]
- Add patch, 05-illegal_cast.diff, to remove unnecessary cast that breaks the 
  build. Bugzilla #324686.

* Tue Dec 20 2005 - [email protected]
- Bump to 2.13.2. Remove upstream patch, 04-ipv4-port-hosed.
- Add ORBit-04-gcc-Werror.diff so gcc option is only set when using gcc.

* Thu Oct 06 2005 - [email protected]
- Add gtkdocize call to 64 bit section.

* Wed Sep 29 2005 - [email protected]
- Add gtkdocize call for automake.

* Tue Sep 27 2005 - [email protected]
- Bump to 2.12.4.

* Sun Sep 18 2005 - [email protected]
- Remove some patches.

* Wed Aug 17 2005 - [email protected]
- Bump to 2.12.3.

* Wed Jun 15 2005 - [email protected]
- Add patch new-pkgconfig.diff taken from GNOME CVS to make ORBit2 build
  with pkg-config > 0.15.0

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

* Tue Apr 19 2005 - [email protected]
- fix login failure when ipv4 port in the IOR
  is taken to be valid on login after reboot
  Fixes #6238754

* Fri Mar 11 2005 - [email protected]
- fix a bogus linc_protocol_destroy assertion 
  coming up at install time

* Wed Mar 02 2005 - [email protected]
- another attempt to fix dhcp bug safely. 

* Tue Feb 15 2005 - [email protected]
- Add patch to fix dhcp hostname change blocking 
  the login

* Tue Dec 21 2004 - [email protected]
- Obsoletes linc for upgrade purposes. Fix bug 6211773.

* 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

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

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

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

* Fri Jun 11 2004 - <[email protected]>
- Put back /etc/orbitrc which is required by A11y login. Bug 5059822.

* Tue Jun 08 2004 - <[email protected]>
- removed /etc/orbitrc at the moment as this is a feature for Cinnabar not
  metro.

* Mon Feb 23 2004 - <[email protected]>
- Bump to 2.9.8

* Wed Feb 11 2004 - <[email protected]>
- Bump to 2.9.7, gtk-doc.make hack patch 03

* Mon Dec 15 2003 - <[email protected]>
- Bump to 2.9.2

* Mon Oct 02 2003 - <[email protected]> 2.8.1-2
- Require gtk-doc.

* Mon Oct 02 2003 - <[email protected]> 2.8.1-1
- Update to 2.8.1.

* Thu Aug 14 2003 - <[email protected]>
- add patch to disable static linking of test programs
- remove lib*.a and .la, except libname-server-2.a which is
  apparently needed by bonobo-activation
- move *.so to -devel

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

* Wed Apr 30 2003 - <[email protected]>
- Create new spec file for ORBit2