From 08149dfe6a2ee0d826f93a1ed7db544b28a9cca1 Mon Sep 17 00:00:00 2001 From: Orcan Ogetbil Date: Aug 13 2011 02:49:01 +0000 Subject: Update to swami2. Fixes RHBZ#728694 --- diff --git a/.gitignore b/.gitignore index 2d7bbbb..b8ca834 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ swami-0.9.4.tar.bz2 +/swami-2.0.0-svn386.tar.bz2 diff --git a/sources b/sources index 7a04290..254a503 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -83da8e71ce1e6cda0f41d9f5e0ed3fdf swami-0.9.4.tar.bz2 +59e8649b81cbbd2e61bf8bdd00dfd6b7 swami-2.0.0-svn386.tar.bz2 diff --git a/swami-snapshot.sh b/swami-snapshot.sh new file mode 100644 index 0000000..29e2964 --- /dev/null +++ b/swami-snapshot.sh @@ -0,0 +1,37 @@ +#!/bin/bash + +# $1 - revision number to checkout. +: ${1?"You must either provide desired revision number \"X\" to checkout: `basename $0` X + or fetch the latest revision by: `basename $0` latest"} + +set -e + +tmp=$(mktemp -d) + +trap cleanup EXIT +cleanup() { + set +e + [ -z "$tmp" -o ! -d "$tmp" ] || rm -rf "$tmp" +} + +unset CDPATH +pwd=$(pwd) +name=swami +version=2.0.0 + +if [[ $1 == "latest" ]] ; then +revision=HEAD +else +revision=$1 +fi + +pushd "$tmp" >/dev/null +echo "Fetching SVN revision: $1" +svn export -r$revision https://swami.svn.sourceforge.net/svnroot/swami/trunk/$name $name-$version |tee $name.stdout +revision=$(cat $name.stdout|grep "Exported revision"|sed 's|[^0-9]*||g') +echo "Fetched SVN revision: $revision" +rm -f $name.stdout + +tar jcf "$pwd"/$name-$version-svn$revision.tar.bz2 $name-$version +echo "Written: $name-$version-svn$revision.tar.bz2" +popd >/dev/null diff --git a/swami.desktop b/swami.desktop deleted file mode 100644 index 3562a4f..0000000 --- a/swami.desktop +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Name=Swami Instrument Editor -GenericName=Instrument Editor -Comment=Create, play and organize MIDI instruments and sounds -Exec=swami %F -Icon=swami -StartupNotify=true -Terminal=false -Type=Application -Categories=GTK;AudioVideo;Audio;AudioVideoEditing;Midi; -MimeType=audio/dls;audio/x-soundfont; diff --git a/swami.spec b/swami.spec index 8f93dff..af4534d 100644 --- a/swami.spec +++ b/swami.spec @@ -1,31 +1,28 @@ Name: swami -Version: 0.9.4 -Release: 7%{?dist} +Version: 2.0.0 +Release: 1.20110806svn386%{?dist} Summary: MIDI instrument and sound editor Group: Applications/Multimedia -License: GPLv2+ -URL: http://swami.resonance.org/ -Source0: http://downloads.sourceforge.net/swami/%{name}-%{version}.tar.bz2 -# These files are from upstream trunk (.desktop file is slightly modified) -# http://swami.resonance.org/trac/browser/trunk/swami -Source1: %{name}.svg -Source2: %{name}.desktop -Source3: %{name}.xml -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) - -BuildRequires: audiofile-devel -BuildRequires: autoconf -BuildRequires: automake +License: GPLv2 +URL: http://www.swamiproject.org/ +# Upstream applied our patches and switched to cmake in trunk. It is easier +# just to package the trunk than patching it. The original tarball is at +#Source0: http://downloads.sourceforge.net/swami/swami-%%{version}.tar.gz +Source0: swami-2.0.0-svn386.tar.bz2 +# To fetch the sources +Source1: swami-snapshot.sh + +BuildRequires: cmake BuildRequires: desktop-file-utils +BuildRequires: fftw-devel BuildRequires: fluidsynth-devel -BuildRequires: gnome-libs-devel -BuildRequires: ImageMagick -BuildRequires: libpng-devel -BuildRequires: libsndfile-devel -BuildRequires: libtool -BuildRequires: popt-devel +BuildRequires: libglade2-devel +BuildRequires: libgnomecanvas-devel +BuildRequires: libinstpatch-devel +BuildRequires: librsvg2-devel Requires: hicolor-icon-theme +Requires: swami-libs%{?_isa} = %{version}-%{release} %description The Swami Project - Sampled Waveforms And Musical Instruments - is a collection @@ -33,47 +30,35 @@ of free software for editing and sharing MIDI instruments and sounds. Swami aims to provide an instrument editing and sharing software for instrument formats such as SoundFont, DLS and GigaSampler. -%prep -%setup -q - -# Fix libdir -sed -i 's|/lib/|/%{_lib}/|g' configure.ac - -%build -autoreconf -v -i -f -%configure --disable-static -make %{?_smp_mflags} +%package libs +Summary: MIDI instrument and sound editor library +%description libs +Shared libraries for The Swami Project - Sampled Waveforms And Musical +Instruments. -%install -rm -rf $RPM_BUILD_ROOT -make install DESTDIR=$RPM_BUILD_ROOT +%package devel +Summary: MIDI instrument and sound editor development files +Requires: swami-libs%{?_isa} = %{version}-%{release} -# kill .la files -rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/*.la +%description devel +Headers and development files for The Swami Project - Sampled Waveforms And +Musical Instruments. -# desktop file -install -dm 755 $RPM_BUILD_ROOT/%{_datadir}/icons/hicolor/scalable/apps -install -pm 644 %{SOURCE1} \ - $RPM_BUILD_ROOT/%{_datadir}/icons/hicolor/scalable/apps +%prep +%setup -q -# icon -install -dm 755 $RPM_BUILD_ROOT/%{_datadir}/applications -desktop-file-install \ - --dir=${RPM_BUILD_ROOT}%{_datadir}/applications \ - %{SOURCE2} +%build +mkdir -p %{_target_platform} +pushd %{_target_platform} +%{cmake} -DLIB_SUFFIX="" -DPLUGINS_DIR=%{_libdir}/swami/ .. +popd -# mime-type file -install -dm 755 $RPM_BUILD_ROOT/%{_datadir}/mime/packages -install -pm 644 %{SOURCE3} $RPM_BUILD_ROOT/%{_datadir}/mime/packages/ +make %{?_smp_mflags} -C %{_target_platform} -# to avoid filename conflicts -for file in AUTHORS ChangeLog README; do - mv src/libinstpatch/$file $file.libinstpatch -done -%clean -rm -rf $RPM_BUILD_ROOT +%install +make install DESTDIR=%{buildroot} -C %{_target_platform} %post @@ -92,17 +77,33 @@ update-mime-database %{_datadir}/mime &> /dev/null || : %posttrans gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : +%post libs -p /sbin/ldconfig + +%postun libs -p /sbin/ldconfig %files -%defattr(-,root,root,-) -%doc AUTHORS* ChangeLog* COPYING NEWS README* +%doc AUTHORS ChangeLog NEWS README %{_libdir}/%{name}/ +%{_datadir}/%{name}/ %{_bindir}/%{name} %{_datadir}/applications/%{name}.desktop -%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg +%{_datadir}/icons/hicolor/*/apps/* %{_datadir}/mime/packages/%{name}.xml +%files libs +%doc COPYING +%{_libdir}/lib%{name}*.so.* + +%files devel +%doc HACKERS +%{_libdir}/lib%{name}*.so +%{_includedir}/%{name}/ + + %changelog +* Fri Aug 12 2011 Orcan Ogetbil - 2.0.0-1.20110806svn386 +- Update to swami2. Fixes RHBZ#728694 + * Wed Feb 09 2011 Fedora Release Engineering - 0.9.4-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild diff --git a/swami.svg b/swami.svg deleted file mode 100644 index b14e207..0000000 --- a/swami.svg +++ /dev/null @@ -1,214 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - image/svg+xml - - - - - - - - - - - - - - - - - - diff --git a/swami.xml b/swami.xml deleted file mode 100644 index 7ba2d88..0000000 --- a/swami.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - Downloadable Sounds - - - - - - - - - - SoundFont - - - - - - - -