From 4f93c376052233b694cd1738278741b4fb77f983 Mon Sep 17 00:00:00 2001 From: fred Date: Wed, 27 Mar 2002 00:57:49 +0000 Subject: [PATCH] lilypond-1.3.138 --- Documentation/topdocs/INSTALL.texi | 23 +++--- Documentation/user/GNUmakefile | 3 +- aclocal.m4 | 45 ++++++------ input/tutorial/os-music.ly | 32 +++++++++ input/tutorial/os-score.ly | 75 ++++++++++++++++++++ lily/lily-version.cc | 7 +- lily/main.cc | 28 ++++++-- make/lilypond-vars.make | 8 ++- make/stepmake.make | 4 ++ stepmake/aclocal.m4 | 43 ++++++----- stepmake/make/stepmake.make | 4 ++ stepmake/stepmake/documentation-targets.make | 2 +- 12 files changed, 203 insertions(+), 71 deletions(-) create mode 100644 input/tutorial/os-music.ly create mode 100644 input/tutorial/os-score.ly diff --git a/Documentation/topdocs/INSTALL.texi b/Documentation/topdocs/INSTALL.texi index 19e1623757..9d7e01ad9d 100644 --- a/Documentation/topdocs/INSTALL.texi +++ b/Documentation/topdocs/INSTALL.texi @@ -235,9 +235,11 @@ Options to configure include: unreliable on some compiler/platform combinations (eg, DEC Alpha and PPC) @item @code{--enable-profiling} Compile with support for profiling. -@item @code{--enable-config} - Output to a different configuration file. Needed for multi-platform - builds +@item @code{--enable-config=CONF} + Output to different configuration files. Enables different binary + builds alongside eachother, eg, multi-configuration (debugging, + profiling), or multi-platform builds. Use `make conf=CONF' to + build for a specific configuration. @end table All options are documented in the @file{configure} help @@ -257,10 +259,11 @@ contain all files generated during compilation). @section Configuring for multiple platforms -If you want to compile LilyPond with different configuration settings, -then, you can use the @code{--enable-config} option. Example: suppose I -want to build with and without profiling. Then I'd use the -following for the normal build, +If you want to build multiple versions of LilyPond with different +configuration settings, you can use the @code{--enable-config=CONF} +option. You should use @samp{make conf=CONF} to generate the output in +@file{out-CONF}. Example: suppose I want to build with and without +profiling. Then I'd use the following for the normal build, @example @@ -275,9 +278,9 @@ and for the profiling version, I specify a different configuration. @example ./configure --prefix=~ --enable-profiling --enable-config=prof --enable-optimise --disable-checking - make config=prof - make config=prof install - + make conf=prof + make conf=prof install + @end example diff --git a/Documentation/user/GNUmakefile b/Documentation/user/GNUmakefile index b6c5d83f79..db0ed79d93 100644 --- a/Documentation/user/GNUmakefile +++ b/Documentation/user/GNUmakefile @@ -107,11 +107,10 @@ local-clean: backdoc-WWW: $(outdir)/lilypond-internals/lilypond-internals.html $(SHELL) $(buildscript-dir)/install-info-html.sh --dir=$(outdir) lilypond lilypond-internals -#ugh. lily/OUT/lilypond hardcoded. # when cross-compiling, we don't have lilypond ifneq ($(CROSS),yes) $(outdir)/lilypond-internals.nexi $(outdir)/lilypond-internals.texi: - cd $(outdir) && ../$(depth)/$(builddir)/lily/out/lilypond ../$(src-depth)/ly/generate-documentation + cd $(outdir) && ../$(depth)/$(builddir)/lily/$(outconfbase)/lilypond ../$(src-depth)/ly/generate-documentation -ln $(outdir)/lilypond-internals.texi $(outdir)/lilypond-internals.nexi else $(outdir)/lilypond-internals.nexi $(outdir)/lilypond-internals.texi: diff --git a/aclocal.m4 b/aclocal.m4 index a7f2f44300..b5684b86ad 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -1,5 +1,3 @@ -dnl WARNING WARNING WARNING WARNING -dnl do not edit! this is aclocal.m4, generated from stepmake/aclocal.m4 dnl aclocal.m4 -*-shell-script-*- dnl StepMake subroutines for configure.in @@ -27,29 +25,24 @@ AC_DEFUN(AC_STEPMAKE_COMPILE, [ debug_b=yes AC_ARG_ENABLE(checking, - [ enable-checking set runtime checks (assert calls). Default: on], + [ --enable-checking set runtime checks (assert calls). Default: on], [checking_b=$enableval] ) - # actually, the default is: tja='-O' to get inlining... - # off='' --jcn + AC_ARG_ENABLE(debugging, + [ --enable-debugging compile with debugging info. Default: on], + [debug_b=$enableval]) - #actually, that sucks. - # tja looks like a typo. Default is optimisation off. --hwn - AC_ARG_ENABLE(optimise, - [ enable-optimise use maximal speed optimisations. Default: off], + [ --enable-optimise use maximal speed optimisations. Default: off], [optimise_b=$enableval]) AC_ARG_ENABLE(profiling, - [ enable-profiling compile with gprof support. Default: off], + [ --enable-profiling compile with gprof support. Default: off], [profile_b=$enableval]) - AC_ARG_ENABLE(debugging, - [ enable-debugging set debug info. Default: on], - [debug_b=$enableval]) - AC_ARG_ENABLE(mingw-prefix, - [ enable-mingw-prefix=DIR set the mingw32 directory (standalone windows32 exes)], + [ --enable-mingw-prefix=DIR + set the mingw32 directory (standalone windows32 exes)], [MINGWPREFIX=$enableval], [MINGWPREFIX=no]) @@ -335,7 +328,8 @@ AC_DEFUN(AC_STEPMAKE_INIT, [ CONFIGSUFFIX= AC_ARG_ENABLE(config, - [ enable-config=FILE put configure settings in config-FILE.make], + [ --enable-config=CONF put settings in config-CONF.make and config-CONF.h; + do \`make conf=CONF' to get output in ./out-CONF], [CONFIGSUFFIX=-$enableval]) CONFIGFILE=config$CONFIGSUFFIX @@ -436,8 +430,8 @@ dnl fi AC_DEFUN(AC_STEPMAKE_KPATHSEA, [ kpathsea_b=yes - AC_ARG_ENABLE(kpathsea, - [ enable-kpathsea use kpathsea lib. Default: on], + AC_ARG_WITH(kpathsea, + [ --with-kpathsea use kpathsea lib. Default: on], [kpathsea_b=$enableval]) if test $kpathsea_b = yes; then @@ -518,12 +512,13 @@ AC_DEFUN(AC_STEPMAKE_LOCALE, [ # with/enable ?? AC_ARG_WITH(localedir, - [ with-localedir=LOCALE use LOCALE as locale dir. Default: PREFIX/share/locale ], + [ --with-localedir=LOCALE use LOCALE as locale dir. Default: + PREFIX/share/locale ], localedir=$with_localedir, localedir='${prefix}/share/locale') AC_ARG_WITH(lang, - [ with-lang=LANG use LANG as language to emit messages], + [ --with-lang=LANG use LANG as language to emit messages], language=$with_lang, language=English) @@ -588,17 +583,18 @@ AC_DEFUN(AC_STEPMAKE_MSGFMT, [ #why has this been dropped? AC_DEFUN(XXAC_STEPMAKE_TEXMF_DIRS, [ AC_ARG_ENABLE(tex-prefix, - [ enable-tex-prefix=DIR set the tex-directory to find TeX subdirectories. Default: PREFIX], + [ --enable-tex-prefix=DIR set the tex-directory to find TeX + subdirectories. Default: PREFIX], [TEXPREFIX=$enableval], [TEXPREFIX=auto] ) AC_ARG_ENABLE(tex-dir, - [ enable-tex-dir=DIR set the directory to put $PACKAGE_NAME TeX files in. ], + [ --enable-tex-dir=DIR set the directory to put $PACKAGE_NAME TeX files in. ], [TEXDIR=$enableval], [TEXDIR=auto] ) AC_ARG_ENABLE(mf-dir, - [ enable-mf-dir=DIR set the directory to put $PACKAGE_NAME MetaFont files in. ], + [ --enable-mf-dir=DIR set the directory to put $PACKAGE_NAME MetaFont files in. ], [MFDIR=$enableval], [MFDIR=auto]) @@ -622,7 +618,8 @@ AC_DEFUN(XXAC_STEPMAKE_TEXMF_DIRS, [ AC_DEFUN(AC_STEPMAKE_TEXMF_DIRS, [ AC_ARG_ENABLE(tfm-path, - [ enable-tfm-path=PATH set path of tex directories where tfm files live, esp.: cmr10.tfm. Default: use kpsewhich], + [ --enable-tfm-path=PATH set path of tex directories where tfm files live, + esp.: cmr10.tfm. Default: use kpsewhich], [tfm_path=$enableval], [tfm_path=auto] ) diff --git a/input/tutorial/os-music.ly b/input/tutorial/os-music.ly new file mode 100644 index 0000000000..96136d0f3b --- /dev/null +++ b/input/tutorial/os-music.ly @@ -0,0 +1,32 @@ +\header { + title = "Zo, goed lieverd?"; + subtitle = "How's, this babe?"; + composer = "JCN"; + opus = "1"; + piece = "Laid back"; +} +global = { + \time 2/4; + \skip 2*4; \bar "|."; +} +Key = \notes \key as \major; +flautoI = \notes\relative c'' { + f8 g f g f g f g + bes as bes as bes as bes as +} +flautoII = \notes\relative c'' { + as8 bes as bes R1 d4 ~ d +} +tromboI = \notes\relative c'' { + c4. c8 c8 c4. es4 R1*1/2 es4 +} +tromboII = \notes\relative c'' { + as4. as8 as8 as4. R1*1/2 as4 es' +} +timpani = \notes\relative c, { + \times 2/3 { f4 f f } + \times 4/5 { as8 as as as as } +} +corno = \notes\relative c' { + bes4 d f, bes d f, bes d +} diff --git a/input/tutorial/os-score.ly b/input/tutorial/os-score.ly new file mode 100644 index 0000000000..adb670fab6 --- /dev/null +++ b/input/tutorial/os-score.ly @@ -0,0 +1,75 @@ + +\include "os-music.ly"; +\include "paper13.ly"; + +#(set! point-and-click #t) +#(define text-flat '((font-relative-size . -2) (music "accidentals--1"))) + +\score { + < + \global + \context StaffGroup = woodwind < + \context Staff = flauti < + \property Staff.midiInstrument = #"flute" + \property Staff.instrument = "2 Flauti" + \property Staff.instr = "Fl." + \Key + \context Voice=one { \voiceOne \flautoI } + \context Voice=two { \voiceTwo \flautoII } + > + > + \context StaffGroup = timpani < + \context Staff = timpani < + \property Staff.midiInstrument = #"timpani" + \property Staff.instrument = #'(lines "Timpani" "(C-G)") + \property Staff.instr = #"Timp." + \clef bass; + \Key + \timpani + > + > + \context StaffGroup = brass < + \context Staff = trombe < + \property Staff.midiInstrument = #"trumpet" + \property Staff.instrument = #`(lines "2 Trombe" "(C)") + \property Staff.instr = #`(lines "Tbe." "(C)") + \Key + \context Voice=one \partcombine Voice + \context Thread=one \tromboI + \context Thread=two \tromboII + > + \context Staff = corni < + \property Staff.midiInstrument = #"french horn" + \property Staff.instrument = #`(lines "Corno" (rows "(E" ,text-flat ")")) + \property Staff.instr = #`(lines "Cor." (rows "(E" ,text-flat ")")) + \property Staff.transposing = #3 + \notes \key bes \major; + \context Voice=one \corno + > + > + > + \paper { + indent = 15 * \staffspace; + linewidth = 60 * \staffspace; + textheight = 90 * \staffspace; + \translator{ + \ThreadContext + \consists "Rest_engraver"; + } + \translator{ + \VoiceContext + \remove "Rest_engraver"; + } + \translator{ + \HaraKiriStaffContext + } + \translator { + \OrchestralScoreContext + BarNumber \override #'padding = #3 + } + } + \midi { + \tempo 4 = 75; + } +} + diff --git a/lily/lily-version.cc b/lily/lily-version.cc index 081504324a..40220a5532 100644 --- a/lily/lily-version.cc +++ b/lily/lily-version.cc @@ -10,12 +10,13 @@ #include "version.hh" #include "lily-version.hh" -#define VERSION MAJOR_VERSION "." MINOR_VERSION "." PATCH_LEVEL "." MY_PATCH_LEVEL - String version_str () { - String str = VERSION; + String str (MAJOR_VERSION "." MINOR_VERSION "." PATCH_LEVEL); + String mpl ("." MY_PATCH_LEVEL); + if (mpl != ".") + str += mpl; return str; } diff --git a/lily/main.cc b/lily/main.cc index 7f122864d8..acaafadc00 100644 --- a/lily/main.cc +++ b/lily/main.cc @@ -387,6 +387,17 @@ main_prog (int, char**) exit (exit_status_global); } +static int +sane_putenv (char const* key, char const* value) +{ + /* + putenv is POSIX, setenv is BSD 4.3 + Urg, but putenv blindly overwrites environment settings. + */ + if (!getenv (key)) + return putenv ((char*)((String (key) + "=" + value).ch_C ())); + return -1; +} int main (int argc, char **argv) @@ -394,13 +405,18 @@ main (int argc, char **argv) debug_init (); // should be first (can see that; but Why?) setup_paths (); - /* - prepare guile for heavy mem usage. + /* Prepare GUILE for heavy memory usage. If you have plenty memory, + this may speed up GUILE a bit. If you're short on memory, these + settings + + export GUILE_INIT_SEGMENT_SIZE_1=36000 + export GUILE_MAX_SEGMENT_SIZE=576000 - putenv is POSIX, setenv is BSD 4.3 - */ - putenv ("GUILE_INIT_SEGMENT_SIZE_1=4194304"); - putenv ("GUILE_MAX_SEGMENT_SIZE=8388608"); + may considerably decrease memory footprint (~*0.85), with a small + execution time penalty (~*1.10). */ + + sane_putenv ("GUILE_INIT_SEGMENT_SIZE_1", "4194304"); + sane_putenv ("GUILE_MAX_SEGMENT_SIZE", "8388608"); ly_init_kpath (argv[0]); diff --git a/make/lilypond-vars.make b/make/lilypond-vars.make index c0d23272d4..5f94a465bd 100644 --- a/make/lilypond-vars.make +++ b/make/lilypond-vars.make @@ -18,9 +18,10 @@ ifneq ($(the-script-dir),) ABC2LY = $(script-dir)/abc2ly.py CONVERT_LY = $(script-dir)/convert-ly.py -LY2DVI = $(script-dir)/ly2dvi.py +LILYPOND = $(depth)/$(builddir)/lily/$(outconfbase)/lilypond LILYPOND_BOOK = $(script-dir)/lilypond-book.py -LILYPOND_BOOK_INCLUDES = -I $(pwd) -I $(input-dir)/tricks/ -I $(input-dir)/regression/ -I $(input-dir)/test/ +LILYPOND_BOOK_INCLUDES = -I $(pwd) -I $(input-dir)/tricks/ -I $(input-dir)/regression/ -I $(input-dir)/test/ -I $(input-dir)/tutorial/ +LY2DVI = $(script-dir)/ly2dvi.py PS_TO_GIFS = $(buildscript-dir)/ps-to-gifs.sh PS_TO_PNGS = $(buildscript-dir)/ps-to-pngs.sh @@ -29,10 +30,11 @@ else ### $(message running from installed stepmake) ABC2LY = $(shell $(SHELL) -c 'type -p abc2ly') -LY2DVI = $(shell $(SHELL) -c 'type -p ly2dvi') CONVERT_LY = $(shell $(SHELL) -c 'type -p convert-ly') +LILYPOND = $(shell $(SHELL) -c 'type -p lilypond') LILYPOND_BOOK = $(shell $(SHELL) -c 'type -p lilypond-book') LILYPOND_BOOK_INCLUDES = -I. -I.. -I$(outdir) +LY2DVI = $(shell $(SHELL) -c 'type -p ly2dvi') PS_TO_GIFS = $(shell $(SHELL) -c 'type -p ps-to-gifs') PS_TO_PNGS = $(shell $(SHELL) -c 'type -p ps-to-pngs') diff --git a/make/stepmake.make b/make/stepmake.make index ae5f5cb46a..6d25f54696 100644 --- a/make/stepmake.make +++ b/make/stepmake.make @@ -50,6 +50,10 @@ endif outdir=$(outroot)/$(outbase) config_h=$(depth)/$(builddir)/config$(CONFIGSUFFIX).h +# The outdir that was configured for: best guess to find binaries +outconfbase=out$(CONFIGSUFFIX) +outconfdir=$(outroot)/$(outconfbase) + # user package stepdir = $(stepmake)/stepmake # for stepmake package diff --git a/stepmake/aclocal.m4 b/stepmake/aclocal.m4 index edcddbe763..b5684b86ad 100644 --- a/stepmake/aclocal.m4 +++ b/stepmake/aclocal.m4 @@ -25,29 +25,24 @@ AC_DEFUN(AC_STEPMAKE_COMPILE, [ debug_b=yes AC_ARG_ENABLE(checking, - [ enable-checking set runtime checks (assert calls). Default: on], + [ --enable-checking set runtime checks (assert calls). Default: on], [checking_b=$enableval] ) - # actually, the default is: tja='-O' to get inlining... - # off='' --jcn + AC_ARG_ENABLE(debugging, + [ --enable-debugging compile with debugging info. Default: on], + [debug_b=$enableval]) - #actually, that sucks. - # tja looks like a typo. Default is optimisation off. --hwn - AC_ARG_ENABLE(optimise, - [ enable-optimise use maximal speed optimisations. Default: off], + [ --enable-optimise use maximal speed optimisations. Default: off], [optimise_b=$enableval]) AC_ARG_ENABLE(profiling, - [ enable-profiling compile with gprof support. Default: off], + [ --enable-profiling compile with gprof support. Default: off], [profile_b=$enableval]) - AC_ARG_ENABLE(debugging, - [ enable-debugging set debug info. Default: on], - [debug_b=$enableval]) - AC_ARG_ENABLE(mingw-prefix, - [ enable-mingw-prefix=DIR set the mingw32 directory (standalone windows32 exes)], + [ --enable-mingw-prefix=DIR + set the mingw32 directory (standalone windows32 exes)], [MINGWPREFIX=$enableval], [MINGWPREFIX=no]) @@ -333,7 +328,8 @@ AC_DEFUN(AC_STEPMAKE_INIT, [ CONFIGSUFFIX= AC_ARG_ENABLE(config, - [ enable-config=FILE put configure settings in config-FILE.make], + [ --enable-config=CONF put settings in config-CONF.make and config-CONF.h; + do \`make conf=CONF' to get output in ./out-CONF], [CONFIGSUFFIX=-$enableval]) CONFIGFILE=config$CONFIGSUFFIX @@ -434,8 +430,8 @@ dnl fi AC_DEFUN(AC_STEPMAKE_KPATHSEA, [ kpathsea_b=yes - AC_ARG_ENABLE(kpathsea, - [ enable-kpathsea use kpathsea lib. Default: on], + AC_ARG_WITH(kpathsea, + [ --with-kpathsea use kpathsea lib. Default: on], [kpathsea_b=$enableval]) if test $kpathsea_b = yes; then @@ -516,12 +512,13 @@ AC_DEFUN(AC_STEPMAKE_LOCALE, [ # with/enable ?? AC_ARG_WITH(localedir, - [ with-localedir=LOCALE use LOCALE as locale dir. Default: PREFIX/share/locale ], + [ --with-localedir=LOCALE use LOCALE as locale dir. Default: + PREFIX/share/locale ], localedir=$with_localedir, localedir='${prefix}/share/locale') AC_ARG_WITH(lang, - [ with-lang=LANG use LANG as language to emit messages], + [ --with-lang=LANG use LANG as language to emit messages], language=$with_lang, language=English) @@ -586,17 +583,18 @@ AC_DEFUN(AC_STEPMAKE_MSGFMT, [ #why has this been dropped? AC_DEFUN(XXAC_STEPMAKE_TEXMF_DIRS, [ AC_ARG_ENABLE(tex-prefix, - [ enable-tex-prefix=DIR set the tex-directory to find TeX subdirectories. Default: PREFIX], + [ --enable-tex-prefix=DIR set the tex-directory to find TeX + subdirectories. Default: PREFIX], [TEXPREFIX=$enableval], [TEXPREFIX=auto] ) AC_ARG_ENABLE(tex-dir, - [ enable-tex-dir=DIR set the directory to put $PACKAGE_NAME TeX files in. ], + [ --enable-tex-dir=DIR set the directory to put $PACKAGE_NAME TeX files in. ], [TEXDIR=$enableval], [TEXDIR=auto] ) AC_ARG_ENABLE(mf-dir, - [ enable-mf-dir=DIR set the directory to put $PACKAGE_NAME MetaFont files in. ], + [ --enable-mf-dir=DIR set the directory to put $PACKAGE_NAME MetaFont files in. ], [MFDIR=$enableval], [MFDIR=auto]) @@ -620,7 +618,8 @@ AC_DEFUN(XXAC_STEPMAKE_TEXMF_DIRS, [ AC_DEFUN(AC_STEPMAKE_TEXMF_DIRS, [ AC_ARG_ENABLE(tfm-path, - [ enable-tfm-path=PATH set path of tex directories where tfm files live, esp.: cmr10.tfm. Default: use kpsewhich], + [ --enable-tfm-path=PATH set path of tex directories where tfm files live, + esp.: cmr10.tfm. Default: use kpsewhich], [tfm_path=$enableval], [tfm_path=auto] ) diff --git a/stepmake/make/stepmake.make b/stepmake/make/stepmake.make index 39cea41b9b..b98bd15401 100644 --- a/stepmake/make/stepmake.make +++ b/stepmake/make/stepmake.make @@ -49,6 +49,10 @@ endif outdir=$(outroot)/$(outbase) config_h=$(depth)/$(builddir)/config$(CONFIGSUFFIX).h +# The outdir that was configured for: best guess to find binaries +outconfbase=out$(CONFIGSUFFIX) +outconfdir=$(outroot)/$(outconfbase) + # user package # stepdir = $(stepmake)/stepmake # for stepmake package diff --git a/stepmake/stepmake/documentation-targets.make b/stepmake/stepmake/documentation-targets.make index 7084ab5b69..fab3e31af9 100644 --- a/stepmake/stepmake/documentation-targets.make +++ b/stepmake/stepmake/documentation-targets.make @@ -5,7 +5,7 @@ default: local-WWW: $(OUTHTML_FILES) footify local-web: - $(MAKE) CONFIGSUFFIX=www local-WWW + $(MAKE) out=www local-WWW footify: $(footify) $(sort $(wildcard $(outdir)/*.html out/*.html out-www/*.html)) -- 2.39.2