]> git.donarmstrong.com Git - lilypond.git/blob - make/lilypond.redhat.spec.in
07176b3d8ea35e6b99feb769916886c459d87bf7
[lilypond.git] / make / lilypond.redhat.spec.in
1 # -*-rpm-spec-mode-*-
2
3 %define info yes
4 %define docdir %{_docdir}/lilypond/
5
6 Name: lilypond
7 Version: @TOPLEVEL_VERSION@
8 Release: 1
9 License: GPL
10 Group: Applications/Publishing
11 Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-@TOPLEVEL_VERSION@.tar.gz
12 Summary: Create and print music notation 
13 URL: http://www.lilypond.org/
14 BuildRoot: %{_tmppath}/%{name}-%{version}-root
15
16
17 Buildrequires: t1utils bison flex mftrace texinfo
18 Requires: tetex  tetex-latex libstdc++ python 
19
20 %description
21 LilyPond lets you create music notation.  It produces
22 beautiful sheet music from  a high-level description file.
23
24 %package documentation
25 Summary:  All LilyPond documentation, in HTML
26 Group: Applications/Publishing
27 # BuildArchitectures: noarch
28
29 %description documentation
30 Documentation and example files of LilyPond. An index is available at
31 %{docdir}/web/Documentation/out-www/index.html
32
33 %prep
34 %setup
35
36 %build
37
38 # DO NOT use % { configure } , it hardcodes all paths, runs libtool,
39 # so we can't do make prefixix=/tmp/ install.
40
41 # In fact, do not take out the spaces between % and { in the above comment,
42 # because RPM will gladly do a substitution anyway.
43
44 ./configure --disable-checking --prefix=%{_prefix} --enable-optimising
45
46
47 make MAKE_PFA_FILES=1 all
48 make -C mf/ pfa
49
50 # make info
51 make -C Documentation
52
53 # make  html
54 make web-doc top-web 
55 make -C Documentation/user/ omf
56
57
58 %install
59
60
61 rm -rf $RPM_BUILD_ROOT
62 mkdir -p $RPM_BUILD_ROOT/tmp/lilypond-rpm-doc
63
64 strip lily/out/lilypond 
65 make prefix="$RPM_BUILD_ROOT%{_prefix}" infodir="$RPM_BUILD_ROOT%{_infodir}" MAKE_PFA_FILES=1 mandir="$RPM_BUILD_ROOT%{_mandir}" install
66
67 %if %{info}
68 rm -f $RPM_BUILD_ROOT/%{_infodir}/dir
69 gzip -9fn $RPM_BUILD_ROOT%{_infodir}/*
70 %endif
71
72 mkdir -p $RPM_BUILD_ROOT%{_datadir}/emacs/site-lisp/site-start.d
73 install -m 644 lilypond-mode.el lilypond-font-lock.el lilypond-indent.el lilypond.words $RPM_BUILD_ROOT/%{_datadir}/emacs/site-lisp/
74 install -m 644 lilypond-init.el $RPM_BUILD_ROOT/%{_datadir}/emacs/site-lisp/site-start.d
75
76 gzip -9fn $RPM_BUILD_ROOT%{_mandir}/man1/*
77
78 mkdir -p $RPM_BUILD_ROOT/etc/profile.d
79 cp buildscripts/out/lilypond-profile $RPM_BUILD_ROOT/etc/profile.d/lilypond.sh
80 cp buildscripts/out/lilypond-login $RPM_BUILD_ROOT/etc/profile.d/lilypond.csh
81
82 make prefix="$RPM_BUILD_ROOT%{_prefix}" web-doc-install
83 make -C Documentation/user/  prefix="$RPM_BUILD_ROOT%{_prefix}" omf-install
84
85
86
87 %post
88
89 touch /tmp/.lilypond-install
90 rm `find /var/lib/texmf -name 'feta*pk' -or -name 'feta*tfm' -or -name 'parmesan*pk' -or -name 'parmesan*tfm' -print` /tmp/.lilypond-install
91
92 %if %{info}
93 /sbin/install-info %{_infodir}/lilypond.info.gz %{_infodir}/dir 
94 %endif
95
96 chkfontpath --add=%{_datadir}/lilypond/@TOPLEVEL_VERSION@/fonts/type1/
97
98 echo 'Please logout first before using LilyPond.'
99
100 %preun
101
102 %post documentation
103 scrollkeeper-update
104
105 %preun documentation
106 scrollkeeper-update
107
108
109 %if %{info}
110 if [ $1 = 0 ]; then
111     /sbin/install-info --delete %{_infodir}/lilypond.info.gz %{_infodir}/dir 
112 fi
113 %endif
114
115 chkfontpath --remove=%{_datadir}/share/lilypond/@TOPLEVEL_VERSION@/fonts/type1/
116
117 %files
118 %defattr(-, root, root)
119 %{_datadir}/emacs/site-lisp/lilypond*
120 %{_datadir}/emacs/site-lisp/site-start.d/lilypond-*
121
122 %{_bindir}/abc2ly
123 %{_bindir}/as2text
124 %{_bindir}/convert-ly
125 %{_bindir}/etf2ly
126 %{_bindir}/lilypond
127 %{_bindir}/ly2dvi
128 %{_bindir}/midi2ly
129 %{_bindir}/lilypond-book
130 %{_bindir}/mup2ly
131 %{_bindir}/musedata2ly
132 %{_bindir}/pmx2ly
133
134 %if %{info}
135 %{_infodir}/*
136 %endif
137
138 %{_mandir}/man1/abc2ly.1.gz
139 %{_mandir}/man1/as2text.1.gz
140 %{_mandir}/man1/convert-ly.1.gz
141 %{_mandir}/man1/etf2ly.1.gz
142 %{_mandir}/man1/lilypond.1.gz
143 %{_mandir}/man1/ly2dvi.1.gz
144 %{_mandir}/man1/midi2ly.1.gz
145 %{_mandir}/man1/lilypond-book.1.gz
146 %{_mandir}/man1/musedata2ly.1.gz
147 %{_mandir}/man1/mup2ly.1.gz
148 %{_mandir}/man1/pmx2ly.1.gz
149
150 %{_datadir}/lilypond/@TOPLEVEL_VERSION@/
151 %{_datadir}/locale/*/LC_MESSAGES/lilypond.mo
152
153
154 /etc/profile.d/lilypond.*
155
156
157 %files documentation
158
159 %defattr(-, root, root)
160
161 %{docdir}/lilypond/@TOPLEVEL_VERSION@
162 %{_datadir}/omf/lilypond/@TOPLEVEL_VERSION@
163
164