ORBit2.spec
author dermotm
Mon, 18 Oct 2004 09:30:38 +0000
changeset 4276 2a2c7f354601
parent 4271 eb46de360ab6
child 4365 d8676a6421af
permissions -rw-r--r--
Incremented release numbers for build 21

Name:         ORBit2
License:      LGPL
Group:        System/Libraries
Provides:     ORBit2 
Summary:      High-performance CORBA Object Request Broker
Version:      2.10.1
Release:      23
Distribution: Cinnabar
Vendor:       Sun Microsystems, Inc.
Source:       http://ftp.gnome.org/pub/GNOME/sources/ORBit2/2.10/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-gtk-doc-make.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

Requires:      libIDL >= %{libIDL_version}
Requires:      popt >= %{popt_version}
BuildRequires: libIDL-devel >= %{libIDL_version}
BuildRequires: popt-devel >= %{popt_version}
BuildRequires: gtk-doc >= %{gtk_doc_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
%patch1 -p1
%patch2 -p1
%patch3 -p1

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

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

cd ../ORBit2-%version-64

export CFLAGS="$CFLAGS64"
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH64"

libtoolize --copy --force
aclocal -I %{_datadir}/aclocal
automake --add-missing --copy
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"

%endif
%endif


libtoolize --copy --force
aclocal -I %{_datadir}/aclocal
automake --add-missing --copy
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
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
* 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