Summary: Several X utilities mainly for use with multimedia files.
Summary(ja): マルチメディアファイルを扱う為の X ユーティリティ
Name: multimedia
Version: 2.1
Release: 21%{?_dist_release}
License: GPL
Group: Applications/Multimedia
Source: ftp://sunsite.unc.edu/pub/Linux/apps/sound/suites/multimedia-2.1.tar.gz
Patch: multimedia-2.1-misc.patch
Patch1: multimedia-2.1-scsi.patch
Patch2: multimedia-2.1-res.patch
Patch3: multimedia-2.1-64bit.patch
Patch4: multimedia-2.1-ustat.patch
Patch5: multimedia-dir.patch
Patch6: multimedia-umask.patch
Patch100: multimedia-2.1-gcc33.patch
Patch101: multimedia-2.1-files.patch
Buildroot: %{_tmppath}/%{name}-%{version}-root


%description
The multimedia package contains several X Window System utilities for
handling multimedia files, including xplaycd, xmixer and xgetfile.
Xplaycd is a CD player for playing audio CDs on your machine's CD-ROM
drive.  Xmixer controls the volume settings on your machine's sound
card.  Xgetfile is a versatile file browser, intended for use in shell
scripts.

Install the multimedia package if you need an audio CD player, a sound
card volume controller, or a file browser for use in shell scripts.

%description -l ja
multimedia パッケージには，xplaycd, xmixer, xgetfile 等
マルチメディアファイルを扱う為の X ウィンドウシステム向け
ユーティリティが幾つか収められています．
xplaycd は CD-ROM ドライブのオーディオ CD を再生する為の
CD プレーヤです．xmixer はサウンドカードのボリュームを設定
するツールです．xgetfile はシェルスクリプト内で使うことを主眼に置いた
万能ファイルブラウザです．

オーディオ CD プレーヤ，サウンドカードのボリューム設定ツール，
シェルスクリプト内から使うファイルブラウザが必要ならば
この multimedia パッケージをインストールして下さい．


%prep
%setup -q -n multimedia
%patch -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1 
%patch6 -p1
%patch100 -p1
%patch101 -p1


%build
make depend
make RPM_OPT_FLAGS="$RPM_OPT_FLAGS" LIBOPTS=-L%{_libdir}


%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_bindir}
mkdir -p $RPM_BUILD_ROOT%{_mandir}/man1
mkdir -p $RPM_BUILD_ROOT%{_datadir}/X11/app-defaults
make install \
	BINDIR=$RPM_BUILD_ROOT%{_bindir} \
	MANDIR=$RPM_BUILD_ROOT%{_mandir}/man1 \
	DEFAULTDIR=$RPM_BUILD_ROOT%{_datadir}/X11/app-defaults \
	LIBDIR=$RPM_BUILD_ROOT%{_libdir} \
	MKDIR="mkdir -p"

chmod 644 $RPM_BUILD_ROOT%{_datadir}/X11/app-defaults/*
chmod 644 $RPM_BUILD_ROOT%{_mandir}/man1/*
strip $RPM_BUILD_ROOT%{_bindir}/*
mkdir -p $RPM_BUILD_ROOT/etc/X11/applnk/Multimedia
cat > $RPM_BUILD_ROOT/etc/X11/applnk/Multimedia/xplaycd.desktop <<EOF
[Desktop Entry]
Name=XPlayCD
Name[sv]=XPlayCD
Type=Application
Comment=CD player
Comment[sv]=CD-spelare
Exec=xplaycd
EOF

cat > $RPM_BUILD_ROOT/etc/X11/applnk/Multimedia/xmixer.desktop <<EOF
[Desktop Entry]
Name=XMixer
Name[sv]=XMixer
Type=Application
Comment=Sound card mixer panel
Comment[sv]=Ljudkortsmixerpanel
Exec=xmixer
EOF

mkdir -p $RPM_BUILD_ROOT/var/lib/cddb/
chmod 1777 $RPM_BUILD_ROOT/var/lib/cddb/ 


%clean
rm -rf $RPM_BUILD_ROOT


%files
%defattr(-,root,root)
%config(missingok) /etc/X11/applnk/Multimedia/*
%{_bindir}/*
%{_mandir}/man1/*
%dir /var/lib/cddb/ 

%config %{_datadir}/X11/app-defaults/*
%doc INSTALL

%changelog
* Sat Oct 04 2008 Shu KONNO <owa@bg.wakwak.com> 2.1-21vl5
- applied new versioning policy, spec in utf-8

* Mon Jun 11 2007 Shu KONNO <owa@bg.wakwak.com> 2.1-20vl3
- rebuilt with new toolchain
- changed lib to %%{_lib}
- added Patch101: multimedia-2.1-files.patch

* Fri Mar 19 2004 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 2.1-20vl2
- rebuild with new toolchains
- add Patch100 to compile with gcc-3.3.x
- s/Copyright/License/

* Thu Jan 25 2001 MATSUBAYASHI 'Shaolin' Kohji <shaolin@rhythmaning.org>
- 2.1-20vl1
- based on 2.1-20 from Rawhide
- added Japanese summary and description
- use better macros (%%{_tmppath})

* Fri Aug  4 2000 Bill Nottingham <notting@redhat.com>
- add translation to desktop entry

* Wed Jul 12 2000 Prospector <bugzilla@redhat.com>
- automatic rebuild

* Sat Jun 10 2000 Bill Nottingham <notting@redhat.com>
- fix cddb stuff (#11372)

* Mon Feb 07 2000 Preston Brown <pbrown@redhat.com>
- wmconfig -> desktop

* Thu Feb  3 2000 Bill Nottingham <notting@redhat.com>
- handle compressed man pages

* Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com> 
- auto rebuild in the new build environment (release 15)

* Thu Feb 11 1999 Michael Maher <mike@redhat.com>
- fixed bug #633

* Tue Jan 24 1999 Michael Maher <mike@redhat.com>
- changed groups, ran thru build system.

* Thu Dec 17 1998 Michael Maher <mike@redhat.com>
- built package for 6.0

* Thu Sep 17 1998 Jeff Johnson <jbj@redhat.com>
- use "mkdir -p" rather than mkdirhier to avoid IFS problem with bash-2.02.

* Thu Sep 10 1998 Cristian Gafton <gafton@redhat.com>
- spec install fix

* Fri May 01 1998 Prospector System <bugs@redhat.com>
- translations modified for de, fr, tr

* Fri Apr 10 1998 Cristian Gafton <gafton@redhat.com>
- Manhattan build
- buildroot

* Tue Oct 21 1997 Michael Fulbright <msf@redhat.com>
- updated spec file
- added wmconfig stuff, but not included in file lists
  because users genarally cant control /dev/cdrom or /dev/mixer.
  Once users can do this we should include the wmconfig files.

* Fri Aug 22 1997 Erik Troan <ewt@redhat.com>
- incorporated 64bit cleanliness patch
- incorporated pointer init patch w/ makes xmplay work on Alphas
- built against glibc
