%global fontfamilyname %{name} Summary: Linux MusE Score Typesetter Name: mscore Version: 1.3 Release: %mkrel 6 # (Fedora) rtf2html is LGPLv2+ # paper4.png paper5.png are LGPLv3 # the rest is GPLv2 License: GPLv2 and LGPLv2+ and LGPLv3 Url: http://musescore.org Group: Publishing # From Fedora # Upstream tarball contains a non-free soundfont "Gort's Minipiano" # And one demo file which is CC-BY-NC-SA (non-free) # We generate our own tarball by removing these files via: # wget http://download.sourceforge.net/mscore/mscore-1.3.tar.bz2 # tar jxf mscore-1.3.tar.bz2 # rm -f mscore-*/mscore/mscore/data/piano1.sf2 # rm -f mscore-*/mscore/demos/prelude.mscx # tar jcf mscore-1.3-free.tar.bz2 mscore-1.3/ Source0: %{name}-%{version}-free.tar.bz2 # For mime types Source2: %{name}.xml # Use Fedora's default soundfont instead of the removed one: Patch0: %{name}-use-default-soundfont.patch # We don't build the common files (font files, wallpapers, demo song, instrument # list) into the binary executable to reduce its size. This is also useful to # inform the users about the existence of different choices for common files. # The font files need to be separated due to the font packaging guidelines. Patch1: %{name}-separate-commonfiles.patch # Split the large documentation into a separate package Patch2: %{name}-split-doc.patch # Fix some gcc warnings Patch3: %{name}-fix-gcc-warnings.patch # Fix DSO linking. Seems to have been fixed in trunk, but misssing in the tarball # http://musescore.org/en/node/5817 Patch4: %{name}-dso-linking.patch # Use system qtsingleapplication Patch5: %{name}-system-qtsingleapplication.patch # Fix crash on Accidentals click RHBZ#738044 From upstream trunk rev 3193 Patch6: %{name}-fix-accidentals-crash.patch Patch7: %{name}-1.0-awl-fix-underlink.patch Patch8: %{name}-1.3-no-prelude.patch Patch9: mscore-1.3-mga-freetype2-include.patch BuildRequires: cmake BuildRequires: libalsa-devel BuildRequires: jackit-devel BuildRequires: fluidsynth-devel BuildRequires: portaudio-devel BuildRequires: qt4-devel > 4:4.4 BuildRequires: pkgconfig(QtWebKit) >= 4.4 BuildRequires: qt4-linguist BuildRequires: qtsingleapplication-devel BuildRequires: texlive BuildRequires: texlive-texmf BuildRequires: doxygen Requires: qtscriptbindings Requires: %{name}-fonts = %{version}-%{release} Requires: soundfont2-default Provides: musescore = %{version}-%{release} Obsoletes: musescore < 1.2-1 %description MuseScore stands for Linux MusE Score Typesetter. Features: - WYSIWYG design, notes are entered on a "virtual notepaper" - TrueType font(s) for printing & display allows for high quality scaling to all sizes - easy & fast note entry - many editing functions - MusicXML import/export - Midi (SMF) import/export - MuseData import - Midi input for note entry - integrated sequencer and software synthesizer to play the score - print or create pdf files %package doc Summary: MuseScore documentation Group: Development/Other License: CC-BY Requires: %{name} = %{version}-%{release} BuildArch: noarch Obsoletes: musescore-doc %description doc MuseScore is a free cross platform WYSIWYG music notation program. This package contains the user manual of MuseScore in different languages. %package fonts Summary: MuseScore fonts Group: Publishing License: GPL+ with exceptions and OFL BuildArch: noarch BuildRequires: fontforge BuildRequires: tetex BuildRequires: t1utils %description fonts MuseScore is a free cross platform WYSIWYG music notation program. This package contains the musical notation fonts for use of MuseScore. %prep %setup -q %apply_patches # (Fedora) Remove the precompiled binary rm mscore/rtf2html/rtf2html # Force Fedora specific flags: find . -name CMakeLists.txt -exec sed -i -e 's|-m32|%{optflags}|' -e 's|-O3|%{optflags}|' {} \; # (Fedora) Do not build the bundled qt scripting interface: sed -i 's|BUILD_SCRIPTGEN TRUE|BUILD_SCRIPTGEN FALSE|' %{name}/CMakeLists.txt # (Fedora) Fix EOL encoding sed 's|\r||' %{name}/rtf2html/README > tmpfile touch -r %{name}/rtf2html/README tmpfile mv -f tmpfile %{name}/rtf2html/README # (Fedora) Remove preshipped fonts. We will build them from source rm -f %{name}/%{name}/fonts/*.ttf # (Fedora) Change font name according to our conventions sed -i 's|MuseJazz.ttf|%{fontfamilyname}-MuseJazz.ttf|' %{name}/%{name}/fonts/gen-jazz.pe # (Fedora) Disable rpath sed -i '/rpath/d' %{name}/%{name}/CMakeLists.txt # (Fedora) We don't use this 3rd party lib but remove anyways rm -fr mscore/singleapp/ mscore/scriptgen/ %build # Build the actual program export PATH=${PATH}:%{_libdir}/qt4/bin %cmake -DCMAKE_BUILD_TYPE=RELEASE \ -DCMAKE_CXX_FLAGS="%{optflags}" \ -DUSE_SYSTEM_QTSINGLEAPPLICATION=1 \ ../mscore %make lupdate %make lrelease %make VERBOSE=1 # Build fonts from source: pushd ../%{name}/%{name}/fonts ./genFont fontforge gen-jazz.pe popd %install %{makeinstall_std} -C build # (Fedora) Install fonts mkdir -p %{buildroot}/%{_datadir}/fonts/%{name}/ install -pm 644 %{name}/%{name}/fonts/%{fontfamilyname}*.ttf %{buildroot}/%{_datadir}/fonts/%{name} # (Fedora) Install mimetype file install -D -pm 644 %{SOURCE2} %{buildroot}/%{_datadir}/mime/packages/%{name}.xml # (Fedora) Desktop file #desktop-file-install \ # --dir=%{buildroot}/%{_datadir}/applications \ # --add-category="X-Notation" \ # --remove-category="Sequencer" \ # --remove-category="AudioVideoEditing" \ # --add-mime-type="audio/midi" \ # --add-mime-type="text/x-lilypond" \ # --add-mime-type="application/xml" \ # %{buildroot}/%{_datadir}/applications/%{name}.desktop # (Fedora) Move images to the freedesktop location mkdir -p %{buildroot}/%{_datadir}/icons/hicolor/{32x32,64x64}/apps/ mkdir -p %{buildroot}/%{_datadir}/icons/hicolor/{32x32,64x64}/mimetypes/ cp -a %{buildroot}/%{_datadir}/pixmaps/%{name}.xpm \ %{buildroot}/%{_datadir}/icons/hicolor/32x32/mimetypes/application-x-musescore.xpm mv %{buildroot}/%{_datadir}/pixmaps/%{name}.xpm \ %{buildroot}/%{_datadir}/icons/hicolor/32x32/apps/ cp -a %{buildroot}/%{_datadir}/pixmaps/%{name}.png \ %{buildroot}/%{_datadir}/icons/hicolor/64x64/mimetypes/application-x-musescore.png mv %{buildroot}/%{_datadir}/pixmaps/%{name}.png \ %{buildroot}/%{_datadir}/icons/hicolor/64x64/apps/ # (Fedora) Manpage mkdir -p %{buildroot}/%{_mandir}/man1 install -pm 644 %{name}/packaging/%{name}.1 %{buildroot}/%{_mandir}/man1/ # Openoffice templates cp -a %{name}/utils/OOoMuseScore/ %{buildroot}/%{_datadir}/%{name}-%{version} # (Fedora) gather the doc files in one location # There are many doc files spread around the tarball. Let's collect them pushd %{name} mv rtf2html/ChangeLog ChangeLog.rtf2html mv rtf2html/COPYING.LESSER COPYING.LESSER.rtf2html mv rtf2html/README README.rtf2html mv rtf2html/README.mscore README.mscore.rtf2html mv rtf2html/README.ru README.ru.rtf2html mv osdabzip/README README.osdabzip mv osdabzip/README.mscore README.mscore.osdabzip mv share/wallpaper/COPYRIGHT COPYING.wallpaper popd %files %doc mscore/{ChangeLog*,COPYING*,NEWS,README*} %{_bindir}/%{name} %{_datadir}/%{name}-%{version}/ %exclude %{_datadir}/%{name}-%{version}/man/ %{_datadir}/icons/hicolor/*/*/* %{_datadir}/applications/%{name}.desktop %{_datadir}/mime/packages/%{name}.xml %{_datadir}/soundfonts/TimGM6mb.sf2 %{_mandir}/man1/* %{_qt4_plugindir}/designer/libawlplugin.so %files doc %doc %{_datadir}/%{name}-%{version}/man/ %files fonts %{_datadir}/fonts/%{name}/%{fontfamilyname}*.ttf %changelog * Wed Oct 15 2014 umeabot <umeabot> 1.3-6.mga5 + Revision: 741920 - Second Mageia 5 Mass Rebuild - Mageia 5 Mass Rebuild * Wed Mar 26 2014 akien <akien> 1.3-4.mga5 + Revision: 608866 - Add a patch for freetype2 include - Fix provides for musescore - Reobsolete musescore with proper version * Mon Oct 21 2013 spuhler <spuhler> 1.3-3.mga4 + Revision: 541132 - reversed last change - changed the make to single cpu to get it built + umeabot <umeabot> - Mageia 4 Mass Rebuild + luigiwalser <luigiwalser> - BR texlive-texmf * Thu May 23 2013 spuhler <spuhler> 1.3-1.mga4 + Revision: 424881 - upgrade to version 1.3 - removed none-free prelude sample - renumbered patches - removed obsolete fonts line * new version will automatically replace/upgrade existing package * Sun Jan 13 2013 spuhler <spuhler> 1.2-3.mga3 + Revision: 377983 - changed BuildRequires: from texlive-mf2pt1 to texlive texlive now provides it again + umeabot <umeabot> - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild * Sun Nov 11 2012 spuhler <spuhler> 1.2-2.mga3 + Revision: 317079 - corrected the location of the fonts. Theprogram now can find them Bumped rel. * Sun Nov 11 2012 spuhler <spuhler> 1.2-1.mga3 + Revision: 316904 - changed name of package mscore from musescore to sync with fedora replaced the vanilla 1.2 source tar with the one tat has the none free piano fonts removed