File childsplay-languagepacks.spec of Package childsplay-languagepacks

#
# spec file for package childsplay-languagepacks 
#
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#

# norootforbuild

Name:           childsplay-languagepacks
Summary:        Localized soundfiles for childsplay
Version:        0.4.3
Release:        3
License:        GPLv2
Group:          Amusements/Games
Url:            http://childsplay.sourceforge.net/
Vendor:         openSUSE-Education
BuildArch:      noarch
Source0:        alphabet_sounds_ca-%version.tar.bz2 
Source1:        alphabet_sounds_de-%version.tar.bz2 
Source2:        alphabet_sounds_es-%version.tar.bz2 
Source3:        alphabet_sounds_fr-%version.tar.bz2 
Source4:        alphabet_sounds_it-%version.tar.bz2 
Source5:        alphabet_sounds_nl-%version.tar.bz2 
Source6:        alphabet_sounds_pt-%version.tar.bz2 
Source7:        alphabet_sounds_ru-%version.tar.bz2 
Source8:        alphabet_sounds_sv-%version.tar.bz2 
Source9:        alphabet_sounds_sl-%version.tar.bz2
Source10:       childsplay-language_packs-rpmlintrc
Requires:       childsplay >= 0.71  
Requires:       childsplay-languagepack = %{version}
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} > 1020
BuildRequires:  fdupes
%endif

%description
These are localized soundfiles used by the childsplay project.



%package ca
Summary:        Localized soundfiles for Catalan
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:ca)

%description ca
This package contains localized soundfiles for Catalan.

%files ca
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/ca*
#----------------------------------------------------------------------
%package de
Summary:        Localized soundfiles for German
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:de)

%description de
This package contains localized soundfiles for German.

%files de
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/de*
#----------------------------------------------------------------------
%package es
Summary:        Localized soundfiles for Spanish 
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:es)

%description es
This package contains localized soundfiles for Spanish.

%files es
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/es*
#----------------------------------------------------------------------
%package fr
Summary:        Localized soundfiles for French
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:fr)

%description fr
This package contains localized soundfiles for French.

%files fr
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/fr*
#----------------------------------------------------------------------
%package it
Summary:        Localized soundfiles for Italian
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:it)

%description it
This package contains localized soundfiles for Italian.

%files it
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/it*
#----------------------------------------------------------------------
%package nl
Summary:        Localized soundfiles for Dutch
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:nl)

%description nl
This package contains localized soundfiles for Dutch.

%files nl
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/nl*
#----------------------------------------------------------------------
%package pt
Summary:        Localized soundfiles for Portuguese
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:pt)

%description pt
This package contains localized soundfiles for Portuguese.

%files pt
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/pt*
#----------------------------------------------------------------------
%package ru
Summary:        Localized soundfiles for Russian
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:ru)

%description ru
This package contains localized soundfiles for Russian.

%files ru
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/ru*
#----------------------------------------------------------------------
%package sl
Summary:        Localized soundfiles for Slovenian
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:sl)

%description sl
This package contains localized soundfiles for Slovenian.

%files sl
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/sl*
#----------------------------------------------------------------------
%package sv
Summary:        Localized soundfiles for Swedish
Group:          Amusements/Teaching/Other
Requires:       childsplay >= 0.71
Provides:       childsplay-languagepack = %version-%release
Provides:       locale(childsplay:sv)

%description sv
This package contains localized soundfiles for Swedish.

%files sv
%defattr (-,root,root,-)
%_datadir/childsplay/Data/AlphabetSounds/sv*
#----------------------------------------------------------------------


%prep
%setup -q -n alphabet_sounds_ca-%version 


%build

%install
install -d %buildroot%_datadir/childsplay/Data/
cp -rf AlphabetSounds %buildroot%_datadir/childsplay/Data/
install %SOURCE1 %buildroot%_datadir/childsplay/Data/
install %SOURCE2 %buildroot%_datadir/childsplay/Data/
install %SOURCE3 %buildroot%_datadir/childsplay/Data/
install %SOURCE4 %buildroot%_datadir/childsplay/Data/
install %SOURCE5 %buildroot%_datadir/childsplay/Data/
install %SOURCE6 %buildroot%_datadir/childsplay/Data/
install %SOURCE7 %buildroot%_datadir/childsplay/Data/
install %SOURCE8 %buildroot%_datadir/childsplay/Data/
install %SOURCE9 %buildroot%_datadir/childsplay/Data/
pushd %buildroot%_datadir/childsplay/Data/ 1>/dev/null
for i in *.tar.bz2; do
 LANG=$(echo ${i/alphabet_sounds_/} | sed -e "s#-%version.tar.bz2##")
 DIR=$(basename $i .tar.bz2)
 echo "extracting $LANG"
 tar -xjf $i
 install -d %buildroot%_datadir/childsplay/Data/AlphabetSounds/$LANG
 find %buildroot%_datadir/childsplay/Data/$DIR/AlphabetSounds/ -name "*.ogg" -exec mv {} %buildroot%_datadir/childsplay/Data/AlphabetSounds/$LANG/ \;
 rm $i
 rm -rf %buildroot%_datadir/childsplay/Data/$DIR
done
popd 1>/dev/null

%if 0%{?suse_version} > 1020
%fdupes -s %buildroot
%endif

%clean
rm -rf %buildroot

%files
%defattr(-, root, root, -)
%doc copyright GPL*
%dir %_datadir/childsplay
%dir %_datadir/childsplay/Data
%dir %_datadir/childsplay/Data/AlphabetSounds

%changelog
openSUSE Build Service is sponsored by