1 |
%define srcname MuseScore |
2 |
%define shortname mscore |
3 |
|
4 |
Summary: Linux MusE Score Typesetter |
5 |
Name: musecore |
6 |
Version: 1.0 |
7 |
Release: %mkrel 1 |
8 |
# (Fedora) rtf2html is LGPLv2+ |
9 |
# paper4.png paper5.png are LGPLv3 |
10 |
# the rest is GPLv2 |
11 |
License: GPLv2 and LGPLv2+ and LGPLv3 |
12 |
Url: http://musescore.org |
13 |
Group: Publishing |
14 |
Source0: http://downloads.sourceforge.net/project/mscore/mscore/%{srcname}-%{version}/%{srcname}-%{version}.tar.bz2 |
15 |
# (Fedora) For building the jazz font |
16 |
Source1: mscore-ConvertFont.ff |
17 |
# (Fedora) For mime types |
18 |
Source2: mscore.xml |
19 |
Patch0: mscore-1.0-awl-fix-underlink.patch |
20 |
Patch1: mscore-1.0-disable-uitools.patch |
21 |
# (Fedora) use the system default soundfont instead of the deleted, non-free, one |
22 |
Patch2: mscore-use-default-soundfont.patch |
23 |
# (Fedora) don't build the common files (font files, wallpapers, demo song, |
24 |
# instrument list) into the binary executable to reduce its size. This is also |
25 |
# useful to inform the users about the existence of different choices for common |
26 |
# files. The font files need to be separated due to the font packaging guidelines. |
27 |
Patch3: mscore-separate-commonfiles.patch |
28 |
# (Fedora) Split the large documentation into a separate package |
29 |
Patch4: mscore-split-doc.patch |
30 |
# (Fedora) Fix DSO linking. |
31 |
Patch5: mscore-dso-linking.patch |
32 |
# (Fedora) Fix some gcc warnings |
33 |
Patch6: mscore-fix-gcc-warnings.patch |
34 |
BuildRequires: cmake |
35 |
BuildRequires: libalsa-devel |
36 |
BuildRequires: jackit-devel |
37 |
BuildRequires: fluidsynth-devel |
38 |
BuildRequires: portaudio-devel |
39 |
BuildRequires: qt4-devel > 4:4.4 |
40 |
BuildRequires: qt4-linguist |
41 |
Requires: qtscriptbindings |
42 |
Requires: %{name}-fonts = %{version}-%{release} |
43 |
Requires: soundfont2-default |
44 |
Provides: mscore |
45 |
Obsoletes: mscore |
46 |
|
47 |
%description |
48 |
MuseScore stands for Linux MusE Score Typesetter. |
49 |
|
50 |
Features: |
51 |
- WYSIWYG design, notes are entered on a "virtual notepaper" |
52 |
- TrueType font(s) for printing & display allows for high quality |
53 |
scaling to all sizes |
54 |
- easy & fast note entry |
55 |
- many editing functions |
56 |
- MusicXML import/export |
57 |
- Midi (SMF) import/export |
58 |
- MuseData import |
59 |
- Midi input for note entry |
60 |
- integrated sequencer and software synthesizer to |
61 |
play the score |
62 |
- print or create pdf files |
63 |
|
64 |
%package doc |
65 |
Summary: MuseScore documentation |
66 |
Group: Development/Other |
67 |
License: CC-BY |
68 |
Requires: %{name} = %{version}-%{release} |
69 |
BuildArch: noarch |
70 |
Obsoletes: mscore-doc |
71 |
|
72 |
%description doc |
73 |
MuseScore is a free cross platform WYSIWYG music notation program. |
74 |
|
75 |
This package contains the user manual of MuseScore in different languages. |
76 |
|
77 |
%package fonts |
78 |
Summary: MuseScore fonts |
79 |
Group: Publishing |
80 |
License: GPL+ with exceptions and OFL |
81 |
BuildArch: noarch |
82 |
BuildRequires: fontforge |
83 |
BuildRequires: tetex |
84 |
BuildRequires: t1utils |
85 |
Obsoletes: mscore-fonts |
86 |
|
87 |
%description fonts |
88 |
MuseScore is a free cross platform WYSIWYG music notation program. |
89 |
|
90 |
This package contains the musical notation fonts for use of MuseScore. |
91 |
|
92 |
%prep |
93 |
%setup -q -n %{shortname}-%{version}/mscore |
94 |
%patch0 -p2 -b .underlink |
95 |
%patch1 -p0 -b .disable-uitools |
96 |
|
97 |
%patch2 -p2 -b .default-soundfont |
98 |
%patch3 -p2 -b .separate-commonfiles |
99 |
%patch4 -p2 -b .split-doc |
100 |
%patch5 -p2 -b .dso-linking |
101 |
%patch6 -p2 -b .gcc-warnings |
102 |
|
103 |
# only install .qm files |
104 |
perl -pi -e 's,.*.ts\n,,g' share/locale/CMakeLists.txt |
105 |
|
106 |
# (Fedora) Remove the precompiled binary |
107 |
rm rtf2html/rtf2html |
108 |
|
109 |
# (Fedora) Do not build the bundled qt scripting interface: |
110 |
sed -i 's|scriptgen||' CMakeLists.txt |
111 |
|
112 |
# (Fedora) Fix EOL encoding |
113 |
sed 's|\r||' rtf2html/README > tmpfile |
114 |
touch -r rtf2html/README tmpfile |
115 |
mv -f tmpfile rtf2html/README |
116 |
|
117 |
# (Fedora) Remove preshipped fonts. We will build them from source |
118 |
rm -f %{shortname}/%{shortname}/fonts/*.ttf |
119 |
|
120 |
# (Fedora) Disable rpath |
121 |
sed -i '/rpath/d' %{shortname}/CMakeLists.txt |
122 |
|
123 |
# (Fedora) this is non-free soundfont "Gort's Minipiano" |
124 |
rm -f mscore/data/piano1.sf2 |
125 |
|
126 |
# (Fedora) Force specific compile flags: |
127 |
find . -name CMakeLists.txt -exec sed -i 's|-O3|%{optflags}|' {} \; |
128 |
|
129 |
%build |
130 |
%cmake_qt4 -DUSE_GLOBAL_FLUID=ON -DBUILD_SCRIPT_INTERFACE=OFF |
131 |
%make |
132 |
make lupdate |
133 |
make lrelease |
134 |
|
135 |
# (Fedora) Build fonts from source: |
136 |
pushd ../%{shortname}/fonts |
137 |
# adapt genFont script to mandriva's cmake build dir |
138 |
sed -i 's,../../../build/mscore/genft,../../build/mscore/genft,' genFont |
139 |
./genFont |
140 |
fontforge %{SOURCE1} MuseJazz.sfd |
141 |
popd |
142 |
|
143 |
%install |
144 |
rm -rf %{buildroot} |
145 |
%{makeinstall_std} -C build |
146 |
|
147 |
# Install fonts |
148 |
mkdir -p %{buildroot}/%{_datadir}/fonts/%{shortname} |
149 |
install -pm 644 %{shortname}/fonts/%{shortname}*.ttf %{buildroot}/%{_datadir}/fonts/%{shortname} |
150 |
|
151 |
# Install Manpage |
152 |
install -D -pm 644 packaging/%{shortname}.1 %{buildroot}/%{_mandir}/man1/%{shortname}.1 |
153 |
|
154 |
# Install mimetype file |
155 |
install -D -pm 644 %{SOURCE2} %{buildroot}/%{_datadir}/mime/packages/%{shortname}.xml |
156 |
|
157 |
# (Fedora) gather the doc files in one location |
158 |
cp -p rtf2html/ChangeLog ChangeLog.rtf2html |
159 |
cp -p rtf2html/COPYING.LESSER COPYING.LESSER.rtf2html |
160 |
cp -p rtf2html/README README.rtf2html |
161 |
cp -p rtf2html/README.mscore README.mscore.rtf2html |
162 |
cp -p rtf2html/README.ru README.ru.rtf2html |
163 |
cp -p osdabzip/README README.osdabzip |
164 |
cp -p osdabzip/README.mscore README.mscore.osdabzip |
165 |
cp -p share/wallpaper/COPYRIGHT COPYING.wallpaper |
166 |
|
167 |
|
168 |
%clean |
169 |
rm -rf %{buildroot} |
170 |
|
171 |
%files |
172 |
%defattr(-,root,root) |
173 |
%doc ChangeLog* NEWS README* COPYING* |
174 |
%{_bindir}/%{shortname} |
175 |
%{_datadir}/%{shortname}* |
176 |
%{_datadir}/applications/%{shortname}.desktop |
177 |
%{_datadir}/pixmaps/%{shortname}.* |
178 |
%{_datadir}/mime/packages/%{shortname}.xml |
179 |
%{_datadir}/soundfonts/TimGM6mb.sf2 |
180 |
%{_mandir}/man1/* |
181 |
%{qt4plugins}/designer/libawlplugin.so |
182 |
%exclude %{_datadir}/%{shortname}-1.0/man/ |
183 |
|
184 |
%files doc |
185 |
%defattr(-,root,root,-) |
186 |
%doc %{_datadir}/%{shortname}-1.0/man/ |
187 |
|
188 |
%files fonts |
189 |
%{_datadir}/fonts/%{shortname} |