Hi,

Here you can find a patch to create the /debian directory in order to
create packages.

I tested (generated packages) on a lenny amd64 host. It should work for
other debian-based distros too (surch as ubuntu).

I separated every packages by its function. Maybe there is a smarter way
to build them.

By the way the git repository tags release/2.11.53-1 and
release/2.11.53-2 are both the same and there are not presents in the
master branch.
Thus git-describe would find release/2.11.52-1 as most recent version.
As the package generator uses git tag to get the version, it would be
better to fix up git tags.

Hope this helps.

Cheers

--
Sébastien Gross
diff --git a/debian/README.Debian b/debian/README.Debian
new file mode 100644
index 0000000..f91910d
--- /dev/null
+++ b/debian/README.Debian
@@ -0,0 +1,26 @@
+Lilypond for Debian
+-------------------
+
+This package is a Debian version of Lilypond. Please note that the
+application had been compiled against the "master" head of the git
+repository (git://git.sv.gnu.org/lilypond.git) and may contains bugs
+or be instable.
+
+Packages detail:
+
+  - lilypond: the whole binary
+  - lilypond-doc: the full version of the documentation
+  - lilypond-dvips: empty
+  - lilypond-emacs: emacs extension files
+  - lilypond-fonts: fonts used by lilypond
+  - lilypond-guile: guile lilypond routines
+  - lilypond-info: documentation in info format
+  - lilypond-locale: insternationalization files
+  - lilypond-ly: lilypond (.ly) extention files
+  - lilypond-omf: documentation suitable for scrollkeeper
+  - lilypond-ps: postscript extensions
+  - lilypond-python: python lilypond routines
+  - lilypond-tex: tex extensions
+  - lilypond-vim: vim extension files
+
+ -- Sébastien Gross <[EMAIL PROTECTED]>  Tue, 22 Jul 2008 09:24:58 +0000 
diff --git a/debian/build-debian b/debian/build-debian
new file mode 100755
index 0000000..0310c0f
--- /dev/null
+++ b/debian/build-debian
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+tag=$(git describe | sed 's,^release/\(.\+\)-g.*$,\1,' )
+g_ver=$(echo ${tag} | sed 's/-[^-]\+$//')
+VERSION=$(echo ${tag} | sed 's/-/+git/2')
+
+full_version=$(sed -n 's/^[^ ]\+ (\([^)]\+\)) [^;]\+; urgency=[^ ]\+$/\1/p' < debian/changelog | head -n1)
+upstream=$(echo ${full_version} | cut -d+ -f1)
+release=$(echo ${full_version} | cut -d+ -f2 | cut -d- -f2)
+
+if test "${upstream}" == "${g_ver}"; then
+	release=$((${release} + 1))
+else
+	release=1
+fi
+
+dch -b -v "${VERSION}-${release}" -D stable -m \
+	"New debian package version (see /usr/share/doc/lilypond/changelog-full.gz)"
+git log > changelog-full
+debuild --no-tgz-check -I.git* -Iconfig.log -Iconfig.status
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..3b8590b
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,26 @@
+lilypond (2.11.52-1+git77-4) stable; urgency=low
+
+  * New debian package version (see /usr/share/doc/lilypond/changelog-
+    full.gz)
+
+ -- Sébastien Gross <[EMAIL PROTECTED]>  Thu, 24 Jul 2008 14:13:28 +0000
+
+lilypond (2.11.52-1+git69-3) stable; urgency=low
+
+  * New debian package version (see /usr/share/doc/lilypond/changelog-
+    full.gz)
+
+ -- Sébastien Gross <[EMAIL PROTECTED]>  Wed, 23 Jul 2008 14:50:25 +0000
+
+lilypond (2.11.52-1+git69-2) stable; urgency=low
+
+  * New debian package version (see /usr/share/doc/lilypond/changelog-
+    full.gz)
+
+ -- Sébastien Gross <[EMAIL PROTECTED]>  Wed, 23 Jul 2008 14:50:03 +0000
+
+lilypond (2.11.52-1+git55-1) stable; urgency=low
+
+  * New debian package version (see /usr/doc/lilypond/changelog-full.gz)
+
+ -- Sébastien Gross <[EMAIL PROTECTED]>  Tue, 22 Jul 2008 09:24:58 +0000
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..7ed6ff8
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+5
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..bc61a31
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,144 @@
+Source: lilypond
+Section: utils
+Priority: extra
+Maintainer: Sébastien Gross <[EMAIL PROTECTED]>
+Build-Depends: cdbs, debhelper (>= 5), rsync
+Standards-Version: 3.7.2
+
+Package: lilypond-vim
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Depends: vim-common
+Suggests: lilypond (= ${binary:Version}), vim
+Description: LilyPond syntax files for vim
+ This package contains vim syntax files for the LilyPond music
+ typesetting software.
+
+Package: lilypond-emacs
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Suggests: lilypond (= ${binary:Version}), emacs
+Description: LilyPond syntax files for emacs
+ This package contains emacs syntax files for the LilyPond music
+ typesetting software.
+
+Package: lilypond-info
+Architecture: all
+Section: doc
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Suggests: lilypond (= ${binary:Version}), info
+Description: LilyPond info files
+ This package contains LilyPond documentation in info format.
+
+Package: lilypond-omf
+Architecture: all
+Section: doc
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Suggests: lilypond (= ${binary:Version}), scrollkeeper
+Description: LilyPond OMF files
+ This package contains LilyPond documentation in OMF (Open Source Metadata
+ Framework) format.
+
+Package: lilypond-fonts
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Description: LilyPond font files
+ This package contains LilyPond Emmentaler / Feta / Parmesan fonts.
+
+Package: lilypond-guile
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Description: LilyPond guile files
+ This package contains LilyPond guile (scheme) extension files.
+
+Package: lilypond-python
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Description: LilyPond python files
+ This package contains LilyPond python extension files.
+
+Package: lilypond-ly
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Description: LilyPond ly files
+ This package contains LilyPond .ly extension files.
+
+Package: lilypond-tex
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Description: LilyPond tex files
+ This package contains LilyPond .tex extension files.
+
+Package: lilypond-dvips
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Description: LilyPond ps files
+ This package contains LilyPond dvi-postscript extension files.
+
+Package: lilypond-ps
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Description: LilyPond ps files
+ This package contains LilyPond postscript extension files.
+
+Package: lilypond-locale
+Architecture: all
+Section: utils
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Description: LilyPond locale files
+ This package contains LilyPond locale files for internationnalization.
+
+Package: lilypond-doc
+Architecture: all
+Section: doc
+Replaces: lilypond (<= 2.2.3-1), lilypond-data (<= 2.2.3-1)
+Suggests: gv | postscript-viewer, lilypond (= ${binary:Version}), mozilla-browser | www-browser
+Description: LilyPond Documentation in HTML, PS and DVI formats
+ This package contains the HTML, PostScript and DVI documentation for the
+ LilyPond music typesetting software.
+Tag: made-of::{data:html,data:postscript,data:tex}, role::documentation, use::typesetting, works-with::music-notation, works-with::text, works-with-format::tex
+
+Package: lilypond
+Architecture: any 
+Replaces: lilypond1.3
+Provides: lilypond1.3
+Depends: guile-1.8, guile-1.8-libs, libc6 (>= 2.7-1), libfontconfig1 (>= 2.4.0), libfreetype6 (>= 2.3.5), libgcc1 (>= 1:4.1.1-21), libglib2.0-0 (>= 2.12.0), libgmp3c2, libltdl3 (>= 1.5.2-2), libpango1.0-0 (>= 1.18.4), libstdc++6 (>= 4.2.1-4), python, zlib1g, lilypond-fonts (= ${binary:Version}), lilypond-guile (= ${binary:Version}), lilypond-python (= ${binary:Version}), lilypond-ly (= ${binary:Version}), lilypond-tex (= ${binary:Version}), lilypond-ps (= ${binary:Version}), lilypond-dvips (= ${binary:Version})
+Recommends: lilypond-info (= ${binary:Version}), lilypond-locale (= ${binary:Version})
+Suggests: lilypond-doc (= ${binary:Version}), lilypond-vim (= ${binary:Version}), lilypond-emacs (= ${binary:Version}), lilypond-omf (= ${binary:Version})
+Conflicts: guile-1.8 (= 1.8.2+1-2)
+Description: A program for typesetting sheet music
+ LilyPond is a music typesetter, an automated engraving system.  It
+ produces beautiful sheet music using a high level description file as
+ input.
+ .
+ LilyPond supports many forms of music notation constructs, including
+ chord names, drum notation, figured bass, grace notes, guitar tablature,
+ modern notation (cluster notation and rhythmic grouping), tremolos,
+ (nested) tuplets in arbitrary ratios, and more.
+ .
+ LilyPond's text-based music input language support can integrate into
+ LaTeX, HTML and Texinfo seamlessly, allowing single sheet music
+ or musicological treatises to be written from a single source.  Form and
+ content are separate, and with LilyPond's expert automated formatting,
+ users don't need typographical expertise to produce good notation.
+ .
+ LilyPond produces PDF, PostScript, SVG, or TeX printed output, as well as
+ MIDI for listening pleasures.  LilyPond is exported from the
+ RoseGarden and NoteEdit GUIs, and can import ABC, ETF and MIDI.
+ .
+ LilyPond is part of the GNU Project.
+ .
+ Home Page: http://lilypond.org/
+ Authors: Han-Wen Nienhuys <[EMAIL PROTECTED]>
+          Jan Nieuwenhuizen <[EMAIL PROTECTED]>
+Tag: implemented-in::{c++,python,scheme}, interface::commandline, role::program, scope::utility, suite::gnu, use::typesetting, works-with::music-notation, works-with::text, works-with-format::tex
+
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..467a275
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,38 @@
+This package was debianized by Sébastien Gross <[EMAIL PROTECTED]> on
+Fri, 09 May 2008 13:07:54 +0000.
+
+It was downloaded from http://lilypond.org/
+
+Upstream Author: 
+
+   * Han-Wen Nienhuys <[EMAIL PROTECTED]>,
+     `http://www.xs4all.nl/~hanwen/',     Main author.
+	
+   * Jan Nieuwenhuizen <[EMAIL PROTECTED]>,
+     `http://www.xs4all.nl/~jantien/',     Main author.
+
+Copyright: 
+
+    Copyright 1999–2008 by the authors
+
+License:
+
+    This package is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+ 
+    This package is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+ 
+    You should have received a copy of the GNU General Public License
+    along with this package; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+
+On Debian systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL'.
+
+The Debian packaging is (C) 2008, Sébastien Gross <[EMAIL PROTECTED]> and
+is licensed under the GPL, see above.
diff --git a/debian/lilypond-doc.compress b/debian/lilypond-doc.compress
new file mode 100644
index 0000000..e69de29
diff --git a/debian/lilypond-doc.dirs b/debian/lilypond-doc.dirs
new file mode 100644
index 0000000..d3ff8f2
--- /dev/null
+++ b/debian/lilypond-doc.dirs
@@ -0,0 +1 @@
+usr/share/doc/lilypond/html
diff --git a/debian/lilypond-doc.install b/debian/lilypond-doc.install
new file mode 100644
index 0000000..d3ff8f2
--- /dev/null
+++ b/debian/lilypond-doc.install
@@ -0,0 +1 @@
+usr/share/doc/lilypond/html
diff --git a/debian/lilypond-doc.links b/debian/lilypond-doc.links
new file mode 100644
index 0000000..54bbf84
--- /dev/null
+++ b/debian/lilypond-doc.links
@@ -0,0 +1 @@
+usr/share/doc/lilypond/html usr/share/doc/lilypond-doc/html
diff --git a/debian/lilypond-dvips.install b/debian/lilypond-dvips.install
new file mode 100644
index 0000000..8b86578
--- /dev/null
+++ b/debian/lilypond-dvips.install
@@ -0,0 +1 @@
+usr/share/lilypond/*/dvips
diff --git a/debian/lilypond-emacs.install b/debian/lilypond-emacs.install
new file mode 100644
index 0000000..ee4dcb5
--- /dev/null
+++ b/debian/lilypond-emacs.install
@@ -0,0 +1 @@
+usr/share/emacs
diff --git a/debian/lilypond-fonts.install b/debian/lilypond-fonts.install
new file mode 100644
index 0000000..cf2171d
--- /dev/null
+++ b/debian/lilypond-fonts.install
@@ -0,0 +1 @@
+usr/share/lilypond/*/fonts
diff --git a/debian/lilypond-guile.install b/debian/lilypond-guile.install
new file mode 100644
index 0000000..5c4bdbf
--- /dev/null
+++ b/debian/lilypond-guile.install
@@ -0,0 +1 @@
+usr/share/lilypond/*/scm
diff --git a/debian/lilypond-info.install b/debian/lilypond-info.install
new file mode 100644
index 0000000..6f7a137
--- /dev/null
+++ b/debian/lilypond-info.install
@@ -0,0 +1 @@
+usr/share/info/
diff --git a/debian/lilypond-locale.install b/debian/lilypond-locale.install
new file mode 100644
index 0000000..3635480
--- /dev/null
+++ b/debian/lilypond-locale.install
@@ -0,0 +1 @@
+usr/share/locale
diff --git a/debian/lilypond-ly.install b/debian/lilypond-ly.install
new file mode 100644
index 0000000..7db859a
--- /dev/null
+++ b/debian/lilypond-ly.install
@@ -0,0 +1 @@
+usr/share/lilypond/*/ly
diff --git a/debian/lilypond-omf.install b/debian/lilypond-omf.install
new file mode 100644
index 0000000..081491f
--- /dev/null
+++ b/debian/lilypond-omf.install
@@ -0,0 +1 @@
+usr/share/omf
diff --git a/debian/lilypond-omf.links.in b/debian/lilypond-omf.links.in
new file mode 100644
index 0000000..1c45e77
--- /dev/null
+++ b/debian/lilypond-omf.links.in
@@ -0,0 +1 @@
+usr/share/omf/lilypond/@LYCUR@ usr/share/omf/lilypond/current
diff --git a/debian/lilypond-ps.install b/debian/lilypond-ps.install
new file mode 100644
index 0000000..e57c431
--- /dev/null
+++ b/debian/lilypond-ps.install
@@ -0,0 +1 @@
+usr/share/lilypond/*/ps
diff --git a/debian/lilypond-python.install b/debian/lilypond-python.install
new file mode 100644
index 0000000..a9e5464
--- /dev/null
+++ b/debian/lilypond-python.install
@@ -0,0 +1 @@
+usr/share/lilypond/*/python/*.py
diff --git a/debian/lilypond-tex.install b/debian/lilypond-tex.install
new file mode 100644
index 0000000..a5d4125
--- /dev/null
+++ b/debian/lilypond-tex.install
@@ -0,0 +1 @@
+usr/share/lilypond/*/tex
diff --git a/debian/lilypond-vim.dirs b/debian/lilypond-vim.dirs
new file mode 100644
index 0000000..3339c43
--- /dev/null
+++ b/debian/lilypond-vim.dirs
@@ -0,0 +1,5 @@
+usr/share/vim/vimcurrent/compiler
+usr/share/vim/vimcurrent/ftdetect
+usr/share/vim/vimcurrent/ftplugin
+usr/share/vim/vimcurrent/indent
+usr/share/vim/vimcurrent/syntax
diff --git a/debian/lilypond-vim.install b/debian/lilypond-vim.install
new file mode 100644
index 0000000..0d36e64
--- /dev/null
+++ b/debian/lilypond-vim.install
@@ -0,0 +1 @@
+usr/share/lilypond/*/vim
diff --git a/debian/lilypond-vim.links b/debian/lilypond-vim.links
new file mode 100644
index 0000000..5c1a21b
--- /dev/null
+++ b/debian/lilypond-vim.links
@@ -0,0 +1,6 @@
+usr/share/lilypond/current/vim/syntax/lilypond.vim usr/share/vim/vimcurrent/syntax/lilypond.vim
+usr/share/lilypond/current/vim/syntax/lilypond-words usr/share/vim/vimcurrent/syntax/lilypond-words
+usr/share/lilypond/current/vim/syntax/lilypond-words.vim usr/share/vim/vimcurrent/syntax/lilypond-words.vim
+usr/share/lilypond/current/vim/ftdetect/lilypond.vim usr/share/vim/vimcurrent/ftdetect/lilypond.vim
+usr/share/lilypond/current/vim/ftplugin/lilypond.vim usr/share/vim/vimcurrent/ftplugin/lilypond.vim
+usr/share/lilypond/current/vim/compiler/lilypond.vim usr/share/vim/vimcurrent/compiler/lilypond.vim
diff --git a/debian/lilypond.dirs b/debian/lilypond.dirs
new file mode 100644
index 0000000..e772481
--- /dev/null
+++ b/debian/lilypond.dirs
@@ -0,0 +1 @@
+usr/bin
diff --git a/debian/lilypond.docs b/debian/lilypond.docs
new file mode 100644
index 0000000..8f8a311
--- /dev/null
+++ b/debian/lilypond.docs
@@ -0,0 +1 @@
+changelog-full
diff --git a/debian/lilypond.install b/debian/lilypond.install
new file mode 100644
index 0000000..35ed4f7
--- /dev/null
+++ b/debian/lilypond.install
@@ -0,0 +1,3 @@
+usr/bin
+usr/lib
+usr/share/man
diff --git a/debian/lilypond.links.in b/debian/lilypond.links.in
new file mode 100644
index 0000000..c9a0dde
--- /dev/null
+++ b/debian/lilypond.links.in
@@ -0,0 +1 @@
+usr/share/lilypond/@LYCUR@ usr/share/lilypond/current
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..d856485
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,48 @@
+#!/usr/bin/make -f
+
+DEB_AUTO_CLEANUP_RCS            := yes
+DEB_VERBOSE_ALL                 := yes
+
+BUILD_ROOT                      := debian/lilypond
+DEB_DH_INSTALL_SOURCEDIR	:= $(CURDIR)/debian/tmp
+
+include /usr/share/cdbs/1/rules/debhelper.mk
+#include /usr/share/cdbs/1/rules/tarball.mk
+include /usr/share/cdbs/1/class/makefile.mk
+include /usr/share/cdbs/1/class/autotools.mk
+include $(CURDIR)/VERSION
+
+LYCUR	:= $(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_LEVEL)
+
+DEB_CONFIGURE_USER_FLAGS += \
+	--prefix=/usr \
+	--infodir='$${prefix}/share/info' \
+	--mandir='$${prefix}/share/man' \
+	--enable-optimising
+
+%: %.in
+	cat $< | sed 's/@LYCUR@/$(LYCUR)/' > $@
+
+
+pre-build:: debian/lilypond.links debian/lilypond-omf.links
+	# update autotools
+	./autogen.sh --noconf
+
+clean::
+	-$(MAKE) web-clean clean
+	-$(RM) debian/lilypond.links debian/lilypond-omf.links
+	
+build/lilypond-doc::
+	-$(MAKE) web
+
+install/lilypond-doc::
+	#mkdir -p $(CURDIR)/debian/tmp/usr/share/doc/html
+	-$(MAKE) web-install DESTDIR=$(DEB_DH_INSTALL_SOURCEDIR)
+
+distclean: clean
+	-$(MAKE) distclean
+	-$(RM) changelog-full
+	# remove ignored files
+	git ls-files -o -i --exclude-standard -z | xargs -0 --no-run-if-empty $(RM)
+	# remove all 'out' and 'out-www' directories
+	find  -name 'out' -o -name 'out-www' -print0 | xargs -0 --no-run-if-empty $(RM) -r
_______________________________________________
lilypond-user mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to