pwlib.spec
author bc99092
Mon, 12 Apr 2004 17:01:06 +0000
changeset 2443 f3d5eaba70ee
parent 2442 399a13f93b52
child 2494 6b1189c3cc84
permissions -rw-r--r--
2004-04-12 Brian Cameron <[email protected]> * openh323.spec, pwlib.spec: Use pwd to set PWLIBDIR since this works on both Solaris and Linux. * libexif-gtk.spec: Add ACLOCAL_FLAGS to aclocal call.

Name:		pwlib
License:	MPL
Group: 		System Environment/Libraries
Version: 	1.6.3
Release: 	9
Distribution:	Cinnabar
Vendor:       	Sun Microsystems Inc.
Summary: 	Portable Windows Libary
Source: 	pwlib-%{version}.tar.bz2
Patch0:  	pwlib-01-makefiles.diff
Patch1:  	pwlib-02-forte-makefiles.diff
Patch2:     	pwlib-03-include.diff
Patch3:     	pwlib-04-source.diff
URL: 		http://www.openh323.org/
BuildRoot: 	%{_tmppath}/%{name}-root
Docdir:       	%{_defaultdocdir}/doc
AutoReqProv:  	on
Prereq:         /sbin/ldconfig

%description
PWLib is a moderately large class library that has its genesis many
years ago as a method to produce applications to run on both Microsoft
Windows and Unix X-Window systems. 

It is supplied mainly to support the open H323 project, but that shouldn't stop
you from using it in whatever project you have in mind if you so desire. 

%package devel
Summary: Development package for pwlib
Group: Development/Libraries
Requires: pwlib = %{version}

%description devel
The pwlib-devel package includes the libraries and header files for pwlib.

%prep
%setup -q -n pwlib
%patch0 -p1 
%patch1 -p1 
%patch2 -p1 
%patch3 -p1 

%build
export PWLIBDIR=`pwd`
export PWLIB_BUILD="yes"
aclocal $ACLOCAL_FLAGS -I %{_datadir}/aclocal/gnome2-macros
autoconf
%ifos solaris
%define regexp_options "--enable-internalregex"
%else
%define regexp_options ""
%endif

./configure --prefix=%{_prefix} 	\
	    --sysconfdir=%{_sysconfdir}	\
	    --disable-alsa %{regexp_options}

make optshared OPTCCFLAGS="$RPM_OPT_FLAGS" 

cd tools/asnparser
make optshared OPTCCFLAGS="$RPM_OPT_FLAGS"

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_bindir}
mkdir -p $RPM_BUILD_ROOT%{_libdir}
mkdir -p $RPM_BUILD_ROOT%{_includedir}/ptclib
mkdir -p $RPM_BUILD_ROOT%{_includedir}/ptlib/unix/ptlib
mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name}/make
cp -d lib/*.so* $RPM_BUILD_ROOT%{_libdir}
install include/ptlib.h $RPM_BUILD_ROOT%{_includedir}
install include/ptbuildopts.h $RPM_BUILD_ROOT%{_includedir}
install include/ptlib/*.h $RPM_BUILD_ROOT%{_includedir}/ptlib/
install include/ptlib/*.inl $RPM_BUILD_ROOT%{_includedir}/ptlib/
install include/ptlib/unix/ptlib/*.h $RPM_BUILD_ROOT%{_includedir}/ptlib/unix/ptlib
install include/ptlib/unix/ptlib/*.inl $RPM_BUILD_ROOT%{_includedir}/ptlib/unix/ptlib
install include/ptclib/*.h $RPM_BUILD_ROOT%{_includedir}/ptclib/
%ifos solaris
install tools/asnparser/obj_solaris_*/asnparser $RPM_BUILD_ROOT%{_bindir}
%else
install tools/asnparser/obj_linux_*/asnparser $RPM_BUILD_ROOT%{_bindir}
%endif
install -m 755 make/ptlib-config $RPM_BUILD_ROOT%{_bindir}

cd make
for l in *.mak ; do
	sed -e 's#@prefix@#%{_prefix}#' \
	    -e 's#@makdir@#%{_datadir}/pwlib#' \
		< $l > $RPM_BUILD_ROOT%{_datadir}/%{name}/make/$l
done

%clean
rm -rf $RPM_BUILD_ROOT

%post   
/sbin/ldconfig

%postun 
/sbin/ldconfig

%files
%defattr(-,root,root)
%doc History.txt ReadMe.txt mpl-1.0.htm
%defattr(-,root,root)
%{_libdir}/libpt*.so.*

%files devel
%defattr(-,root,root)
%{_libdir}/libpt*.so
%{_includedir}/*
%{_datadir}/pwlib
%attr(755,root,root) %{_bindir}/*

%changelog
* Fri Apr 09 2004 - Fixed cp lib/*so* so it is lib/*.so* because this
  was picking up a directory that gets added on Solaris only.  Also
  added %ifos so that tools/asnparser/obj_solaris_* gets installed
  instead of the linux directory when building on Solaris.

* Wed Apr 07 2004 - [email protected]
- Removed %ifos solaris from around patches 02-04 as the patch 
  pwlib-02-forte-makefiles.diff now works correctly for linux and solaris 
  for openh323.

* Mon Apr 05 2004 - [email protected]
- Use internal-regex when building on Solaris since the pwlib 1.6.3 code
  doesn't work properly with Solaris.  Now call aclocal since configure.in
  changed to support Solaris readdir_r (fix ported from pwlib CVS head).
 
* Mon Apr 05 2004 - [email protected]
- Added %ifos solaris around the patches 02-04 which is solaris specific.

* Thu Apr 01 2004 - [email protected]
- Added patch 02, 03, and 04 to improve compile on Solari.

* Mon Mar 01 2004 - [email protected]
- Fixed built problem due to old version of alsa on Cinnabar.
  Put in --disable-alsa.

* Fri Feb 27 2004 - [email protected]
- updated tarball to 1.6.3 which is required for g-m 1.00 release.

* Fri Feb 27 2004 - [email protected]
- Updated Distro

* Thu Feb 26 2004 - [email protected]
- Updated tarball to 1.5.2

* Mon Aug 18 2003 - [email protected]
- Include ptbuildopt.h into the the include dir which is needed by
  gnomemeeting.
* Tue Jul 15 2003 - [email protected]
- Initial Sun Release