/[packages]/cauldron/TiMidity++/current/SPECS/TiMidity++.spec
ViewVC logotype

Contents of /cauldron/TiMidity++/current/SPECS/TiMidity++.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 162629 - (show annotations) (download)
Fri Nov 4 02:36:46 2011 UTC (12 years, 5 months ago) by fwang
File size: 5984 byte(s)
build with correct ldflags
1 %define name TiMidity++
2 %define version 2.13.2
3 %define release %mkrel 32
4
5 # Stick to /usr/lib/timidity on any platform
6 # XXX probably better in /usr/share/timidity for arch independent data
7 # but it's not worth splitting that much
8 %define timiditydir %{_prefix}/lib/timidity
9
10 #
11 # When big change is involved (e.g. timidity.cfg change location),
12 # so that new timidity binray and old patch RPM won't work together,
13 # increment this number by 1 for all timidity related RPMs
14 #
15 %define patch_pkg_version 2
16
17 #
18 # NOTE: When updating config for midia patch set, please refresh both
19 # config file included here and the one in patch pkg
20 #
21
22 Summary: MIDI to WAVE converter and player
23 Name: %{name}
24 Version: %{version}
25 Release: %{release}
26 URL: http://timidity.sourceforge.net/
27 License: GPLv2+
28 Group: Sound
29 Source0: %{name}-%{version}.tar.bz2
30 Source1: http://www.timidity.jp/dist/cfg/timidity.cfg
31 Source2: timidity-emacs-mode.el
32 Source3: timidity.README.mga
33 Source11: %{name}48.png
34 Source12: %{name}32.png
35 Source13: %{name}16.png
36 # (Abel) change default config path to /etc/timidity/timidity.cfg
37 Patch0: timidity-2.13.2-default-config-path.patch
38 # (Abel) it checked for speex.h, not speex/speex.h
39 Patch1: timidity-2.13.2-speex-header-path.patch
40 # (Abel) fix timidity path in .el file and install .el file when
41 # enabling dynamic module
42 Patch2: timidity-2.13.2-emacs.patch
43 # (Abel) fix wishx path in tcl scripts
44 Patch3: timidity-2.13.2-tcl.patch
45 # (Abel) CVS fixes for 2.13.2
46 Patch4: timidity-2.13.2-cvs-fixes.patch
47 Patch5: TiMidity++-2.13.2-gcc4.patch
48 #(nl) CVS Fix Build against portaudio V19
49 Patch6: Timidity-fix-portaudioV19-build.diff
50 Patch7: TiMidity++-2.13.2+flac-1.1.3-partial.patch
51 Patch8: timidity-2.13.2-tcl-legacy.patch
52 Patch9: timidity-2.13.2-wformat.patch
53 Requires: timidity-instruments = %{patch_pkg_version}
54 BuildRequires: alsa-lib-devel
55 BuildRequires: autoconf
56 BuildRequires: emacs-bin
57 BuildRequires: gtk2-devel
58 BuildRequires: jackit-devel
59 BuildRequires: lesstif-devel
60 BuildRequires: libao-devel
61 BuildRequires: libflac-devel >= 1.1.3
62 BuildRequires: liboggflac-devel
63 BuildRequires: ncurses-devel
64 BuildRequires: oggvorbis-devel
65 BuildRequires: portaudio-devel
66 BuildRequires: speex-devel
67 BuildRequires: tcl-devel
68 BuildRequires: tk-devel
69 BuildRequires: libxaw-devel
70 BuildRequires: slang-devel
71
72 BuildConflicts: Xaw3d-devel
73
74
75 %description
76 TiMidity is a MIDI to WAVE converter and player that uses Gravis
77 Ultrasound(tm) or SoundFont(tm) patch files to generate digital audio data
78 from general MIDI files. The audio data can be played through any
79 sound device or stored on disk.
80
81 %package interfaces-extra
82 Summary: Extra GUI/text mode interfaces for TiMidity
83 Group: Sound
84 Requires: %{name} = %{version}-%{release}
85 Requires: emacs-bin
86
87 %description interfaces-extra
88 TiMidity is a MIDI to WAVE converter and player that uses Gravis
89 Ultrasound(tm) or SoundFont(tm) patch files to generate digital audio data
90 from general MIDI files. The audio data can be played through any
91 sound device or stored on disk.
92
93 Install this if you want to use TiMidity under other interfaces, such as
94 Motif(or Lesstif), Tcl/Tk, emacs etc.
95
96 %prep
97 %setup -q
98 %patch0 -p1 -b .default-path
99 %patch1 -p1 -b .speex-header
100 %patch2 -p1 -b .emacs
101 %patch3 -p1
102 %patch4 -p1 -b .cvs
103 %patch5 -p1 -b .gcc4
104 %patch6 -p0 -b .portaudioV19
105 %patch7 -p1 -b .flac
106 %patch8 -p0 -b .tcl_legacy
107 %patch9 -p0 -b .wformat
108
109 %build
110 autoconf
111
112 # little ugly trick to force install of tclIndex, running wish requires
113 # X display
114 touch interface/tclIndex
115
116
117 export SHLDFLAGS=`echo '%{ldflags}'|sed -e 's/-Wl,--no-undefined//'`
118 %configure2_5x \
119 --enable-audio=oss,alsa,portaudio,jack,ao,vorbis,flac,speex \
120 --enable-dynamic=dynamic,ncurses,slang,motif,tcltk,emacs,xaw,xskin,gtk \
121 --enable-interface=alsaseq \
122 --enable-network \
123 --enable-server
124
125 %make LDFLAGS="-lFLAC"
126
127 %install
128 rm -rf %{buildroot}
129 %makeinstall_std
130 install -d %{buildroot}%{_datadir}/timidity
131 install -m644 %{SOURCE1} -D %{buildroot}%{_sysconfdir}/timidity/timidity-custom.cfg
132
133 install -d %{buildroot}%{_datadir}/applications
134 cat <<EOF > %{buildroot}%{_datadir}/applications/mageia-%{name}.desktop
135 [Desktop Entry]
136 Name=TiMidity++
137 Comment=MIDI file player
138 Exec=timidity -ig
139 Icon=%{name}
140 Terminal=false
141 Type=Application
142 StartupNotify=true
143 Categories=Audio;Midi;
144 EOF
145
146 #icons
147 install -m644 %{SOURCE11} -D %{buildroot}%{_iconsdir}/hicolor/48x48/apps/%{name}.png
148 install -m644 %{SOURCE12} -D %{buildroot}%{_iconsdir}/hicolor/32x32/apps/%{name}.png
149 install -m644 %{SOURCE13} -D %{buildroot}%{_iconsdir}/hicolor/16x16/apps/%{name}.png
150
151 # emacs mode
152 install -m644 %{SOURCE2} -D $RPM_BUILD_ROOT%{_sysconfdir}/emacs/site-start.d/timidity.el
153
154 # japanese manpages
155 install -m644 doc/ja_JP.eucJP/timidity.1 -D %{buildroot}%{_mandir}/ja/man1/timidity.1
156 install -m644 doc/ja_JP.eucJP/timidity.cfg.5 %{buildroot}%{_mandir}/ja/man1/timidity.cfg.5
157
158 %clean
159 rm -rf %{buildroot}
160
161 %post
162
163 %postun
164 if [ "$1" = "0" ]; then
165 %{_sbindir}/update-alternatives --remove timidity.cfg %{_sysconfdir}/timidity/timidity-custom.cfg
166 fi
167
168 %triggerpostun -- %{name} <= 2.13.2-22
169 %{_sbindir}/update-alternatives --install %{_sysconfdir}/timidity/timidity.cfg timidity.cfg %{_sysconfdir}/timidity/timidity-custom.cfg 10
170
171 %files
172 %defattr(-,root,root)
173 %doc AUTHORS ChangeLog INSTALL NEWS README doc/C/FAQ
174 %doc doc/C/README.{alsaseq,dl,sf,m2m,mts}
175 %config(noreplace) %{_sysconfdir}/timidity
176 %{_bindir}/timidity
177 %{_mandir}/man?/timidity*
178 %lang(ja) %{_mandir}/ja/man?/*
179 %{_datadir}/timidity
180 %dir %{timiditydir}
181 %{timiditydir}/interface_[gn].*
182 %{_datadir}/applications/mageia-%{name}.desktop
183 %{_iconsdir}/hicolor/16x16/apps/%{name}.png
184 %{_iconsdir}/hicolor/32x32/apps/%{name}.png
185 %{_iconsdir}/hicolor/48x48/apps/%{name}.png
186
187 %files interfaces-extra
188 %defattr(-,root,root)
189 %doc doc/C/README.{tk,xaw,xskin}
190 %config(noreplace) %{_sysconfdir}/emacs/site-start.d/*.el
191 %{timiditydir}/interface_[aeikms].*
192 %{_datadir}/emacs/site-lisp/*.el
193 %{timiditydir}/*.tcl
194 %{timiditydir}/tclIndex
195 %{timiditydir}/bitmaps

  ViewVC Help
Powered by ViewVC 1.1.30