Sophie

Sophie

distrib > Mandriva > 2009.1 > i586 > media > main-release-src > by-pkgid > c5700f42d7da5badc86808f5b0e0dada > files > 4

ptlib-2.6.1-2mdv2009.1.src.rpm

%define _disable_ld_no_undefined	1

%define	fname	pt

%define version		2.6.1
%define major		%version
%define libname		%mklibname %{fname} %{major}
%define develname	%mklibname %{fname} -d

Summary:	Portable Tool Library
Name:		ptlib
Version:	%version
Release:	%mkrel 2
License:	MPL
Group:		System/Libraries
URL:		http://www.opalvoip.org
# Always use the GNOME.org version, not the opalvoip.org version. The
# major user of ptlib and opal is Ekiga, and Ekiga is designed to work
# with the GNOME.org versions of these libraries, not the opalvoip.org
# versions. - AdamW 2008/09
Source0:	ftp://ftp.gnome.org/pub/GNOME/sources/ptlib/%{name}-%{version}.tar.bz2
Patch: ptlib-2.5.2-format-string.patch
# gw build fix for http://bugzilla.gnome.org/show_bug.cgi?id=573824
Patch1: ptlib-2.6.0-odbctypes.patch
BuildRequires:	alsa-lib-devel
BuildRequires:	esound-devel
BuildRequires:	autoconf
BuildRequires:	bison
BuildRequires:  expat-devel
BuildRequires:	flex
BuildRequires:	gcc-c++
BuildRequires:	libavc1394-devel
BuildRequires:  dc1394-devel >= 0.9.5
BuildRequires:	libdv-devel
BuildRequires:	libraw1394_8-devel
BuildRequires:	openldap-devel
BuildRequires:	openssl-devel
BuildRequires:	SDL-devel
BuildRequires:	libv4l-devel
BuildRequires:	unixODBC-devel
BuildRequires:	sed
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-buildroot
BuildConflicts: libdc1394-devel >= 2.0.0

%description
PTLib is a C++ multi-platform abstraction library that has its genesis
many years ago as a method to produce applications to run on both
Microsoft Windows and Unix systems. It also was to have a Macintosh
port but this never eventuated.

This is the GNOME.org version of ptlib.

%package -n	%{libname}
Summary:	Portable Windows Libary
Group:		System/Libraries
Requires:	%{libname}-plugins >= %{version}-%{release}
Obsoletes:	%{mklibname pt 2} < 2.4.1-2mdv

%description -n	%{libname}
PTLib is a C++ multi-platform abstraction library that has its genesis
many years ago as a method to produce applications to run on both
Microsoft Windows and Unix systems. It also was to have a Macintosh
port but this never eventuated.

This is the GNOME.org version of ptlib.

%package -n	%{develname}
Summary:	Portable Windows Libary development files
Group:		Development/C
Requires:	%{libname} = %{version}-%{release}
Provides:	%{name}-devel = %{version}-%{release}
Conflicts:	%{mklibname pwlib -d}

%description -n	%{develname}
Header files and libraries for developing applications that use ptlib.

%package -n	%{libname}-plugins
Summary:	Main plugins for ptlib
Group:		System/Libraries
Requires:	%{libname} = %{version}-%{release}
Provides:	%{name}-plugins = %{version}-%{release}
Provides:	%{name}-plugins-alsa = %{version}-%{release}
Provides:	%{name}-plugins-oss = %{version}-%{release}
Provides:	%{name}-plugins-v4l = %{version}-%{release}
Provides:	%{name}-plugins-v4l2 = %{version}-%{release}
Obsoletes:	%{mklibname pt 2}-plugins < 2.4.1-2mdv

%description -n	%{libname}-plugins
This package contains the oss, alsa, v4l1 and v4l2 plugins for ptlib.

%package -n	%{libname}-plugins-dc
Summary:	Dc plugin for ptlib
Group:		System/Libraries
Requires:	%{libname} = %{version}-%{release}
Provides:	%{name}-plugins-dc = %{version}-%{release}
Obsoletes:	%{mklibname pt 2}-plugins-dc < 2.4.1-2mdv

%description -n	%{libname}-plugins-dc
This package contains the dc plugin for ptlib.

%package -n	%{libname}-plugins-avc
Summary:	AVC plugin for ptlib
Group:		System/Libraries
Requires:	%{libname} = %{version}-%{release}
Provides:	%{name}-plugins-avc = %{version}-%{release}
Obsoletes:	%{mklibname pt 2}-plugins-avc < 2.4.1-2mdv

%description -n	%{libname}-plugins-avc
This package contains the AVC plugin for ptlib.

%prep
%setup -q
%patch -p1
%patch1 -p1 -b .odbctypes

%build
%configure2_5x \
    --enable-v4l2 \
    --enable-v4l \
    --enable-plugins \
    --enable-oss \
    --enable-esd

%make RPM_OPT_FLAGS="%{optflags}"

%install
[ "%{buildroot}" != "/" ] && rm -rf %{buildroot}

%makeinstall_std

%multiarch_includes %{buildroot}%{_includedir}/ptbuildopts.h
%multiarch_includes %{buildroot}%{_includedir}/ptlib/pluginmgr.h

#fix doc perms
chmod a+r *.txt

#remove unpackaged files
rm -f %{buildroot}%{_datadir}/ptlib/make/*.{pat,in,lib64,libname,ptlibdir,includesdir}

# fix ptlib-config
install -d %{buildroot}%{_bindir}
ln -snf %{_datadir}/ptlib/make/ptlib-config %{buildroot}%{_bindir}/ptlib-config

# fix strange perms
find %{buildroot} -type d -perm 0700 -exec chmod 755 {} \;
find %{buildroot} -type f -perm 0555 -exec chmod 755 {} \;
find %{buildroot} -type f -perm 0444 -exec chmod 644 {} \;
find %{buildroot}%{_libdir} -type f -name '*.so*' -exec chmod 755 {} \;

# it's not stable at major version level...
rm -f %{buildroot}%{_libdir}/libpt.so.?
rm -f %{buildroot}%{_libdir}/libpt.so.?.?

%if %mdkversion < 200900
%post -n %{libname} -p /sbin/ldconfig
%endif

%if %mdkversion < 200900
%postun -n %{libname} -p /sbin/ldconfig
%endif

%clean
[ "%{buildroot}" != "/" ] && rm -rf %{buildroot}

%files -n %{libname}
%defattr(-,root,root)
%attr(0755,root,root) %{_libdir}/lib*.so.%{major}*

%files -n %{develname}
%defattr(-,root,root)
%doc *.txt
%attr(0755,root,root) %{_bindir}/ptlib-config
%attr(0755,root,root) %{_libdir}/*.so
%{_libdir}/*.*a
%{_includedir}/*
%{_datadir}/%{name}
%{_libdir}/pkgconfig/%{name}.pc

%files -n %{libname}-plugins
%defattr(-,root,root)
%dir %{_libdir}/%{name}-%{version}
%dir %{_libdir}/%{name}-%{version}/devices
%dir %{_libdir}/%{name}-%{version}/devices/sound
%dir %{_libdir}/%{name}-%{version}/devices/videoinput
%attr(0755,root,root) %{_libdir}/%{name}-%{version}/devices/sound/alsa_pwplugin.so
%attr(0755,root,root) %{_libdir}/%{name}-%{version}/devices/sound/oss_pwplugin.so
%attr(0755,root,root) %{_libdir}/%{name}-%{version}/devices/sound/esd_pwplugin.so
%attr(0755,root,root) %{_libdir}/%{name}-%{version}/devices/videoinput/v4l_pwplugin.so
%attr(0755,root,root) %{_libdir}/%{name}-%{version}/devices/videoinput/v4l2_pwplugin.so

%files -n %{libname}-plugins-dc
%defattr(-,root,root)
%attr(0755,root,root) %{_libdir}/%{name}-%{version}/devices/videoinput/dc_pwplugin.so

%files -n %{libname}-plugins-avc
%defattr(-,root,root)
%attr(0755,root,root) %{_libdir}/%{name}-%{version}/devices/videoinput/avc_pwplugin.so


%changelog
* Sun Mar 22 2009 Funda Wang <fundawang@mandriva.org> 2.6.1-2mdv2009.1
+ Revision: 360134
- as needed is fine

* Wed Mar 18 2009 Götz Waschk <waschk@mandriva.org> 2.6.1-1mdv2009.1
+ Revision: 357185
- update to new version 2.6.1

* Mon Mar 02 2009 Götz Waschk <waschk@mandriva.org> 2.6.0-1mdv2009.1
+ Revision: 347588
- new version
- fix build with unixODBC
- spec cleanup

* Tue Jan 06 2009 Götz Waschk <waschk@mandriva.org> 2.5.2-1mdv2009.1
+ Revision: 325394
- new version
- fix format strings
- depend on the right libraw1394

* Tue Oct 21 2008 Götz Waschk <waschk@mandriva.org> 2.4.2-1mdv2009.1
+ Revision: 295931
- new version
- new major
- fix source URL

* Thu Sep 25 2008 Adam Williamson <awilliamson@mandriva.org> 2.4.1-2mdv2009.0
+ Revision: 288194
- since there's no stability at major / minor version level, the major / minor
  versioned library symlinks shouldn't exist, so don't package them
- drop now unnecessary autotools calls
- obsolete the incorrect major packages
- major should be 2.4.1 (that's the SONAME)

* Tue Sep 23 2008 Adam Williamson <awilliamson@mandriva.org> 2.4.1-1mdv2009.0
+ Revision: 287368
- adjust file list for new layout (versioned plugin directory)
- explicitly enable v4l plugin build (doesn't seem to get built otherwise)
- drop lib64.patch: MDV-specific hack that likely isn't needed any more
- drop libname.patch, fix-libpt.so-symlink.diff, preprocess.patch and
  fix-build-with-libv4l.patch: merged upstream
- new release 2.4.1

  + Götz Waschk <waschk@mandriva.org>
    - use default optflags

* Wed Sep 10 2008 Götz Waschk <waschk@mandriva.org> 2.3.1-4mdv2009.0
+ Revision: 283461
- patch to make it use libv4l (b.g.o #550961)

* Thu Sep 04 2008 Götz Waschk <waschk@mandriva.org> 2.3.1-3mdv2009.0
+ Revision: 280239
- add another missing build dep
- build with libv4l

* Tue Sep 02 2008 Adam Williamson <awilliamson@mandriva.org> 2.3.1-1mdv2009.0
+ Revision: 279240
- add new .pc file to file list
- drop 'fix ptlibDIR' workaround, no longer relevant
- have to run aclocal before autoconf or autoconf fails
- drop conditionals for unsupported releases
- fix lib64.patch - it was missing a @ and hence wasn't actually working right
  (ptlib-config --lib would always return @LIB)
- add comment to remind people always to use gnome.org source
- disable underlinking protection (upstream has internal underlinking issues)
- new release 2.3.1, from gnome.org

  + Thierry Vignaud <tvignaud@mandriva.com>
    - rebuild early 2009.0 package (before pixel changes)

  + Pixel <pixel@mandriva.com>
    - do not call ldconfig in %%post/%%postun, it is now handled by filetriggers

* Mon May 12 2008 Adam Williamson <awilliamson@mandriva.org> 2.2.0-1mdv2009.0
+ Revision: 206476
- new release 2.2.0

* Tue Dec 25 2007 Adam Williamson <awilliamson@mandriva.org> 2.1.2-2mdv2008.1
+ Revision: 137747
- explicit conflicts between libpt-devel and libpwlib-devel

* Mon Dec 24 2007 Adam Williamson <awilliamson@mandriva.org> 2.1.2-1mdv2008.1
+ Revision: 137590
- import ptlib