Sophie

Sophie

distrib > Mandriva > 2007.0 > x86_64 > media > contrib-release-src > by-pkgid > 41fabbdfab0e01f301e0b40894ad1aac > files > 6

lilypond-2.6.5-1mdk.src.rpm

%define version 2.6.5
%define release %mkrel 1

# Taken from pango spec
%define biarches_32 %{ix86}
%define biarches_64 x86_64
%define query_modules_suffix %{nil}
%ifarch %{biarches_32}
%define query_modules_suffix -32
%endif
%ifarch %{biarches_64}
%define query_modules_suffix -64
%endif
%define query_modules pango-querymodules%{query_modules_suffix}

Summary:	A program for printing sheet music
Name:		lilypond
Version:	%{version}
Release:	%{release}
License:	GPL
Group:		Publishing
URL:		http://www.lilypond.org/
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-buildroot

Source0:	http://lilypond.org/download/v2.6/%{name}-%{version}.tar.bz2
Source1:	%{name}.bash-completion.bz2
# (Abel) use utf8 as input encoding by default for tex backend
Patch2:		lilypond-2.6.1-tex-use-utf8.patch.bz2
# (Abel) use locale-independency date as document timestamp
Patch3:		lilypond-2.6.3-locale-indep-date.patch.bz2
# (Abel) use ImageMagick to replace netpbm -- pnmtopng segfault
# and I'm too lazy to look into the problem
Patch4:		lilypond-2.6.4-use-imagemagick.patch.bz2

# (Abel) bib2html or bibtex2html -- pick either one
BuildRequires:  bib2html
BuildRequires:	bison > 1.75
BuildRequires:	ec-fonts-mftraced >= 1.0.5
BuildRequires:	flex >= 2.5.4a-22mdk
BuildRequires:	fontforge >= 1.0-0.20050624.1mdk
BuildRequires:	gettext
BuildRequires:	ghostscript >= 8.14
BuildRequires:	groff-for-man
BuildRequires:	gtk2-devel >= 2.4.0
BuildRequires:	guile-devel >= 1.6.5
BuildRequires:	mftrace >= 1.1.1
BuildRequires:	python-devel
BuildRequires:	tetex-devel
BuildRequires:	texinfo >= 4.7
BuildRequires:	info-install
BuildRequires:	zip
BuildRequires:	ImageMagick
Requires:	ec-fonts-mftraced >= 1.0.5
Requires(post):		chkfontpath
Requires(preun):	chkfontpath
Requires(post):		info-install
Requires(preun):	info-install
Requires(post):		findutils
Requires(post):		tetex
Requires(postun):	tetex
 

%description
LilyPond is a music typesetter.  It produces beautiful sheet music using a
high level description file as input.  LilyPond is part of the GNU project.
 
LilyPond is split into two packages.  The package "lilypond" provides the
core package, containing the utilities for converting the music source
(.ly) files into printable output.  The package "lilypond-doc" 
provides the full documentation, example .ly files for various features and 
the Mutopia project files (musical equivalent of the Gutenberg project - see
http://www.mutopiaproject.org for details).
 
If you are new to lilypond, you will almost certainly want to install the
"lilypond-doc" package and take a look at tutorials under
%{_docdir}/lilypond.


%package	doc
Summary:	LilyPond documentation, examples and Mutopia files
Group:		Publishing
Obsoletes:	%{name}-manual
Provides:	%{name}-manual
Requires(post,postun):	scrollkeeper

%description	doc
The documentation of LilyPond, both in HTML and PostScript, along with
example input files and the files from the Mutopia project. If you
want to try the examples or score files from Mutopia project, please
also install LilyPond main package.


%prep
%setup -q
%patch2 -p1 -b .utf8
%patch3 -p1 -b .date
%patch4 -p1 -b .netpbm

bzcat %{SOURCE1} > %{name}.bash-completion

%build
#
# build environment untrustworthy
#
%{_bindir}/%query_modules > pango.modules
echo "[Pango]" > pangorc
echo "ModuleFiles = `pwd`/pango.modules" >> pangorc
export PANGO_RC_FILE=`pwd`/pangorc

#
# build timestamp in HTML can be affected by locale
# (not necessary after applying date patch)
#
#export LC_TIME=C

%configure2_5x --enable-gui
%make all
%make web

%install
rm -rf $RPM_BUILD_ROOT
%makeinstall_std

#
# web doc
#
make out=www web-install DESTDIR=$RPM_BUILD_ROOT

#
# move emacs file to our location
#
install -D -m 644 elisp/lilypond-init.el $RPM_BUILD_ROOT%{_sysconfdir}/emacs/site-start.d/lilypond-init.el

#
# move vim stuff to our location
#
mv $RPM_BUILD_ROOT%{_datadir}/lilypond/%{version}/vim $RPM_BUILD_ROOT%{_datadir}/vim

#
# some more house cleaning
#
find $RPM_BUILD_ROOT -path '*%{_datadir}/lilypond/%{version}/fonts' -prune -type f -o -name 'fonts.cache-1' -print0 | xargs -r -0 %{__rm}
find $RPM_BUILD_ROOT%{_docdir} -name '*.png' -empty -print0 | xargs -r -0 %{__rm}
find $RPM_BUILD_ROOT%{_datadir}/lilypond/%{version} -xtype l -print0 | xargs -r -0 %{__rm}

#
# Create symlinks to lilypond folder under TeX directory, so that TeX can
# use lilypond files natively, courtesy of Michael Brown's great hacks
# Necessary for tex backend to work, since startup profile is gone -- Abel
#
mkdir -p $RPM_BUILD_ROOT%{_datadir}/texmf/dvips \
         $RPM_BUILD_ROOT%{_datadir}/texmf/tex \
         $RPM_BUILD_ROOT%{_datadir}/texmf/fonts/source \
         $RPM_BUILD_ROOT%{_datadir}/texmf/fonts/tfm
pushd $RPM_BUILD_ROOT%{_datadir}/texmf > /dev/null
ln -s ../../lilypond/%{version}/ps dvips/lilypond
ln -s ../../lilypond/%{version}/tex tex/lilypond
ln -s ../../../lilypond/%{version}/fonts/source fonts/source/lilypond
ln -s ../../../lilypond/%{version}/fonts/tfm fonts/tfm/lilypond
popd > /dev/null

#
# bash-completion file
#
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d
bzip2 -dc %{SOURCE1} > $RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d/%{name}

%{find_lang} %{name}

%post
%_install_info %{name}/lilypond.info
%_install_info %{name}/lilypond-internals.info
%_install_info %{name}/music-glossary.info

find /var/lib/texmf \( -name 'feta*.pk' -or -name 'feta*.tfm' -or -name 'parmesan*.pk' -or -name 'parmesan*.tfm' \) -print0 | xargs -r -0 %{__rm} -f

%{_bindir}/mktexlsr > /dev/null

mkfontdir %{_datadir}/lilypond/%{version}/fonts/type1
chkfontpath -l | grep -q %{_datadir}/lilypond/%{version}/fonts/type1 || chkfontpath --add=%{_datadir}/lilypond/%{version}/fonts/type1

%preun
%_remove_install_info %{name}/lilypond.info
%_remove_install_info %{name}/lilypond-internals.info
%_remove_install_info %{name}/music-glossary.info

%{__rm} -f %{_datadir}/lilypond/%{version}/fonts/type1/fonts.dir
if chkfontpath -l | grep -q %{_datadir}/lilypond/%{version}/fonts/type1; then chkfontpath --remove=%{_datadir}/lilypond/%{version}/fonts/type1; fi

%postun
%{_bindir}/mktexlsr > /dev/null

%post doc
if [ -x %{_bindir}/scrollkeeper-update ]; then %{_bindir}/scrollkeeper-update -q; fi

%postun doc
if [ -x %{_bindir}/scrollkeeper-update ]; then %{_bindir}/scrollkeeper-update -q; fi

%clean
rm -rf $RPM_BUILD_ROOT

%files -f %{name}.lang
%defattr(-, root, root)
%doc COPYING README.txt INSTALL.txt DEDICATION NEWS.txt AUTHORS.txt THANKS

%config(noreplace) %{_sysconfdir}/bash_completion.d/%{name}
%config(noreplace) %{_sysconfdir}/emacs/site-start.d/*

%{_bindir}/*
%{_datadir}/emacs/site-lisp/lilypond*
%{_datadir}/%{name}
%{_datadir}/texmf/dvips/lilypond
%{_datadir}/texmf/fonts/source/lilypond
%{_datadir}/texmf/fonts/tfm/lilypond
%{_datadir}/texmf/tex/lilypond
%{_datadir}/vim/*/*
%{_libdir}/%{name}
%{_mandir}/man?/*
%{_infodir}/*

%files doc
%defattr(-, root, root)
%doc %{_docdir}/lilypond
%{_datadir}/omf/%{name}

%changelog
* Fri Feb 24 2006 Rafael Garcia-Suarez <rgarciasuarez@mandriva.com> 2.6.5-1mdk
- New release 2.6.5
- Drop patch 0

* Sat Oct 15 2005 Abel Cheung <deaddog@mandriva.org> 2.6.4-1mdk
- New release 2.6.4
- Drop patch1 (upstream)
- Patch4: netpbm segfaults, so use ImageMagick to replace it

* Tue Aug 16 2005 Abel Cheung <deaddog@mandriva.org> 2.6.3-3mdk
- Fix midi2ly by moving python module to expected location
- Fix bash completion file

* Mon Aug 08 2005 Abel Cheung <deaddog@mandriva.org> 2.6.3-2mdk
- Fix URL
- Some sensible rpmlint fixes

* Sat Aug 06 2005 Abel Cheung <deaddog@mandriva.org> 2.6.3-1mdk
- New release
- Patch3: use locale-independency date as document timestamp, so no need
  to set LC_TIME manually
- Fix directory name during install time (don't hardcode as 2.6.1)

* Tue Jul 26 2005 Abel Cheung <deaddog@mandriva.org> 2.6.1-2mdk
- Patch1: don't mark empty string as translatable, otherwise lilypond-book
  shows .po file header
- Patch2: use utf8 as default encoding for generated tex file
- set LC_TIME during build, otherwise HTML doc contains localized timestamp
- Reintroduce Michael Brown's hacks (aka let TeX read lilypond file natively),
  at least tex backend produces something now, though some problem still
  remains (first page in dvi file contains nothing)

* Sat Jul 23 2005 Abel Cheung <deaddog@mandriva.org> 2.6.1-1mdk
- New release
- Startup profile no more needed
- Drop .scm search path patch (P1), no more necessary
- Build machine broken, avoiding system pango config
- Respect original doc file location (otherwise must modify omf file too)
- Forgot FHS temporarily, involves lots of work
- Reduce destdir patch (P0) to just bare minimum, can't maintain patch
  this way

* Sun Feb  6 2005 Abel Cheung <deaddog@mandrake.org> 2.5.11-1mdk
- 2.5.11
- Merge the work done seperately by:
  o Noam Meltzer <tsnoam@zahav.net.il>
  o Torbjorn Turpeinen <tobbe@nyvalls.se>
  o Heikki Johannes Junes <hjunes@cc.hut.fi>
- Too many changes to list, they mainly include:
  o Remove menu entry
  o Always install info files
  o So called lib package is just python binding, merge into main pkg
  o Clean up some over-usage and under-usage of macros
  o P0: DESTDIR support, replaces patch the just sets vim file path
  o P1: Fix search path for .scm files, build failed

* Tue Nov 09 2004 Noam Meltzer <tsnoam@zahav.net.il> 2.4.2-1_tsn
- change release to 1_tsn and ver. to 2.4.2
- remove the full path reference to mkfontdir
- removing ending slashes from path elements of the font dir
- make some sanity checks before adding/removing fontpath elements

* Sun Nov 07 2004 Noam Meltzer <tsnoam@zahav.net.il> 2.4.1-2_tsn
- change release to 2_tsn
- when doing install-info, point it to the correct path.
- add a patch that willl replace the vimdir inside config.make.in to be $(datadir)/vim
- add %{_datadir}/vim to the files section

* Sat Nov 06 2004 Noam Meltzer <tsnoam@zahav.net.il> 2.4.1-1_tsn
- change release to 1_tsn and start to add changelog entries :-)
- change the source file to be a tar.gz file (instead of tar.bz2) as downloaded
- change the buildrequires from libMagick5.5.4-devel to just libmMagick5-devel
- add buildrequires: tetex-devel, python-devel
- add a requires: ec-fonts-mftraced
- use the bzip2, mkdir, rm, cp, strip, install & install-info macros instead of calling the commands directly
- fix a bug with the compression of the info files (add another element to the path)
- use only the %files -f %{name}.lang method to add locales, don't add it twice
- refer to /etc as sysconfdir, and not the ugly earlier way used before
- add more parameters to the configure scripts, according to the %configure macro
- build the gnome gui also
- make the link to the Source0 file correct
- use %make instead of make
- when doing 'make web-install', add all the prefixes needed to install it in rpmbuildroot
- add a packager line

* Fri Jul 16 2004 Michael Scherer <misc@mandrake.org> 2.2.0-2mdk 
- rebuild for new gcc

* Fri Apr 2 2004 Austin Acton <austin@mnadrke.org> 2.2.0-1mdk
- 2.2.0

* Mon Dec 29 2003 Guillaume Rousse <guillomovitch@mandrake.org> 2.0.1-1mdk
- new version
- added bash-completion
- removed some redundant requires/buildrequires
- no library package
- renamed documentation subapckage to manual subpackage for coherency
- no menu entry just for info and html pages
- let spechelper do its job
- spec cleanup

* Thu Sep 01 2003 Heikki Johannes Junes <hjunes@cc.hut.fi> 1.8.4-4mdk
- add target lilypond.words.

* Sun Aug 25 2003 Torbjorn Turpeinen <tobbe@nyvalls.se> 1.8.1-3mdk
- Fixed doc-path in menu.

* Sun Aug 24 2003 Torbjorn Turpeinen <tobbe@nyvalls.se> 1.8.1-2mdk
- Added Heikki Johannes Junes fix for confilcting PHP variable
  out=/dev/vc/ by adding unset out before compiling
- Compiled with recent guile = 1.6.4 and mftrace = 1.0.19
- Changed icon to lilypond.png
- Added menu and icons again

* Sun Aug 24 2003 Austin Acton <aacton@yorku.ca> 1.8.1-1mdk
- 1.8.1
- buildrequires XFree86
- build icons with ImageMagick

* Thu Aug 07 2003 Heikki Johannes Junes <hjunes@cc.hut.fi> 1.8.0-1mdk
- removed menu and icons, sync with redhat-spec

* Thu Jun 12 2003 Heikki Johannes Junes <hjunes@cc.hut.fi> 1.7.23-1mdk
- refreshed dependencies and file list.

* Thu Mar 06 2003 Buchan Milne <bgmilne@linux-mandrake.com> 1.7.14-1mdk
- 1.7.14

* Fri Feb 14 2003 Buchan Milne <bgmilne@linux-mandrake.com> 1.7.12-2mdk
- thac->contrib
- gcc fix (Thanks narfi) - p1
- Many fixes to make rpmlint happy - buildrequires,find-lang etc
- No bugs accepted, only patches ;-)

* Sat Feb 01 2003 Torbjorn Turpeinen <tobbe@nyvalls.se> 1.7.12-1mdk
- Built for Mandrake 9.1

* Fri Dec 01 2002 Heikki Johannes Junes <hjunes@cc.hut.fi> 1.7.9-1mdk
- set menu-items to lilypond-info and lilypond-documentation.

* Fri Nov 30 2002 Heikki Johannes Junes <hjunes@cc.hut.fi> 1.7.8-4mdk
- add pre/post-dependencies and menus with icon from source.

* Fri Oct 28 2002 Heikki Johannes Junes <hjunes@cc.hut.fi> 1.7.4-1mdk
- info, commented menu

* Fri Aug 30 2002 Heikki Johannes Junes <hjunes@cc.hut.fi> 1.6.0-1mdk
- Adapted from lilypond.redhat.skel and skeleton found in Mandrake's RPM-docs.
- TODO: info (?) and dependencies.

* Fri Jun 01 2001 Lenny Cartier <lenny@mandrakesoft.com> 1.4.2-1mdk
- updated by Michael Brown <mbrown@linux-mandrake.com> :
	- Upgraded to 1.4.2
	- Changed URL
	- Removed /etc/profile.d scripts: all TeX bits are now located properly
	- Rearranged documentation
	- Tidied spec file
	- Updated README.first

* Mon Feb 26 2001 Lenny Cartier <lenny@mandrakesoft.com> 1.3.129-1mdk
- added in contribs by Michael Brown <mbrown@fensystems.co.uk> :
	- Removed info files completely (couldn't get info reader to read them)
	- TODO: Get this to work at some point (in the meantime, use documentation in lilypond-extras)

* Sat Feb 17 2001 Michael Brown <mbrown@fensystems.co.uk>
- Moved TeX font folders into the system TeX tree (this ensures that the /var/lib/texmf font cache is used instead of current folder)
- Added mktexlsr to post-install and post-uninstall scripts
- Patched scripts in /etc/profile.d to reflect changes to font locations
- Added QuickStart guide and Points to note sections to README.first (well worth reading)
- Fixed install-info and uninstall-info sections to use Mandrake's RPM macros :-)

* Tue Feb 13 2001 Michael Brown <mbrown@fensystems.co.uk>
- First Mandrake package
- spec file heavily adapted from PowerPC contribs.
- Note HTML documentation may contain duff links and may be incomplete.  Lots of warnings appear when building HTML docs.
- PostScript documentation is duplicated (how do you get an rpm package to contain a symlink?)
- Created README.first file