]> git.donarmstrong.com Git - lilypond.git/commitdiff
release: 0.1.1 release/0.1.1
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Tue, 5 Aug 1997 01:17:14 +0000 (03:17 +0200)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Tue, 5 Aug 1997 01:17:14 +0000 (03:17 +0200)
141 files changed:
AUTHORS.text
BUGS
Documentation/INSTALL.pod
Documentation/Makefile
Documentation/Rules.make
Documentation/lilygut.pod
Documentation/lilyliterature.pod
Documentation/links.pod
Documentation/mudela-book.pod
Documentation/mudela-course.doc
Documentation/mudela-man.doc
INSTALL.text
NEWS
ONEWS [new file with mode: 0644]
README
TODO
VERSION
aclocal.m4 [new file with mode: 0644]
bin/Makefile
bin/make-patch [new file with mode: 0755]
bin/make_patch [deleted file]
bin/mudela-book.in
bin/release
bin/show-latest.in
configure
configure.in
flower/Makefile
flower/NEWS
flower/ONEWS [new file with mode: 0644]
flower/TODO
flower/VERSION
flower/choleski.cc
flower/configure
flower/configure.in
flower/diagonal-storage.cc
flower/directed-graph.cc
flower/full-storage.cc
flower/include/Makefile
flower/include/choleski.hh
flower/include/diagonal-storage.hh
flower/include/full-storage.hh
flower/include/full-storage.icc [new file with mode: 0644]
flower/include/parray.hh
flower/include/rational.hh
flower/include/real.hh
flower/include/varray.hh
flower/include/vector.hh
flower/include/virtual-methods.hh
flower/matrix-storage.cc
flower/matrix.cc
flower/rational.cc [new file with mode: 0644]
flower/test/mat-test.cc
init/paper16.ly
input/rock.ly [new file with mode: 0644]
input/wohltemperirt.ly
lib/Makefile
lib/config.hh.in [new file with mode: 0644]
lib/include/moment.hh
lily/Makefile
lily/Stable.make
lily/VERSION
lily/boxes.cc
lily/break-caching.cc [new file with mode: 0644]
lily/break.cc
lily/colhpos.cc
lily/command-request.cc
lily/debug.cc
lily/elem-group-item.cc
lily/elem-group.cc
lily/engraver-group.cc
lily/gourlay-breaking.cc [new file with mode: 0644]
lily/grouping.cc
lily/groupregs.cc [deleted file]
lily/horizontal-align-item.cc
lily/horizontal-group-item.cc [new file with mode: 0644]
lily/include/break-caching.hh [new file with mode: 0644]
lily/include/break.hh
lily/include/colhpos.hh
lily/include/const.hh
lily/include/elem-group-item.hh
lily/include/elem-group.hh
lily/include/gourlay-breaking.hh [new file with mode: 0644]
lily/include/horizontal-align-item.hh
lily/include/horizontal-group-item.hh [new file with mode: 0644]
lily/include/ineq-constrained-qp.hh
lily/include/item.hh
lily/include/line-group-grav.hh
lily/include/line-spacer.hh
lily/include/linespace.hh
lily/include/music-list.hh
lily/include/p-col.hh
lily/include/performer.hh
lily/include/request.hh
lily/include/score-elem-info.hh
lily/include/score-elem.hh
lily/include/scoreline.hh
lily/include/spanner.hh
lily/include/spring-spacer.hh
lily/include/vertical-group-spanner.hh [new file with mode: 0644]
lily/include/word-wrap.hh
lily/ineq-constrained-qp.cc
lily/input-translator.cc
lily/item.cc
lily/keyword.cc
lily/line-group-grav.cc
lily/line-spacer.cc
lily/lookup.cc
lily/misc.cc
lily/molecule.cc
lily/music-iterator.cc
lily/music-list.cc
lily/music.cc
lily/p-score.cc
lily/parser.y
lily/performer-group-performer.cc
lily/qlp.cc
lily/qlpsolve.cc
lily/score-align-grav.cc
lily/score-elem.cc
lily/score.cc
lily/scoreline.cc
lily/spanner.cc
lily/spring-spacer.cc
lily/staffline.cc
lily/template2.cc
lily/template5.cc
lily/tex.cc
lily/vertical-align-grav.cc
lily/vertical-group-spanner.cc [new file with mode: 0644]
lily/word-wrap.cc [new file with mode: 0644]
lily/wordwrap.cc [deleted file]
make/Configure_variables.make.in
make/Makefile
make/Targets.make
make/Toplevel.make.in
make/Variables.make
make/lilypond.lsm
make/lilypond.lsm.in
make/lilypond.spec
make/lilypond.spec.in
mi2mu/Makefile

index 8ebc36383a140ccec2e30dabc902adf9c597d131..4ebcd6982302feec2c2f85471cd00f070173ca47 100644 (file)
@@ -61,6 +61,6 @@ C\bC\bC\bCO\bO\bO\bON\bN\bN\bNT\bT\bT\bTR\bR\bR\bRI\bI\bI\bIB\bB\bB\bBU\bU\bU\bUT\bT\bT\bTO\bO\bO\bOR\bR\bR\bRS\bS
 
 
 
-30/Jul/97                 LilyPond 0.1.0                        1
+30/Jul/97                 LilyPond 0.1.1                        1
 
 
diff --git a/BUGS b/BUGS
index e0f534ec8e2c9e50e9fba6e15e9f1d5d6500d2d6..84a3fddf939aa827088350750c70aedb80606c3e 100644 (file)
--- a/BUGS
+++ b/BUGS
@@ -16,3 +16,7 @@
 } 
 
 *******************
+
+Stack frame overwrite in on Solaris 2.5.
+Engraver_group_engraver::Engraver_group_engraver() called from
+Score_engraver::Score_engraver()
index 60100908e85551365021b09432b8099be4458eb7..82d5e944fd7dafb64b593aa126666fa9b6f18b35 100644 (file)
@@ -188,7 +188,11 @@ Set then directory TeX input is in (detected as a subdir of tex-prefix)
 
 =item --enable-mf-dir
 
-Set then directory mf input is in (idem) [obsolete]
+Set the directory mf input is in (idem) [obsolete]
+
+=item --enable-out-dir
+
+Set the directory for machine generated output.
 
 =back
 
@@ -203,6 +207,33 @@ everything will be compiled, but nothing will be installed.  The
 resulting binaries can be found in the subdirectories F<out/> (which
 contain all files generated during compilation).
 
+=head2 Building for multiple hosts
+
+LilyPond does not follow the GNU standards when it comes to
+configuring and making Makefiles. In LilyPond, F<make> generates I<all>
+output in output directories (called F<out/>, by default). 
+You can have multiple compiles from the same source-tree, by
+overriding the setting for the output directory.
+
+Example: on my system, I do debugging and lots compiling. For this I
+use the configuration as follows:
+
+       configure --prefix=~ --enable-debugging --enable-printing --enable-checking
+       make all
+
+and I want to do profiling. For that I use
+
+       configure --prefix=~ --enable-debugging --disable-printing\
+               --disable-checking --enable-profiling --enable-optimise\
+               --enable-out-dir=out-profile
+
+       make OUTDIR_NAME=out-profile all
+
+These two commands build two entirely separate versions of
+LilyPond. In Real Life, you would probably also want to have two
+different prefixes. On my machine this is no problem; I never do 
+C<make install>. My prefix dirs are linked back to my source directory.
+
 
 =head1 INSTALLING
 
@@ -232,6 +263,10 @@ files, I ran "texhash"
 The -O2 option to gcc triggers a gcc bug on DEC Alpha in dstream.cc. You
 should turn off this flag for this file.
 
+=item * 
+
+Perl5.003 and Perl5.004 use different syntax for pod2html:
+
 =back
 
 =head1 EXAMPLE
@@ -271,6 +306,11 @@ F<Variables.make>. (If you create the RPM as a normal user the
 permissions will not be set correctly, unfortunately)
 
 
+=head1 DEBIAN GNU/LINUX
+
+A Debian package is in the works
+
+
 =head1 WINDOZE
 
 Windows NT:
index ea4a7be9c09669ea909f1290159030c66e846161..edd922ce57c2aa3f4a388a9f263099c5a5ed57f2 100644 (file)
@@ -52,7 +52,6 @@ include $(depth)/make/Rules.make
 #
 
 localclean:
-       rm -f out/*
        rm -f $(TEXTFILES) $(HTMLFILES) $(GROFFFILES)
 
 MAN1FILES = lilypond convert-mudela mi2mu mudela-book
index 71388de3c4268114b68c80c12fcc88fc125aece5..77248077993806495a8c257a29e491978e075673 100644 (file)
@@ -36,7 +36,7 @@ $(outdir)/%.1: %.pod
 $(outdir)/%.gz: $(outdir)/%
        gzip -c9 $< > $@
 
-$(outdir)/%.dvi: $(depth)/input/%.ly
+$(outdir)/%.dvi: $(depth)/input/%.ly $(lilyout)/lilypond
        (cd $(outdir); lilypond ../$< ;\
        if [ -f ../$(basename $< ).tex ]; \
        then \
index 71d0f8f566d4527d8e0904a2da2f43dbdee4e3f2..4d174f1e630f54d2602ad5ce23484cb54562c9d3 100644 (file)
@@ -6,7 +6,8 @@ LilyGuts - doco to the internals of GNU LilyPond
 
 This page documents some aspects of the internals of GNU LilyPond. Some of
 this stuff comes from e-mail I wrote, some from e-mail others wrote,
-some are large comments taken away from the headers
+some are large comments taken away from the headers. This is why this
+page may be a little incoherent.
 
 You should use doc++ to take a peek at the sources.
 
@@ -28,20 +29,32 @@ might be integrated in larger systems.
 
 =item Parsing:
 
-No difficult algorithms. Associated datastructures have prefix Input
-(eg Input_score, Input_command). The .ly file is read, and converted
-to 
+No difficult algorithms. The .ly file is read, and converted to a list
+of C<Scores>, which each contain C<Music> and paper/midi-definitions.
 
 =item Creating elements
 
-Requests are processed and used to create elements (like balls, stems,
-slurs etc). This is done by a hierarchy of "brokers" (called
-Translators: the ones for paper output are Engravers, for MIDI
-Performers), which swallow requests, broadcast them and couple
-different elements.
+The music is walked column by column. The iterators which do the
+walking report the Request to Translators which use this information
+to create elements, either MIDI or "visual" elements. The translators
+form a hierarchy; the ones for paper output are Engravers, for MIDI
+Performers).
 
-In this step data-structures for the next steps are created and filled
-with data: Score_elements, PScore, PCol.
+The translators swallow requests, create elements, broadcast them to
+other translators on higher or same level  in the hierarchy:
+
+The stem of a voice A is broadcast to the staff which contains A, but
+not to the noteheads of A, and not to the stems, beams and noteheads
+of a different voice (say B) or a different staff. The stem and
+noteheads of A are coupled, because the the Notehead_engraver
+broadcasts its heads, and the Stem catches these.
+
+The engraver which agrees to handle a request decides whether to to
+honor the request, ignore it, or merge it with other requests. Merging
+of requests is preferably done with other requests done by members of
+the same voicegroups (beams, brackets, stems). In this way you can put
+the voices of 2 instruments in a conductor's score so they make chords
+(the Stem_reqs of both instruments will be merged).
 
 =item Prebreaking
 
@@ -50,35 +63,30 @@ Breakable stuff (eg. clefs and bars) are copied into pre and postbreaks.
 =item Preprocessing
 
 Some dependencies are resolved, such as the direction of stems, beams,
+and "horizontal" placement issues (the order of clefs,  keys etc,
+placement of chords in multi-voice music), 
 
 =item Break calculation:
 
-The lines and horizontal positions of the columns are determined
+The lines and horizontal positions of the columns are determined.
 
 =item Breaking
 
-
 Through some magical interactions with Line_of_score and Super_elem
 (check out the source) the "lines" are produced. 
 
 All other spanners can figure across which lines they are spread. If
 applicable, they break themselves into pieces. After this, each piece
-works (or, if there are no pieces) the spanner throws out any
-dependencies which are in the wrong line.
+(or, if there are no pieces, the original spanner itself) throws out
+any dependencies which are in the wrong line.
 
 =item Postprocesing:
 
 Some items and all spanners need computation after the PCol positions
-are determined.
+are determined. Examples: slurs, vertical positions of staffs.
 
 =item Output paper
 
-
-=item Output midi
-
-The music is run through a translator (called Performer) which 
-creates midi-items from the requests.
-
 =back
 
 =head1 INTERNALS
@@ -92,24 +100,7 @@ In music typesetting, the user might want to cram a lot more symbols
 on the paper than actually fits. To reflect this idea (the user asks
 more than we can do), the container for this data is called Request.
 
-The music (requests) are read/interpreted by a set of objects
-(translators), the Performers/Engravers.  The engraver which agrees to
-handle a request decides whether to to honor the request, ignore it,
-or merge it with other requests. Merging of requests is preferably
-done with other requests done by members of the same voicegroups
-(beams, brackets, stems).
-
-The result of a request will be an C<Item> or a C<Spanner>, which
-will be put on the score.
-
-Different staffs can produce different outputs; a melodious voice
-which is put into a percussion-Staff, will be typeset as the rythm of
-that voice.
-
-After C<Staff> made up her mind, the resultant items and
-spanners are put on the PScore.
-
-Some of the important requests are:
+In a lot of other formats this would be called an 'Event'
 
 =over 4
 
@@ -205,8 +196,8 @@ this to the Staff_engraver. Staff_engraver will tell
 C<Stem_beam_engraver> about the C<Notehead>, which will add the
 C<Notehead> to the C<Stem> it just created.
 
-To decide on merging, C<Complex_staff> has grouped several
-engravers. Please check F<init/engraver.ly>.
+To decide on merging, several engravers have been grouped. Please
+check F<init/engraver.ly>.
 
 
 =head1 ITEMS and SPANNERS
@@ -228,8 +219,7 @@ should be calculated.
 
 =head1 BREAKING
 
-So what's the deal with PREBREAK and POSTBREAK and all this
-stuff?
+So what is this PREBREAK and POSTBREAK stuff?
 
 Let's take text as an example. In German some compound
 words change their spelling if they are broken: "backen" becomes
@@ -258,7 +248,7 @@ on the next line if it is broken.
 
 =head1 SPACING
 
-I think my method is the most elegant algorithm i've seen so far.
+
 Some terminology: I call a vertical group of symbols (notes) which
 start at the same time a "column".  Each line of a score has notes in
 it, grouped in columns. The difference in starting time between those
@@ -267,9 +257,9 @@ columns.
 
 Example:
 
-               time ----->
+       time ----->
 
-               col1    col2    col3    col4
+       cols:   col1    col2    col3    col4
 
 
        voice1  1               1
@@ -284,8 +274,7 @@ Example:
        time_difference (col2 , col3) = 0.5 wholes,
        etc.
 
-these differences are translated into ideal distances (these translations
-have been the subject of discussion in this thread).
+these differences are translated into ideal distances 
 
         distance (col1,col2) = 10 pt
         distance (col1,col3) = 14.1 pt
@@ -326,3 +315,5 @@ springs. This is an area that needs a lot of work, and the optimal
 solution to find is not of a mathematical nature.
 
 Gourlay's solution is used.
+
+
index 1ea51c9b450457798b765e6eec7ac3a946d918b5..5bba17b13815ece6f79438faea9e66a78fd5258d 100644 (file)
@@ -49,6 +49,7 @@ December 1996
 
 [Pamphlet explaining some fine points in music font design HWN]
 
+
 =head2 Notation with computers
 
 Donald Byrd.  ``Music Notation by Computer''.  Dissertation Indiana
@@ -73,11 +74,6 @@ Assisted Research in the Humanities.
 [Annual editions since 1985, many containing surveys of music
 typesetting technology. SP]
 
-Wael A. Hegazy and John S. Gourlay. ``Optimal line breaking in music''. In
-Document Manipulation and Typography, J.C. van Vliet (ed) 1988.
-
-[This generalizes TeX's breaking algorithm to music HWN]
-
 David A.  Gomberg; ``A Computer-oriented System for Music Printing.''
 Computers and the Humanities, Vol.11, pp 63-80.
 
@@ -111,6 +107,13 @@ Computer and Information Science, The Ohio State University, 1987.
 [Describes the "parser" which converts MusiCopy MDL  to MusiCopy
 Simultaneities & columns HWN]
 
+Wael A. Hegazy and John S. Gourlay. ``Optimal line breaking in
+music''.  Technical Report OSU-CISRC-8/87-TR33, Department of Computer
+and Information Science, The Ohio State University, 1987
+
+[This generalizes TeX's breaking algorithm to music. It also appeared in
+Document Manipulation and Typography, J.C. van Vliet (ed) 1988. HWN]
+
 Dean K. Roush. ``Using MusiCopy''. Technical Report
 OSU-CISRC-18/87-TR31, Department of Computer and Information Science,
 The Ohio State University, 1987
@@ -244,15 +247,12 @@ Kurt Stone. Music Notation in the Twentieth Century. New York: Norton,
 1980.
 
 
-=head2 other stuff
+=head2 Other stuff
 
 
 More on GNU Music:
 http://dept-info.labri.u-bordeaux.fr/~strandh/Gsharp
 
-Tablature: http://wabakimi.carleton.ca/~phacket2/guitar/tabfaq.html
-
-
 Peter S. Langston, ``Unix music tools at Bellcore''.  Software ---
 Practice and Experience, Vol. 20(S1), S1/47--S1/61, 1990.
 
@@ -261,15 +261,36 @@ playback. It doesn't mention notation issues, but does come with the
 grand idea (not) of using music to monitor complex systems. Imagine
 your nuclear plant supervisor to use AC/DC for checking the reactor HWN]
 
+
+=head2 File formats
+
+Tablature: http://wabakimi.carleton.ca/~phacket2/guitar/tabfaq.html
+
 Cindy Grande, NIFF6a Notation Interchange File Format.  Grande
-Software Inc., 1995.  ftp://blackbox.cartah.washington.edu/pub/
+Software Inc., 1995.  ftp://blackbox.cartah.washington.edu/pub/,
+http://www.jtauber.com/music/encoding/niff/
 
 [Specs for NIFF, a comprehensive but binary (yuk) format for notation HWN]
 
+SMDL, Standard Musical Description Language 
+ftp://ftp.ornl.gov/pub/sgml/wg8/smdl/10743.pdf
+
+MPDL,
+
+HMSL, Hierarchical Music Structured Language, 
+
+DARMS, 
+
+enigma, 
+
+SCORE,
+
+
 =head1 AUTHORS
 
 References and comments contributed by Han-Wen Nienhuys (HWN), Miguel
 Filgueiras, Mark Basinski (MB), Dorothea Blostein, Stephen Page (SP),
-Jan Nieuwenhuizen.
+Jan Nieuwenhuizen, Peter Kerr.
 
 This should really be redone in BibTeX
+
index 9c7edf0a62833e34dcaab844bb51031864fb7969..c5fadae0039c659270541df97790947087e61474 100644 (file)
@@ -45,7 +45,7 @@ Beta releases will also be at
 
 =item ftp://pcnov095.win.tue.nl/pub/lilypond
 
-=item ftp://alpha.gnu.ai.mit.edu/
+=item ftp://alpha.gnu.ai.mit.edu/gnu/
 
 =back
 
@@ -117,8 +117,13 @@ Dave Philips' Linux sound applications page
 
 More software for (early) music.
 
-=item http://www.emry.net/
+=item http://www.emry.net/webwatcher/
 
-Linux webwatcher.
+The Linux webwatcher.
+
+=item http://www.pbm.com/~lindahl/ravenscroft/modern
+
+Transcriptions of the music of Thomas Ravenscroft, partly using
+LilyPond
 
 =back
index 042948dc4b338b88dd13a499500aa9b281ac4860..5742521677281d182be0de27f92e70f12fc9b8c3 100644 (file)
@@ -4,10 +4,12 @@ mudela-book - integrate LaTeX and mudela
 
 =head1 SYNOPSIS
 
-       convert-mudela [options] [files]
+       convert-mudela [options] [file]
 
 =head1 DESCRIPTION
 
+If no file is given, input is taken from the standard input
+
 mudela-book runs LilyPond on fragments of mudela in your source file,
 and produces a LaTeXable document, with formatted music.
 
@@ -38,7 +40,8 @@ CONTENTS is copied into the TeX source enclosed in a verbatim block.
 
 =item B<--outname>
 
-The name of TeX file to output
+The name of TeX file to output. If none is given, the output is
+printed on stdout.
 
 =item B<--outdir> 
 
index 089b74444c3bd5f6dd5a2951c04ec0aeb53607a4..a918c5df2e95c83f16bfd3dca2f2122e4db78b14 100644 (file)
@@ -14,6 +14,9 @@
 \def\preexample{\par\medskip}
 \def\postexample{\par\medskip}
 
+\emph{This document is not complete yet. It's just a brief blurb which
+  skimps some features of Mudela}
+
 
 \section{Overview}
 Mudela is a language for specifying music. LilyPond is a
index afcf5c4c19290d3c9b6cb60ba5faeed878839330..8e3d0de2eacf9b944db34439b28191449f16cf04 100644 (file)
@@ -15,6 +15,8 @@
 \def\postexample{\par\medskip}
 \def\file#1{{\texttt{#1}}}
 
+\emph{This document is not complete yet}
+
 \section{Introduction}
 
 This document describes the the GNU LilyPond input format, which is an
@@ -24,13 +26,13 @@ short.\footnote{If anybody comes up with a better name, we'd gladly
   take this. Gourlay already uses Musical Description Language,
   G-Sharp Score Definition Language. We're not being original here}
 
-The first aim of Mudela is to define a piece of music, 
-being complete from both from a musical typesetting, 
-as from a musical performing point of view.
+The first aim of Mudela is to define a piece of music, being complete
+from both from a musical typesetting, as from a musical performing
+point of view.
 
 The Musical Definition Language (Mudela), has a logical structure,
 making use of identifiers, that allows for flexible input, and
-definition reuse. See MANIFESTO for reasons and design considerations.
+definition reuse. See \file{MANIFESTO} for reasons and design considerations.
 
 The below included for explanatory purposes only (i.e., for a complete
 and up-to-date definition, see \file{lily/parser.y} and
index 485136c65905b3a8c0c626645e0fbe16b3eb0787..3a2b240602ab7855475c4509d0f22a12063e3623 100644 (file)
@@ -61,7 +61,7 @@ R\bR\bR\bRU\bU\bU\bUN\bN\bN\bNN\bN\bN\bNI\bI\bI\bIN\bN\bN\bNG\bG\bG\bG
 
 
 
-1/Aug/97                  LilyPond 0.1.0                        1
+3/Aug/97                  LilyPond 0.1.1                        1
 
 
 
@@ -127,7 +127,7 @@ C\bC\bC\bCO\bO\bO\bON\bN\bN\bNF\bF\bF\bFI\bI\bI\bIG\bG\bG\bGU\bU\bU\bUR\bR\bR\bRI\bI\bI\bIN\bN\bN\bNG\bG\bG\bG a\b
 
 
 
-1/Aug/97                  LilyPond 0.1.0                        2
+3/Aug/97                  LilyPond 0.1.1                        2
 
 
 
@@ -186,14 +186,14 @@ INSTALL(1)            LilyPond documentation           INSTALL(1)
                 subdir of tex-prefix)
 
        --enable-mf-dir
-                Set then directory mf input is in (idem)
+                Set the directory mf input is in (idem)
                 [obsolete]
 
-                All options are documented in the _\bc_\bo_\bn_\bf_\bi_\bg_\bu_\br_\be help
 
 
 
-1/Aug/97                  LilyPond 0.1.0                        3
+
+3/Aug/97                  LilyPond 0.1.1                        3
 
 
 
@@ -202,6 +202,10 @@ INSTALL(1)            LilyPond documentation           INSTALL(1)
 INSTALL(1)            LilyPond documentation           INSTALL(1)
 
 
+       --enable-out-dir
+                Set the directory for machine generated output.
+
+                All options are documented in the _\bc_\bo_\bn_\bf_\bi_\bg_\bu_\br_\be help
                 The option -\b-\b-\b--\b-\b-\b-e\be\be\ben\bn\bn\bna\ba\ba\bab\bb\bb\bbl\bl\bl\ble\be\be\be-\b-\b-\b-o\bo\bo\bop\bp\bp\bpt\bt\bt\bti\bi\bi\bim\bm\bm\bmi\bi\bi\bis\bs\bs\bse\be\be\be is recommended for
                 Real Life usage.
 
@@ -214,6 +218,35 @@ INSTALL(1)            LilyPond documentation           INSTALL(1)
                 in the subdirectories _\bo_\bu_\bt_\b/ (which contain all
                 files generated during compilation).
 
+       B\bB\bB\bBu\bu\bu\bui\bi\bi\bil\bl\bl\bld\bd\bd\bdi\bi\bi\bin\bn\bn\bng\bg\bg\bg f\bf\bf\bfo\bo\bo\bor\br\br\br m\bm\bm\bmu\bu\bu\bul\bl\bl\blt\bt\bt\bti\bi\bi\bip\bp\bp\bpl\bl\bl\ble\be\be\be h\bh\bh\bho\bo\bo\bos\bs\bs\bst\bt\bt\bts\bs\bs\bs
+
+       LilyPond does not follow the GNU standards when it comes
+       to configuring and making Makefiles. In LilyPond, _\bm_\ba_\bk_\be
+       generates _\ba_\bl_\bl output in output directories (called _\bo_\bu_\bt_\b/,
+       by default).  You can have multiple compiles from the same
+       source-tree, by overriding the setting for the output
+       directory.
+
+       Example: on my system, I do debugging and lots compiling.
+       For this I use the configuration as follows:
+
+               configure --prefix=~ --enable-debugging --enable-printing --enable-checking
+               make all
+
+       and I want to do profiling. For that I use
+
+               configure --prefix=~ --enable-debugging --disable-printing\
+                       --disable-checking --enable-profiling --enable-optimise\
+                       --enable-out-dir=out-profile
+
+               make OUTDIR_NAME=out-profile all
+
+       These two commands build two entirely separate versions of
+       LilyPond. In Real Life, you would probably also want to
+       have two different prefixes. On my machine this is no
+       problem; I never do make install. My prefix dirs are
+       linked back to my source directory.
+
 I\bI\bI\bIN\bN\bN\bNS\bS\bS\bST\bT\bT\bTA\bA\bA\bAL\bL\bL\bLL\bL\bL\bLI\bI\bI\bIN\bN\bN\bNG\bG\bG\bG
        If you have done a successful make, then a simple
 
@@ -223,6 +256,18 @@ I\bI\bI\bIN\bN\bN\bNS\bS\bS\bST\bT\bT\bTA\bA\bA\bAL\bL\bL\bLL\bL\bL\bLI\bI\bI\bIN\bN\bN\bNG\bG\bG\bG
 
        Install the musixtex fonts in a directory which TeX and MF
        knows (if you are root, look for a directory which
+
+
+
+3/Aug/97                  LilyPond 0.1.1                        4
+
+
+
+
+
+INSTALL(1)            LilyPond documentation           INSTALL(1)
+
+
        contains the directories with AMS and CM source (*.mf)
        files. Create a subdir lilypond or musixtex and copy the
        fonts into that). Do not forget to rehash TeX (if
@@ -239,6 +284,9 @@ C\bC\bC\bCA\bA\bA\bAV\bV\bV\bVE\bE\bE\bEA\bA\bA\bAT\bT\bT\bTS\bS\bS\bS
                  Alpha in dstream.cc. You should turn off this
                  flag for this file.
 
+       +\bo         Perl5.003 and Perl5.004 use different syntax for
+                 pod2html:
+
 E\bE\bE\bEX\bX\bX\bXA\bA\bA\bAM\bM\bM\bMP\bP\bP\bPL\bL\bL\bLE\bE\bE\bE
        This is what I type in my xterm:
 
@@ -248,26 +296,6 @@ E\bE\bE\bEX\bX\bX\bXA\bA\bA\bAM\bM\bM\bMP\bP\bP\bPL\bL\bL\bLE\bE\bE\bE
 
        This is what the output looks like over here:
 
-
-
-
-
-
-
-
-
-
-
-
-1/Aug/97                  LilyPond 0.1.0                        4
-
-
-
-
-
-INSTALL(1)            LilyPond documentation           INSTALL(1)
-
-
                GNU LilyPond 0.0.78 #4/FlowerLib 1.1.24 #0
                Parsing ... [/home/hw/share/lilypond/init//
                        <..etc..>
@@ -293,6 +321,22 @@ R\bR\bR\bRE\bE\bE\bED\bD\bD\bDH\bH\bH\bHA\bA\bA\bAT\bT\bT\bT L\bL\bL\bLI\bI\bI\bIN\bN\bN\bNU\bU\bU\bUX\bX\bX\bX
        create the RPM as a normal user the permissions will not
        be set correctly, unfortunately)
 
+
+
+
+
+3/Aug/97                  LilyPond 0.1.1                        5
+
+
+
+
+
+INSTALL(1)            LilyPond documentation           INSTALL(1)
+
+
+D\bD\bD\bDE\bE\bE\bEB\bB\bB\bBI\bI\bI\bIA\bA\bA\bAN\bN\bN\bN G\bG\bG\bGN\bN\bN\bNU\bU\bU\bU/\b/\b/\b/L\bL\bL\bLI\bI\bI\bIN\bN\bN\bNU\bU\bU\bUX\bX\bX\bX
+       A Debian package is in the works
+
 W\bW\bW\bWI\bI\bI\bIN\bN\bN\bND\bD\bD\bDO\bO\bO\bOZ\bZ\bZ\bZE\bE\bE\bE
        Windows NT:
 
@@ -325,6 +369,28 @@ A\bA\bA\bAU\bU\bU\bUT\bT\bT\bTH\bH\bH\bHO\bO\bO\bOR\bR\bR\bRS\bS\bS\bS
 
 
 
-1/Aug/97                  LilyPond 0.1.0                        5
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3/Aug/97                  LilyPond 0.1.1                        6
 
 
diff --git a/NEWS b/NEWS
index a06bb286319a54b3059ece426984b3280e93a7c5..6f889e266482de0d062000a920971596255ca016 100644 (file)
--- a/NEWS
+++ b/NEWS
+pl 0.1.1
+       - {Horizontal, Vertical}_group.  A score_element may be in at most one. 
+       - This means Horizontal_group_item and Vertical_group_spanner need special support.
+       - This also means a big speed increase
+       - configure cleanup
+       - bf: Choleski solve.
+       - doc updates: lilygut, INSTALL
 
-august 1
+pl 0.1.1.hwn
+       - recode of Break/Colhpos interfaces
+       - Gourlay_breaking: dynamic-programming optimal solution for 
+       casting off. Word_wrap is still optional
+       - some printing short cuts if no -d specced.
+       - band_matrices for column calcs
+       - more Diagonal_storage fixes
+       - retake: INFTY fixes ( now infinity_mom, infinity_f )
 
-VERSION 0.1.0
-       
-       - bf: output tempo to track 0 too
-       - bf: don't forget to copy id_str_, so moved  into Music
+pl 78.jcn3
+       - configure: ln and zip 
+       - target doosdist -> lilypond-x.x.x.exe.zip: + executables - sources
 
-pl 78.jcn1
-       - fix for multi-staff midi: wohltemperirt.ly, standchen.ly
-       - doze fixes
-       - bf: conflily, configure (text)
-*****
-july 31
-pl 78
-       - bf: Midi_instrument 
-       - added  enable/disable defaults to help.
-       - incredibly ugly NAME_MEMBERS(); bug. Immediately changed to 
-DECLARE_MY_RUNTIME_TYPEINFO;
-       - \stem -1 -> \stem \down in input      
-       - bf: slurchar index
-       - configure warnings 
-       - preliminary stuff for multiarch building
-       - #!/usr/bin/perl fixes (AO)
-       - some Makefile cleanups: now faster.
 
-pl 77.jcn2
-       - Midi_instrument
 
-******
-july 29
-pl 77  
-       - some fixes for internal compiler errors 
-derive from Pointer_list with default dtor gives error with -O2
-       - .ini -> .ly
-       - lyrics fix 
-       - Performer beautification: got rid of set_track(), midi_output()
-       - pseudo RTTI for midi-items
-       - bf: Performer*::print() 
-       - links.pod
-       - Voice_element -> Request_chord
-       - fixed flex problems: stdin input works again 
-       - Documentation/Rules.make, make-website via make
-       - spacing: now add basicspace
-
-*******
-july 28
-pl 76
-       - mudela version bumped to 0.1
-       - mudela-book
-       - doco updates, now some stuff in LaTeX
-       - junked book.{ly,tex} example
-       - progress indicator
-       - rhythm.ly updated
-       - removed mf sources from distribution due to (c) stuff
-       - allowal of breaks handled cleanly
-       - junked Subtle_reqs, junked Request_iterator. Request
-       iteration now by Voice_element_iterator
-       - Piano_bar, Piano_bar_engraver, Span_score_bar_engraver, 
-       Span_score_bar
-       - Swallow_performer
-       - removed  Staff_engravers, grouping into Line_group_engraver
-       - Head_column as base for Rest_column,Note_column
-       - Score_column derived from PCol
-       - regurgled Line spacing: interface and implementation
-       separate. Idealspacing moved into Spring_spacer
-       - Gourlay style linespacing
-
-pl 75.jcn6
-       - {lyric,meter,key}-performer
-       - span-brace-* (Removed again. Such is life)
-       - doze compile
-       - midi output, notes only
-       - working midi output -- hacked
-       - doze compile, mingw32 configure (still triggers gcc int. comp err)
-
-pl 74pre.jcn2
-       - mi2mu fixes after scott snyder <snyder@d0sgif.fnal.gov> [sss]
-       - mi2mu update for mudela 0.0.61
-       - conflily fixes
-
-*******
-july 21
-
-pl 75
-       - inbook.ly & book.tex example.
-       - natural width: linewidth = -1.0\cm
-
-pl 74pre.jcn1
-       - oversimplified midi output thru performer hierarchy
-       - bf: Spanner::doprint
-
-pl 72pre.jcn1
-       - naming fixes; some iter*() explicitations
-        - removed acceptor.hh
-       - *performer*: second draft of midi (audio/...)
-
-*******
-july 9
-
-pl 74pre
-       - Input_engraver -> Input_translator
-       - bf: span start/stop is now a "used" col.
-       - Rest_column/Rest_collisions bugfixes
-       - bf: crescendi.
-       - Spanner do_print()
-
-******
-july 7
-pl 73pre
-       - some refs doco.
-       - move Input_engraver into Paper_def
-       - junk Interpreter
-       - naming: Request_engraver -> Engraver, 
-       - Music_iterator::next() -> process_and_next()
-       - junk Voice_engravers
-       - Span_bar, Span_bar_engraver
-       - Vertical_align_engraver
-       
-*******
-july 2
-pl 72pre
-       - \paper{} syntax: var = 1.0\pt;, with an Assoc array
-       - sketch of MIDI Performer classes.
-       - bf: memleak in parser
-       - naming: Acceptor -> Translator
-       - input: bf collisions.ly, scales.ly
-       - bf: [r8 c8]
-       - naming: Register -> Engraver
-       - force \\ on identifiers
-       - doco updates
-       - musixtex T73 fonts
-
-pl 70.mb
-       - bf: find syntax in Variables.make
-*****
-july 1
-pl 71pre
-       - nested \melodic and \lyric constructs
-       - init id's, Input_register aliases.
-       - bf: notehead x-swap 
-       - bf: auto-keys.
-       - bf: first clef
-       - junked \init_end; construct
-       - Preparatory work for MIDI output:
-               * Acceptor as baseclass for Register_group_register
-               * Global_acceptor as interface of Register to Score
-       - bf: empty voice
-       - Lyrics: partially working
-       - some doco updates (junks, mostly)
-
-
-******
-june 30
-
-
-pl 70pre
-       - bf: text Script
-       - bf: Script::dir_i_ checks.
-       - bf: script stacking
-       - bf: Text_spanner::do_subst.
-       - bf: Text_spanner::Text_spanner(Text_spanner&)
-       - bf: script priority read from script.ini
-       - bf: Script_def::do_equal_b
-       - bf: script dims.
-       - mudela: ; obligatory for \paper {}.
-       - some cosmetic changes involving RTTI macros
-
-*******
-june 29
-pl 69pre
-       - bf: whole rest position, whole/half rest dots.
-       - bf: scripts
-       - reg termination
-       - centered bars
-       - bf: init of Tie::dir_i_ 
-       - bf: Staff_side depends on staff_sym_
-       - bf: Script::do_substitute_dependency() now implemented
-       - more print info (also in output)
-       - bf: Vertical_align_element
-       - stemless beams now allowed (with warning)
-       - bf: Rest_column::stem_l_ init
-       - merge rests.ly with collisions.ly
-
-pl 67.jcn3
-       - rests under beam [c8 r c]
-
-pl 67.jcn2
-       - first attempt at rest collisions
-       - rests.ly
-
-pl 67.jcn1
-       - beam stem length: beams.ly
-       - bf: mingw configure
-       - re: conflily
-
-******
-june 26
-pl 68pre
-       - doco: other-packages.pod, lots of lilyliterature.pod
-       - last duration mode now is default.
-       - some OpusTeX stuff.
-       - bf Y2K in convert-mudela
-       - Grand rewrite of Music/Register stuff:
-         * separation of Y and X-elt-groups
-         * Registers: info up: broadcasts, info down: get_xxx_info()
-         * Registers: try_request works from bottom to top of tree.
-         * Score_elem empty_b_ and transparent_b_ flag
-         * Junk Staff_column, and find the requests while walking the
-         Voices.
-         * Score_register
-         * Staff_group, Score_request_register.
-         * align key/Meters/bar across staffs
-         * junked Staff, Staff_column, Staff_walker, Complex_walker,
-           Request_column Pulk_voice, Pulk_voices, Walker_registers,
-           Voice_element, 
-           Input_score, Input_staff, Input_music and a lot of
-           parserjunk.
-         * mudela: lots of structure changes : now much simpler
-         * generation of pre/postbreak items now in Score_elem with deps.
-       
-       - bf: make_patch explanation
-       - bf: make install TeX stuff
-       - mudela: . mandatory for REALs
-
-
-pl 67
-       - damped beamslope after wanske
-
-******
-june 3
-pl 67
-       - sketch of Music classes
-       - General_script_def as baseclass for Text_def and Script_def
-       - bf: clean lib/out/liblily.a
-       - bf: rests shorter than 1/4
-
-pl 66.jcn3
-       - bf: make uninstall
-       - conflily
-       - f: some pedaling
-       - plet hack removed :-( [ c c c ]2/3 -> [2/3 c c c ]1/1
-
-pl 66.jcn2
-       - bf: bar, Hilfslinie
-       - bf: configure for mingw32
-
-pl 66.jcn1
-       - WIN32 -> WINDOWS32, more win32->windows32
-       - some GNU/Linux changes
-       - cygnus b18 / mingw update
-       - doze compile; bf: p-score.cc compares
-       - reincluded toccata fixes
-       - small stuff: vi tags, typos, bibl
-
-******
-may 27
-pl 66
-       - make_website --jpeg, --png and --gif
-       - win32 -> windows32
-       - bf: Score_elem::TeXstring assert fail
-       - bf: headswap with stemdown
-       - bf: broken tie
-       - bf: broken slur
-       - bf: accidental dims
-       - bf: measure bar width
-       
-
-******
-may 26
-
-pl 65
-       - bf pathfind /root/file
-       - massive Score_elem rewrite:
-         * group_element_i_ count
-         * support for removing an individual Score_elem cleanly.
-         * moved dep stuff into class Directed_graph_node
-         * Score_elems can be copied and deleted freely.
-         * junk PStaff
-         * Spanner_elem_group
-         * Line_of_{score,staff} now are Score_elems
-         * clean dep handling upon deletion
-         * delete unbroken spanners
-         * added a break_processing round.
-         * Super_elem
-       - junk Complex_staff, 
-       - clean {lily}?proto.hh
-       - Element_group
-       - Score_elem now as virtual base class everywhere
-       - naming: Staff_elem -> Score_elem
-       - bf: make in toplevel dir
-       - bf: broken tie y-pos
-       - bf: sharing 4th, 8th and 16th noteheads 
-       - bf: overlapping chords. <\multivoice c d >
-
-pl 64.wl
-       - new stem direction code
-       - bfs: wohltemperirt.ly (thanks, Werner)
-       - bf: stem direction
-
-pl 63.jcn2
-       - doze compile
-
-pl 63.jcn1
-       - bf: mi2mu mudela commands
-       - bf: mi2mu tracks
-       - mi2mu quantify tuning
-       - mi2mu TODO
-
-*********
-may 16
-pl 64
-       - exe's now built in out/
-       - toplevel Makefile dep from make/Toplevel.make.in
-       - make_website: add version footer
-       - make_website: bf dist *.txt
-       - bf: fix loose bars :  \meter 4/4; c1.  
-       - Staff_elem -> Score_elem
-       - bf <cis cis>
-       - vbrace lookup
-       - resync barcheck
-
-*******
-
-may 15
-pl 63
-       - bf: segfault during MIDI output  with mi2mu output.
-       - kludge: parse error beyond eof
-       - don't read ini if toplevel file not found
-       - accumulate \kern in TeX output.
-       - bf: try to prevent long lines; TeX breaks on them.
-       - naming: Pointer->Link, IPointer->Pointer
-       - bf: \plet didn't work (MB)
-       - GMP manifesto.
-
-pl 61.jcn4
-       - mi2mu -p -s16 fugua2.midi getting better!
-         plus factor 2 mi2mu speedup (fugue2.midi 5.50user)
-       - bf: Duration_convert quantify threshold down
-       - bf: (on quantify): tcols quantified; no silly voices
-
-pl 61.jcn3
-       - lily parsing speedup: backup rules for lexer.l
-       - bf: mi2mu, using midi_voice list...
-
-pl 61.jcn2
-       - all in all mi2mu speedup of about factor 8 since pl61
-        (fugue.midi 82.72user to 10.30user on a 586.133)
-        what about lily?
-       - binary search on track-columns
-       - mi2mu IP*list to Array (implications?!) conversion
-       - mi2mu parsing speedup: backup rules for midi-lexer.l
-       - bf: zero denominator
-
-**********
-may 14 
-pl 62
-       - make clean bf: remove lex & yacc files too 
-       - added kludge in case measure too long 
-       - added kludge in case of unconnected columns.
-       - kludged columns get error marker
-       - kludged lines get error marker
-
-
-pl 61.jcn1
-       - smarter + faster duration-convert using Array
-       - bf: mi2mu compilation/duration-conversions
-       - lots faster mi2mu, hopefully does type 1 too...
-pl 60.jcn1
-       - mi2mu handles non-quantified rests, try mi2mu -b wtk-i/fugue2.midi
-
-
-       
-**********
-pl 61
-       - scales.ly bugfix: dimensions default to ((0,0), (0,0))
-       - naming: PointerList->Pointer_list
-       - tied notes don't get accidental
-       - bf: crescendo size
-       - fixes: make_patch,
-       - bf: _"text" direction
-       - mailing list into lilypond.pod
-
-pl 60.mb
-       - set_flower_debug: Warning if -d is used when NPRINT is defined.
-       - Fixed several TeX details. vcenter renamed since it interfered
-         with LaTeX. Position of accents changed.
-       - New example; scripts.ly
-       - table_sixteen: added scriptdefinition (Lilypond breaks if a
-         script is defined without dimensions).
-       - bf: ifndef typos in p-score.cc, choleski.cc
-       - bf: Slur::do_post_processing(), whole notes caused SIGSEGV.
-
-(ascension break :-)
-*******
-pl 57.jcn4
-       - mi2mu handles rests (quantified only)
-       - fixed configure buglet
-        - "!date" Fri May  2 02:18:12 MET DST 1997
-
-pl 60
-       - Request_register::get_feature(), tie direction, Slur direction
-       - lilypond output is now directly texable. 
-       - make_website checks return status
-
-*******
-may 5
-pl 59
-       - Slur now into voicegroups, and take stems into account.
-       - bf: rest size in table.
-       - split Slur in baseclass Bow
-       - Tie, Tie_req, Tie_register
-
-******
-may 2
-pl 58.jcn1
-       - bf: toccata-fuga-E.ly
-
-pl 57.jcn4
-       - mi2mu handles rests (quantified only)
-       - fixed configure buglet
-        - "!date" Fri May  2 02:18:12 MET DST 1997
-pl 58
-       - lexer cleanup
-       - national chars in lyrics
-       - \stem 2; bf
-       - long comments: %{ %} 
-       - *.ini mode bf
-       - bf: partial may be everywhere
-       - bf: meterchange not at start of measure
-       - some doc updates
-       - bf: stem too long if stem is down.
-
-pl 57.jcn3
-       - dank je schat, voor wtk-i
-       - mi2mu tries to handle rests
-        - "!date" Thu May  1 02:34:04 MET DST 1997
-       - maak je het niet te laat schat?
-         XXXX HWN
-
-pl 57.jcn2
-       - small toccata-fuga-E.ly fixes
-       - \bar "||"; is now doublebar, "|." is finishbar
-       - collision hshift fix, with on-line assistance
-******
-pl 57
-       - lots of TODO doco
-       - text alignment bugfix
-       - bugfix Voice_group_regs::get_register_p() now is actually called too
-       - bugfix init  of Text_item::pos_i_
-
-pl 56.jcn1
-       - toccata-fuga-in-E.ly, excerpts with real-life collisions
-       - \{l,r}{b,f}{toe,heel} --- using cmsy fonts...
-       - pedal.ly 
-
-pl 55.jcn1
-       - mi2mu man page
-       - make doc fixlet
-       - \[lr]heel \[lr]toe scripts (happy pedal studies, pa)
-       - lyric with width
-       - removal of some example files
-
-pl 56.mb:
-       - last duration fix
-       - makefile fixes
-       - space rest
-       - swedish note name update
-
-******
-pl 56
-       - Massive Rest/Stem/Collision/Note_column rewrite: resolve
-notehead/rest ambiguities and bugs. eg, [c8 r8 c8] 
-
-pl 54.jcn1
-       - standchen.ly: repeats; lyricii to end
-       - convert-mudela: help + usage
-       - fixed midi key/meter-change (triggered by martien.ly) bug
-
-******
-April 23
-pl 55
-       - staff-side robustification
-       - script-on-rest bug
-       - doc update
-       - transpose syntax
-******
-pl 54
-       - bugfix Colhpos.cc::OK assert fail.
-       - Inclusion of MusixTeX MF files, 
-       - detection of MF dir
-pl 53.hwn
-       - stacked lyrics 
-       - configure/make buglets.
-******
-pl 53
-       - spurious accidental bug.
-       - simultaneity check.
-       - added AUTHORS.pod
-       - convert-mudela auto from guess
-       - include -> \include
-       - change order of opening parse/init file 
-       - Pulk_voice, Pulk_voices
-       - Request_column
-       - revised request-from-voice extraction. Now much faster
-
-******
-april 17
-pl 52
-       - Buildroot RPM
-       - tex-prefix and tex-dir sep'd (here you are jan)
-       - convert-mudela framework
-       - Collision_register, Collision
-       - \hshift 1; input
-       - Features changed
-pl 50.jcn1
-       - LILYINCLUDE dir searched before DIR_DATADIR(?)
-       - lily reads from stdin again (but does not now when to stop)
-******
-pl 51
-       - transposition bugfix + doco
-       - LilyPond -> GNU LilyPond
-       - bugfixes for Staff_side and Note_column*
-       - wohltemperirt: complete
-
-******
-april 11
-
-pl 50
-       - merge rest / notehead.
-       - Staff_side as a base class for most "staff-side" symbols.
-       - version check
-       - Note_column_register, Note_column
-       - multiple scripts
-
-********
-april 8
-pl 49.jcn1
-Bugfix
-       - configure[.in], make/Configure_variables.make.in c++ (=doze fix)
-       - "configure; make" ok for doze, win32 target may be removed now
-       - win32/gcc 2.7.2 compile fixes -- why does this all compile 
-           (without warnings, why can-t i even trigger warnings) under 
-           linux/gcc-2.7.2.1?  it's quite a tedious job fixing this 
-           shit _on doze_ all the time.
-           * fixed #includes global-regs.cc, staff-info.cc, staff.cc
-           * key.hh:Key() -> Octave_key()
-           * added missing lily/include/input.hh: Input( Input const& )
-       
-pl 49
-       - lsm template
-       - clef in cadenza mode.
-       - notename clear
-       - \command bla; for \meter, \clef, \octave etc.
-*******
-pl 48
-       - notenames init
-       - Duration order -> grouping
-       - broken key s
-       - default octave
-
-******
-april 3
-pl 47
-       - dynamic flowerlib
-       - Input mods: now use Source_file iso Sources
-       - makefile lib deps restructured
-       - make_website now produces in out/
-
-pl 46
-       - examples.pod
-       - LILYINCLUDE env var.
-       - push/popgroup
-       - website updated
-       - Swallow_register
-       - Lyric_register.
-       - Staff_sym_register
-       - user settable register config
-       - struct Input now used iso defined_ch_C_
-       - Walker_registers and Staff_registers separated
-       - dynamic-reg -> hairpins
-
-pl 44.jcn2
-       - doze configure/compile fixes
-       - doze make refixed
-       - faq
-       - install mudela manpage too
-       - RedHat spec lilypond.spec fixed
-       - target: rpm (make RedHat packages)
-
-******
-Mar 26
-pl 45
-       - Removing unused Voice_regs & Voice_groups
-       - -O2 bugfix
-
-pl 44.jcn1
-       - merged 42.3 42.jcn4 code trees (see stuff below)
-       - moving towards Mudela 0.1 (again)
-           * keyword "music" dropped for horizontal music
-           * keywords "\lyric" "\melodic" introduced, e.g.:
-               melody = \melodic { c c | g g }
-           * removed level of indirection:
-               - staff initialisable with music identifier list: 
-                   \staff{ global melody }
-               - \score and staffs alike
-       - gnu standard(?) help texts
-       - configure "creates" toplevel Makefile from make/Toplevel.make
-
-Bugfix
-       - fixed mi2mu
-       - write meter to track0 too...
-       - default octave
-       - new Sources in My_midi_lexer: sourcefile_p_ = get_file_l(): oeps.
-         (ain-t hungarian grand?)
-
-Examples
-       - updated for mudela 0.1
-
-******
-pl 44
-       - naming: _c_l -> _C
-       - pure parser, My_lily_parser
-       - ''a iso ``a
-       - Includable_lexer
-       - junk Input_file
-       - Duration in parser, Duration restructuring
-       - grandiose lexer hax. Flex should be fixed, really.
-       Lexer much faster now.
-       - opps. mi2mu broken
-
-******
-pl 43
-       - transposition.
-       - $variable&@name 
-       - warnings if incorrect mode
-       - missing scsii measure
-       - declaration used check.
-       -
-
-pl 42.jcn4
-       - lily writes midi meter/key changes from requests
-       - mi2mu: 
-         + write mudela 0.1
-         + write bar change requests
-         + more tunable quantisation
-
-Examples
-       - half-new-menuetto.ly converted to mudela -almost- 0.1
-       - new mi2mu of bach's wtk pre1/fugue1
-
-pl 42.3 (jcn version)
-        - oeps, branched source tree
-
-pl 42.hwn3
-       - const naming change (T const <-> const T)
-       - Mudela 0.1 (roughly the same as below..)
-
-pl 42.3
-       - moving towards Mudela 0.1:
-           * all keywords must be preceded by backslash '\'
-           * explicit lexer switches '$' and '@' dropped
-           * keyword "music" dropped for horizontal music
-           * keywords "\lyric" " introduced, e.g.:
-               melody = \melodic { c c | g g }
-           * staff initialisable with music identifier: 
-               \staff{ melody }
-           * chords: < c e >
-           * octavate ''c`` 
-           * \meter{ 2/4 }
-           * \octave{ ''`` }
-        - configure sets CXX (to c++, commonly)
-Internal
-       - renamed lexer.hh, mylexer.cc My_flex_lexer to my.lily.lexer.*
-
-pl 42.2
-       - new lilyinput (Mudela 0.1) doc.
-Examples
-       - new-twinkle.ly (in Mudela 0.1, hopefully)
-
-pl 42.1
-       - further Makefile revamping.
-       - moved flowerlib
-
-*******
-pl 42
-
-
-pl 41.hwn3
-       - struct Lexer_prefs
-       - parser bug
-       - make uninstall
-
-pl 41.hwn2
-       - make file rehack
-       - spec update
-       - make install
-       - detect TeX directory
-
-pl 41.hwn1
-       - cygnus configure,
-       - updated versioning 
-       - install.pod
-  
-pl 41.jn1
-Bugfix
-       - doze compile
-*******
-pl 41
-       - release
-
-pl 40.3
-       - all of the above
-       - hw's configure.in
-       - p-name.xx fixes
-
-pl 40.hwn1
-       - hairpin dynamics
-       - notename now as identifier. Parser/lexer cleanup
-
-pl 40.2
-       - mi2mu --blonde-durations, --no-silly options.
-       - mi2mu starts to look promising, see examples
-Examples
-       - pre1.midi.ly, fugue.midi.ly
-Internal
-       - Duration handles blonde midi-durations
-       - More settings for Duration_convert
-       - lily writes meter too (ugh, howto?)
-Bugfix
-       - mi2mu auto track number fix
-       - mi2mu / lily Midi_tempo fixed/added
-
-pl 40.1
-Bugfix
-       - lily midi output track 0 name
-       - mi2mu tempo fixed
-       - make out/make and out/make/Site.make in configure script!
-       - mi2mu double newline fix
-
-
-******
-Mar 11
-pl 40
-       - release
-
-pl 39-5
-       - own versioning for mi2mu: 0.0.10
-       - some file renaming mi2mu
-pl 39-4
-       - all of the above
-
-pl 39-hwn2
-       - last bar bugfix
-Internal
-       - simple dynamics
-       - experimental RPM spec.
-       - doco update.
-
-pl 39-3
-       - all of the above
-       - m2m renamed to mi2mu
-       - better line breaking in mi2mu
-       - (somewhat broken) progress indicator for mi2mu 
-       - mi2mu output === lily input (in names and durations,
-         always assuming voices > 1 though)
-
-Bugfix
-       - midi: note on/off only once per pitch per track 
-         (sending all note-on events introduces cool mi2mu feature)
-       - make clean removes deps too
-       - mi2mu notename/accidental/octave, and key fixed
-
-Internal
-       - auto create of out-dirs, config headers, using tag file .GENERATE
-
-Examples
-       - stanchen.ly debugged
-
-pl 39-2
-       - configure script help and in topdir again, duh.
-       - auto configure upon virgin make
-       - configured makefile stuff in make/out/
-
-
-********
-pl 39-1
-       - doze target (for 16 bit dos xcompiler: gcc-go32)
-Internal
-       - make/User.make; C..FLAGS sorted out
-Bugfix
-       - make clean...
-
-pl 39
-       - new make structure, featuring:
-           * top-level/sub-level build
-           * auto custom-library dependencies/build
-           * top-level/sub-level dist
-           * minimal(? can even smaller) specific Makefiles
-           * which makes for simple lib/exe module split (make/Template.make)
-           * integrated flowerlib
-           * all stuff into subbirs (make/Stuff.make)
-           * all headers into <module>/include dirs (make/Include.make)
-           * all output into <module>/out (executables into bin/)
-           * more make features, like make config, make help
-           * small lily lib
-           * lilypond-x.x.x/.version for toplevel lily version
-           * lilypond-x.x.x/<module>/.version for <module> version (eg: flower)
-           * versioning using additional optional MY_PATCH_LEVEL 
-               for easy make_patch
-
-       - bin/cptogen
-
-Internal
-       - generic m2m header: m2m.hh
-
-Bugfix
-       - small fixes, make, dist, configure
-
-pl 38-5
-       - all of the below, e.g. new filenames and new makefile 
-         structure patches merged
-******
-pl 38
-
-Internal
-       - great filename renaming operation with - convention.
-       - printing methods for paper_def/lookup/symtab(s)
-       - untied all registers from complexwalker. Now registers are
-intrinsically hierarchical. All walker communication is done via a
-"top level" register.
-
-pl 37-3
-       - m2m handles voices
-       - instrument, track_name, copyright/left stuff for m2m/ly
-
-Internal
-       - Midi_voice
-
-pl 37-1
-       - text, key, tempo event in midi output/ly input
-
-Internal
-       - simple makefile structure, allows for multiple projects
-
-******
-pl 37
-
-
-Documentation
-       - language.pod as starting point for mudela devel.
-
-       - Jan's patches:
-Features
-       - m2m patchy --no-triplet option;
-         lilypond accepts m2m's real midi output (hand-add red tape)
-       - m2m output only valid durations, resync option wip
-       - m2m produces .ly output
-Internal
-       - simpler and better naming for Duration*
-       - the great String renaming / index to base=0 change
-       - Track_column, Lily_stream
-       - Duration, Plet, Duration_convert taking load off duration calc.
-Bugfix
-       - m2m duration calc
-
-
-
-******
-pl 36
-       - Jan's patches:
-       - do MIDI rests cleanly.
-       - lily/m2m: time and tempo fixed for metric timing
-Internal
-       - Midi_tempo
-       - m2m parses more midi stuff (all of bach-wtc); timing??
-       - m2m recognises some commandline options
-Examples
-       - fixed midi.ly
-
-*******
-Feb 25
-pl 35
-       - Register_group
-Bugfix
-       - alignment of breakable items.
-
-*******
-pl 34
-       - better midi syntax.
-       - --midi,-M option.
-       - preliminary midi2mudela (/mudela2midi) converter: m2m (JCN)
-Internal
-       - m2m sources: midi-*; (JCN)
-       - new Midi_walker, fixes several MIDI bugs.
-       - junked Midi_staff, Staff_column children, Midi_walker
-       - Midi_output
-
-pl 33-1
-       - m2m parses midi
-Internal
-       - Binary_source_file
-       - Source_file::error_str simplified
-*******
-pl33
-Examples
-       - Swedish notenames (MB)
-
-pl pre33-2
-
-Bugfix
-       - midi pitch
-       
-Features
-       - Jan's patches, see below
-Bugfix
-       - some midi bugfixes.
-
-pl pre33-1 (JCN)
-
-
-       - midi output using pitches iso notename
-Examples
-       - added midi output (some midi output files broken?)
-       - all melodic fixed (except for error.ly:-) 
-       - midi.ly
-Bugfix
-       - midiwalker line break
-       - empty/nonexistent include at top of ly
-       - midi #tracks
-       - midi pitch c0
-       - midi poor man-s staff dynamics
-Internal
-       - Midi_column, Midi_staff, Midi_walker
-
-pl pre33 (JCN)
-       - Jan's patches, see below
-
-Features
-       - simple plet notation (JCN)
-       - lyrics centred, but no fully suppored? (JCN)
-Internal
-       - Midi_stream 
-       - Mididef
-       - Midi_item, Midi_pitch, Midi_duration
-       - Midi_chunk, Midi_header, Midi_track
-       - preparations for midi output 
-       - no exit upon context error (JCN)
-       - converted some "warnings" to errors; no output (JCN)
-Bugfix:
-       - simple plet bugfix
-Examples
-       - updated standchen, menuetto (JCN)
-       - new plet notation (JCN)
-       - plet.ly (parse and spacing tests) (JCN)
-
-*******
-pl 32
-Features
-       - multiple meters, see rhythm.ly
-       - skip syntax/Skip_req
-       - score_wide_music: commands in staff now override commands in score.
-Internal:
-       - command carnage
-       - Key_register
-       - Bar_register
-       - Meter_register
-       - meters now kept in baseclass Staff_walker
-       - Score_walker (to ease MIDI output)
-Doc:
-       - Hungarian doco added to CodingStyle
-
-pl 32-1
-       - music processing speedup
-       - website added to doco
-       - clef must *inside* music
-       - fixed spurious "beam too narrow" messages.
-Internal:
-       - merge musical / non-musical staff_column
-       - musical/ non-musical requests
-       - Clef_register
-       - split up request.hh, Musical_req vs. Nonmusical_req
-*******
-pl 31
-
-Examples
-       - Coriolan example (JN)
-       - standchen updated
-Bugfix
-       - calcideal assertion bugfix
-*******
-Feb 12 13:55
-pl 30
-
-Features
-       - better multivoice spacing
-       - move rest in multivoice staff
-       - errors in TeX output now warnings
-       - progress indicator
-       - music processing speedup.
-Internal
-       - make spanner for staffsym; scrap Line_pstaff
-       - scrap simplestaff (Rhythmic_staff temporarily disabled)
-       - docxx 3.0 format comments
-       - split register source files
-       - hardcoded dimensions compile time
-       - Lookup::tex_hairpin
-Bugfix
-       - non G-clef clefs
-       - script junking (2x)
-       - empty files
-       - beam::center (plet position!)
-       
-pl 29
-       - multiplatform Makefile (JN)
-       - context errors: bugfixes (JN)
-*******
-pl 28
-
-Internal
-       - idealspacing slightly better for multivoice.
-Doc
-       - Request_register
-Bugfix
-       - Script.cc : float exception (MB)
-       - Request::Request(Request) copying of definition pointer (JN)
-       - cleaned dependencies for broken spanners
-       - stupid typo in Staff_elem::post_processing()
-       - init of hpos in PCol::PCol
-       - Word_wrap::solve() bug 
-*******
-pl 27
-       - preliminary WIN32 support (JN)
-Features
-       - errors converted to warnings (JN)
-       - context errors (JN)
-       - As vs. as  notename.
-       - WARNING: "melodic" stafftype will create the new Complex_staff!
-Examples
-       - Lohman's Viola Quartet (JN)
-       - JS Bach Solo Cello suite II menuet (JN)
-
-
-pl pre27
-
-Features       
-       - option --init
-       - last_duration_mode: default_duration is last duration entered
-       (\duration{\last})
-       - syntax: grouping 2*4 3*8
-       - preliminary multivoice support
-Examples
-       - JS Bach's WTK example added.
-
-Internal:
-       - Text_reg and Script_reg
-*******
-pl 26
-       - Documentation/lelie_logo.png
-       - 8-bit chars for input (see ltest.tex) (MB)
-       - quotes around string now optional
-Bugfixes:
-       - unmatched ] (MB)
-Internal:
-       - print/name methods of Staff_elem
-       - added Request_register
-       - Voice_group_registers, Voice_registers, *_register
-       - Complex_staff
-*******
- Jan 27 '97 
-pl 25
-       - other clefs added, keys typeset properly (MB)
-
-*******
-pl 24:
-       - Lyrics (JCN)
-       - Commands in music-mode (an input feature) (there you are, Mats)
-
-*******
-pl 23:
-       - TODO file inc'd
-       - cadenza mode.
-       - default extension, search path.
-       - error.pod,faq.pod
-       - Markers
-       - configure script
-       - inputfile name in output.
-Internal changes:
-       - scrapped VPATH
-       - Make dependencies per .o
-       - Split Input_* parsing steps to enable marking 
-Bugfixes:
-       - unconnected columns
-
-
-*******
-pl 22:
-       - doco from mpp
-       - repeat signs
-       - | checks for bar in a voice (Barcheck_req)
-Internal changes:
-       - naming (Hungarian notation, svec vs. Array)
-       - cleanup PScore, Score
-       - removed Staff_commands, plugging commands into Staff_column directly
-Bugfixes:
-       - bug noteheadswap
-       - huge memleak fixed; unearthed lots of bugs
-
-*******
-pl 21:
-       - scripts
-       - texts
-       - nplets (triplets!)
-Internal changes:
-       - Move breaking stuff into a separate class Break_algorithm
-       - dependencies for Staff_elem's
-
-*******
-Dec 23 
-pl 20: 
-       - updated doco to .pod
-       - include files from .ly
-Internal changes:
-       - Rational for time measurement
-       - directionalspanner/textspanner
-
-*******
-pl 19:
-       - grouping code: LilyPond can set advanced multibeams.
-Internal changes:
-       - struct Moment
-
-*******
-
-pl 18:
-       - robust Staff_commands
-
-*******
-pl 17:
-       - robust Input_commands
-       - merged Vertical_/Horizontal music
-       - PARTIALs with duration
-       - modularized lexer: multiple runs
-
-*******
-pl 16
-       - notenames configurable
-
-*******
-pl 15
-       - grouping code
-       - multibeams (simple)
-
-*******
-pl 14
-       - symtables from .ly
-       - Input_command
-       - Input_{score/staff}
-
-*******
-Dec  2 
-pl 13
-       - Horizontal/Vertical music
-       - Input_commands
diff --git a/ONEWS b/ONEWS
new file mode 100644 (file)
index 0000000..f936254
--- /dev/null
+++ b/ONEWS
@@ -0,0 +1,1170 @@
+
+This file documents changes in version 0.0
+
+august 1
+
+VERSION 0.1.0
+       
+       - bf: output tempo to track 0 too
+       - bf: don't forget to copy id_str_, so moved  into Music
+
+pl 78.jcn2
+       - INFTY doze fixes
+
+pl 78.jcn1
+       - fix for multi-staff midi: wohltemperirt.ly, standchen.ly
+       - doze fixes
+       - bf: conflily, configure (text)
+*****
+july 31
+pl 78
+       - bf: Midi_instrument 
+       - added  enable/disable defaults to help.
+       - incredibly ugly NAME_MEMBERS(); bug. Immediately changed to 
+DECLARE_MY_RUNTIME_TYPEINFO;
+       - \stem -1 -> \stem \down in input      
+       - bf: slurchar index
+       - configure warnings 
+       - preliminary stuff for multiarch building
+       - #!/usr/bin/perl fixes (AO)
+       - some Makefile cleanups: now faster.
+
+pl 77.jcn2
+       - Midi_instrument
+
+******
+july 29
+pl 77  
+       - some fixes for internal compiler errors 
+derive from Pointer_list with default dtor gives error with -O2
+       - .ini -> .ly
+       - lyrics fix 
+       - Performer beautification: got rid of set_track(), midi_output()
+       - pseudo RTTI for midi-items
+       - bf: Performer*::print() 
+       - links.pod
+       - Voice_element -> Request_chord
+       - fixed flex problems: stdin input works again 
+       - Documentation/Rules.make, make-website via make
+       - spacing: now add basicspace
+
+*******
+july 28
+pl 76
+       - mudela version bumped to 0.1
+       - mudela-book
+       - doco updates, now some stuff in LaTeX
+       - junked book.{ly,tex} example
+       - progress indicator
+       - rhythm.ly updated
+       - removed mf sources from distribution due to (c) stuff
+       - allowal of breaks handled cleanly
+       - junked Subtle_reqs, junked Request_iterator. Request
+       iteration now by Voice_element_iterator
+       - Piano_bar, Piano_bar_engraver, Span_score_bar_engraver, 
+       Span_score_bar
+       - Swallow_performer
+       - removed  Staff_engravers, grouping into Line_group_engraver
+       - Head_column as base for Rest_column,Note_column
+       - Score_column derived from PCol
+       - regurgled Line spacing: interface and implementation
+       separate. Idealspacing moved into Spring_spacer
+       - Gourlay style linespacing
+
+pl 75.jcn6
+       - {lyric,meter,key}-performer
+       - span-brace-* (Removed again. Such is life)
+       - doze compile
+       - midi output, notes only
+       - working midi output -- hacked
+       - doze compile, mingw32 configure (still triggers gcc int. comp err)
+
+pl 74pre.jcn2
+       - mi2mu fixes after scott snyder <snyder@d0sgif.fnal.gov> [sss]
+       - mi2mu update for mudela 0.0.61
+       - conflily fixes
+
+*******
+july 21
+
+pl 75
+       - inbook.ly & book.tex example.
+       - natural width: linewidth = -1.0\cm
+
+pl 74pre.jcn1
+       - oversimplified midi output thru performer hierarchy
+       - bf: Spanner::doprint
+
+pl 72pre.jcn1
+       - naming fixes; some iter*() explicitations
+        - removed acceptor.hh
+       - *performer*: second draft of midi (audio/...)
+
+*******
+july 9
+
+pl 74pre
+       - Input_engraver -> Input_translator
+       - bf: span start/stop is now a "used" col.
+       - Rest_column/Rest_collisions bugfixes
+       - bf: crescendi.
+       - Spanner do_print()
+
+******
+july 7
+pl 73pre
+       - some refs doco.
+       - move Input_engraver into Paper_def
+       - junk Interpreter
+       - naming: Request_engraver -> Engraver, 
+       - Music_iterator::next() -> process_and_next()
+       - junk Voice_engravers
+       - Span_bar, Span_bar_engraver
+       - Vertical_align_engraver
+       
+*******
+july 2
+pl 72pre
+       - \paper{} syntax: var = 1.0\pt;, with an Assoc array
+       - sketch of MIDI Performer classes.
+       - bf: memleak in parser
+       - naming: Acceptor -> Translator
+       - input: bf collisions.ly, scales.ly
+       - bf: [r8 c8]
+       - naming: Register -> Engraver
+       - force \\ on identifiers
+       - doco updates
+       - musixtex T73 fonts
+
+pl 70.mb
+       - bf: find syntax in Variables.make
+*****
+july 1
+pl 71pre
+       - nested \melodic and \lyric constructs
+       - init id's, Input_register aliases.
+       - bf: notehead x-swap 
+       - bf: auto-keys.
+       - bf: first clef
+       - junked \init_end; construct
+       - Preparatory work for MIDI output:
+               * Acceptor as baseclass for Register_group_register
+               * Global_acceptor as interface of Register to Score
+       - bf: empty voice
+       - Lyrics: partially working
+       - some doco updates (junks, mostly)
+
+
+******
+june 30
+
+
+pl 70pre
+       - bf: text Script
+       - bf: Script::dir_i_ checks.
+       - bf: script stacking
+       - bf: Text_spanner::do_subst.
+       - bf: Text_spanner::Text_spanner(Text_spanner&)
+       - bf: script priority read from script.ini
+       - bf: Script_def::do_equal_b
+       - bf: script dims.
+       - mudela: ; obligatory for \paper {}.
+       - some cosmetic changes involving RTTI macros
+
+*******
+june 29
+pl 69pre
+       - bf: whole rest position, whole/half rest dots.
+       - bf: scripts
+       - reg termination
+       - centered bars
+       - bf: init of Tie::dir_i_ 
+       - bf: Staff_side depends on staff_sym_
+       - bf: Script::do_substitute_dependency() now implemented
+       - more print info (also in output)
+       - bf: Vertical_align_element
+       - stemless beams now allowed (with warning)
+       - bf: Rest_column::stem_l_ init
+       - merge rests.ly with collisions.ly
+
+pl 67.jcn3
+       - rests under beam [c8 r c]
+
+pl 67.jcn2
+       - first attempt at rest collisions
+       - rests.ly
+
+pl 67.jcn1
+       - beam stem length: beams.ly
+       - bf: mingw configure
+       - re: conflily
+
+******
+june 26
+pl 68pre
+       - doco: other-packages.pod, lots of lilyliterature.pod
+       - last duration mode now is default.
+       - some OpusTeX stuff.
+       - bf Y2K in convert-mudela
+       - Grand rewrite of Music/Register stuff:
+         * separation of Y and X-elt-groups
+         * Registers: info up: broadcasts, info down: get_xxx_info()
+         * Registers: try_request works from bottom to top of tree.
+         * Score_elem empty_b_ and transparent_b_ flag
+         * Junk Staff_column, and find the requests while walking the
+         Voices.
+         * Score_register
+         * Staff_group, Score_request_register.
+         * align key/Meters/bar across staffs
+         * junked Staff, Staff_column, Staff_walker, Complex_walker,
+           Request_column Pulk_voice, Pulk_voices, Walker_registers,
+           Voice_element, 
+           Input_score, Input_staff, Input_music and a lot of
+           parserjunk.
+         * mudela: lots of structure changes : now much simpler
+         * generation of pre/postbreak items now in Score_elem with deps.
+       
+       - bf: make_patch explanation
+       - bf: make install TeX stuff
+       - mudela: . mandatory for REALs
+
+
+pl 67
+       - damped beamslope after wanske
+
+******
+june 3
+pl 67
+       - sketch of Music classes
+       - General_script_def as baseclass for Text_def and Script_def
+       - bf: clean lib/out/liblily.a
+       - bf: rests shorter than 1/4
+
+pl 66.jcn3
+       - bf: make uninstall
+       - conflily
+       - f: some pedaling
+       - plet hack removed :-( [ c c c ]2/3 -> [2/3 c c c ]1/1
+
+pl 66.jcn2
+       - bf: bar, Hilfslinie
+       - bf: configure for mingw32
+
+pl 66.jcn1
+       - WIN32 -> WINDOWS32, more win32->windows32
+       - some GNU/Linux changes
+       - cygnus b18 / mingw update
+       - doze compile; bf: p-score.cc compares
+       - reincluded toccata fixes
+       - small stuff: vi tags, typos, bibl
+
+******
+may 27
+pl 66
+       - make_website --jpeg, --png and --gif
+       - win32 -> windows32
+       - bf: Score_elem::TeXstring assert fail
+       - bf: headswap with stemdown
+       - bf: broken tie
+       - bf: broken slur
+       - bf: accidental dims
+       - bf: measure bar width
+       
+
+******
+may 26
+
+pl 65
+       - bf pathfind /root/file
+       - massive Score_elem rewrite:
+         * group_element_i_ count
+         * support for removing an individual Score_elem cleanly.
+         * moved dep stuff into class Directed_graph_node
+         * Score_elems can be copied and deleted freely.
+         * junk PStaff
+         * Spanner_elem_group
+         * Line_of_{score,staff} now are Score_elems
+         * clean dep handling upon deletion
+         * delete unbroken spanners
+         * added a break_processing round.
+         * Super_elem
+       - junk Complex_staff, 
+       - clean {lily}?proto.hh
+       - Element_group
+       - Score_elem now as virtual base class everywhere
+       - naming: Staff_elem -> Score_elem
+       - bf: make in toplevel dir
+       - bf: broken tie y-pos
+       - bf: sharing 4th, 8th and 16th noteheads 
+       - bf: overlapping chords. <\multivoice c d >
+
+pl 64.wl
+       - new stem direction code
+       - bfs: wohltemperirt.ly (thanks, Werner)
+       - bf: stem direction
+
+pl 63.jcn2
+       - doze compile
+
+pl 63.jcn1
+       - bf: mi2mu mudela commands
+       - bf: mi2mu tracks
+       - mi2mu quantify tuning
+       - mi2mu TODO
+
+*********
+may 16
+pl 64
+       - exe's now built in out/
+       - toplevel Makefile dep from make/Toplevel.make.in
+       - make_website: add version footer
+       - make_website: bf dist *.txt
+       - bf: fix loose bars :  \meter 4/4; c1.  
+       - Staff_elem -> Score_elem
+       - bf <cis cis>
+       - vbrace lookup
+       - resync barcheck
+
+*******
+
+may 15
+pl 63
+       - bf: segfault during MIDI output  with mi2mu output.
+       - kludge: parse error beyond eof
+       - don't read ini if toplevel file not found
+       - accumulate \kern in TeX output.
+       - bf: try to prevent long lines; TeX breaks on them.
+       - naming: Pointer->Link, IPointer->Pointer
+       - bf: \plet didn't work (MB)
+       - GMP manifesto.
+
+pl 61.jcn4
+       - mi2mu -p -s16 fugua2.midi getting better!
+         plus factor 2 mi2mu speedup (fugue2.midi 5.50user)
+       - bf: Duration_convert quantify threshold down
+       - bf: (on quantify): tcols quantified; no silly voices
+
+pl 61.jcn3
+       - lily parsing speedup: backup rules for lexer.l
+       - bf: mi2mu, using midi_voice list...
+
+pl 61.jcn2
+       - all in all mi2mu speedup of about factor 8 since pl61
+        (fugue.midi 82.72user to 10.30user on a 586.133)
+        what about lily?
+       - binary search on track-columns
+       - mi2mu IP*list to Array (implications?!) conversion
+       - mi2mu parsing speedup: backup rules for midi-lexer.l
+       - bf: zero denominator
+
+**********
+may 14 
+pl 62
+       - make clean bf: remove lex & yacc files too 
+       - added kludge in case measure too long 
+       - added kludge in case of unconnected columns.
+       - kludged columns get error marker
+       - kludged lines get error marker
+
+
+pl 61.jcn1
+       - smarter + faster duration-convert using Array
+       - bf: mi2mu compilation/duration-conversions
+       - lots faster mi2mu, hopefully does type 1 too...
+pl 60.jcn1
+       - mi2mu handles non-quantified rests, try mi2mu -b wtk-i/fugue2.midi
+
+
+       
+**********
+pl 61
+       - scales.ly bugfix: dimensions default to ((0,0), (0,0))
+       - naming: PointerList->Pointer_list
+       - tied notes don't get accidental
+       - bf: crescendo size
+       - fixes: make_patch,
+       - bf: _"text" direction
+       - mailing list into lilypond.pod
+
+pl 60.mb
+       - set_flower_debug: Warning if -d is used when NPRINT is defined.
+       - Fixed several TeX details. vcenter renamed since it interfered
+         with LaTeX. Position of accents changed.
+       - New example; scripts.ly
+       - table_sixteen: added scriptdefinition (Lilypond breaks if a
+         script is defined without dimensions).
+       - bf: ifndef typos in p-score.cc, choleski.cc
+       - bf: Slur::do_post_processing(), whole notes caused SIGSEGV.
+
+(ascension break :-)
+*******
+pl 57.jcn4
+       - mi2mu handles rests (quantified only)
+       - fixed configure buglet
+        - "!date" Fri May  2 02:18:12 MET DST 1997
+
+pl 60
+       - Request_register::get_feature(), tie direction, Slur direction
+       - lilypond output is now directly texable. 
+       - make_website checks return status
+
+*******
+may 5
+pl 59
+       - Slur now into voicegroups, and take stems into account.
+       - bf: rest size in table.
+       - split Slur in baseclass Bow
+       - Tie, Tie_req, Tie_register
+
+******
+may 2
+pl 58.jcn1
+       - bf: toccata-fuga-E.ly
+
+pl 57.jcn4
+       - mi2mu handles rests (quantified only)
+       - fixed configure buglet
+        - "!date" Fri May  2 02:18:12 MET DST 1997
+pl 58
+       - lexer cleanup
+       - national chars in lyrics
+       - \stem 2; bf
+       - long comments: %{ %} 
+       - *.ini mode bf
+       - bf: partial may be everywhere
+       - bf: meterchange not at start of measure
+       - some doc updates
+       - bf: stem too long if stem is down.
+
+pl 57.jcn3
+       - dank je schat, voor wtk-i
+       - mi2mu tries to handle rests
+        - "!date" Thu May  1 02:34:04 MET DST 1997
+       - maak je het niet te laat schat?
+         XXXX HWN
+
+pl 57.jcn2
+       - small toccata-fuga-E.ly fixes
+       - \bar "||"; is now doublebar, "|." is finishbar
+       - collision hshift fix, with on-line assistance
+******
+pl 57
+       - lots of TODO doco
+       - text alignment bugfix
+       - bugfix Voice_group_regs::get_register_p() now is actually called too
+       - bugfix init  of Text_item::pos_i_
+
+pl 56.jcn1
+       - toccata-fuga-in-E.ly, excerpts with real-life collisions
+       - \{l,r}{b,f}{toe,heel} --- using cmsy fonts...
+       - pedal.ly 
+
+pl 55.jcn1
+       - mi2mu man page
+       - make doc fixlet
+       - \[lr]heel \[lr]toe scripts (happy pedal studies, pa)
+       - lyric with width
+       - removal of some example files
+
+pl 56.mb:
+       - last duration fix
+       - makefile fixes
+       - space rest
+       - swedish note name update
+
+******
+pl 56
+       - Massive Rest/Stem/Collision/Note_column rewrite: resolve
+notehead/rest ambiguities and bugs. eg, [c8 r8 c8] 
+
+pl 54.jcn1
+       - standchen.ly: repeats; lyricii to end
+       - convert-mudela: help + usage
+       - fixed midi key/meter-change (triggered by martien.ly) bug
+
+******
+April 23
+pl 55
+       - staff-side robustification
+       - script-on-rest bug
+       - doc update
+       - transpose syntax
+******
+pl 54
+       - bugfix Colhpos.cc::OK assert fail.
+       - Inclusion of MusixTeX MF files, 
+       - detection of MF dir
+pl 53.hwn
+       - stacked lyrics 
+       - configure/make buglets.
+******
+pl 53
+       - spurious accidental bug.
+       - simultaneity check.
+       - added AUTHORS.pod
+       - convert-mudela auto from guess
+       - include -> \include
+       - change order of opening parse/init file 
+       - Pulk_voice, Pulk_voices
+       - Request_column
+       - revised request-from-voice extraction. Now much faster
+
+******
+april 17
+pl 52
+       - Buildroot RPM
+       - tex-prefix and tex-dir sep'd (here you are jan)
+       - convert-mudela framework
+       - Collision_register, Collision
+       - \hshift 1; input
+       - Features changed
+pl 50.jcn1
+       - LILYINCLUDE dir searched before DIR_DATADIR(?)
+       - lily reads from stdin again (but does not now when to stop)
+******
+pl 51
+       - transposition bugfix + doco
+       - LilyPond -> GNU LilyPond
+       - bugfixes for Staff_side and Note_column*
+       - wohltemperirt: complete
+
+******
+april 11
+
+pl 50
+       - merge rest / notehead.
+       - Staff_side as a base class for most "staff-side" symbols.
+       - version check
+       - Note_column_register, Note_column
+       - multiple scripts
+
+********
+april 8
+pl 49.jcn1
+Bugfix
+       - configure[.in], make/Configure_variables.make.in c++ (=doze fix)
+       - "configure; make" ok for doze, win32 target may be removed now
+       - win32/gcc 2.7.2 compile fixes -- why does this all compile 
+           (without warnings, why can-t i even trigger warnings) under 
+           linux/gcc-2.7.2.1?  it's quite a tedious job fixing this 
+           shit _on doze_ all the time.
+           * fixed #includes global-regs.cc, staff-info.cc, staff.cc
+           * key.hh:Key() -> Octave_key()
+           * added missing lily/include/input.hh: Input( Input const& )
+       
+pl 49
+       - lsm template
+       - clef in cadenza mode.
+       - notename clear
+       - \command bla; for \meter, \clef, \octave etc.
+*******
+pl 48
+       - notenames init
+       - Duration order -> grouping
+       - broken key s
+       - default octave
+
+******
+april 3
+pl 47
+       - dynamic flowerlib
+       - Input mods: now use Source_file iso Sources
+       - makefile lib deps restructured
+       - make_website now produces in out/
+
+pl 46
+       - examples.pod
+       - LILYINCLUDE env var.
+       - push/popgroup
+       - website updated
+       - Swallow_register
+       - Lyric_register.
+       - Staff_sym_register
+       - user settable register config
+       - struct Input now used iso defined_ch_C_
+       - Walker_registers and Staff_registers separated
+       - dynamic-reg -> hairpins
+
+pl 44.jcn2
+       - doze configure/compile fixes
+       - doze make refixed
+       - faq
+       - install mudela manpage too
+       - RedHat spec lilypond.spec fixed
+       - target: rpm (make RedHat packages)
+
+******
+Mar 26
+pl 45
+       - Removing unused Voice_regs & Voice_groups
+       - -O2 bugfix
+
+pl 44.jcn1
+       - merged 42.3 42.jcn4 code trees (see stuff below)
+       - moving towards Mudela 0.1 (again)
+           * keyword "music" dropped for horizontal music
+           * keywords "\lyric" "\melodic" introduced, e.g.:
+               melody = \melodic { c c | g g }
+           * removed level of indirection:
+               - staff initialisable with music identifier list: 
+                   \staff{ global melody }
+               - \score and staffs alike
+       - gnu standard(?) help texts
+       - configure "creates" toplevel Makefile from make/Toplevel.make
+
+Bugfix
+       - fixed mi2mu
+       - write meter to track0 too...
+       - default octave
+       - new Sources in My_midi_lexer: sourcefile_p_ = get_file_l(): oeps.
+         (ain-t hungarian grand?)
+
+Examples
+       - updated for mudela 0.1
+
+******
+pl 44
+       - naming: _c_l -> _C
+       - pure parser, My_lily_parser
+       - ''a iso ``a
+       - Includable_lexer
+       - junk Input_file
+       - Duration in parser, Duration restructuring
+       - grandiose lexer hax. Flex should be fixed, really.
+       Lexer much faster now.
+       - opps. mi2mu broken
+
+******
+pl 43
+       - transposition.
+       - $variable&@name 
+       - warnings if incorrect mode
+       - missing scsii measure
+       - declaration used check.
+       -
+
+pl 42.jcn4
+       - lily writes midi meter/key changes from requests
+       - mi2mu: 
+         + write mudela 0.1
+         + write bar change requests
+         + more tunable quantisation
+
+Examples
+       - half-new-menuetto.ly converted to mudela -almost- 0.1
+       - new mi2mu of bach's wtk pre1/fugue1
+
+pl 42.3 (jcn version)
+        - oeps, branched source tree
+
+pl 42.hwn3
+       - const naming change (T const <-> const T)
+       - Mudela 0.1 (roughly the same as below..)
+
+pl 42.3
+       - moving towards Mudela 0.1:
+           * all keywords must be preceded by backslash '\'
+           * explicit lexer switches '$' and '@' dropped
+           * keyword "music" dropped for horizontal music
+           * keywords "\lyric" " introduced, e.g.:
+               melody = \melodic { c c | g g }
+           * staff initialisable with music identifier: 
+               \staff{ melody }
+           * chords: < c e >
+           * octavate ''c`` 
+           * \meter{ 2/4 }
+           * \octave{ ''`` }
+        - configure sets CXX (to c++, commonly)
+Internal
+       - renamed lexer.hh, mylexer.cc My_flex_lexer to my.lily.lexer.*
+
+pl 42.2
+       - new lilyinput (Mudela 0.1) doc.
+Examples
+       - new-twinkle.ly (in Mudela 0.1, hopefully)
+
+pl 42.1
+       - further Makefile revamping.
+       - moved flowerlib
+
+*******
+pl 42
+
+
+pl 41.hwn3
+       - struct Lexer_prefs
+       - parser bug
+       - make uninstall
+
+pl 41.hwn2
+       - make file rehack
+       - spec update
+       - make install
+       - detect TeX directory
+
+pl 41.hwn1
+       - cygnus configure,
+       - updated versioning 
+       - install.pod
+  
+pl 41.jn1
+Bugfix
+       - doze compile
+*******
+pl 41
+       - release
+
+pl 40.3
+       - all of the above
+       - hw's configure.in
+       - p-name.xx fixes
+
+pl 40.hwn1
+       - hairpin dynamics
+       - notename now as identifier. Parser/lexer cleanup
+
+pl 40.2
+       - mi2mu --blonde-durations, --no-silly options.
+       - mi2mu starts to look promising, see examples
+Examples
+       - pre1.midi.ly, fugue.midi.ly
+Internal
+       - Duration handles blonde midi-durations
+       - More settings for Duration_convert
+       - lily writes meter too (ugh, howto?)
+Bugfix
+       - mi2mu auto track number fix
+       - mi2mu / lily Midi_tempo fixed/added
+
+pl 40.1
+Bugfix
+       - lily midi output track 0 name
+       - mi2mu tempo fixed
+       - make out/make and out/make/Site.make in configure script!
+       - mi2mu double newline fix
+
+
+******
+Mar 11
+pl 40
+       - release
+
+pl 39-5
+       - own versioning for mi2mu: 0.0.10
+       - some file renaming mi2mu
+pl 39-4
+       - all of the above
+
+pl 39-hwn2
+       - last bar bugfix
+Internal
+       - simple dynamics
+       - experimental RPM spec.
+       - doco update.
+
+pl 39-3
+       - all of the above
+       - m2m renamed to mi2mu
+       - better line breaking in mi2mu
+       - (somewhat broken) progress indicator for mi2mu 
+       - mi2mu output === lily input (in names and durations,
+         always assuming voices > 1 though)
+
+Bugfix
+       - midi: note on/off only once per pitch per track 
+         (sending all note-on events introduces cool mi2mu feature)
+       - make clean removes deps too
+       - mi2mu notename/accidental/octave, and key fixed
+
+Internal
+       - auto create of out-dirs, config headers, using tag file .GENERATE
+
+Examples
+       - stanchen.ly debugged
+
+pl 39-2
+       - configure script help and in topdir again, duh.
+       - auto configure upon virgin make
+       - configured makefile stuff in make/out/
+
+
+********
+pl 39-1
+       - doze target (for 16 bit dos xcompiler: gcc-go32)
+Internal
+       - make/User.make; C..FLAGS sorted out
+Bugfix
+       - make clean...
+
+pl 39
+       - new make structure, featuring:
+           * top-level/sub-level build
+           * auto custom-library dependencies/build
+           * top-level/sub-level dist
+           * minimal(? can even smaller) specific Makefiles
+           * which makes for simple lib/exe module split (make/Template.make)
+           * integrated flowerlib
+           * all stuff into subbirs (make/Stuff.make)
+           * all headers into <module>/include dirs (make/Include.make)
+           * all output into <module>/out (executables into bin/)
+           * more make features, like make config, make help
+           * small lily lib
+           * lilypond-x.x.x/.version for toplevel lily version
+           * lilypond-x.x.x/<module>/.version for <module> version (eg: flower)
+           * versioning using additional optional MY_PATCH_LEVEL 
+               for easy make_patch
+
+       - bin/cptogen
+
+Internal
+       - generic m2m header: m2m.hh
+
+Bugfix
+       - small fixes, make, dist, configure
+
+pl 38-5
+       - all of the below, e.g. new filenames and new makefile 
+         structure patches merged
+******
+pl 38
+
+Internal
+       - great filename renaming operation with - convention.
+       - printing methods for paper_def/lookup/symtab(s)
+       - untied all registers from complexwalker. Now registers are
+intrinsically hierarchical. All walker communication is done via a
+"top level" register.
+
+pl 37-3
+       - m2m handles voices
+       - instrument, track_name, copyright/left stuff for m2m/ly
+
+Internal
+       - Midi_voice
+
+pl 37-1
+       - text, key, tempo event in midi output/ly input
+
+Internal
+       - simple makefile structure, allows for multiple projects
+
+******
+pl 37
+
+
+Documentation
+       - language.pod as starting point for mudela devel.
+
+       - Jan's patches:
+Features
+       - m2m patchy --no-triplet option;
+         lilypond accepts m2m's real midi output (hand-add red tape)
+       - m2m output only valid durations, resync option wip
+       - m2m produces .ly output
+Internal
+       - simpler and better naming for Duration*
+       - the great String renaming / index to base=0 change
+       - Track_column, Lily_stream
+       - Duration, Plet, Duration_convert taking load off duration calc.
+Bugfix
+       - m2m duration calc
+
+
+
+******
+pl 36
+       - Jan's patches:
+       - do MIDI rests cleanly.
+       - lily/m2m: time and tempo fixed for metric timing
+Internal
+       - Midi_tempo
+       - m2m parses more midi stuff (all of bach-wtc); timing??
+       - m2m recognises some commandline options
+Examples
+       - fixed midi.ly
+
+*******
+Feb 25
+pl 35
+       - Register_group
+Bugfix
+       - alignment of breakable items.
+
+*******
+pl 34
+       - better midi syntax.
+       - --midi,-M option.
+       - preliminary midi2mudela (/mudela2midi) converter: m2m (JCN)
+Internal
+       - m2m sources: midi-*; (JCN)
+       - new Midi_walker, fixes several MIDI bugs.
+       - junked Midi_staff, Staff_column children, Midi_walker
+       - Midi_output
+
+pl 33-1
+       - m2m parses midi
+Internal
+       - Binary_source_file
+       - Source_file::error_str simplified
+*******
+pl33
+Examples
+       - Swedish notenames (MB)
+
+pl pre33-2
+
+Bugfix
+       - midi pitch
+       
+Features
+       - Jan's patches, see below
+Bugfix
+       - some midi bugfixes.
+
+pl pre33-1 (JCN)
+
+
+       - midi output using pitches iso notename
+Examples
+       - added midi output (some midi output files broken?)
+       - all melodic fixed (except for error.ly:-) 
+       - midi.ly
+Bugfix
+       - midiwalker line break
+       - empty/nonexistent include at top of ly
+       - midi #tracks
+       - midi pitch c0
+       - midi poor man-s staff dynamics
+Internal
+       - Midi_column, Midi_staff, Midi_walker
+
+pl pre33 (JCN)
+       - Jan's patches, see below
+
+Features
+       - simple plet notation (JCN)
+       - lyrics centred, but no fully suppored? (JCN)
+Internal
+       - Midi_stream 
+       - Mididef
+       - Midi_item, Midi_pitch, Midi_duration
+       - Midi_chunk, Midi_header, Midi_track
+       - preparations for midi output 
+       - no exit upon context error (JCN)
+       - converted some "warnings" to errors; no output (JCN)
+Bugfix:
+       - simple plet bugfix
+Examples
+       - updated standchen, menuetto (JCN)
+       - new plet notation (JCN)
+       - plet.ly (parse and spacing tests) (JCN)
+
+*******
+pl 32
+Features
+       - multiple meters, see rhythm.ly
+       - skip syntax/Skip_req
+       - score_wide_music: commands in staff now override commands in score.
+Internal:
+       - command carnage
+       - Key_register
+       - Bar_register
+       - Meter_register
+       - meters now kept in baseclass Staff_walker
+       - Score_walker (to ease MIDI output)
+Doc:
+       - Hungarian doco added to CodingStyle
+
+pl 32-1
+       - music processing speedup
+       - website added to doco
+       - clef must *inside* music
+       - fixed spurious "beam too narrow" messages.
+Internal:
+       - merge musical / non-musical staff_column
+       - musical/ non-musical requests
+       - Clef_register
+       - split up request.hh, Musical_req vs. Nonmusical_req
+*******
+pl 31
+
+Examples
+       - Coriolan example (JN)
+       - standchen updated
+Bugfix
+       - calcideal assertion bugfix
+*******
+Feb 12 13:55
+pl 30
+
+Features
+       - better multivoice spacing
+       - move rest in multivoice staff
+       - errors in TeX output now warnings
+       - progress indicator
+       - music processing speedup.
+Internal
+       - make spanner for staffsym; scrap Line_pstaff
+       - scrap simplestaff (Rhythmic_staff temporarily disabled)
+       - docxx 3.0 format comments
+       - split register source files
+       - hardcoded dimensions compile time
+       - Lookup::tex_hairpin
+Bugfix
+       - non G-clef clefs
+       - script junking (2x)
+       - empty files
+       - beam::center (plet position!)
+       
+pl 29
+       - multiplatform Makefile (JN)
+       - context errors: bugfixes (JN)
+*******
+pl 28
+
+Internal
+       - idealspacing slightly better for multivoice.
+Doc
+       - Request_register
+Bugfix
+       - Script.cc : float exception (MB)
+       - Request::Request(Request) copying of definition pointer (JN)
+       - cleaned dependencies for broken spanners
+       - stupid typo in Staff_elem::post_processing()
+       - init of hpos in PCol::PCol
+       - Word_wrap::solve() bug 
+*******
+pl 27
+       - preliminary WIN32 support (JN)
+Features
+       - errors converted to warnings (JN)
+       - context errors (JN)
+       - As vs. as  notename.
+       - WARNING: "melodic" stafftype will create the new Complex_staff!
+Examples
+       - Lohman's Viola Quartet (JN)
+       - JS Bach Solo Cello suite II menuet (JN)
+
+
+pl pre27
+
+Features       
+       - option --init
+       - last_duration_mode: default_duration is last duration entered
+       (\duration{\last})
+       - syntax: grouping 2*4 3*8
+       - preliminary multivoice support
+Examples
+       - JS Bach's WTK example added.
+
+Internal:
+       - Text_reg and Script_reg
+*******
+pl 26
+       - Documentation/lelie_logo.png
+       - 8-bit chars for input (see ltest.tex) (MB)
+       - quotes around string now optional
+Bugfixes:
+       - unmatched ] (MB)
+Internal:
+       - print/name methods of Staff_elem
+       - added Request_register
+       - Voice_group_registers, Voice_registers, *_register
+       - Complex_staff
+*******
+ Jan 27 '97 
+pl 25
+       - other clefs added, keys typeset properly (MB)
+
+*******
+pl 24:
+       - Lyrics (JCN)
+       - Commands in music-mode (an input feature) (there you are, Mats)
+
+*******
+pl 23:
+       - TODO file inc'd
+       - cadenza mode.
+       - default extension, search path.
+       - error.pod,faq.pod
+       - Markers
+       - configure script
+       - inputfile name in output.
+Internal changes:
+       - scrapped VPATH
+       - Make dependencies per .o
+       - Split Input_* parsing steps to enable marking 
+Bugfixes:
+       - unconnected columns
+
+
+*******
+pl 22:
+       - doco from mpp
+       - repeat signs
+       - | checks for bar in a voice (Barcheck_req)
+Internal changes:
+       - naming (Hungarian notation, svec vs. Array)
+       - cleanup PScore, Score
+       - removed Staff_commands, plugging commands into Staff_column directly
+Bugfixes:
+       - bug noteheadswap
+       - huge memleak fixed; unearthed lots of bugs
+
+*******
+pl 21:
+       - scripts
+       - texts
+       - nplets (triplets!)
+Internal changes:
+       - Move breaking stuff into a separate class Break_algorithm
+       - dependencies for Staff_elem's
+
+*******
+Dec 23 
+pl 20: 
+       - updated doco to .pod
+       - include files from .ly
+Internal changes:
+       - Rational for time measurement
+       - directionalspanner/textspanner
+
+*******
+pl 19:
+       - grouping code: LilyPond can set advanced multibeams.
+Internal changes:
+       - struct Moment
+
+*******
+
+pl 18:
+       - robust Staff_commands
+
+*******
+pl 17:
+       - robust Input_commands
+       - merged Vertical_/Horizontal music
+       - PARTIALs with duration
+       - modularized lexer: multiple runs
+
+*******
+pl 16
+       - notenames configurable
+
+*******
+pl 15
+       - grouping code
+       - multibeams (simple)
+
+*******
+pl 14
+       - symtables from .ly
+       - Input_command
+       - Input_{score/staff}
+
+*******
+Dec  2 
+pl 13
+       - Horizontal/Vertical music
+       - Input_commands
diff --git a/README b/README
index 39909a29c39d082eb62ea60e671435a36910acff..81977e36033fc59448d3583d01a31af5e0cfbfeb 100644 (file)
--- a/README
+++ b/README
@@ -5,15 +5,6 @@ GNU LilyPond which converts music definition files into visual or
 audio output: it can typeset formatted sheet music in TeX and 
 and (mechanical) perfomances to MIDI files.
 
-0.
-
-LilyPond is known to have a minor bug if  you use glibc; we will look into it
-Please download 0.1.1 when it's available.
-
-LilyPond exhibits a g++ bug on Solaris 2.5 (The stack frame gets corrupted by
-a constructor) if you compile with -O2. We don't know workarounds 
-
-
 1. VERSIONING
 
 if you have downloaded a
@@ -23,6 +14,7 @@ if you have downloaded a
 version, then this is version is *not* meant for producing nice output
 (but to keep your patchsets up to date). It might not even compile.
 
+
 2. REQUIREMENTS
 
 For the compilation and running of LilyPond you need some additional
@@ -30,11 +22,13 @@ packages. The most unusual one of this are the mf sources to
 MusixTeX. Please refer to the installation instructions on how to
 obtain and install them.
 
+
 3. INSTALLATINON
 
 For your convenience, a formatted copy of the INSTALL instructions are
 in the toplevel directory, as INSTALL.text
 
+
 4. DOCUMENTATION
 
 Please refer to the directory Documentation/ for the real doco.
@@ -45,6 +39,8 @@ and then do this:
        make doc
 
 You can also simply read the .pod sources. They are ASCII text. 
+.pod is the documentation format of perl (see perlpod(1))
+
 
 5. COMMENTS
 
diff --git a/TODO b/TODO
index 78cecc175ec03229882fe049cd19edfba904f3a3..f617a2a566520854bcf4ffa5ae9defaf259e9fa9 100644 (file)
--- a/TODO
+++ b/TODO
@@ -6,6 +6,27 @@ done, or is an idea that I want to think about
 Most of the items are marked in the code as well, with full explanation. 
 grep for TODO and ugh/ugr
 
+       * generate stuff in out/default, out/sun5-irix etc iso out/ 
+and out-sun5/
+
+       * derive dstream, texstream from ostream?
+
+       * A typical pop-music example.
+
+       * check libtool, automake
+
+       * have make dist produce tarball in out/ directory.
+
+       * write a faster Spring_spacer ( without matrices if possible )
+
+       * A decent scalar type
+
+       * relate energybound to linelen unitspace fontsize etc.
+
+       * naming of Voice_group/Voice
+
+       * benchmark band_matrices.
+
        * versioning stuff (cvt mudela, mudela, etc.)
 
        * get rid of gif files.
@@ -23,6 +44,13 @@ grep for TODO and ugh/ugr
        * lyrics in chords still fuck up.
 
        * rewire acknowledge_element() logic with a process_acknowledged()
+       
+       * Global type registration.  
+
+               My_class * p = create_object( My_class )
+               Type t = get_type ( *p );
+               if ( t <= get_type( q ))
+                       ..
 
        * progress when creating MIDI elts.
 
@@ -32,16 +60,36 @@ grep for TODO and ugh/ugr
 
        * piano staff
 
-       * implement better breaking algorithm
-
        * update 20 pt table
 
        * decent TeX page layout
 
        * a tutorial
 
+3RD PARTY BUGS:
+
+       * bugreport to doc++ devel: struct not in class hier; public
+       virtual baseclasses
+
+       * DOC++ bugs/ newer version?
+
+       * Rational infty(HUGE_VAL) on glibc / w32
+
+       * Fix profiling. gprof bugreport?
+
+       * read from mmap directly: bugreport to flex developers->
+       yy_scan_buffer in C++..
+
+       * (where are the) gcc compile warnings on linux
+       
+
 PROJECTS
 
+       * input converters
+       - NIFF?
+       - ABC? 
+       - SMDL?
+
        * add to MIDI output:
        - tempo change
        - repeat
@@ -134,16 +182,10 @@ PARSER
 
 BUGS
 
-       * fix mysterious Flex malloc bug 
-
        * should adjust stemlength for flag number.
 
        * lilypond - -> crash
 
-       * standchen triool beam up/down
-       
-       * (where are the) gcc compile warnings on linux
-       
 SEVERELY LACKING:
 
        * SPEED!
@@ -214,11 +256,6 @@ SMALLISH PROJECTS
 
        * shared lib on Solaris too.
 
-       * bugreport to doc++ devel: struct not in class hier; public
-       virtual baseclasses
-
-       * get rid of init_end;
-
        * cleanup lily-proto.hh and proto.hh
 
        * half-sharps, half-flats
@@ -250,9 +287,6 @@ SMALLISH PROJECTS
 
        * parshape
 
-       * read from mmap directly: bugreport to flex developers->
-       yy_scan_buffer in C++..
-
        * binsearch/hash for identifiers
 
        * stafftypes: voice names/ instrument names.
@@ -303,8 +337,6 @@ FUTURE
 
        * guitar chord
 
-       * better beamslope calculation: QLP for beams?
-
        * Text_crescendo
 
        * clean solution for staffsize in items.
diff --git a/VERSION b/VERSION
index e014f462b8c18ae9d2eed09f879faf0693221c1b..4f48ae745f6be2d7ede5409024971dfc5a9e95c1 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -1,8 +1,6 @@
 TOPLEVEL_MAJOR_VERSION = 0
 TOPLEVEL_MINOR_VERSION = 1
-TOPLEVEL_PATCH_LEVEL = 0
+TOPLEVEL_PATCH_LEVEL = 1
 
 # use to send patches, always empty for released version:
-# include separator: ".postfix", don't use -,
-# it makes rpm barf
 TOPLEVEL_MY_PATCH_LEVEL = 
diff --git a/aclocal.m4 b/aclocal.m4
new file mode 100644 (file)
index 0000000..5f62970
--- /dev/null
@@ -0,0 +1,85 @@
+
+AC_DEFUN(AC_JUNK_ARGS, [
+])
+
+AC_DEFUN(AC_LILY_WARN, [
+    AC_MSG_WARN($1)
+    warn_b=yes
+])
+
+dnl should cache result.
+dnl should  look in $prefix first.
+
+AC_DEFUN(AC_TEX_PREFIX, [
+    
+
+    AC_MSG_CHECKING(TeX/MF root dir directory)    
+
+    find_root_prefix="$prefix"
+    
+
+    test "x$find_root_prefix" = xNONE && find_root_prefix="$ac_default_prefix"
+    find_texpostfix="";
+    for postfix in "/lib/tex/" "/lib/texmf" "/lib" "/tex" "/texmf"; do
+       find_texprefix="$find_root_prefix$postfix"
+       if test -d $find_texprefix; then
+           find_texpostfix=$postfix
+           break;
+       fi
+    done
+    
+    if test "x$find_texpostfix" = x; then
+       find_texpostfix='/lib/texmf/tex'
+       AC_LILY_WARN(Cannot determine the TeX-directory. Please use --enable-tex-prefix)
+    fi
+
+    find_texprefix="$find_root_prefix/$find_texpostfix"
+
+    # only assign if variablename not empty
+    if test x != "x$1"; then
+       $1='${prefix}'/"$find_texpostfix"
+    fi
+    AC_MSG_RESULT($find_texprefix)
+
+])
+
+# find a directory inside a prefix, 
+# $1 the prefix (expanded version)
+# $2 variable to assign
+# $3 the directory name 
+# $4 description
+AC_DEFUN(AC_FIND_DIR_IN_PREFIX, [
+    
+    AC_MSG_CHECKING($4 directory)    
+    find_dirdir=`(cd $1; 
+      $FIND ./ -type d -a -name $3 -print |sort|head -1|sed 's#^\./##')`
+    
+
+    if test "x$find_dirdir" = x; then
+       find_dirdir="/$3";
+       AC_LILY_WARN(Cannot determine $4 subdirectory. Please set from command-line)
+       true
+    fi
+    $2=$find_dirdir
+    AC_MSG_RESULT($1/$find_dirdir)
+])
+
+AC_DEFUN(AC_TEX_SUBDIR, [
+dnl    AC_REQUIRE([AC_TEX_PREFIX])
+    AC_FIND_DIR_IN_PREFIX($find_texprefix, $1, tex,TeX input)
+    $1="$TEXPREFIX/$$1"
+])
+
+AC_DEFUN(AC_MF_SUBDIR, [
+dnl     AC_REQUIRE([AC_TEX_PREFIX])
+    AC_FIND_DIR_IN_PREFIX($find_texprefix, $1, source, MF input)
+    $1="$TEXPREFIX/$$1"
+])
+
+AC_DEFUN(AC_CHECK_SEARCH_RESULT, [
+       if test $1 = "error" 
+       then
+               AC_LILY_WARN(can't find $2. $3)
+       fi
+])
index 5f98246cecfbf54893e6d98feac90bb293e5149f..bfee282e45264a65dcb26904c4aab6cae28b9b98 100644 (file)
@@ -4,7 +4,7 @@ depth = ..
 include $(depth)/make/Include.make
 
 # list of distribution files:
-SCRIPTS = clearlily cpgento make_patch lily.efence \
+SCRIPTS = clearlily cpgento make-patch lily.efence \
        make-version release conflily
 PERL_SCRIPTS_IN = $(wildcard *.in)
 PERL_SCRIPTS = $(addprefix $(outdir)/, $(PERL_SCRIPTS_IN:.in=))
diff --git a/bin/make-patch b/bin/make-patch
new file mode 100755 (executable)
index 0000000..4c98e9f
--- /dev/null
@@ -0,0 +1,57 @@
+#!/bin/sh
+
+case $# in
+0) echo make_patch old new name
+       exit 1;;
+esac
+
+old=$1
+new=$2
+nm=$3-
+
+newarc=../releases/$nm$new.tar.gz
+oldarc=../releases/$nm$old.tar.gz
+
+
+if [ ! -x  $nm$new ]
+then
+   echo untarring ..
+  if [ ! -f $newarc ]
+  then
+       echo cant find $newarc
+       exit
+  fi
+  tar zfx $newarc
+fi
+if [ ! -x  $nm$old ]
+then
+   echo untarring
+
+  if [ ! -f $oldarc ]
+  then
+       echo cant find $oldarc
+       exit
+  fi
+   tar zfx $oldarc
+fi
+
+# not interested in auto generated files.
+for a in lilypond.lsm INSTALL.text AUTHORS.text lilypond.spec configure; do
+    rm `find  $nm$old $nm$new  -name $a`
+done    
+
+cat <<EOF > patch-$new
+Generated with 
+
+       make_patch $1 $2 $3
+
+usage 
+
+       cd lilypond-source-dir; patch -E -p0 < patch-$new
+       
+Patches do not contain automatically generated files, 
+i.e. you should rerun configure
+EOF
+
+(cd $nm$new; diff -urN  ../$nm$old . >> ../patch-$new)
+rm -rf $nm$old $nm$new
diff --git a/bin/make_patch b/bin/make_patch
deleted file mode 100755 (executable)
index 4c98e9f..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-#!/bin/sh
-
-case $# in
-0) echo make_patch old new name
-       exit 1;;
-esac
-
-old=$1
-new=$2
-nm=$3-
-
-newarc=../releases/$nm$new.tar.gz
-oldarc=../releases/$nm$old.tar.gz
-
-
-if [ ! -x  $nm$new ]
-then
-   echo untarring ..
-  if [ ! -f $newarc ]
-  then
-       echo cant find $newarc
-       exit
-  fi
-  tar zfx $newarc
-fi
-if [ ! -x  $nm$old ]
-then
-   echo untarring
-
-  if [ ! -f $oldarc ]
-  then
-       echo cant find $oldarc
-       exit
-  fi
-   tar zfx $oldarc
-fi
-
-# not interested in auto generated files.
-for a in lilypond.lsm INSTALL.text AUTHORS.text lilypond.spec configure; do
-    rm `find  $nm$old $nm$new  -name $a`
-done    
-
-cat <<EOF > patch-$new
-Generated with 
-
-       make_patch $1 $2 $3
-
-usage 
-
-       cd lilypond-source-dir; patch -E -p0 < patch-$new
-       
-Patches do not contain automatically generated files, 
-i.e. you should rerun configure
-EOF
-
-(cd $nm$new; diff -urN  ../$nm$old . >> ../patch-$new)
-rm -rf $nm$old $nm$new
index 2481b37f1632061ee0880a01934eb76969705d01..11f27a40aadf4b740b5a2948de60f3b71e56f7dd 100644 (file)
@@ -1,8 +1,8 @@
-#!@PERL@ -w
+#!@PERL@ -w            
+# -*-Perl-*-
 my $mudcount = 0;
 my $mudela_b = 0;
-my $outdir = "";
-my $outname = "";
+my $outname = "-";
 use Getopt::Long;
 
 sub gen_mufile
@@ -19,7 +19,7 @@ sub close_mudela
 {
     $mudela_b = 0;
     if ($fragment_b) {
-       print MUDELA "}\n \\paper { linewidth = -1.0\\cm; } }\n";
+       print MUDELA "}\n \\paper { linewidth = -1.0\\cm; castingalgorithm = \\Wordwrap; } }\n";
        $fragment_b =0;
     }
     if ( $verbatim_b)  {
@@ -80,14 +80,42 @@ sub parse_mudela_opts
    $fragment_b = 1 if ($s =~ /fragment/ );
 }   
 
+sub help
+{
+    print  "usage: convert-mudela [options] [file]
+options: 
+--help
+--outdir=DIRECTORY     write all files in directory DIRECTORY
+--outname=NAME         use NAME as base  for the output
+";
+    exit;
+}
+    
 sub main
 {
-    GetOptions( 'outdir=s', 'outname=s');
-    $outdir = $opt_outdir;
-    $outname = $opt_outname if (defined ($opt_outname) && $opt_outname);
-    open INFILE, $ARGV[0];
+    GetOptions( 'outdir=s', 'outname=s', 'help');
+    help    if ( $opt_help ) ;
+
+    if  (defined ($opt_outdir)) {
+       $outdir = $opt_outdir .  "/";
+    } else {
+       $outdir = "";
+    }
+   
+    if (defined ($ARGV[0])) {
+       $infile = $ARGV[0] ;
+    } else {
+       $infile = "-";
+    }
+    if (defined ($opt_outname)) {
+       $outname = $opt_outname ;
+    } else { 
+       die "Need to have an output name, use --outname" if ( $infile == "-");
+       $outname = "$infile.tex";
+    }
     
-    open BOOK, ">$outdir/$outname";
+    open INFILE, "<$infile";
+    open BOOK, ">$outdir$outname";
     while (<INFILE>) {
        if ($mudela_b) {
            if (end_b "mudela") {
@@ -117,4 +145,5 @@ sub main
     close BOOK;
 }
 
+
 main;
index d95553a8b69dfa8c0658173303eb11865fb750c6..7521b49f1150b9e23189fef72e4102adcd626177 100755 (executable)
@@ -50,7 +50,7 @@ patch=patch-$LILYVER.gz
 mv  $tarball $releasedir/
 
 cd ../test
-$heredir/bin/make_patch $LASTVER $NEWVER lilypond
+$heredir/bin/make-patch $LASTVER $NEWVER lilypond
 gzip -f9 patch-$NEWVER
 mv $patch $patchdir//
 
index e87a6ad630682405bfc11870bb48a0cb7a6c33d6..a75250b54f288b869c722bff1ffd82d10f60ced3 100644 (file)
@@ -1,28 +1,30 @@
 #!@PERL@
+# -*-Perl-*-
 
 
-$reldir="~/musix/releases";
+$reldir="/home/hw/musix/releases";
 
 use FileHandle;
+use Getopt::Long;
 
-sub  cmpver 
+sub cmpver 
 {      
-
-       my(@a)= split /\./,$a;
-       my(@b)= split /\./,$b;
-       
-       for $i (0,1,2) {
-           return $a[$i] <=> $b[$i] if ($a[$i] != $b[$i]);
-       }
-       return $a cmp $b;
+    my(@a)= split( /\./, $a);
+    my(@b)= split( /\./, $b);
+    
+    for $i (0,1,2) {
+       return $a[$i] <=> $b[$i] if ($a[$i] != $b[$i]);
+    }
+    return $a cmp $b;
 }
 
 my @versions;
 open LS, "ls -1 $reldir|";
 
+GetOptions( 'print', 'news', 'latest');
+
 
 while (<LS>) {
-       
     $_ =~ /lilypond-([^.]+\.[^.]+\.[^.]+).tar.gz/;
     push @versions, $1;
 }
@@ -32,12 +34,20 @@ while (<LS>) {
 my $last= (pop @versions);
 
 
-system "rm $reldir/zZ*";
-system  "> $reldir/zZ_LATEST_IS_$last";
+if (  $opt_print ) {
+    print $last;
+}
+
+if ( $opt_latest) {
+    system "rm $reldir/zZ*";
+    system  "> $reldir/zZ_LATEST_IS_$last";
+}
+if ( $opt_news ) {
+    open NEWS, "tar --to-stdout  -zxf $reldir/lilypond-$last.tar.gz lilypond-$last/NEWS |";
+    input_record_separator NEWS "****";
+    $desc = <NEWS>;
+    chop ($desc);
+    close NEWS;
 
-open NEWS, "tar --to-stdout  -zxf $reldir/lilypond-$last.tar.gz lilypond-$last/NEWS |";
-input_record_separator NEWS "****";
-$desc = <NEWS>;
-chop ($desc);
-close NEWS;
     print $desc;
+}
index d2c4808da791628f7a108f90aa205d687269669b..ab1ca42f2771ed4a9aba4bcb51eb842f1fc78cae 100755 (executable)
--- a/configure
+++ b/configure
@@ -14,9 +14,9 @@ ac_default_prefix=/usr/local
 ac_help="$ac_help
   enable-printing         turn on debug printing"
 ac_help="$ac_help
-  enable-checking        set runtime checks (assert calls). Default: on"
+  enable-checking         set runtime checks (assert calls). Default: on"
 ac_help="$ac_help
-  enable-debugging       set debug info. Default: on"
+  enable-debugging        set debug info. Default: on"
 ac_help="$ac_help
   enable-optimise         use maximal speed optimisations. Default: off"
 ac_help="$ac_help
@@ -28,7 +28,7 @@ ac_help="$ac_help
 ac_help="$ac_help
   tex-dir=DIR             set the directory to put LilyPond TeX files in. "
 ac_help="$ac_help
-  mf-dir=DIR              set the directory to put LilyPond MetaFont files in."
+  out-dir                 set the directory for machine generated files. Default out or out-HOST"
 
 # Initialize some variables set by options.
 # The variables have the same names as the options, with
@@ -538,22 +538,27 @@ fi
 
 
 
+if test x$srcdir != x.; then
+  echo Please look in the INSTALL instructions for
+  echo directions for multi-architecture building
+    
+  { echo "configure: error: This package does not support --srcdir." 1>&2; exit 1; }
+fi
+
 # if given here, these vars are initted at the checking point.
 if test x$host = xNONE; then
-    buildprefix=.
+    OUTDIR_NAME=${OUTDIR_NAME-"out"}
 else
-    buildprefix="$host-build-dir"
-    mkdir $buildprefix;
-    for a in `find -type d -and -not -name '*-build-dir'`; do
-       mkdir $buildprefix/$a;
-    done
+    OUTDIR_NAME=${OUTDIR_NAME-"out-$host"}
 fi
+
 printing_b=no
 checking_b=yes
 debug_b=yes
 optimise_b=no
 profile_b=no
 warn_b=no    
+
 ac_ext=C
 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
 ac_cpp='$CXXCPP $CPPFLAGS'
@@ -625,12 +630,14 @@ else
 fi
 
 
-# Check whether --enable-mf-dir or --disable-mf-dir was given.
-if test "${enable_mf_dir+set}" = set; then
-  enableval="$enable_mf_dir"
-  MFDIR=$enableval
-else
-  MFDIR=auto 
+
+
+
+# Check whether --enable-out-dir or --disable-out-dir was given.
+if test "${enable_out_dir+set}" = set; then
+  enableval="$enable_out_dir"
+  OUTDIR_NAME=$enableval
+    
 fi
 
 
@@ -660,6 +667,14 @@ if test $optimise_b = yes; then
     DEFINES="$DEFINES -O2 -DSTRING_UTILS_INLINED"
 fi
 
+if test "x$OSTYPE" = "xWindows_NT"; then
+    LN=cp # hard link does not work under cygnus-nt (yet?)
+    ZIP="zip -r -9" #
+else
+    LN=ln
+    ZIP="zip -r -9"
+fi
+
 AUTOHEADER="This file was automatically generated by configure"
 CPPFLAGS=${CPPFLAGS:-""}       # we don't want -g -O junk
 CXXFLAGS=${CXXFLAGS:-""}       # we don't want -g -O junk
@@ -669,7 +684,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:673: checking for $ac_word" >&5
+echo "configure:688: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -700,7 +715,7 @@ test -n "$CXX" || CXX="gcc"
 
 
 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:704: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:719: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
 
 ac_ext=C
 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -710,11 +725,11 @@ ac_link='${CXX-g++} -o conftest $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $L
 cross_compiling=$ac_cv_prog_cxx_cross
 
 cat > conftest.$ac_ext <<EOF
-#line 714 "configure"
+#line 729 "configure"
 #include "confdefs.h"
 main(){return(0);}
 EOF
-if { (eval echo configure:718: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:733: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   ac_cv_prog_cxx_works=yes
   # If we can't run a trivial program, we are probably using a cross compiler.
   if (./conftest; exit) 2>/dev/null; then
@@ -734,12 +749,12 @@ if test $ac_cv_prog_cxx_works = no; then
   { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
 fi
 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:738: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:753: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
 echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
 cross_compiling=$ac_cv_prog_cxx_cross
 
 echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:743: checking whether we are using GNU C++" >&5
+echo "configure:758: checking whether we are using GNU C++" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -748,7 +763,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:752: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:767: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
   ac_cv_prog_gxx=yes
 else
   ac_cv_prog_gxx=no
@@ -763,7 +778,7 @@ if test $ac_cv_prog_gxx = yes; then
   ac_save_CXXFLAGS="$CXXFLAGS"
   CXXFLAGS=
   echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:767: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:782: checking whether ${CXX-g++} accepts -g" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -793,7 +808,7 @@ fi
 # Extract the first word of "ranlib", so it can be a program name with args.
 set dummy ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:797: checking for $ac_word" >&5
+echo "configure:812: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -849,7 +864,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
 # ./install, which can be erroneously created by make from ./install.sh.
 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:853: checking for a BSD compatible install" >&5
+echo "configure:868: checking for a BSD compatible install" >&5
 if test -z "$INSTALL"; then
 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -903,7 +918,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:907: checking for $ac_word" >&5
+echo "configure:922: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_TAR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -937,7 +952,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:941: checking for $ac_word" >&5
+echo "configure:956: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_FIND'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -973,7 +988,11 @@ if test FIND = error; then
     warn_b=yes
 
 fi
-    
+
+
+
+
+
 
 
 
@@ -995,7 +1014,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:999: checking for $ac_word" >&5
+echo "configure:1018: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_BISON'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1029,7 +1048,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1033: checking for $ac_word" >&5
+echo "configure:1052: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_FLEX'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1063,7 +1082,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1067: checking for $ac_word" >&5
+echo "configure:1086: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_MAKE'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1095,7 +1114,7 @@ test -n "$MAKE" || MAKE="error"
 # Extract the first word of "perl", so it can be a program name with args.
 set dummy perl; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1099: checking for $ac_word" >&5
+echo "configure:1118: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1129,7 +1148,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1133: checking for $ac_word" >&5
+echo "configure:1152: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_PODMAN'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1165,7 +1184,7 @@ if test "x$TEXPREFIX" = xauto ; then
     
 
     echo $ac_n "checking TeX/MF root dir directory""... $ac_c" 1>&6
-echo "configure:1169: checking TeX/MF root dir directory" >&5    
+echo "configure:1188: checking TeX/MF root dir directory" >&5    
 
     find_root_prefix="$prefix"
     
@@ -1206,7 +1225,7 @@ if test "x$TEXDIR" = xauto ; then
     
     
     echo $ac_n "checking TeX input directory""... $ac_c" 1>&6
-echo "configure:1210: checking TeX input directory" >&5    
+echo "configure:1229: checking TeX input directory" >&5    
     find_dirdir=`(cd $find_texprefix; 
       $FIND ./ -type d -a -name tex -print |sort|head -1|sed 's#^\./##')`
     
@@ -1227,59 +1246,73 @@ echo "configure:1210: checking TeX input directory" >&5
 fi
 
     
-if test $MAKE = "error" 
-then
-       { echo "configure: error: Please install GNU make" 1>&2; exit 1; }
-else
-       $MAKE -v| grep GNU > /dev/null
-       if test "$?" = 1
+
+
+       if test $MAKE = "error" 
        then
-           
-    echo "configure: warning: Please install *GNU* make" 1>&2
+               
+    echo "configure: warning: can't find GNU make. You should install GNU make" 1>&2
     warn_b=yes
-    fi 
-fi 
-    
-if test $BISON = "error" 
-then
-       
-    echo "configure: warning: can't find bison. Please install Bison (1.25 or better)" 1>&2
+
+       fi
+
+
+       if test $BISON = "error" 
+       then
+               
+    echo "configure: warning: can't find bison. Please install Bison" 1>&2
     warn_b=yes
 
-else
-    bison_version=`$BISON --version| sed 's/^.*version 1.//g' `
-    if test $bison_version -lt 25; then
-       
-    echo "configure: warning: Your bison is too old (1.$bison_version). Please install 1.25" 1>&2
+       fi
+
+
+       if test $PERL = "error" 
+       then
+               
+    echo "configure: warning: can't find perl. You should install Perl" 1>&2
     warn_b=yes
 
-    fi 
-fi
+       fi
 
-if test $PERL = "error" 
-then
-       
-    echo "configure: warning: can't find perl. You should install Perl (version 5 or better)" 1>&2
+
+       if test $PODMAN = "error" 
+       then
+               
+    echo "configure: warning: can't find pod. You should install Perl" 1>&2
     warn_b=yes
 
-       PERL=/usr/bin/perl
-fi
+       fi
 
-if test $PODMAN = "error" 
-then
-       
-    echo "configure: warning: can't find pod. You should install Perl (version 5 or better)" 1>&2
+
+       if test $FLEX = "error" 
+       then
+               
+    echo "configure: warning: can't find flex. Please install Flex" 1>&2
     warn_b=yes
 
-fi
+       fi
 
-if test $FLEX = "error" 
-then
+
+
+if test $MAKE != "error" ; then
+    $MAKE -v| grep GNU > /dev/null
+    if test "$?" = 1
+    then
+           
+    echo "configure: warning: Please install *GNU* make" 1>&2
+    warn_b=yes
+    fi 
+fi 
+    
+if test $BISON != "error"; then
+    bison_version=`$BISON --version| sed 's/^.*version 1.//g' `
+    if test $bison_version -lt 25; then
        
-    echo "configure: warning: can't find flex. Please install Flex (2.5 or better)" 1>&2
+    echo "configure: warning: Your bison is too old (1.$bison_version). Please install 1.25" 1>&2
     warn_b=yes
 
+    fi 
 fi
 
 if $CXX --version | grep '2\.7' > /dev/null
@@ -1293,7 +1326,7 @@ else
 fi
 
 echo $ac_n "checking how to run the C++ preprocessor""... $ac_c" 1>&6
-echo "configure:1297: checking how to run the C++ preprocessor" >&5
+echo "configure:1330: checking how to run the C++ preprocessor" >&5
 if test -z "$CXXCPP"; then
 if eval "test \"`echo '$''{'ac_cv_prog_CXXCPP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1306,12 +1339,12 @@ ac_link='${CXX-g++} -o conftest $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $L
 cross_compiling=$ac_cv_prog_cxx_cross
   CXXCPP="${CXX-g++} -E"
   cat > conftest.$ac_ext <<EOF
-#line 1310 "configure"
+#line 1343 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1315: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1348: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   :
@@ -1331,17 +1364,17 @@ echo "$ac_t""$CXXCPP" 1>&6
 
 ac_safe=`echo "FlexLexer.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for FlexLexer.h""... $ac_c" 1>&6
-echo "configure:1335: checking for FlexLexer.h" >&5
+echo "configure:1368: checking for FlexLexer.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1340 "configure"
+#line 1373 "configure"
 #include "confdefs.h"
 #include <FlexLexer.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1345: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1378: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -1367,8 +1400,18 @@ else
 fi
 
 
+for a in `find -type d -and -not -name 'out*'`; do
+    if test ! -d  $a/$OUTDIR_NAME; then
+       mkdir $a/$OUTDIR_NAME
+    fi
+done
+
 subdirs="flower"
 
+
+# ugh
+eval "DIR_DATADIR=$datadir/lilypond"
+    
 trap '' 1 2 15
 cat > confcache <<\EOF
 # This file is a shell script that caches the results of configure
@@ -1482,7 +1525,9 @@ done
 ac_given_srcdir=$srcdir
 ac_given_INSTALL="$INSTALL"
 
-trap 'rm -fr `echo "$buildprefix/make/out/Configure_variables.make:make/Configure_variables.make.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+trap 'rm -fr `echo "make/$OUTDIR_NAME/Configure_variables.make:make/Configure_variables.make.in
+    lib/$OUTDIR_NAME/config.hh:lib/config.hh.in
+    Makefile:make/Toplevel.make.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
 EOF
 cat >> $CONFIG_STATUS <<EOF
 
@@ -1518,6 +1563,7 @@ s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
 s%@INSTALL_DATA@%$INSTALL_DATA%g
 s%@TAR@%$TAR%g
 s%@FIND@%$FIND%g
+s%@OUTDIR_NAME@%$OUTDIR_NAME%g
 s%@ICFLAGS@%$ICFLAGS%g
 s%@ILDFLAGS@%$ILDFLAGS%g
 s%@DEFINES@%$DEFINES%g
@@ -1525,10 +1571,13 @@ s%@COMPILEINFO@%$COMPILEINFO%g
 s%@AUTOHEADER@%$AUTOHEADER%g
 s%@BISON@%$BISON%g
 s%@FLEX@%$FLEX%g
+s%@LN@%$LN%g
 s%@PERL@%$PERL%g
+s%@ZIP@%$ZIP%g
 s%@TEXPREFIX@%$TEXPREFIX%g
 s%@TEXDIR@%$TEXDIR%g
 s%@MFDIR@%$MFDIR%g
+s%@DIR_DATADIR@%$DIR_DATADIR%g
 s%@EXTRA_LIBES@%$EXTRA_LIBES%g
 s%@MAKE@%$MAKE%g
 s%@PODMAN@%$PODMAN%g
@@ -1575,7 +1624,9 @@ EOF
 
 cat >> $CONFIG_STATUS <<EOF
 
-CONFIG_FILES=\${CONFIG_FILES-"$buildprefix/make/out/Configure_variables.make:make/Configure_variables.make.in"}
+CONFIG_FILES=\${CONFIG_FILES-"make/$OUTDIR_NAME/Configure_variables.make:make/Configure_variables.make.in
+    lib/$OUTDIR_NAME/config.hh:lib/config.hh.in
+    Makefile:make/Toplevel.make.in"}
 EOF
 cat >> $CONFIG_STATUS <<\EOF
 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
@@ -1744,49 +1795,20 @@ if test "$no_recursion" != yes; then
 fi
 
 
-
-
-eval "DIR_DATADIR=$datadir"
-DIR_DATADIR="$DIR_DATADIR/lilypond"
-echo $ac_n "checking ""... $ac_c" 1>&6
-echo "configure:1753: checking " >&5
-
-cat << EOF > $buildprefix/lib/out/config.hh
-
-/* automatically generated by configure */
-/* include this file only once! */
-
-#define  DIR_DATADIR "$DIR_DATADIR"
-
-EOF
-
-CXX="$ac_cv_prog_CXX" bin/make-version >> $buildprefix/lib/out/config.hh
-
-touch $buildprefix/make/out/Site.make
-
-# ugr
-(cd mi2mu; CXX="$ac_cv_prog_CXX" ../bin/make-version > ../$buildprefix/mi2mu/out/version.hh
-
-)
-(cd lily; CXX="$ac_cv_prog_CXX" ../bin/make-version > ../$buildprefix/lily/out/version.hh
-)
-
-echo '# WARNING : Automatically generated from make/Toplevel.make.in' \
-    | cat - make/Toplevel.make.in > Makefile
-
+touch make/$OUTDIR_NAME/Site.make
 
 cat << END
 For making everything, do:
 
     make               # GNU make
 
-or if you used --host=SunUltraWitteReus
+or if you used --outdir=blabla
 
-    make buildprefix=SunUltraWitteReus-build-dir
+    make OUTDIR_NAME=blabla
     
 If you want to make site-wide extensions to the makefiles, please use
 
-    make/out/Site.make
+    make/$OUTDIR_NAME/Site.make
     
 END
 
index 4df3d11ff70293866c1b4382ae11a555e0b0dbfc..ffe79f3e4aca29800c6169a087614d2bc14befe3 100644 (file)
@@ -1,99 +1,30 @@
 dnl -*-shell-script-*-
 dnl  Process this file with autoconf to produce a configure script. 
 
-dnl should cache result.
-dnl should  look in $prefix first.
-
-AC_DEFUN(AC_LILY_WARN, [
-    AC_MSG_WARN($1)
-    warn_b=yes
-])
-AC_DEFUN(AC_TEX_PREFIX, [
-    
-
-    AC_MSG_CHECKING(TeX/MF root dir directory)    
-
-    find_root_prefix="$prefix"
-    
-
-    test "x$find_root_prefix" = xNONE && find_root_prefix="$ac_default_prefix"
-    find_texpostfix="";
-    for postfix in "/lib/tex/" "/lib/texmf" "/lib" "/tex" "/texmf"; do
-       find_texprefix="$find_root_prefix$postfix"
-       if test -d $find_texprefix; then
-           find_texpostfix=$postfix
-           break;
-       fi
-    done
-    
-    if test "x$find_texpostfix" = x; then
-       find_texpostfix='/lib/texmf/tex'
-       AC_LILY_WARN(Cannot determine the TeX-directory. Please use --enable-tex-prefix)
-    fi
-
-    find_texprefix="$find_root_prefix/$find_texpostfix"
-
-    # only assign if variablename not empty
-    if test x != "x$1"; then
-       $1='${prefix}'/"$find_texpostfix"
-    fi
-    AC_MSG_RESULT($find_texprefix)
+AC_INIT(flower/choleski.cc)
 
-])
 
-# find a directory inside a prefix, 
-# $1 the prefix (expanded version)
-# $2 variable to assign
-# $3 the directory name 
-# $4 description
-AC_DEFUN(AC_FIND_DIR_IN_PREFIX, [
-    
-    AC_MSG_CHECKING($4 directory)    
-    find_dirdir=`(cd $1; 
-      $FIND ./ -type d -a -name $3 -print |sort|head -1|sed 's#^\./##')`
+if test x$srcdir != x.; then
+  echo Please look in the INSTALL instructions for
+  echo directions for multi-architecture building
     
-
-    if test "x$find_dirdir" = x; then
-       find_dirdir="/$3";
-       AC_LILY_WARN(Cannot determine $4 subdirectory. Please set from command-line)
-       true
-    fi
-    $2=$find_dirdir
-    AC_MSG_RESULT($1/$find_dirdir)
-])
-
-AC_DEFUN(AC_TEX_SUBDIR, [
-dnl    AC_REQUIRE([AC_TEX_PREFIX])
-    AC_FIND_DIR_IN_PREFIX($find_texprefix, $1, tex,TeX input)
-    $1="$TEXPREFIX/$$1"
-])
-
-AC_DEFUN(AC_MF_SUBDIR, [
-dnl     AC_REQUIRE([AC_TEX_PREFIX])
-    AC_FIND_DIR_IN_PREFIX($find_texprefix, $1, source, MF input)
-    $1="$TEXPREFIX/$$1"
-])
-   
-AC_INIT(flower/choleski.cc)
-
+  AC_MSG_ERROR(This package does not support --srcdir.)
+fi
 
 # if given here, these vars are initted at the checking point.
 if test x$host = xNONE; then
-    buildprefix=.
+    OUTDIR_NAME=${OUTDIR_NAME-"out"}
 else
-    buildprefix="$host-build-dir"
-    mkdir $buildprefix;
-    for a in `find -type d -and -not -name '*-build-dir'`; do
-       mkdir $buildprefix/$a;
-    done
+    OUTDIR_NAME=${OUTDIR_NAME-"out-$host"}
 fi
+
 printing_b=no
 checking_b=yes
 debug_b=yes
 optimise_b=no
 profile_b=no
 warn_b=no    
+
 AC_LANG_CPLUSPLUS
 
 AC_ARG_ENABLE(printing,
@@ -102,11 +33,11 @@ AC_ARG_ENABLE(printing,
 
        
 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] )
 
 AC_ARG_ENABLE(debugging,
-    [  enable-debugging       set debug info. Default: on],
+    [  enable-debugging        set debug info. Default: on],
     [debug_b=$enableval])
 
 AC_ARG_ENABLE(optimise,
@@ -132,10 +63,15 @@ AC_ARG_ENABLE(tex-dir,
     [TEXDIR=$enableval],
     [TEXDIR=auto] )
 
-AC_ARG_ENABLE(mf-dir,
-    [  mf-dir=DIR              set the directory to put LilyPond MetaFont files in.],
-    [MFDIR=$enableval],
-    [MFDIR=auto] )
+AC_JUNK_ARGS( AC_ARG_ENABLE(mf-dir,
+     [  mf-dir=DIR             set the directory to put LilyPond MetaFont files in. (obsolete)],
+     [MFDIR=$enableval],
+     [MFDIR=auto] ))
+
+AC_ARG_ENABLE(out-dir,
+    [  out-dir                 set the directory for machine generated files. Default out or out-HOST],
+    [OUTDIR_NAME=$enableval]
+    [])
 
 if test $profile_b = yes; then
     EXTRA_LIBES="-pg"
@@ -163,6 +99,14 @@ if test $optimise_b = yes; then
     DEFINES="$DEFINES -O2 -DSTRING_UTILS_INLINED"
 fi
 
+if test "x$OSTYPE" = "xWindows_NT"; then
+    LN=cp # hard link does not work under cygnus-nt (yet?)
+    ZIP="zip -r -9" #
+else
+    LN=ln
+    ZIP="zip -r -9"
+fi
+
 dnl COMPILEINFO="$HOST $host $TARGET $target"
 AUTOHEADER="This file was automatically generated by configure"
 CPPFLAGS=${CPPFLAGS:-""}       # we don't want -g -O junk
@@ -178,7 +122,8 @@ dnl should check out -print
 if test FIND = error; then
    AC_LILY_WARN(Couldn't find \`find'.  Please use --enable-tex-dir)
 fi
-    
+
+AC_SUBST(OUTDIR_NAME)
 AC_SUBST(CXXFLAGS)
 AC_SUBST(CPPFLAGS)
 AC_SUBST(CXX)
@@ -189,10 +134,13 @@ AC_SUBST(COMPILEINFO)
 AC_SUBST(AUTOHEADER)
 AC_SUBST(BISON)
 AC_SUBST(FLEX)
+AC_SUBST(LN)
 AC_SUBST(PERL)
+AC_SUBST(ZIP)
 AC_SUBST(TEXPREFIX)
 AC_SUBST(TEXDIR)
 AC_SUBST(MFDIR)
+AC_SUBST(DIR_DATADIR)
 AC_SUBST(EXTRA_LIBES)
 
 AC_CHECK_PROGS(BISON, bison, error)
@@ -216,43 +164,29 @@ dnl if test "x$MFDIR" = xauto; then
 dnl     AC_MF_SUBDIR(MFDIR)
 dnl fi
     
-if test $MAKE = "error" 
-then
-       AC_MSG_ERROR(Please install GNU make)
-else
-       $MAKE -v| grep GNU > /dev/null
-       if test "$?" = 1
-       then
+
+AC_CHECK_SEARCH_RESULT($MAKE, GNU make,  You should install GNU make)
+AC_CHECK_SEARCH_RESULT( $BISON, bison,  Please install Bison, 1.25 or better)
+AC_CHECK_SEARCH_RESULT($PERL, perl, You should install Perl, version 5 or better)
+AC_CHECK_SEARCH_RESULT($PODMAN, pod,  You should install Perl, version 5 or better)
+AC_CHECK_SEARCH_RESULT( $FLEX,  flex, Please install Flex, 2.5 or better)
+
+
+if test $MAKE != "error" ; then
+    $MAKE -v| grep GNU > /dev/null
+    if test "$?" = 1
+    then
            AC_LILY_WARN(Please install *GNU* make) 
     fi 
 fi 
     
-if test $BISON = "error" 
-then
-       AC_LILY_WARN(can't find bison. Please install Bison (1.25 or better))
-else
+if test $BISON != "error"; then
     bison_version=`$BISON --version| sed 's/^.*version 1.//g' `
     if test $bison_version -lt 25; then
        AC_LILY_WARN(Your bison is too old (1.$bison_version). Please install 1.25)
     fi 
 fi
 
-if test $PERL = "error" 
-then
-       AC_LILY_WARN(can't find perl. You should install Perl (version 5 or better))
-       PERL=/usr/bin/perl
-fi
-
-if test $PODMAN = "error" 
-then
-       AC_LILY_WARN(can't find pod. You should install Perl (version 5 or better))
-fi
-
-if test $FLEX = "error" 
-then
-       AC_LILY_WARN(can't find flex. Please install Flex (2.5 or better))
-fi
-
 if $CXX --version | grep '2\.7' > /dev/null
 then
        true
@@ -263,52 +197,35 @@ fi
 AC_CHECK_HEADER(FlexLexer.h, true,
        AC_LILY_WARN(can't find flex header. Please install Flex headers correctly))
 
-AC_CONFIG_SUBDIRS(flower)
-AC_OUTPUT($buildprefix/make/out/Configure_variables.make:make/Configure_variables.make.in)
-
-
-
-dnl URG!!!!!!
-eval "DIR_DATADIR=$datadir"
-DIR_DATADIR="$DIR_DATADIR/lilypond"
-AC_MSG_CHECKING
-
-cat << EOF > $buildprefix/lib/out/config.hh
-
-/* automatically generated by configure */
-/* include this file only once! */
-
-#define  DIR_DATADIR "$DIR_DATADIR"
-
-EOF
-
-CXX="$ac_cv_prog_CXX" bin/make-version >> $buildprefix/lib/out/config.hh
-
-touch $buildprefix/make/out/Site.make
-
-# ugr
-(cd mi2mu; CXX="$ac_cv_prog_CXX" ../bin/make-version > ../$buildprefix/mi2mu/out/version.hh
+for a in `find -type d -and -not -name 'out*'`; do
+    if test ! -d  $a/$OUTDIR_NAME; then
+       mkdir $a/$OUTDIR_NAME
+    fi
+done
 
-)
-(cd lily; CXX="$ac_cv_prog_CXX" ../bin/make-version > ../$buildprefix/lily/out/version.hh
-)
+AC_CONFIG_SUBDIRS(flower)
 
-echo '# WARNING : Automatically generated from make/Toplevel.make.in' \
-    | cat - make/Toplevel.make.in > Makefile
+# ugh
+eval "DIR_DATADIR=$datadir/lilypond"
+    
+AC_OUTPUT(make/$OUTDIR_NAME/Configure_variables.make:make/Configure_variables.make.in
+    lib/$OUTDIR_NAME/config.hh:lib/config.hh.in
+    Makefile:make/Toplevel.make.in)
 
+touch make/$OUTDIR_NAME/Site.make
 
 cat << END
 For making everything, do:
 
     make               # GNU make
 
-or if you used --host=SunUltraWitteReus
+or if you used --outdir=blabla
 
-    make buildprefix=SunUltraWitteReus-build-dir
+    make OUTDIR_NAME=blabla
     
 If you want to make site-wide extensions to the makefiles, please use
 
-    make/out/Site.make
+    make/$OUTDIR_NAME/Site.make
     
 END
 
index 30b2a6f8f4294a7e7d8c4c5c49159c8316cac472..1089809e21e17ad9a5fdc6bb92d20e53fefe6d6c 100644 (file)
@@ -39,7 +39,7 @@ SUBDIRS = include test
 # list of distribution files:
 #
 SCRIPTS = 
-README_FILES = NEWS README TODO
+README_FILES = ONEWS NEWS README TODO
 EXTRA_DISTFILES= configure config.hh.in configure.in VERSION $(README_FILES) $(SCRIPTS) Flower-flags.make.in
 #
 
@@ -74,3 +74,6 @@ endif
 
 localuninstall:
        rm -f $(libdir)/libflower.{so,a}
+
+
+$(outdir)/flower-version.o: $(outdir)/version.hh
index a93f485302ac60247617d70722e2b1f9335c7e1d..57ad102788a65da08df99651fbeb68fba24529ee 100644 (file)
@@ -1,4 +1,9 @@
-version 1.1:
+
+
+pl 25
+       - unordered_substitute and unordered_del
+       - Full_storage inline functions
+       - more Diagonal_storage fixes
 
 pl 24 
        - Diagonal_storage for band matrices.
@@ -9,6 +14,7 @@ pl 24
 pl 23:
        - virtual-methods : static_is_type_b
        - Choleski checks off if not PARANOID
+
 pl 22:
        - ACursor and PACursor to give array a List like interface.
 
@@ -18,6 +24,7 @@ pl 20.mb
 
 pl 20
        - List::junk_links()
+
 pl 19
        - Array::reverse()
 
@@ -29,6 +36,7 @@ pl 18
 
 pl 17
        - naming: Pointer->Link, IPointer->Pointer
+
 pl 16
        - Array::get()
        - P< > doco.
@@ -39,6 +47,7 @@ pl 15
 
 pl 14
        - interval methods
+
 pl 13
        - better test-bed
        - Heap PQueue implementation
@@ -115,36 +124,3 @@ pl 1
 0:
                
 
-------------------
-1.0:
-
-pl 27-3
-       - debug memmove code
-       - StringData bugfix
-       - old String::String( char, int ) bugfix
-
-pl 27-1,2 (not released)
-       patches by JCN
-       - stringutils.cc included again 
-       - bin2hex_str bugfix
-       - String class handles null bytes
-       - StringUtils inlined/outlined by #define
-       - StringConversion (only hex for now)
-
-pl 27
-       - (temporarily?) removed findcursor* t*mat*
-
-pl 26
-       - docxx 3.0
-
-pl 25
-       - merge sstack and Array
-
-pl 24
-       - small fix in vector print
-
-pl 23
-       - win32 patches (JN)
-
-pl 22
-       - Array::add -> Array::push
diff --git a/flower/ONEWS b/flower/ONEWS
new file mode 100644 (file)
index 0000000..9f4df5b
--- /dev/null
@@ -0,0 +1,34 @@
+history of flower lib 0.0
+
+version 1.1  release
+
+pl 27-3
+       - debug memmove code
+       - StringData bugfix
+       - old String::String( char, int ) bugfix
+
+pl 27-1,2 (not released)
+       patches by JCN
+       - stringutils.cc included again 
+       - bin2hex_str bugfix
+       - String class handles null bytes
+       - StringUtils inlined/outlined by #define
+       - StringConversion (only hex for now)
+
+pl 27
+       - (temporarily?) removed findcursor* t*mat*
+
+pl 26
+       - docxx 3.0
+
+pl 25
+       - merge sstack and Array
+
+pl 24
+       - small fix in vector print
+
+pl 23
+       - win32 patches (JN)
+
+pl 22
+       - Array::add -> Array::push
index 169a0525e6957791433e404bf8d56c494cb2fc3a..b71ad836c0a0b6e762f1e526136aa67f6b8479f4 100644 (file)
@@ -1,5 +1,8 @@
        * write a String_hash template
 
+
+       * Array::slice() upper too
+
        * write a Pointer_hash template
 
        * fix/junk ambiguous String constructor overloads, e.g.:
index fafe5106a46e9925eacedbe521bc37018efc8bd6..d05f7ff918571601ba9acd4b3e9df705a1b8fcb6 100644 (file)
@@ -1,6 +1,6 @@
 MAJOR_VERSION = 1
 MINOR_VERSION = 1
-PATCH_LEVEL = 24
+PATCH_LEVEL = 25
 # use to send patches, always empty for released version:
 MY_PATCH_LEVEL = # include separator: "-1" or ".a"
 #
index d619b97460f724c428e00758a32e94fbb4aa2602..086759193fb57b4152ddbb3331168bd05d2d5c61 100644 (file)
@@ -12,13 +12,15 @@ const Real EPS = 1e-7;              // so sue me. Hard coded
 // for testing new Matrix_storage.
 //#define PARANOID
 
-Vector
-Choleski_decomposition::solve(Vector rhs)const
+void
+Choleski_decomposition::full_matrix_solve(Vector &out, Vector const &rhs)const
 {
     int n= rhs.dim();
     assert(n == L.dim());
-    Vector y(n);
-
+    Vector y;
+    y.set_dim( n);
+    out.set_dim(n);
+    
     // forward substitution
     for (int i=0; i < n; i++) {
        Real sum(0.0);
@@ -26,18 +28,67 @@ Choleski_decomposition::solve(Vector rhs)const
            sum += y(j) * L(i,j);
        y(i) = (rhs(i) - sum)/L(i,i);
     }
+    
     for (int i=0; i < n; i++)
        y(i) /= D(i);
 
     // backward subst
-    Vector &x(rhs);            // using input as return val.
+    Vector &x(out);            // using input as return val.
     for (int i=n-1; i >= 0; i--) {
        Real sum(0.0);
        for (int j=i+1; j < n; j++)
            sum += L(j,i)*x(j);
        x(i) = (y(i) - sum)/L(i,i);
     }
-    return x;
+}
+
+void
+Choleski_decomposition::band_matrix_solve(Vector &out, Vector const &rhs)const
+{
+    int n= rhs.dim();
+    int b = L.band_i();
+    assert(n == L.dim());
+
+      out.set_dim(n);
+  
+    Vector y;
+    y.set_dim(n);
+    
+    // forward substitution
+    for (int i=0; i < n; i++) {
+       Real sum(0.0);
+       for (int j= 0 >? i - b; j < i; j++)
+           sum += y(j) * L(i,j);
+       y(i) = (rhs(i) - sum)/L(i,i);
+    }
+    for (int i=0; i < n; i++)
+       y(i) /= D(i);
+
+    // backward subst
+    Vector &x(out);            // using input as return val.
+    for (int i=n-1; i >= 0; i--) {
+       Real sum(0.0);
+       for (int j=i+1; j <= i + b&&j < n ; j++)
+           sum += L(j,i)*x(j);
+       x(i) = (y(i) - sum)/L(i,i);
+    }
+}
+
+void
+Choleski_decomposition::solve(Vector &x, Vector const &rhs)const
+{
+    if (L.band_b()) {
+       band_matrix_solve(x,rhs);
+    } else
+       full_matrix_solve(x,rhs);
+}
+
+Vector
+Choleski_decomposition::solve(Vector rhs)const
+{
+    Vector r;
+    solve(r, rhs);
+    return r;
 }
 
 void
@@ -126,9 +177,10 @@ Choleski_decomposition::inverse() const
     int n=L.dim();
     Matrix invm(n);
     Vector e_i(n);
+    Vector inv(n);
     for (int i = 0; i < n; i++) {
        e_i.set_unit(i);
-       Vector inv(solve(e_i));
+       solve(inv, e_i);
        for (int j = 0 ; j<n; j++)
            invm(i,j) = inv(j);
     }
index 53ff4301cf99ed7da2bee61ce08d75c89c17108d..920d8c0c0828e8229c395a6d319218d0f5e55b5b 100755 (executable)
@@ -15,6 +15,8 @@ ac_help="$ac_help
   enable-shared       shared flower library"
 ac_help="$ac_help
   disable-optimise    optimisations off"
+ac_help="$ac_help
+  out-dir                      set the directory for machine generated files. Default out or out-HOST"
 
 # Initialize some variables set by options.
 # The variables have the same names as the options, with
@@ -534,16 +536,18 @@ optimise_b=yes
 shared_b=no
 LIB_SUFFIX=.a
 
-# if given here, these vars are initted at the checking point.
 if test x$host = xNONE; then
-    flowerbuildprefix=.
+    OUTDIR_NAME=${OUTDIR_NAME-"out"}
 else
-    flowerbuildprefix="../$host-build-dir/Flower"
-    mkdir $flowerbuildprefix;
-    for a in `find -type d -and -not -name '*-build-dir'`; do
-       mkdir $flowerbuildprefix/$a;
-    done
+    OUTDIR_NAME=${OUTDIR_NAME-"out-$host"}
 fi
+
+for a in `find -type d -and -not -name 'out'`; do
+       if test ! -d  $a/$OUTDIR_NAME; then
+               mkdir $a/$OUTDIR_NAME;
+       fi
+done
+
     
 # Check whether --enable-shared or --disable-shared was given.
 if test "${enable_shared+set}" = set; then
@@ -559,6 +563,14 @@ if test "${enable_optimise+set}" = set; then
 fi
 
 
+# Check whether --enable-out-dir or --disable-out-dir was given.
+if test "${enable_out_dir+set}" = set; then
+  enableval="$enable_out_dir"
+  OUTDIR_NAME=$enableval
+    
+fi
+
+
 if test $shared_b = yes; then
        MODULE_CXXFLAGS="$MODULE_CXXFLAGS -fPIC"
        MODULE_LDFLAGS="-shared -Wl,-soname,libflower.so "
@@ -578,7 +590,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:582: checking for $ac_word" >&5
+echo "configure:594: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -609,7 +621,7 @@ test -n "$CXX" || CXX="gcc"
 
 
 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:613: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:625: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
 
 ac_ext=C
 # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -619,11 +631,11 @@ ac_link='${CXX-g++} -o conftest $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $L
 cross_compiling=$ac_cv_prog_cxx_cross
 
 cat > conftest.$ac_ext <<EOF
-#line 623 "configure"
+#line 635 "configure"
 #include "confdefs.h"
 main(){return(0);}
 EOF
-if { (eval echo configure:627: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:639: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   ac_cv_prog_cxx_works=yes
   # If we can't run a trivial program, we are probably using a cross compiler.
   if (./conftest; exit) 2>/dev/null; then
@@ -643,12 +655,12 @@ if test $ac_cv_prog_cxx_works = no; then
   { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
 fi
 echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:647: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:659: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
 echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
 cross_compiling=$ac_cv_prog_cxx_cross
 
 echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:652: checking whether we are using GNU C++" >&5
+echo "configure:664: checking whether we are using GNU C++" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -657,7 +669,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:661: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:673: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
   ac_cv_prog_gxx=yes
 else
   ac_cv_prog_gxx=no
@@ -672,7 +684,7 @@ if test $ac_cv_prog_gxx = yes; then
   ac_save_CXXFLAGS="$CXXFLAGS"
   CXXFLAGS=
   echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:676: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:688: checking whether ${CXX-g++} accepts -g" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -700,7 +712,7 @@ else
 fi
 
 echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
-echo "configure:704: checking for 8-bit clean memcmp" >&5
+echo "configure:716: checking for 8-bit clean memcmp" >&5
 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -708,7 +720,7 @@ else
   ac_cv_func_memcmp_clean=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 712 "configure"
+#line 724 "configure"
 #include "confdefs.h"
 #ifdef __cplusplus
 extern "C" void exit(int);
@@ -721,7 +733,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:725: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:737: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_memcmp_clean=yes
 else
@@ -739,12 +751,12 @@ echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6
 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.o"
 
 echo $ac_n "checking for vprintf""... $ac_c" 1>&6
-echo "configure:743: checking for vprintf" >&5
+echo "configure:755: checking for vprintf" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 748 "configure"
+#line 760 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char vprintf(); below.  */
@@ -770,7 +782,7 @@ vprintf();
 
 ; return 0; }
 EOF
-if { (eval echo configure:774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:786: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_vprintf=yes"
 else
@@ -794,12 +806,12 @@ fi
 
 if test "$ac_cv_func_vprintf" != yes; then
 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
-echo "configure:798: checking for _doprnt" >&5
+echo "configure:810: checking for _doprnt" >&5
 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 803 "configure"
+#line 815 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char _doprnt(); below.  */
@@ -825,7 +837,7 @@ _doprnt();
 
 ; return 0; }
 EOF
-if { (eval echo configure:829: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:841: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func__doprnt=yes"
 else
@@ -852,12 +864,12 @@ fi
 for ac_func in memmem snprintf 
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:856: checking for $ac_func" >&5
+echo "configure:868: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 861 "configure"
+#line 873 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -883,7 +895,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:887: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:899: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -908,8 +920,10 @@ fi
 done
 
 
+if test ! -d $OUTDIR_NAME ; then
+    mkdir $OUTDIR_NAME
+fi
 
-CXX="$ac_cv_prog_CXX" ../bin/make-version > $flowerbuildprefix/out/version.hh
 
 trap '' 1 2 15
 cat > confcache <<\EOF
@@ -1011,7 +1025,7 @@ done
 
 ac_given_srcdir=$srcdir
 
-trap 'rm -fr `echo "$flowerbuildprefix/out/Flower-flags.make:Flower-flags.make.in $flowerbuildprefix/out/config.hh:config.hh.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+trap 'rm -fr `echo "$OUTDIR_NAME/Flower-flags.make:Flower-flags.make.in $OUTDIR_NAME/config.hh:config.hh.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
 EOF
 cat >> $CONFIG_STATUS <<EOF
 
@@ -1087,7 +1101,7 @@ EOF
 
 cat >> $CONFIG_STATUS <<EOF
 
-CONFIG_FILES=\${CONFIG_FILES-"$flowerbuildprefix/out/Flower-flags.make:Flower-flags.make.in"}
+CONFIG_FILES=\${CONFIG_FILES-"$OUTDIR_NAME/Flower-flags.make:Flower-flags.make.in"}
 EOF
 cat >> $CONFIG_STATUS <<\EOF
 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
@@ -1163,7 +1177,7 @@ ac_eD='%g'
 if test "${CONFIG_HEADERS+set}" != set; then
 EOF
 cat >> $CONFIG_STATUS <<EOF
-  CONFIG_HEADERS="$flowerbuildprefix/out/config.hh:config.hh.in"
+  CONFIG_HEADERS="$OUTDIR_NAME/config.hh:config.hh.in"
 EOF
 cat >> $CONFIG_STATUS <<\EOF
 fi
index 619a5fe71ef8f7ec9966cf236746f7e05740d888..dd20827eae99b0a86fdf817e69910bee83126c2a 100644 (file)
@@ -7,16 +7,18 @@ optimise_b=yes
 shared_b=no
 LIB_SUFFIX=.a
 
-# if given here, these vars are initted at the checking point.
 if test x$host = xNONE; then
-    flowerbuildprefix=.
+    OUTDIR_NAME=${OUTDIR_NAME-"out"}
 else
-    flowerbuildprefix="../$host-build-dir/Flower"
-    mkdir $flowerbuildprefix;
-    for a in `find -type d -and -not -name '*-build-dir'`; do
-       mkdir $flowerbuildprefix/$a;
-    done
+    OUTDIR_NAME=${OUTDIR_NAME-"out-$host"}
 fi
+
+for a in `find -type d -and -not -name 'out'`; do
+       if test ! -d  $a/$OUTDIR_NAME; then
+               mkdir $a/$OUTDIR_NAME;
+       fi
+done
+
     
 AC_ARG_ENABLE(shared,
     [  enable-shared       shared flower library],
@@ -26,6 +28,11 @@ AC_ARG_ENABLE(optimise,
     [  disable-optimise    optimisations off],
     [optimise_b=$enableval])
 
+AC_ARG_ENABLE(out-dir,
+    [  out-dir                 set the directory for machine generated files. Default out or out-HOST],
+    [OUTDIR_NAME=$enableval]
+    [])
+
 if test $shared_b = yes; then
        MODULE_CXXFLAGS="$MODULE_CXXFLAGS -fPIC"
        MODULE_LDFLAGS="-shared -Wl,-soname,libflower.so "
@@ -44,9 +51,11 @@ AC_PROG_CXX
 AC_FUNC_MEMCMP
 AC_FUNC_VPRINTF
 AC_CHECK_FUNCS(memmem snprintf )
-AC_CONFIG_HEADER($flowerbuildprefix/out/config.hh:config.hh.in)
 
-CXX="$ac_cv_prog_CXX" ../bin/make-version > $flowerbuildprefix/out/version.hh
+if test ! -d $OUTDIR_NAME ; then
+    mkdir $OUTDIR_NAME
+fi
 
-AC_OUTPUT($flowerbuildprefix/out/Flower-flags.make:Flower-flags.make.in)
+AC_CONFIG_HEADER($OUTDIR_NAME/config.hh:config.hh.in)
+AC_OUTPUT($OUTDIR_NAME/Flower-flags.make:Flower-flags.make.in)
 
index 3cf2f93d20d06eb408242896caca1cdeacd37410..fc812423e5649e2f873b31286badba15de29311e 100644 (file)
@@ -9,6 +9,15 @@
 
 #include "diagonal-storage.hh"
 
+
+#ifdef INLINE
+#undef INLINE
+#endif
+
+#define INLINE inline
+
+#include "full-storage.icc"
+
 int
 Diagonal_storage::dim()const
 {
@@ -40,6 +49,7 @@ Diagonal_storage::band_size_i()const
 void
 Diagonal_storage::set_band_size(int s)
 {
+    assert( s>=0);
     Full_storage f(dim(), 2*s+1);
     for (int i=0; i < dim(); i++) {
        int k=-s;
@@ -110,7 +120,7 @@ void
 Diagonal_storage::resize_dim(int d)
 {
     Full_storage f(d, 2*band_size_i()+1);
-    for (int i=0; i < d&& i < dim(); i++) {
+    for (int i=0; i < d && i < dim(); i++) {
        for ( int k=0;  k < 2*band_size_i(); k++)
            f.elem(i,k) = elem(i,k);
     }
@@ -134,9 +144,7 @@ Diagonal_storage::mult_next(int &i, int &j)const
        j = i- band_size_i();
     if ( j > i + band_size_i() || j >= dim() ) {
        i++;
-       j = i - band_size_i(); 
-       if  (j < 0)
-           j=0;
+       j = 0 >? i - band_size_i(); 
     }
 }
 
@@ -155,9 +163,7 @@ Diagonal_storage::trans_next(int &i, int& j)const
     
     if ( i >= dim() || i > j + band_size_i() ) {
        j++;
-       i = j - band_size_i(); 
-       if  (i < 0)
-           i=0;
+       i = 0 >? j - band_size_i(); 
     }
 }
 
@@ -178,8 +184,9 @@ Diagonal_storage::elem(int i, int j)
     /*
       if this fails, the previous call fucked up
       */
-    assert(nul_entry);
-    if (abs ( i-j ) > band_size_i())
+    assert(!nul_entry);
+
+    if (abs ( i-j ) > band_size_i())  
        return nul_entry;
     else
        return band_.elem(i, j - i + band_size_i());
@@ -196,8 +203,8 @@ Diagonal_storage::try_right_multiply(Matrix_storage*dest,
     if ( right->name() != Diagonal_storage::static_name() ) 
        return false;
     
-    const Diagonal_storage*  diag = (Diagonal_storage const*)right;
-    int band2 = diag->band_size_i();
+    const Diagonal_storage*  right_diag = (Diagonal_storage const*)right;
+    int band2 = right_diag->band_size_i();
     int n = dim();
     /*
       should check if dest is a Diagonal_storage of sufficient size too.
@@ -209,7 +216,7 @@ Diagonal_storage::try_right_multiply(Matrix_storage*dest,
            int relk =  startk + band_size_i() -i;
            Real sum =0.0;
            for ( int k = startk; k <= stopk; k++)
-               sum += band_.elem(i, relk) * diag->elem(relk, j);
+               sum += band_.elem(i, relk++) * right_diag->elem(k, j);
            dest->elem(i, j) = sum;
            
        }
@@ -234,3 +241,5 @@ Diagonal_storage::OK() const
 {
     band_.OK();
 }
+
+IMPLEMENT_VIRTUAL_COPY_CONS(Diagonal_storage, Matrix_storage);
index c47285c71dee4a3b4b74f7ee7e84b7692a2c3cbf..a08f4563819bfd67a9be069d44bbedb662ad1a9a 100644 (file)
@@ -68,7 +68,7 @@ Directed_graph_node::remove_edge_out_idx(int i)
 
     int j = d_l->edge_in_l_arr_.find_i(this);
     assert(j>=0);
-    d_l->edge_in_l_arr_.del(j);
+    d_l->edge_in_l_arr_.unordered_del(j);
     PARANOID_OK();
 }
 
index 223796ba35337d095a06b43fe6580650b0409ec5..fd0d9f550be4a1c9b341e002bd404ef8492087eb 100644 (file)
@@ -8,6 +8,7 @@
 
 #include "full-storage.hh"
 
+
 void
 Full_storage::operator=(Full_storage const &fs)
 {
@@ -19,6 +20,7 @@ Full_storage::operator=(Full_storage const &fs)
            els_p_p_[i][j]= fs.els_p_p_[i][j];
 }
 
+
 void
 Full_storage::OK() const
 {
@@ -30,63 +32,18 @@ Full_storage::OK() const
 #endif
 }
 
-void
-Full_storage::resize_cols(int newh)
-{
-    if (newh <= max_height_i_) {
-       height_i_=newh;
-       return;
-    }
-   
-    Real ** newa=new Real*[newh];
-    int j=0;
-    for (; j < height_i_; j++)
-       newa[j] = els_p_p_[j];
-    for (; j < newh; j++)
-       newa[j] = new Real[max_width_i_];
-    delete[] els_p_p_;
-    els_p_p_=newa;
 
-    height_i_ = max_height_i_ = newh;
-}
 
 
-Full_storage::Full_storage(Matrix_storage*m)
+Full_storage::~Full_storage() 
 {
-    set_size(m->rows(), m->cols());
-    if ( !m->is_type_b ( Full_storage::static_name()))
-       for (int i=0; i<height_i_; i++)
-           for (int j=0; j<width_i_; j++)
-               els_p_p_[i][j]=0.0;
-    for (int i,j=0; m->mult_ok(i,j); m->mult_next(i,j))
-       els_p_p_[i][j] = m->elem(i,j);
-}
-
-void
-Full_storage::resize_rows(int neww)
-{
-    if (neww <= max_width_i_) {
-       width_i_=neww;
-       return;
-    }
-    for (int i=0; i < max_height_i_ ; i++) {
-       Real* newa = new Real[neww];
-       for (int k=0; k < width_i_; k++)
-           newa[k] = els_p_p_[i][k];
-
-       delete[] els_p_p_[i];
-       els_p_p_[i] = newa;
-    }
-    width_i_ = max_width_i_ = neww;    
-}
-
-Full_storage::~Full_storage() {
     for (int i=0; i < max_height_i_; i++)
        delete [] els_p_p_[i];
     delete[] els_p_p_;
 }
 
 void
+
 Full_storage::resize(int rows, int cols)
 {
     OK();
@@ -95,12 +52,14 @@ Full_storage::resize(int rows, int cols)
 }
 
 
+
 bool
 Full_storage::mult_ok(int i, int ) const
 {
     return i < height_i_;
 }
 
+
 bool
 Full_storage::trans_ok(int , int j) const
 {
@@ -108,6 +67,7 @@ Full_storage::trans_ok(int , int j) const
 } 
 
 
+
 void
 Full_storage::trans_next(int &i, int &j) const
 {
@@ -119,6 +79,7 @@ Full_storage::trans_next(int &i, int &j) const
     }
 }
 
+
 void
 Full_storage::mult_next(int &i, int &j) const
 {
@@ -130,6 +91,7 @@ Full_storage::mult_next(int &i, int &j) const
     }
 }
 
+
 void
 Full_storage::delete_column(int k)
 {
@@ -139,6 +101,8 @@ Full_storage::delete_column(int k)
            els_p_p_[i][j-1]=els_p_p_[i][j];
     width_i_--;
 }
+
+
 void
 Full_storage::delete_row(int k)
 {
@@ -150,6 +114,7 @@ Full_storage::delete_row(int k)
 }
 
 
+
 void
 Full_storage::insert_row(int k)
 {
@@ -161,19 +126,6 @@ Full_storage::insert_row(int k)
 
 }
 
-int
-Full_storage::dim()const
-{
-    assert (rows()==cols());
-    return rows();
-}
-
-Full_storage::Full_storage(Full_storage const&s)
-{
-    init();
-    (*this) = s;
-}
-
 bool
 Full_storage::try_right_multiply(Matrix_storage * dest, Matrix_storage const * right)const
 {
@@ -198,3 +150,61 @@ Full_storage::try_right_multiply(Matrix_storage * dest, Matrix_storage const * r
     
 }
 IMPLEMENT_IS_TYPE_B1(Full_storage,Matrix_storage);
+void
+Full_storage::resize_cols(int newh)
+{
+    if (newh <= max_height_i_) {
+       height_i_=newh;
+       return;
+    }
+   
+    Real ** newa=new Real*[newh];
+    int j=0;
+    for (; j < height_i_; j++)
+       newa[j] = els_p_p_[j];
+    for (; j < newh; j++)
+       newa[j] = new Real[max_width_i_];
+    delete[] els_p_p_;
+    els_p_p_=newa;
+
+    height_i_ = max_height_i_ = newh;
+}
+
+
+
+Full_storage::Full_storage(Matrix_storage*m)
+{
+    set_size(m->rows(), m->cols());
+    if ( !m->is_type_b ( Full_storage::static_name()))
+       for (int i=0; i<height_i_; i++)
+           for (int j=0; j<width_i_; j++)
+               els_p_p_[i][j]=0.0;
+    for (int i,j=0; m->mult_ok(i,j); m->mult_next(i,j))
+       els_p_p_[i][j] = m->elem(i,j);
+}
+
+
+void
+Full_storage::resize_rows(int neww)
+{
+    if (neww <= max_width_i_) {
+       width_i_=neww;
+       return;
+    }
+    for (int i=0; i < max_height_i_ ; i++) {
+       Real* newa = new Real[neww];
+       for (int k=0; k < width_i_; k++)
+           newa[k] = els_p_p_[i][k];
+
+       delete[] els_p_p_[i];
+       els_p_p_[i] = newa;
+    }
+    width_i_ = max_width_i_ = neww;    
+}
+
+#ifdef INLINE
+#undef INLINE
+#endif
+#define INLINE
+
+#include "full-storage.icc"
index 1ad45cb4632748d8d20acea150c27eecfe651145..b7716f26767acbb1ae0d20f436fae75118016b85 100644 (file)
@@ -14,5 +14,6 @@ include ./$(depth)/flower/VERSION
 #
 MODULE_NAME = flower
 
+
 #
 
index a3a02a11e0782d7d7c49ec41794fd1a547bbea9f..abd19ee67635a42476b06dca6944d9691a2d55d3 100644 (file)
@@ -30,7 +30,7 @@ struct Choleski_decomposition {
     solve Px = rhs
     */
     Vector solve(Vector rhs) const;
-
+    void solve (Vector &dest, Vector const &rhs)const;
     Vector operator * (Vector rhs) const { return solve (rhs); }
   /**
     return the inverse of the matrix P.
@@ -41,6 +41,8 @@ struct Choleski_decomposition {
     */
     Matrix original() const;
 private:
+    void full_matrix_solve(Vector &,Vector const&)const;
+    void band_matrix_solve(Vector &, Vector const&)const;
     void full_matrix_decompose(Matrix const & P);
     void band_matrix_decompose(Matrix const &P);
         
index 517c5cd814999cc464367505a088fdd49495c3de..f4515edfb1fd1317ce50f67fa940a057e294c193 100644 (file)
@@ -12,9 +12,9 @@
 #include "full-storage.hh"
 
 /**
-  Store a single-band matrix;
+  Store a  matrix with a single-band.
 
-  INVARIANT
+  @invariant
   
   Diagonal_storage(i,j) == band_(i, j-i + band_size_i())
   
@@ -58,7 +58,7 @@ public:
     virtual void mult_next(int &i, int &j) const ;
     virtual bool trans_ok(int i, int j) const;
     virtual void trans_next(int &i, int &j) const;
-    VIRTUAL_COPY_CONS(Diagonal_storage, Matrix_storage);
+    DECLARE_VIRTUAL_COPY_CONS(Diagonal_storage, Matrix_storage);
     DECLARE_MY_RUNTIME_TYPEINFO;
     virtual bool try_right_multiply(Matrix_storage * dest, Matrix_storage const *)const;
 };
index 78bafab43dc9c292f42fe57cb10ba8533fa0b96b..1dfb96e8fa04bf16beabebe31e3773ca986fda1a 100644 (file)
@@ -26,57 +26,28 @@ class Full_storage : public Matrix_storage
     Real** els_p_p_;
 
     void
-    init() {
-       els_p_p_=0;
-       height_i_=width_i_=max_height_i_=max_width_i_=0;
-
-    }
-    
-    bool valid(int i, int j) const {
-       return (i>=0 && i < height_i_)
-           && (j < width_i_ && j >=0);
-    }
-    
+    init() ;
+     
+    bool valid(int i, int j) const ; 
 
     void resize_rows(int);
     void resize_cols(int);
 
 public:
-    virtual int rows() const {
-       return height_i_;
-    }
-    virtual int cols() const {
-       return width_i_;
-    }
+    virtual int rows() const;
+    virtual int cols() const ;
     
     
     virtual void resize(int i, int j);
-    virtual void resize(int i) {
-       resize(i,i);
-    }
-    
-    virtual Real& elem(int i,int j) {
-       assert(valid(i,j));
-       return els_p_p_[i][j];
-    }
-    virtual Real elem(int i, int j) const {
-       assert(valid(i,j));
-       return els_p_p_[i][j];
-    }
+    virtual void resize(int i);
+    virtual Real& elem(int i,int j);
+    virtual Real elem(int i, int j)const ;
     int dim()const;
     Full_storage(Matrix_storage*);
-    Full_storage() {
-       init();
-    }
-    Full_storage(int i, int j) {
-       init();
-       set_size(i,j);
-    }
+    Full_storage();
+    Full_storage(int i, int j);
     Full_storage(Full_storage const&);
-    Full_storage(int i) {
-       init();
-       set_size(i);
-    }
+    Full_storage(int i);
     void OK() const;
     void operator=(Full_storage const &);
     
@@ -89,7 +60,7 @@ public:
     virtual void mult_next(int &i, int &j) const ;
     virtual bool trans_ok(int i, int j) const;
     virtual void trans_next(int &i, int &j) const;
-    VIRTUAL_COPY_CONS(Full_storage,Matrix_storage);
+    DECLARE_VIRTUAL_COPY_CONS(Full_storage,Matrix_storage);
     DECLARE_MY_RUNTIME_TYPEINFO;
     virtual bool try_right_multiply(Matrix_storage * dest, Matrix_storage const * )const;
 };
diff --git a/flower/include/full-storage.icc b/flower/include/full-storage.icc
new file mode 100644 (file)
index 0000000..06bcc9d
--- /dev/null
@@ -0,0 +1,94 @@
+/*
+  full-storage.icc -- implement Full_storage inline functions
+
+  source file of the Flower Library
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef FULL_STORAGE_ICC
+#define FULL_STORAGE_ICC
+
+
+INLINE void
+Full_storage::init()
+{
+    els_p_p_=0;
+    height_i_=width_i_=max_height_i_=max_width_i_=0;
+}
+INLINE bool
+Full_storage::valid(int i, int j)const
+{
+    return (i>=0 && i < height_i_)
+       && (j < width_i_ && j >=0);
+}
+
+
+INLINE
+Full_storage::Full_storage(Full_storage const&s)
+{
+    init();
+    (*this) = s;
+}
+
+INLINE Real& 
+Full_storage::elem(int i,int j)
+{
+    assert(valid(i,j));
+    return els_p_p_[i][j];
+}
+
+INLINE Real
+Full_storage::elem(int i, int j) const {
+    assert(valid(i,j));
+    return els_p_p_[i][j];
+}
+
+INLINE
+Full_storage::Full_storage() {
+    init();
+}
+
+
+INLINE int
+Full_storage::rows() const
+{
+    return height_i_;
+}
+INLINE int
+Full_storage::cols() const
+{
+    return width_i_;
+}
+INLINE int
+Full_storage::dim()const
+{
+    assert (rows()==cols());
+    return rows();
+}
+
+INLINE void
+Full_storage::resize(int i)
+{
+    resize(i,i);
+}
+
+INLINE   
+Full_storage::Full_storage(int i,int j)
+{
+    init();
+    set_size(i,j);
+}
+
+INLINE 
+Full_storage::Full_storage(int i)
+{
+    init();
+    set_size(i);
+}
+INLINE
+IMPLEMENT_VIRTUAL_COPY_CONS(Full_storage,Matrix_storage);
+
+#endif // FULL_STORAGE_ICC
index 1e7404ee5565edf2c34f9157700712288a677670..61c69495c22ac1db08d7993db13bc943c75fc968 100644 (file)
@@ -39,6 +39,17 @@ public:
            else
                del(i);
     }
+    void unordered_substitute(T* old, T * new_l)
+    {
+       int i;
+       while ((i = find_i(old)) >=0) 
+           if (new_l)
+               elem(i) =new_l;
+           else {
+               unordered_del( i );
+           }
+    
+    }
     void default_sort() {
        sort(default_compare);
     }
index 30fa2cb6d6e42db46c4a6c89cd3c33264aabfaec..d3b68f726fba9d0c5c584721a55313c19a015b20 100644 (file)
@@ -1 +1,17 @@
+/*
+  rational.hh -- declare 
+
+  source file of the Flower Library
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef RATIONAL_HH
+#define RATIONAL_HH
 #include <Rational.h>
+
+/// print a Rational. To be called from the  debugger
+void print_rat(Rational const&);
+
+#endif // RATIONAL_HH
index 0533af2111a5510ce0624bf674f805fa8b5a1563..457b82f967f13c278c72aca8402b05c2fd715ca4 100644 (file)
@@ -1,3 +1,12 @@
+/*
+  real.hh -- declare Real
+
+  source file of the Flower Library
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
 #ifndef REAL_HH
 #define REAL_HH
 
 #include <builtin.h>
 #include <minmax.h>
 #include <math.h>
+#include <limits.h>
 
 typedef double Real;
+const Real infinity_f = HUGE_VAL;
 
 inline Real
 distance(Real x,Real y)
 {
     return abs(x-y);
 }
+
 #endif
index 5fe5fa39434bc85f17cdee8a833584dd38241e32..6f0e18aedca6dfc2c9c300291e73e5e822b1100b 100644 (file)
@@ -164,6 +164,11 @@ public:
        del (i);
        return t;
     }
+    void unordered_del(int i)
+    {
+       elem(i) = top();
+       set_size(size() -1);
+    }
     void del(int i) {
        assert(i >=0&& i < size_);
        arrcpy(thearray+i, thearray+i+1, size_-i-1);
@@ -192,7 +197,7 @@ public:
        set_size(size_ + src.size_);
        arrcpy(thearray+s,src.thearray, src.size_);     
     }
-    Array<T> subvec(int lower, int upper) {
+    Array<T> slice(int lower, int upper) {
        assert(lower >= 0 && lower <=upper&& upper <= size_);
        Array<T> r;
        int s =upper-lower;
index fdeab97f1391b84997d7528d9e0334588a5b6aa7..7f7573534498fdd125edccaf5a2dcaa51ece4187 100644 (file)
@@ -23,6 +23,11 @@ public:
        dat.set_size(n);
        fill(0);
     }
+    void set_dim(int i)
+    {
+       dat.set_size(i);
+    }
+       
     void insert(Real v, int i) {
        dat.insert(v,i);
     }
index 88dad44aebc96825c0086d257976c618831e8b9e..ceb12694e3ca0a8c832c8c6e10e504ab8045fd3f 100644 (file)
@@ -24,10 +24,18 @@ int a_stupid_nonexistent_function_to_allow_the_semicolon_come_out()
 #define IMPLEMENT_STATIC_NAME(c)\
     char const *c::static_name() { return #c; } 
 
+
+
 #define VIRTUAL_COPY_CONS(T, R)\
   virtual R *clone() const { return  new T(*this); } \
   int  yet_another_stupid_function_to_allow_semicolon()
 
+
+#define DECLARE_VIRTUAL_COPY_CONS(T,R)\
+      virtual R *clone() const
+#define IMPLEMENT_VIRTUAL_COPY_CONS(T,R)\
+       R *T::clone() const { return  new T(*this); } \
+    
 #define IMPLEMENT_IS_TYPE_B(D)                                                            \
     IMPLEMENT_STATIC_NAME(D)\
   bool D::static_is_type_b(const char *s)                                         \
index 76b89f7f36603533d6f46477d30ad45c28aafc43..54deb7d673145f66f8bf7a518ed608e756f00cbc 100644 (file)
@@ -19,8 +19,8 @@ Matrix_storage::set_addition_result(Matrix_storage *&dat, Matrix_storage *right)
 
        if ( R->band_size_i() > L->band_size_i()) { 
            L->set_band_size(R->band_size_i());
-           return ;
        }
+           return ;
     }
     if  (!dat || !dat->is_type_b(Full_storage::static_name() )) {
 
index 78e3d777b01237593e144a6c10851257c95f55b5..7e1854827b223149729514389bb4d261e13f5833 100644 (file)
@@ -108,6 +108,10 @@ Matrix::operator=(Matrix const &m)
 int
 Matrix::band_i()const
 {
+    if ( band_b() ) {
+       Diagonal_storage const * diag = (Diagonal_storage*) dat;
+       return diag->band_size_i();
+    }
     int starty = dim();
     while (starty >= 0 ) {
        for ( int i = starty, j = 0; i < dim(); i++, j++ )
@@ -206,9 +210,13 @@ operator /(Matrix const& m1,Real a)
     return  m;
 }
 
+/*
+  ugh. Only works for square matrices.
+ */
 void
 Matrix::transpose()            // delegate to storage?
 {
+#if 1
     for (int i=0, j=0; dat->mult_ok(i,j); dat->mult_next(i,j)) {
        if (i >= j)
            continue;
@@ -216,6 +224,7 @@ Matrix::transpose()         // delegate to storage?
        dat->elem(i,j) = dat->elem(j,i);
        dat->elem(j,i)=r;
     }
+#endif
 }
 
 Matrix
@@ -252,6 +261,7 @@ Matrix::set_product(Matrix const &m1, Matrix const &m2)
     
     if (m1.dat->try_right_multiply(dat, m2.dat))
        return; 
+    
     for (int i=0, j=0; dat->mult_ok(i,j);
         dat->mult_next(i,j)) {
        Real r=0.0;
diff --git a/flower/rational.cc b/flower/rational.cc
new file mode 100644 (file)
index 0000000..b1056c2
--- /dev/null
@@ -0,0 +1,18 @@
+/*
+  rational.cc -- implement Rational related functions
+
+  source file of the Flower Library
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+#include "rational.hh"
+#include "string.hh"
+
+void
+print_rat(Rational const &m)
+{
+    cout << String(m) << flush;
+}
+    
+
index f7ce01bfc5fc2186c04fc73dbd555efc6724ad3d..8fdc7d794ebe3af24a0095e89452aac5524c8daa 100644 (file)
@@ -47,7 +47,7 @@ matrix()
     Matrix hilbert(N,N), h2(hilbert);
     for (int i=0; i < N; i++) {
        for (int j=0; j < N; j++) {
-           hilbert(i,j) = 1/(i+j+1);
+           hilbert(i,j) = 1/Real(i+j+1);
             h2 (i,j) = (abs(i-j) > 3) ?0 : hilbert(i,j);
        }
     }
@@ -55,6 +55,10 @@ matrix()
     Choleski_decomposition ch(h2);
     cout << "red Hilbert  " <<  h2;
     cout << "choleski " << ch.L;
+    Matrix T =ch.L.transposed();
+    cout << "L^T " <<  T;
+    cout << "L * L^T" << ch.L * T;
+    cout << "H2^{-1} * H2" << h2 * ch.inverse();
 }
 
 ADD_TEST(matrix);
index 04e0bb285554bd108ac6b2ef4c12db4aed30767e..de6a68c3ac724342d2e0fade60324417677a8d88 100644 (file)
@@ -2,6 +2,9 @@
 \include "table16.ly"
 \include "engraver.ly"
 
+Gourlay = 1.0
+Wordwrap = 0.0
+
 default_paper = \paper {
        linewidth = 15.0 \cm;
        rule_thickness = 0.4\pt;
@@ -15,6 +18,9 @@ default_paper = \paper {
        %
        interbeam = 2.667\pt;
        geometric = 1.414;
+       gourlay_energybound = 50000.;
+       gourlay_maxmeasures = 6.;
+       castingalgorithm = \Gourlay;
        \symboltables { \table_sixteen }
        \requesttranslator { \orchestral_score_translator }
 }
diff --git a/input/rock.ly b/input/rock.ly
new file mode 100644 (file)
index 0000000..b6434ab
--- /dev/null
@@ -0,0 +1,4 @@
+
+mel = \melodic { 
+       [c8 c32 c16] 
+}
index 49d0062a91c5ae2d61a3670cfc991e69ef9f0ba8..6807b651d52b1854d76475ae81266d4d733dfbcd 100644 (file)
@@ -174,8 +174,7 @@ bassdux =
              >
 
     \paper{
-%      unitspace = 40.0\pt;    geometric = 1.6;
-%      geometric= 1.4; unitspace= 34.\pt;
+%      castingalgorithm=0.;
     }
     \midi {
         \tempo 4:84;
index 280af9ce067401caefb248da93b8d2710d2d0744..1fbb2d83c27b1022761e7321b0ae083389cd9faa 100644 (file)
@@ -37,7 +37,7 @@ VERSION_DEPENDENCY =#
 
 # list of distribution files:
 #
-DISTFILES = Makefile $(ALL_SOURCES)
+EXTRA_DISTFILES = config.hh.in
 #
 
 # list of custom libraries:
diff --git a/lib/config.hh.in b/lib/config.hh.in
new file mode 100644 (file)
index 0000000..2aa23df
--- /dev/null
@@ -0,0 +1,6 @@
+/* @configure_input@ */
+#ifndef CONFIG_HH
+#define CONFIG_HH
+#define  DIR_DATADIR "@DIR_DATADIR@"
+
+#endif
index 4f44c07fd965c9b92af0aadfe54abba14702a9c6..bbd3388e742fba9c8c8aa6a621a95b6450284476 100644 (file)
@@ -5,10 +5,24 @@
 #ifndef MOMENT_HH
 #define MOMENT_HH
 
+#include <limits.h>
 #include "rational.hh"
+
+/**
+  A really big time-moment.
+
+  Windhoze-suck-suck-suck-suck-suck-thank-you-cygnus
+
+  I get tired of all these incompatibilities.  Let's just assume that
+  INT_MAX is really, really, really big.
+
+  Can't we name this Saint_jut_mom (Sintjuttemis ?)  */
+  
+const infinity_mom = Rational(INT_MAX);
+
 class String;
 typedef Rational Moment;
-void printm(Moment const&);
+
 
 
 #endif // 
index 65065454be5433eb38ffe361cb53610b2d355b46..785fb9e0e411af4028e2e6f842ee660661b949af 100644 (file)
@@ -12,6 +12,8 @@
 depth = ..
 #
 
+NAME = lilypond
+
 # generic variables:
 #
 include Stable.make
@@ -21,7 +23,6 @@ include VERSION
 
 # identify module:
 #
-NAME = lilypond
 
 #
 
@@ -69,3 +70,5 @@ localclean:
 localinstall: installexe
 
 localuninstall: uninstallexe
+
+$(outdir)/lily-version.o: $(outdir)/version.hh
index 57ea2528d1e8c1076ae58cec3ee964c9484ebd03..885745a247c5d518ef9d6bd118b1c4c6558de138 100644 (file)
@@ -5,8 +5,6 @@ stablecc=atom.cc command-request.cc musical-request.cc bar.cc boxes.cc \
        keyword.cc leastsquares.cc \
        lookup.cc meter.cc\
        parser.cc \
-#      lexer.cc \
        qlp.cc qlpsolve.cc\
-       template1.cc template2.cc template3.cc template4.cc\
-       template5.cc template6.cc version.cc tex-stream.cc  tex.cc\
+       template*.cc  template6.cc version.cc tex-stream.cc  tex.cc\
        identifier.cc note.cc
index a31769b185e03d3e1203386bb157e3f12a601654..013490db64f6405e364965f74cf70f94021f3e8a 100644 (file)
@@ -1,6 +1,6 @@
 MAJOR_VERSION = 0
 MINOR_VERSION = 1
-PATCH_LEVEL = 0
+PATCH_LEVEL = 1
 # use to send patches, always empty for released version:
 # include separator: ".postfix", "-pl" makes rpm barf
 
index f83f7659e929eca8fe24a4771caf09c9d2020c7a..1798cb93c3033162798b3131d29d248aab1976d2 100644 (file)
@@ -1,5 +1,4 @@
 #include "boxes.hh"
-#include "const.hh"
 #include "varray.hh"
 
 
diff --git a/lily/break-caching.cc b/lily/break-caching.cc
new file mode 100644 (file)
index 0000000..8b13789
--- /dev/null
@@ -0,0 +1 @@
+
index 8d3779e4da1eb7bdf842b343b9b2e4164e30d657..1ef5c4bc6f48b41b63831e14c942e0b9c4889e82 100644 (file)
 #include "p-score.hh"
 #include "p-col.hh"
 
+String
+Col_stats::str() const { 
+    String s(count_i_);
+    s += " lines";
+    if  (count_i_)
+       s += String(Real(cols_i_)/count_i_, ", (with an average of %.1f columns)");
+    
+    return s;
+}
+
+void
+Col_stats::add(Line_of_cols const& line)
+{
+    count_i_++;
+    cols_i_ += line.size();
+}
+
+
+Col_stats::Col_stats()
+{
+    count_i_ =0;
+    cols_i_ =0;
+}
+
+/* **************************************************************** */
+
+Line_of_cols
+Break_algorithm::all_cols()const
+{
+    Line_of_cols retval;
+    for (PCursor<PCol*> c(pscore_l_->col_p_list_.top()); 
+        c.ok(); c++) {
+       
+       retval.push(c);
+    }
+    return retval;
+}
+
+Array<int> 
+Break_algorithm::find_break_indices() const
+{
+    Line_of_cols all(all_cols());
+    Array<int> retval;
+    
+    for (int i=0; i < all.size(); i++)
+       if (all[i]->breakable_b())
+           retval.push(i);
+    
+    if ( linelength <=0)
+       while ( retval.size() >2)
+           retval.del(1);
+
+    return retval;
+}
+
 ///  return all breakable columns
 Line_of_cols
 Break_algorithm::find_breaks() const
 {
+    Line_of_cols all(all_cols());
     Line_of_cols retval;
-    for (iter_top(pscore_l_->col_p_list_,c); c.ok(); c++) {
-       if (c->breakable_b())
-           retval.push(c);
-    }
+    
+    for (int i=0; i < all.size(); i++)
+       if (all[i]->breakable_b())
+           retval.push(all[i]);
+
+
     if ( linelength <=0)
        while ( retval.size() >2)
            retval.del(1);
 
     return retval;
 }
+
+
+
  
+
 Line_spacer*
 Break_algorithm::generate_spacing_problem(Line_of_cols curline)const
 {
     Line_spacer * sp= (*get_line_spacer)();
+
     sp->paper_l_ = pscore_l_->paper_l_;
     sp->add_column(curline[0], true, 0.0);
     for (int i=1; i< curline.size()-1; i++)
@@ -44,46 +107,24 @@ Break_algorithm::generate_spacing_problem(Line_of_cols curline)const
        sp->add_column(curline.top(), true, linelength);
     else
        sp->add_column(curline.top());
-    return sp;
-}
 
-Col_hpositions
-Break_algorithm::stupid_solution(Line_of_cols curline)const
-{
-    Line_spacer *sp =generate_spacing_problem(curline);
-    Col_hpositions colhpos;
-    colhpos.cols = curline;
-    colhpos.energy = INFTY_f;
-    colhpos.ugh_b_ = true;
-    colhpos.config = sp->default_solution();
-    delete sp;
-    return colhpos;
+    sp->prepare();
+    return sp;
 }
 
-/// construct an appropriate Spacing_problem and solve it. 
-Col_hpositions
-Break_algorithm::solve_line(Line_of_cols curline) const
+Break_algorithm::Break_algorithm()
 {
-    Line_spacer *sp = generate_spacing_problem(curline);
-    sp->prepare();
-   
-    Array<Real> the_sol=sp->solve();
-    Col_hpositions col_hpos;
-    col_hpos.cols = curline;
-    col_hpos.energy = the_sol.pop();
-    col_hpos.config = the_sol;
-    col_hpos.error_col_l_arr_ = sp->error_pcol_l_arr();
-    col_hpos.OK();
-    delete sp;
-   
-    return col_hpos;
+    pscore_l_ = 0;
+    get_line_spacer =0;
+    linelength = 0;
 }
 
-Break_algorithm::Break_algorithm(PScore&s)
+void
+Break_algorithm::set_pscore(PScore*s)
 {
-    pscore_l_ = &s;
-    get_line_spacer =0;
-    linelength = s.paper_l_->linewidth_f();
+    pscore_l_ = s;
+    linelength = s->paper_l_->linewidth_f();
+    do_set_pscore();
 }
 
 bool
@@ -124,3 +165,17 @@ Break_algorithm::solve()const
     return do_solve();
 }
 
+void
+Break_algorithm::do_set_pscore()
+{
+    
+}
+
+void
+Break_algorithm::print_stats()const
+{
+    if (approx_stats_.count_i_)
+       *mlog << "\nApproximated: " << approx_stats_.str() << "\n";
+    if (exact_stats_.count_i_)
+       *mlog << "Calculated exactly: " << exact_stats_.str() << "\n";
+}
index e87c22f3c56bea77f51258cf4fc1bbd5c4d4a88f..aade26ac49beb35a2888ddaf98bcb650611540dd 100644 (file)
@@ -1,13 +1,28 @@
+/*
+  colhpos.cc -- implement Col_hpositions
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
 #include "colhpos.hh"
 #include "real.hh"
 #include "debug.hh"
-#include "const.hh"
 #include "vector.hh"
+#include "line-spacer.hh"
 
 Col_hpositions::Col_hpositions()
 {
-    energy = INFTY_f;
+    energy_f_ = infinity_f;
     ugh_b_ = false;
+    satisfies_constraints_b_ = false;
+    spacer_l_ =0;
+}
+
+Col_hpositions::~Col_hpositions()
+{
+
 }
 
 void
@@ -20,7 +35,7 @@ void
 Col_hpositions::print() const
 {
 #ifndef NPRINT
-    mtor << "energy : " << energy << '\n';
+    mtor << "energy : " << energy_f_ << '\n';
     mtor << "line of " << config.size() << " cols\n";
     Vector v(config);
     mtor << v;
@@ -34,3 +49,26 @@ Col_hpositions::OK()const
     assert(config.size() == cols.size());
 #endif
 }
+
+void
+Col_hpositions::stupid_solution()
+{
+    energy_f_ = infinity_f;
+    ugh_b_ = true;
+    config = spacer_l_->default_solution();
+}
+
+void
+Col_hpositions::solve_line() 
+{
+    spacer_l_->solve(this);
+}
+
+
+void
+Col_hpositions::approximate_solve_line() 
+{
+    spacer_l_->lower_bound_solution(this);
+}
+
+
index 0d44ccbd351e657f09c53a0dafe0259183282ee3..cf5ef632f8533752febb5df770dbe84127754480 100644 (file)
@@ -186,9 +186,11 @@ Key_change_req::squash_octaves()
 void
 Key_change_req::do_print() const
 {
+#ifndef NPRINT
     for (int i=0; i < melodic_p_arr_.size(); i++) {
        melodic_p_arr_[i]->print();
     }
+#endif
 }
 
 Key_change_req::Key_change_req()
index 3d046bd4147ffdc26a486b54b4366423b49999f3..654578dcb13c4838115b9958449a49a078c4043e 100644 (file)
@@ -9,7 +9,7 @@
 
 Dstream *monitor=0;
 ostream * nulldev =0;
-static void (*rat_printer)(Moment const&);
+
 
 // ugh
 struct _Dinit {
@@ -41,10 +41,13 @@ float_handler(int)
     assert(false);
 }
 
+/// just to make sure print_rat is linked in
+static void (*rat_printer)(Moment const&);
+
 void
 debug_init()
 {
-    rat_printer = printm;      // make sure this is linked in
+    rat_printer = print_rat;   
 #ifndef NDEBUG
     set_new_handler(&mynewhandler);
 #endif
index c1903ffcd065d0909a1ea1dae77079b7b4b6a84a..138bd146a372a72beb3c8ee66949f9498325b42a 100644 (file)
@@ -8,6 +8,7 @@
 
 
 #include "elem-group-item.hh"
+#include "p-col.hh"
 
 void
 Horizontal_vertical_group_item::do_print()const
@@ -16,6 +17,3 @@ Horizontal_vertical_group_item::do_print()const
 }
 
 IMPLEMENT_IS_TYPE_B2(Horizontal_vertical_group_item,Horizontal_vertical_group,Item);
-    
-IMPLEMENT_IS_TYPE_B2(Horizontal_group_item, Horizontal_group, Item);
-
index e60570ed6655816847ce467bc0d003bde50e330a..badb6db85102ac2d91bd86d6a0959ea358729806 100644 (file)
@@ -17,6 +17,11 @@ Elbement_group::contains_b(Score_elem const*e)const
     return elem_l_arr_.find_l(e);
 }
 
+Elbement_group::Elbement_group(Elbement_group const &s)
+    : Score_elem(s)
+{
+}
+
 Interval
 Vertical_group::do_height()const 
 {
@@ -54,14 +59,17 @@ Elbement_group::add_element(Score_elem*i_l)
 void
 Horizontal_group::add_element(Score_elem*elt)
 {
-    elt->x_group_element_i_ ++;
+    assert ( !elt->x_group_l_ );
+    elt->x_group_l_ = this;
     Elbement_group::add_element(elt);
 }
 
 void
 Vertical_group::add_element(Score_elem*e)
 {
-    e->y_group_element_i_++;
+    assert( ! e->y_group_l_ );
+    e->y_group_l_ = this;
+
     Elbement_group::add_element(e);
 }
 
@@ -98,13 +106,13 @@ Horizontal_group::do_substitute_dependency(Score_elem* old, Score_elem *new_l)
     int i;
 
     while ((i=elem_l_arr_.find_i(old))>=0) {
-       old->x_group_element_i_--;
+       old->x_group_l_ =0;
        
        if (new_l){ 
-           new_l->x_group_element_i_ ++;
+           new_l->x_group_l_ = this;
            elem_l_arr_[i] = new_l;
        }else {     
-           elem_l_arr_.del(i);
+           elem_l_arr_.unordered_del(i);
        }
     }
 }
@@ -115,13 +123,13 @@ Vertical_group::do_substitute_dependency(Score_elem* old, Score_elem *new_l)
     int i;
 
     while ((i=elem_l_arr_.find_i(old))>=0) {
-       old->y_group_element_i_--;
+       old->y_group_l_ =0;
        
        if (new_l){ 
-           new_l->y_group_element_i_ ++;
+           new_l->y_group_l_ =this;
            elem_l_arr_[i] = new_l;
        }else {     
-           elem_l_arr_.del(i);
+           elem_l_arr_.unordered_del(i);
        }
     }
 }
@@ -130,16 +138,12 @@ Vertical_group::Vertical_group(Vertical_group
                               const &s)
     : Elbement_group(s)
 {
-   for (int i=0; i < elem_l_arr_.size(); i++) 
-       elem_l_arr_[i]->y_group_element_i_ ++;   
 }
 
 Horizontal_group::Horizontal_group(Horizontal_group 
                                   const &s)
-    : Elbement_group(s)
+       : Elbement_group(s)
 {
-   for (int i=0; i < elem_l_arr_.size(); i++) 
-       elem_l_arr_[i]->x_group_element_i_ ++;   
 }
 
 Elbement_group::Elbement_group()
@@ -185,3 +189,17 @@ Horizontal_group::do_print() const
 {
     Elbement_group::do_print();
 }
+
+
+
+void
+Vertical_group::remove_element(Score_elem*s)
+{
+    remove_dependency( s );
+}
+
+void
+Horizontal_group::remove_element(Score_elem*s)
+{
+    remove_dependency( s );
+}
index a1a77d7da1e604ef930d28494e5d169081d414f6..672c8f2e5f33d760bb314217484b2df1650c98d2 100644 (file)
@@ -174,6 +174,8 @@ void
 Engraver_group_engraver::do_print()const
 {
 #ifndef NPRINT
+    if ( !check_debug)
+       return ;
     mtor << "ID: " << id_str_ << "\n";
     for (PCursor<Engraver*> i(grav_list_.top()); i.ok(); i++)
        i->print();
diff --git a/lily/gourlay-breaking.cc b/lily/gourlay-breaking.cc
new file mode 100644 (file)
index 0000000..03f6d3c
--- /dev/null
@@ -0,0 +1,177 @@
+/*
+  gourlay-breaking.cc -- implement Gourlay_breaking
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+#include "gourlay-breaking.hh"
+#include "colhpos.hh"
+#include "spring-spacer.hh"
+#include "debug.hh"
+#include "p-col.hh"
+#include "p-score.hh"
+#include "paper-def.hh"
+
+
+const HAPPY_DOTS_I = 3;
+
+/**
+  Helper to trace back an optimal path 
+ */
+struct Break_node {
+    /** this was the previous. If negative, this break should not be
+      considered: this path has infinite energy
+      
+     */
+    int prev_break_i_;
+    Real energy_f_;
+    Col_hpositions line_config_;
+    Break_node() {
+       prev_break_i_ = -1;
+    }
+};
+
+/**
+  This algorithms is adapted from 
+ */
+
+Array<Col_hpositions>
+Gourlay_breaking::do_solve()const
+{
+
+    Array<Break_node> optimal_paths;
+    Line_of_cols all = all_cols();
+    Array<int> breaks = find_break_indices();
+    
+    optimal_paths.set_size(breaks.size());
+
+    Break_node first_node ;
+    first_node.prev_break_i_ = -1;
+    first_node.line_config_.energy_f_ = 0;
+    
+    optimal_paths[0] = first_node; 
+    int break_idx=1;
+
+  
+    for (; break_idx< breaks.size(); break_idx++) {
+       Array<int> candidates;
+       Array<Col_hpositions> candidate_lines;
+       Pointer_list<Line_spacer*> spacer_p_list;
+       
+       /*
+         start with a short line, add measures. At some point 
+         the line becomes infeasible. Then we don't try to add more 
+        */
+       for (int start_idx = break_idx; start_idx--; ){
+           if  (break_idx - start_idx > max_measures_i_) 
+               break;
+
+           if (optimal_paths[start_idx].prev_break_i_ < 0
+               && optimal_paths[start_idx].line_config_.energy_f_)
+               
+               continue;
+           
+           Line_of_cols line = all.slice(breaks[start_idx], breaks[break_idx]+1);
+           
+           line[0] = line[0]->postbreak_p_;
+           line.top() = line.top()->prebreak_p_;
+           
+           if (!feasible(line))
+               break;
+           
+           Col_hpositions approx;
+           approx.cols = line;
+           
+           approx.spacer_l_ = generate_spacing_problem( line );
+           spacer_p_list.bottom().add(approx.spacer_l_);
+
+           ((Break_algorithm*)this)->approx_stats_.add( approx.cols );
+           approx.approximate_solve_line(  );
+           
+           if  (approx.energy_f_  > energy_bound_f_ ){ 
+               continue;
+           }
+
+           
+           // this is a likely candidate. Store it.
+           candidate_lines.push( approx );
+           candidates.push( start_idx );
+       }
+
+           
+       int minimal_j = -1;
+       Real minimal_energy = infinity_f;
+       for (int j=0; j < candidates.size(); j++) {
+           int start = candidates[j];
+           if ( optimal_paths[start].line_config_.energy_f_
+                + candidate_lines[j].energy_f_  > minimal_energy)
+               
+               continue;
+
+           if ( !candidate_lines[j].satisfies_constraints_b_) {
+                candidate_lines[j].solve_line( );
+                ((Break_algorithm*)this)->exact_stats_.add ( candidate_lines[j].cols );
+           }
+           
+           Real this_energy 
+               = optimal_paths[start].line_config_.energy_f_ 
+               + candidate_lines[j].energy_f_ ;
+           
+           if ( this_energy < minimal_energy ) {
+               minimal_j = j;
+               minimal_energy = this_energy;
+           }
+       }
+
+       if (minimal_j < 0) {
+           optimal_paths[break_idx].prev_break_i_ = -1;
+           optimal_paths[break_idx].line_config_.energy_f_ = infinity_f;
+       } else {
+           optimal_paths[break_idx].prev_break_i_ = candidates[minimal_j];
+           optimal_paths[break_idx].line_config_ = candidate_lines[minimal_j];
+       }
+
+       if ( !(break_idx % HAPPY_DOTS_I) )
+           *mlog << "[" << break_idx << "]"<<flush;
+    }
+
+    if  ( break_idx % HAPPY_DOTS_I) 
+       *mlog << "[" << break_idx << "]"<<flush;
+    print_stats();
+
+    
+
+    Array<int> final_breaks;
+
+    /* skip 0-th element, since it is a "dummy" elt*/
+    for (int i = optimal_paths.size()-1; i> 0; ) {
+       final_breaks.push ( i );
+       assert ( i > optimal_paths[i].prev_break_i_);
+       i = optimal_paths[i].prev_break_i_;
+    }
+
+    Array<Col_hpositions> lines;
+    for (int i= final_breaks.size(); i--; ) 
+       lines.push ( optimal_paths[final_breaks[i]].line_config_ );
+
+    
+    return lines;
+}
+
+
+Gourlay_breaking::Gourlay_breaking()
+{
+    get_line_spacer = Spring_spacer::constructor;
+    energy_bound_f_ = infinity_f;
+    max_measures_i_ = INT_MAX;
+}
+
+void
+Gourlay_breaking::do_set_pscore()
+{
+    energy_bound_f_ = pscore_l_->paper_l_->get_var(  "gourlay_energybound");
+    max_measures_i_ =int (rint( pscore_l_->paper_l_->get_var(  "gourlay_maxmeasures")));
+}
+
index 9d466b912f6bb4f5ccaf8e4d8132f742d201a18b..0781bf9cb32de9995badb74ea21244ea214b83b9 100644 (file)
@@ -140,7 +140,7 @@ Rhythmic_grouping::split(Array<MInterval> splitpoints)
                ch.push(children[i]);
            } else {
                Rhythmic_grouping *newchild=new Rhythmic_grouping(
-                   children.subvec(starti, i+1));
+                   children.slice(starti, i+1));
 
                ch.push(newchild);
            }
diff --git a/lily/groupregs.cc b/lily/groupregs.cc
deleted file mode 100644 (file)
index e69de29..0000000
index 972b52f8e0812f0472f6b5a177d6e37bbcdf2501..46c9b70b853b2a40d761e7ad48d6ec727e337ced 100644 (file)
 
 
 IMPLEMENT_IS_TYPE_B1(Horizontal_align_item,Item);
-
-
+void
+Horizontal_align_item::OK() const
+{
+   for  (int i =0; i < item_l_arr_.size(); i++) 
+       assert ( pcol_l_ == item_l_arr_[i]->pcol_l_ );
+}
 bool
 Horizontal_align_item::contains_b(Item *i)const
 {
@@ -57,6 +61,7 @@ struct Horizontal_align_item_content {
 void
 Horizontal_align_item::do_pre_processing()
 {
+    OK();
     {  
        Array<Horizontal_align_item_content> content;
        for  (int i =0; i < item_l_arr_.size(); i++) 
diff --git a/lily/horizontal-group-item.cc b/lily/horizontal-group-item.cc
new file mode 100644 (file)
index 0000000..15af0bd
--- /dev/null
@@ -0,0 +1,41 @@
+/*
+  horizontal-group-item.cc -- implement Horizontal_group_item
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+#include "p-col.hh"
+#include "horizontal-group-item.hh"
+
+IMPLEMENT_IS_TYPE_B2(Horizontal_group_item, Horizontal_group, Item);
+
+void
+Horizontal_group_item::OK() const
+{
+    for (int i=0; i < elem_l_arr_.size(); i++) {
+       Item * it_l = elem_l_arr_[i]->item();
+       
+       assert(it_l&& it_l->pcol_l_ == pcol_l_ );
+    }
+}
+
+void
+Horizontal_group_item::do_breakable_col_processing()
+{
+    if (!pcol_l_->breakable_b())
+       return;
+    OK();
+    copy_breakable_items();
+    
+    Link_array<Score_elem> elems = elem_l_arr_;
+
+    for (int i=0; i < elems.size(); i++) {
+       Item* it_l = elems[i]->item();
+       for ( int j=0; j < 2; j++) {
+           Item *new_l = it_l->find_prebroken_piece(broken_to_a_[j]->pcol_l_);
+           ((Horizontal_group_item*)broken_to_a_[j])->add_element( new_l );
+       }
+    }
+}
diff --git a/lily/include/break-caching.hh b/lily/include/break-caching.hh
new file mode 100644 (file)
index 0000000..73b07d2
--- /dev/null
@@ -0,0 +1,23 @@
+/*
+  break-caching.hh -- declare Break_caching
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef BREAK_CACHING_HH
+#define BREAK_CACHING_HH
+
+/**
+  TODO : store breakpoints on the disk.
+ */
+struct Break_caching : Break_algorithm
+{
+    void do_set_pscore();
+    Array<Col_hpositions> do_solve()const;
+};
+
+    
+#endif // BREAK_CACHING_HH
index bb37f4aeabff3d7a6ac4c4fcb628319b30a9dfc0..e016a8806afa7ca008952f74edd10f725659445f 100644 (file)
 #include "lily-proto.hh"
 #include "colhpos.hh"
 
+
+/**
+  Statistics for the number of columns calced.
+ */
+struct Col_stats
+{
+    int count_i_;
+    int cols_i_;
+
+    Col_stats(); 
+    void add(Line_of_cols const&l);
+    String str()const;
+};
+
 /** Class representation of an algorithm which decides where to put
   the column, and where to break lines.
   
-  TODO: a decent algorithm, based on dynamic programming or something
-  a like. A "parindent", caching of breakpoints
+  TODO:  A "parindent", caching of breakpoints
   
   */
 class Break_algorithm {
-    Line_spacer* generate_spacing_problem(Line_of_cols)const;
 protected:
+
     PScore *pscore_l_;
     Real linelength;
 
     /// search all pcols which are breakable.
     Line_of_cols find_breaks() const;
 
-     /// helper: solve for the columns in #curline#.
-    Col_hpositions solve_line(Line_of_cols) const;
+    Line_of_cols all_cols() const;
+    Array<int> find_break_indices()const;
+    
+
+    /// helper: solve for the columns in #curline#.
+    void solve_line(Col_hpositions*) const;
+
+    /// helper: approximate the energyv
+    void approximate_solve_line(Col_hpositions*) const;
 
     /// does curline fit on the paper?    
     bool feasible(Line_of_cols)const;
     
 
-    /** generate a solution with no regard to idealspacings or
-      constraints.  should always work */
-    Col_hpositions stupid_solution(Line_of_cols) const;
+    Line_spacer* generate_spacing_problem(Line_of_cols)const;
+
     virtual Array<Col_hpositions> do_solve()const=0;
+    void print_stats()const;
+
+    virtual void do_set_pscore();
 public:
+    Col_stats approx_stats_;
+    Col_stats exact_stats_;
+
     Line_spacer* (*get_line_spacer)();
     
-    Break_algorithm(PScore&);
+    Break_algorithm();
+    void set_pscore(PScore*);
 
     /// check if the spacing/breaking problem is well-stated
     void problem_OK()const;
index a1407366eaf6833a7dffba62cf3ad57c66f4f336..a8891ea0046c73ccdec794619863bc78fdbdc1e3 100644 (file)
@@ -6,21 +6,29 @@
 
 #ifndef COLHPOS_HH
 #define COLHPOS_HH
+
 #include "varray.hh"
 #include "lily-proto.hh"
 
 typedef Array<PCol*>  Line_of_cols;
 
 struct Col_hpositions {
+    Line_spacer * spacer_l_;
     bool ugh_b_;
     Line_of_cols error_col_l_arr_;
     Line_of_cols cols;
     Array<Real> config;
-    Real energy;
+    Real energy_f_;
+    bool satisfies_constraints_b_;
 
     /* ************** */
     void OK()const;
-
+    ~Col_hpositions();
+    void solve_line();
+    void approximate_solve_line();
+    /** generate a solution with no regard to idealspacings or
+      constraints.  should always work */
+    void stupid_solution();
     Col_hpositions();
     void add( PCol*c);
     void print() const;
index 4b45edc5972ee604ae64b673aa75a38a0c1fc754..531d0021061ec4843310bc35f784402dcde0a860 100644 (file)
@@ -7,7 +7,6 @@
 #include <math.h>
 #include "real.hh"
 
-const Real INFTY=HUGE_VAL;
-const Real INFTY_f=(Real)INT_MAX;
+#error
 
 #endif
index a3e1ea6d16114ce0aa971039048cbf7bcce24ff9..bf532c035d592a6fe5060f96176cbe2a7f47ba51 100644 (file)
@@ -1,6 +1,6 @@
 /*
-  elem-group-item.hh -- declare Element_group_item
-
+  elem-group-item.hh -- declare Horizontal_vertical_group_item
+  
   source file of the GNU LilyPond music typesetter
 
   (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
@@ -21,11 +21,4 @@ protected:
     virtual void do_print() const;
 };
 
-class Horizontal_group_item : public Item, public Horizontal_group {
-    DECLARE_MY_RUNTIME_TYPEINFO;
-    SCORE_ELEM_CLONE(Horizontal_group_item);
-protected:
-    virtual void do_print() const { Elbement_group::do_print(); }
-};
-
 #endif // ELEM_GROUP_ITEM_HH
index 650dc613ceff1fd236085b078a5a219b47e70dc3..9569dcd90cee3e08161bdb0499c385d524acb2fd 100644 (file)
@@ -9,6 +9,7 @@
 
 #ifndef ELEM_GROUP_HH
 #define ELEM_GROUP_HH
+
 #include "score-elem.hh"
 
 class Elbement_group: public virtual Score_elem {
@@ -17,23 +18,26 @@ protected:
     
     virtual void do_print() const ;
 public:
+    Elbement_group(Elbement_group const&);
     Elbement_group();
     bool contains_b(Score_elem const *)const;
     void add_element(Score_elem*);
     DECLARE_MY_RUNTIME_TYPEINFO;
-       
 };
 
 class Horizontal_group : public Elbement_group {
 public:
     DECLARE_MY_RUNTIME_TYPEINFO;
-    Horizontal_group(Horizontal_group const&);
     Horizontal_group(){}
     void add_element(Score_elem*);
+    Horizontal_group(Horizontal_group const&);
+    void remove_element(Score_elem*);
+
 protected:
+    virtual Horizontal_group * horizontal_group() { return this; }
     virtual void do_substitute_dependency(Score_elem*,Score_elem*);
     virtual void do_print() const ;
-  virtual void translate_x(Real);
+    virtual void translate_x(Real);
     virtual Interval do_width()const;
 };
 
@@ -41,10 +45,13 @@ class Vertical_group : public Elbement_group {
 protected:
     virtual void translate_y(Real);
     virtual void do_print() const ;
-  virtual Interval do_height()const;
+    virtual Interval do_height()const;
     virtual void do_substitute_dependency(Score_elem*,Score_elem*);
-    void add_element(Score_elem*);
+    virtual Vertical_group * vertical_group() { return this; }
 public:
+    void add_element(Score_elem*);
+    void remove_element(Score_elem*);
+    
     Vertical_group(Vertical_group const &);
     Vertical_group(){}
     DECLARE_MY_RUNTIME_TYPEINFO;
diff --git a/lily/include/gourlay-breaking.hh b/lily/include/gourlay-breaking.hh
new file mode 100644 (file)
index 0000000..99fa0c9
--- /dev/null
@@ -0,0 +1,28 @@
+/*
+  gourlay-breaking.hh -- declare Gourlay_breaking
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef GOURLAY_BREAKING_HH
+#define GOURLAY_BREAKING_HH
+
+#include "break.hh"
+
+/**
+  A dynamic programming solution to breaking scores into lines
+ */
+struct Gourlay_breaking : public Break_algorithm
+{
+    Real energy_bound_f_ ;
+    
+    /// maximum number of measures in a line
+    int max_measures_i_;
+    void do_set_pscore();
+    Array<Col_hpositions> do_solve()const;
+    Gourlay_breaking();
+};
+#endif // GOURLAY_BREAKING_HH
index 639ce1b22eeef5a5d4450ffb93de0c59a9c8bbb5..d66a85a99f616000c821cb8c21036179b2efd8bd 100644 (file)
@@ -35,6 +35,7 @@ public:
     DECLARE_MY_RUNTIME_TYPEINFO;
     SCORE_ELEM_CLONE(Horizontal_align_item);
     void add(Item*, int p);
+    void OK()const;
     Horizontal_align_item();
 protected:
     
diff --git a/lily/include/horizontal-group-item.hh b/lily/include/horizontal-group-item.hh
new file mode 100644 (file)
index 0000000..3495af9
--- /dev/null
@@ -0,0 +1,25 @@
+/*
+  horizontal-group-item.hh -- declare Horizontal_group_item
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef HORIZONTAL_GROUP_ITEM_HH
+#define HORIZONTAL_GROUP_ITEM_HH
+
+#include "elem-group.hh"
+#include "item.hh"
+
+class Horizontal_group_item : public Item, public Horizontal_group {
+    DECLARE_MY_RUNTIME_TYPEINFO;
+    SCORE_ELEM_CLONE(Horizontal_group_item);
+protected:
+    virtual void do_breakable_col_processing();
+    void OK()const;
+    virtual void do_print() const { Elbement_group::do_print(); }
+};
+
+#endif // HORIZONTAL_GROUP_ITEM_HH
index 161bc51f469467d6a3904a746703137e80b19a17..d3cab9322c2c7b85039a127032b179f9f6f6c324 100644 (file)
@@ -31,6 +31,10 @@ public:
       */
     void assert_solution(Vector sol) const;
     /// solve the problem using a projected gradient method
+    Vector constraint_solve(Vector)const;
+    /**
+      Solve it. First try it the easy way.
+     */
     Vector solve(Vector start) const;
     
     /**
index 6f3eb6a7cb19740a0f668c5489d70397fa1dbb62..dcbae6374fc33f0f35b615e3d9f02dc63b073217 100644 (file)
@@ -8,7 +8,7 @@
 #ifndef ITEM_HH
 #define ITEM_HH
 
-#include "glob.hh"
+
 #include "boxes.hh"
 #include "string.hh"
 #include "score-elem.hh"
@@ -40,11 +40,14 @@ public:
     Real hpos_f() const;
     DECLARE_MY_RUNTIME_TYPEINFO;
     virtual Line_of_score * line_l() const;
+    
 protected:
     virtual void  do_breakable_col_processing();
     virtual void handle_prebroken_dependencies();
     virtual void do_print()const;
 
+    void copy_breakable_items();
+
 };
 
 
index e7153be0f56c92481fa17ff80fc27ba29487f6f3..2c3393806fcb527ad5925bbadf09b671c7484512 100644 (file)
@@ -16,7 +16,7 @@
   Engravers put elements on the same or lowel level in a line
   */
 class Line_group_engraver : public Engraver{
-    Line_of_staff *staffline_p_;   
+    Vertical_group_spanner *staffline_p_;   
 
 protected:
     virtual void do_creation_processing();
index c8bf02b48cb89ac42fd75de04c360bb866a38a4c..96ef38d42f9dc7f059b1100a8efbc3ca8a71d7cb 100644 (file)
@@ -29,15 +29,16 @@ public:
     Paper_def *paper_l()const;
     Line_spacer();
     
-    virtual Array<PCol*> error_pcol_l_arr() const=0;
-
     /** solve the spacing problem
-      
-      @return the column positions, and the energy (last element)
-
       */
-    virtual Array<Real> solve() const=0;
+    virtual void solve(Col_hpositions *) const=0;
 
+    /**
+      Approximate the spacing problem:
+      return a lower bound on the energy
+     */
+    virtual void lower_bound_solution(Col_hpositions *) const=0;
+    
     /** add a col to the problem. columns have to be added left to
       right. The column contains info on it's minimum width.  */
     virtual void add_column(PCol  *, bool fixed=false, Real fixpos=0.0)=0;
@@ -56,6 +57,7 @@ public:
       generate a solution which can't fail
      */
     virtual Vector default_solution() const=0;
+
     
     virtual void OK() const{}
     virtual void print() const{}
index 587ecf912c7e8f21ed80e6c5f94cdb8c424c30f6..60e52bed6ceeb87fc0070d0caa2780d945af227c 100644 (file)
@@ -10,7 +10,7 @@
 
 #ifndef LINESPACE_HH
 #define LINESPACE_HH
-#include "glob.hh"
+
 #include "plist.hh"
 #include "varray.hh"
 #include "vector.hh"
index 8b26d3ee18f815c1f64f6984055d251b006319a6..bcae7cff83d37dc37ccf52258a6ab1b7ea6a5fff 100644 (file)
@@ -48,6 +48,10 @@ public:
     virtual MInterval time_int()const;
 };
 
+/**
+  The request is a collection of Requests. A note that you enter in mudela is 
+  one Request_chord, one syllable of lyrics is one Request_chord
+ */
 class Request_chord : public Chord {
 public:
     DECLARE_MY_RUNTIME_TYPEINFO;
index 2b2266fb7afab91f0f3409448683f61574f0b578..136d25293c3fefd0e1b8bdd3ff982eb7b209f3e8 100644 (file)
@@ -1,7 +1,7 @@
 #ifndef COLS_HH
 #define COLS_HH
 
-#include "glob.hh"
+
 #include "boxes.hh"
 #include "plist.hh"
 #include "item.hh"
index 35911605d9b795eddbd992c933246d906aac62a9..353f1f9b133b434b7aa30fcdf95b16e48d5a265a 100644 (file)
 #include "score-elem-info.hh"
 #include "staff-info.hh"
 
+/**
+  Convert a music definition into a audio representation.
+  A baseclass
+ */
 class Performer {
     bool init_b_;
 public:
index 9a7055bf8fadc0f5e7592bfabb9833151899bf86..37bf51caa8603d390e873dfa131e44e6c8bb3030 100644 (file)
@@ -9,7 +9,7 @@
 #ifndef REQUEST_HH
 #define REQUEST_HH
 
-#include "glob.hh"
+
 #include "string.hh"
 #include "moment.hh"
 #include "virtual-methods.hh"
index 05c1413ddfbeaddd5737d0148f27b63f97d87ddc..4e6b609ff26d43fbb4aa740bb2b0573f332aa0f1 100644 (file)
@@ -14,7 +14,9 @@
 #include "lily-proto.hh"
 #include "varray.hh"
 
-/// data container.
+/**
+  Data container for broadcasts 
+  */
 struct Score_elem_info {
     Score_elem * elem_l_;
     Request*req_l_;
index 2adf9a89112fb948fb865a5ae3c3ca326ec01ad5..39c06152622eed91ea2c3185ccc9358ee8575d51 100644 (file)
@@ -58,8 +58,8 @@ class Score_elem : private Directed_graph_node {
 
 public:
     PScore *pscore_l_;    
-    int x_group_element_i_;
-    int y_group_element_i_;
+    Vertical_group  *y_group_l_;
+    Horizontal_group *x_group_l_;
     Score_elem(Score_elem const&);
     virtual String TeX_string () const ;
     virtual void print() const;
@@ -99,8 +99,19 @@ public:
       add a dependency. It may be the 0 pointer, in which case, it is ignored.
      */
     void add_dependency(Score_elem* );    
+    void copy_dependencies(Score_elem const&);
+    /**
+      junk the dependency array. Don't do derived stuff.
+     */
+    void junk_dependencies();
     
-    
+
+    /*
+      virtual accessors
+     */
+    virtual Vertical_group * vertical_group() { return 0; }
+    virtual Horizontal_group * horizontal_group() { return 0; }
+
     virtual Spanner* spanner()  { return 0; }
     virtual Horizontal_vertical_group* elem_group() { return 0; }
     virtual Item * item() { return 0; }
index ef95d6d078e53de999c74954c8c059ff52c1fbea..abde4af7a2a46105df1d99dccfa945d2c5f8df8d 100644 (file)
@@ -17,7 +17,6 @@ public:
     bool error_mark_b_;
     virtual String TeX_string() const;    
     
-
     DECLARE_MY_RUNTIME_TYPEINFO;
     Line_of_score();
     
@@ -28,9 +27,9 @@ public:
     
     Link_array<Line_of_score> get_lines()const;
     void set_breaking(Array<Col_hpositions> const&);
-    
+
 protected:
-    virtual void break_into_pieces();
+    virtual void break_into_pieces(bool);
     virtual Interval do_width()const;
     virtual void do_print() const;
     SCORE_ELEM_CLONE(Line_of_score);
index f2afbfb241cefb531bfb4225328893ab07de6ae0..30a72290c0e5dc42035e1550559d97d005548214 100644 (file)
@@ -10,8 +10,6 @@
 #include "lily-proto.hh"
 #include "score-elem.hh"
 
-
-
 /** a symbol which is attached between two columns. A spanner is a
   symbol which spans across several columns, so its final appearance
   can only be calculated after the breaking problem is solved.
@@ -43,8 +41,13 @@ public:
     bool broken_b() const;
     Spanner* find_broken_piece(Line_of_score*)const;
 protected:
+    void set_my_columns();
     SCORE_ELEM_CLONE(Spanner);
-    virtual void break_into_pieces();
+
+    /**
+      this is virtual; for instance, Line_of_score overrides it.
+     */
+    virtual void break_into_pieces(bool);
 
     Link_array<Spanner> broken_into_l_arr_;
        
index 55864615a24dbc49d801b91a5eec6d6d4509b680..85b828d2fa257e292de8820c821ba99d18346628 100644 (file)
 #include "line-spacer.hh"
 #include "plist.hh"
 #include "col-info.hh"
+#include "colhpos.hh"
 
-/** the problem, given by the columns (which include constraints) and
-    intercolumn spacing. The problem is:
-
+/** 
+  Determine positions of columns connected by springs and held apart by rods
+  
+  
     Generate a spacing which
     \begin{itemize}
     \item
@@ -24,6 +26,7 @@
     \item
     Looks good, ie tries to conform to  an ideal spacing as much as possible.
     \end{itemize}
+  
     This is converted by regarding idealspacing as "springs" attached
     to columns. The equilibrium of one spring is the ideal
     distance. The columns have a size, this imposes "hard" constraints
@@ -33,7 +36,7 @@
     The quality is given by the total potential energy in the
     springs. The lower the energy, the better the configuration.
 
-    TODO: make item widths work per pstaff.
+    TODO: make item widths work per Staff.
 
 */
 
@@ -77,22 +80,24 @@ class Spring_spacer : public Line_spacer {
     void add_ideal(Idealspacing const *i);
     Vector try_initial_solution() const;
     void calc_idealspacing();
+    void set_fixed_cols(Mixed_qp&)const;
 
     Score_column* scol_l(int);
     void connect(int i,int j, Real,Real);
+    Line_of_cols error_pcol_l_arr()const;
 public:
     static Line_spacer *constructor();
-    Array<PCol*> error_pcol_l_arr() const;
 
-    virtual   Array<Real> solve() const;
-    virtual  void add_column(PCol  *, bool fixed=false, Real fixpos=0.0);
+    virtual void solve(Col_hpositions*) const;
+    virtual void lower_bound_solution(Col_hpositions*) const;
+    virtual void add_column(PCol  *, bool fixed=false, Real fixpos=0.0);
  
 
     virtual Vector default_solution() const;
-    virtual   bool check_constraints(Vector v) const;
-    virtual    void OK() const;
-    virtual    void print() const;
-    virtual    void prepare();
+    virtual bool check_constraints(Vector v) const;
+    virtual void OK() const;
+    virtual void print() const;
+    virtual void prepare();
     virtual ~Spring_spacer(){}
 };
 
diff --git a/lily/include/vertical-group-spanner.hh b/lily/include/vertical-group-spanner.hh
new file mode 100644 (file)
index 0000000..d092d96
--- /dev/null
@@ -0,0 +1,35 @@
+/*
+  vertical-group-spanner.hh -- declare Vertical_group_spanner
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef SPAN_VERTICAL_GROUP_HH
+#define SPAN_VERTICAL_GROUP_HH
+
+#include "spanner.hh"
+#include "elem-group.hh"
+
+/** An element which groups a line. Due to technical problems, this
+   cannot be used as a baseclass */
+class Vertical_group_spanner : public Spanner, public Vertical_group
+{
+protected:
+    virtual void do_break_processing();
+    virtual void do_print()const;
+    VIRTUAL_COPY_CONS(Vertical_group_spanner, Score_elem);
+
+private:
+    void remove_all();
+    /// shouldn't be copied.
+    Vertical_group_spanner(Vertical_group_spanner const&);
+
+public:
+    Vertical_group_spanner();
+    DECLARE_MY_RUNTIME_TYPEINFO;
+};
+
+#endif // SPAN_VERTICAL_GROUP_HH
index b7b7d42cfad8d027065d12ea0966bcea4f484543..6f16af30c8883ae53b417701a9adf5995b6c4b05 100644 (file)
@@ -15,7 +15,7 @@
 /// wordwrap type algorithm: move to next line if current is optimal.
 struct Word_wrap : Break_algorithm {
     virtual Array<Col_hpositions> do_solve()const;
-    Word_wrap(PScore&);
+    Word_wrap();
 };
 
 #endif // WORD_WRAP_HH
index 56d9a555ad90d7547e89aa214b6da800fcb16a52..204c6a4b516d87517507d70adcb9c3d78b584e05 100644 (file)
@@ -7,8 +7,9 @@
 */
 #include "ineq-constrained-qp.hh"
 #include "qlpsolve.hh"
-#include "const.hh"
 #include "debug.hh"
+#include "choleski.hh"
+
 /*
   MAy be this also should go into a library
  */
@@ -75,14 +76,14 @@ Ineq_constrained_qp::eval (Vector v)
 int
 min_elt_index(Vector v)
 {
-    Real m=INFTY_f; 
+    Real m=infinity_f; 
     int idx=-1;
     for (int i = 0; i < v.dim(); i++){
        if (v(i) < m) {
            idx = i;
            m = v(i);
        }
-       assert(v(i) <= INFTY_f);
+       assert(v(i) <= infinity_f);
     }
     return idx;
 }
@@ -102,24 +103,24 @@ min_elt_index(Vector v)
 
     */
 Vector
-Ineq_constrained_qp::solve(Vector start) const 
+Ineq_constrained_qp::constraint_solve(Vector start) const 
 {    
     if (!dim())
        return Vector(0);
+    
     // experimental
-//    quad.try_set_band();
+    if (quad.dim() > 10)
+       quad.try_set_band();
     
     Active_constraints act(this);
-
-
     act.OK();    
 
     
     Vector x(start);
     Vector gradient=quad*x+lin;
-//    Real fvalue = x*quad*x/2 + lin*x + const_term;
-// it's no use.
-    
+       //    Real fvalue = x*quad*x/2 + lin*x + const_term;
+       // it's no use.
+
     Vector last_gradient(gradient);
     int iterations=0;
     
@@ -131,15 +132,15 @@ Ineq_constrained_qp::solve(Vector start) const
        if (direction.norm() > EPS) {
            mtor << act.status() << '\n';
            
-           Real minalf = INFTY_f;
+           Real minalf = infinity_f;
 
            Inactive_iter minidx(act);
 
 
            /*
-    we know the optimum on this "hyperplane". Check if we
-    bump into the edges of the simplex
-    */
+           we know the optimum on this "hyperplane". Check if we
+           bump into the edges of the simplex
+           */
     
            for (Inactive_iter ia(act); ia.ok(); ia++) {
 
@@ -197,3 +198,14 @@ Ineq_constrained_qp::solve(Vector start) const
 } 
 
     
+Vector
+Ineq_constrained_qp::solve(Vector start)const
+{ 
+    /* no hassle if no constraints*/
+    if ( ! cons.size() ) {
+       Choleski_decomposition chol( quad );
+       return - chol.solve(lin);
+    } else {
+       return constraint_solve( start );
+    }
+}
index 748f516bd5212c26980071cec30047916c6ee610..47e93160fb3dbc4b012f6cdd78081fb507ff4c74 100644 (file)
@@ -27,6 +27,8 @@ void
 Input_translator::print() const
 {
 #ifndef NPRINT
+    if ( ! check_debug)
+       return ;
     mtor << base_str_ <<" " << type_str_<<" {\n";
     mtor << "Consists of ";
     for (int i=0; i< consists_str_arr_.size(); i++)
index 2481e4a35069fa7f4b3a4f75a9814c9d38dc31be..083798be00bbe1d4e4abd9300a585d92a30a362e 100644 (file)
@@ -5,20 +5,20 @@
 
   (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
 */
+
 #include "p-score.hh"
 #include "debug.hh"
 #include "item.hh"
 #include "p-col.hh"
+#include "elem-group.hh"
 
 Item::Item()
 {
     pcol_l_ = 0;
-
     broken_to_a_[0]
        = broken_to_a_[1]=0;
 }
 
-
 IMPLEMENT_IS_TYPE_B1(Item, Score_elem);
 
 void
@@ -58,6 +58,23 @@ Item::break_status_i() const
        return 1;
 }
 
+void
+Item::copy_breakable_items()
+{
+    for (int i=0; i < 2; i++) {
+       Item * item_p = clone()->item();
+       item_p->copy_dependencies(*this);
+       /* add our pre and postbreaks blondly to our own y_group
+          Let Vertical_group_spanner figure out the mess.
+        */
+       if  ( y_group_l_ )
+           y_group_l_->add_element( item_p );
+       pscore_l_->typeset_item(item_p, pcol_l_, -1+ 2*i);
+       item_p->handle_prebroken_dependencies();
+       broken_to_a_[i] = item_p;
+    }
+}
+
 void
 Item::do_breakable_col_processing()
 {
@@ -65,12 +82,7 @@ Item::do_breakable_col_processing()
     if (!c->breakable_b())
        return;
     
-    for (int i=0; i < 2; i++) {
-       broken_to_a_[i] = clone()->item();
-       pscore_l_->typeset_item(broken_to_a_[i], c, -1+ 2*i);
-       broken_to_a_[i]->handle_prebroken_dependencies();
-    }
-
+    copy_breakable_items();
     handle_prebroken_dependencies();
 }
 
index 965630964e1997aef969216c281cde2bf921b4e4..1e4385f14a5d7f8c420f7f821c8f52bff0ad78a5 100644 (file)
@@ -4,10 +4,7 @@
 
 #include <stdlib.h>
 
-#include "glob.hh"
 #include "my-lily-lexer.hh"
-//#include "mudobs.hh"
-//#include "gram.hh"
 
 /* for the keyword table */
 struct Keyword_ent
index 843fa5b5518214eafef69f262e80d80d79f2d42a..2e4b5063350214cbba02b0f453aaa4ba9436af96 100644 (file)
@@ -7,12 +7,12 @@
 */
 
 #include "staff-sym.hh"
-#include "line-group-grav.hh"
+#include "vertical-group-spanner.hh"
 #include "command-request.hh"
 #include "bar.hh"
 #include "debug.hh"
 #include "staffline.hh"
-
+#include "line-group-grav.hh"
 
 Line_group_engraver::Line_group_engraver()
 {
@@ -22,7 +22,8 @@ Line_group_engraver::Line_group_engraver()
 void
 Line_group_engraver::acknowledge_element(Score_elem_info  elem)
 {
-    staffline_p_->add_element(elem.elem_l_);
+    if ( !elem.elem_l_->y_group_l_ )
+       staffline_p_->add_element(elem.elem_l_);
 }
 
 
@@ -37,7 +38,7 @@ Line_group_engraver::do_removal_processing()
 void
 Line_group_engraver::do_creation_processing()
 {
-    staffline_p_ = new Line_of_staff;
+    staffline_p_ = new Vertical_group_spanner ;
     staffline_p_->left_col_l_ = get_staff_info().command_pcol_l();
 
     // don't broadcast to self.
index bc5ef29f3435b9cb49ae824f02d03c5be6dac589..3729744ec09d180c0d0cca75ad8a0b598473a49a 100644 (file)
@@ -16,7 +16,5 @@ Line_spacer::Line_spacer()
 Paper_def*
 Line_spacer::paper_l()const
 { 
-
-
     return paper_l_ ;
 }
index 9a0c8c709356c37c91c18d5b734508d2086128b5..6bc298e14798138be4ee70d69fe3eb43c24de6a1 100644 (file)
@@ -47,9 +47,11 @@ Lookup::add(String s, Symtable*p)
 void
 Lookup::print()const
 {
+    #ifndef NPRINT
     mtor << "Lookup: " << texsetting << " {\n";
     symtables_->print();
     mtor << "}\n";
+    #endif
 }
 
 Symbol
index 093af7f0d4b89b80264671dd2eaab4c85961be2c..5ee56d8045d50d573af86298729445659663e40d 100644 (file)
@@ -1,27 +1,17 @@
+/*
+  misc.cc -- implement various stuff
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
 #include <math.h>
 
 #include "item.hh"
 #include "misc.hh"
-#include "glob.hh"
 #include "moment.hh"
 
-
-// depreciated, see struct Duration*
-Moment
-wholes(int dur, int dots)
-{
-    if (!dur)
-       return 0;
-
-    Moment f = Rational(1)/Moment(dur);
-    Moment delta = f;
-
-    while (dots--) {
-       delta /= 2.0;
-       f += delta;
-    }
-    return f;    
-}
 int
 intlog2(int d) {
     int i=0;
@@ -38,6 +28,7 @@ log_2(double x) {
     return log(x)  /log(2.0);
 }
 
+#if 1
 Interval
 itemlist_width(const Array<Item*> &its)
 {
@@ -51,3 +42,4 @@ itemlist_width(const Array<Item*> &its)
     return iv;
 }
 
+#endif
index 2c946484c8657eb2279f7ef623025d7e7ebe7f21..ee4fe5e48527549fa91dd0e7db647b34087fd03a 100644 (file)
@@ -129,8 +129,12 @@ Molecule::Molecule(Molecule const &s)
 void
 Molecule::print() const
 {
+#ifndef NPRINT
+    if (! check_debug)
+       return;
     for (iter_top(ats,c); c.ok(); c++)
        c->print();
+#endif
 }
 
 void
index 09ee833db0ed22dc3295e198e1d3daf9c13939b4..25e5f2b63f393d7d38276bb80187513469d27a64 100644 (file)
@@ -29,6 +29,8 @@ void
 Music_iterator::print() const
 {
 #ifndef NPRINT
+    if ( !check_debug)
+       return ;
     mtor << name() << "{";
     mtor << "report to " << 
        report_to_l() << " (" << report_to_l()->name() << ")\n";
@@ -200,8 +202,6 @@ Chord_iterator::process_and_next(Moment until)
            i++;
     }
     Music_iterator::process_and_next(until);
-
-//    assert(!ok() || next_moment() > until);
 }
 
 
@@ -210,7 +210,7 @@ IMPLEMENT_IS_TYPE_B1(Chord_iterator,Music_iterator);
 Moment
 Chord_iterator::next_moment()const
 {
-    Moment next_ = INFTY_f;
+    Moment next_ = infinity_mom;
     for (PCursor<Music_iterator*> i(children_p_list_.top()); i.ok(); i++)
        next_ = next_ <? i->next_moment() ;
     return next_;
index 49520966975a4796b953688357e7b18d2328a539..bd1cef64d8f9d8357d1ef76c0e19d6135181609f 100644 (file)
@@ -27,12 +27,12 @@ IMPLEMENT_IS_TYPE_B1(Chord,Music_list);
 MInterval
 Chord::time_int()const
 {
-//    MInterval m( -(Real)INT_MAX, (Real)INT_MAX );
-    MInterval m( 0, 0 );
+    MInterval m;
     for (iter(music_p_list_.top(), i); i.ok(); i++)
        m.unite(i->time_int());
     return m;
 }
+
 void
 Chord::translate(Moment m)
 {
index 4949e2737b4557e13504b63c05546ba3e8e47574..7bc52fcd425b15008c30dd680e5bb96bf71f3bab 100644 (file)
@@ -21,6 +21,8 @@ void
 Music::print()const
 {
 #ifndef NPRINT
+    if ( ! check_debug)
+       return ;
     mtor << name() << "{";
     if  (type_str_!="" || id_str_!="")
        mtor << "`" <<type_str_ << " = " << id_str_<<"\'";
index 0e093c9693a55ec6e849ec987ea503aef74c517a..661ccfeaec6ad6454cc4aa610a6737103c93ff47 100644 (file)
 #include "scoreline.hh"
 #include "p-score.hh"
 #include "tex-stream.hh"
-#include "word-wrap.hh"
 #include "p-col.hh"
 
+#include "word-wrap.hh"
+#include "gourlay-breaking.hh"
+
 PScore::PScore(Paper_def*p)
 {
     paper_l_ = p;
@@ -130,6 +132,8 @@ void
 PScore::print() const
 {    
 #ifndef NPRINT
+    if ( !check_debug)
+       return ;
     mtor << "PScore { ";
     paper_l_->print();
     mtor << "\n elements: ";
@@ -203,9 +207,27 @@ PScore::set_breaking(Array<Col_hpositions> const &breaking)
 void
 PScore::calc_breaking()
 {
-    Word_wrap w(*this);
-
-    set_breaking(w.solve());
+    Break_algorithm *algorithm_p;
+    Array<Col_hpositions> sol;
+    bool try_wrap = ! paper_l_->get_var( "castingalgorithm");
+
+    if (!try_wrap) {
+       algorithm_p = new Gourlay_breaking ;
+       algorithm_p->set_pscore(this);
+       sol = algorithm_p->solve();
+       delete algorithm_p;
+       if ( ! sol.size()) { 
+           error ( "Can not solve this casting problem exactly; revert to Word_wrap");
+           try_wrap = true;
+       } 
+    }
+    if  (try_wrap) {
+       algorithm_p = new Word_wrap;    
+       algorithm_p->set_pscore(this);
+       sol = algorithm_p->solve();
+       delete algorithm_p;
+    }
+    set_breaking(sol);
 }
 
 void
index 67acc1d8ae2df58bc0e075c5e9c8c6ed3d588e3b..d494a11a48d7b015fc5b1912668dba0c8f7ed496 100644 (file)
@@ -441,7 +441,7 @@ paper_body:
        | paper_body STRING '=' dim ';'         { 
                $$->set_var(*$2, $4);
        }
-       | paper_body STRING '=' REAL ';' {
+       | paper_body STRING '=' real ';' {
                $$->set_var(*$2, $4);
        }
        | paper_body input_translator_spec      {
index 66471128e2dab1265d4566e311723f9f05d08c7a..55c5e18994f0092c53627ce81f3025829c5cec49 100644 (file)
@@ -167,6 +167,8 @@ void
 Performer_group_performer::do_print()const
 {
 #ifndef NPRINT
+    if ( !check_debug)
+       return ;
     for ( PCursor<Performer*> i( perf_p_list_.top() ); i.ok(); i++ )
        i->print();
 #endif
index 833a76f4e4da68af02609526f23b22e0f29f545a..fd235d6df2d0fc409e124107ff12905f72e12678 100644 (file)
@@ -7,10 +7,7 @@
 */
 
 #include "debug.hh"
-#include "const.hh"
 #include "qlp.hh"
-#include "choleski.hh"
-
 
 void
 Mixed_qp::add_equality_cons(Vector , double )
index 31ec4a85b4dd10bc3f8ee76c7200b72f5ec6257d..46f0ce64f45d8a46ff02d527f94092d92c04f09f 100644 (file)
 
 #include "ineq-constrained-qp.hh"
 #include "qlpsolve.hh"
-#include "const.hh"
 #include "debug.hh"
 #include "choleski.hh"
 
-const Real TOL=1e-2;           // roughly 1/10 mm
+const Real TOL=1e-1;           // roughly 1/30 mm
 
 String
 Active_constraints::status() const
@@ -63,9 +62,7 @@ Active_constraints::OK()
 Vector
 Active_constraints::get_lagrange(Vector gradient)
 {
-    Vector l(A*gradient);
-
-    return l;
+    return (A*gradient);
 }
 
 void
@@ -121,8 +118,9 @@ Active_constraints::drop(int k)
         
         */
         Real q = a*opt->quad*a;
-       H += Matrix(a,a/q);
-       A -= A*opt->quad*Matrix(a,a/q);
+       Matrix aaq(a,a/q);
+       H += aaq;
+       A -= A*opt->quad*aaq;
     }else
        WARN << "degenerate constraints";
 #ifndef NDEBUG
@@ -142,6 +140,10 @@ Active_constraints::Active_constraints(Ineq_constrained_qp const *op)
     for (int i=0; i < op->cons.size(); i++)
        inactive.push(i);
     Choleski_decomposition chol(op->quad);
+
+    /*
+      ugh.
+     */
     H=chol.inverse();
     OK();
 }
index f2845632370734786745c9cfb477d3f80966dc0f..babf47bd321bb8d1f49a36ec2925ed4738b15444 100644 (file)
@@ -7,7 +7,7 @@
 */
 
 
-#include "elem-group-item.hh"
+#include "horizontal-group-item.hh"
 #include "score-align-grav.hh"
 #include "item.hh"
 
index c95817d9fd2341e11408fbc441ae440f1c4f098c..3e945a5e2bc3962f6c3e750363aef90de5c64014 100644 (file)
@@ -67,18 +67,22 @@ Score_elem::TeX_string() const
     
 }
 
-
-Score_elem::Score_elem(Score_elem const&s)
+void
+Score_elem::copy_dependencies(Score_elem const &s)
 {
-    transparent_b_ = s.transparent_b_;
-    empty_b_ = s.empty_b_;
     /* called from derived ctor, so most info points to the same deps
       as (Directed_graph_node&)s. Nobody points to us, so don't copy
       dependents.      
      */
     copy_edges_out(s);
-    x_group_element_i_ = 0;
-    y_group_element_i_ = 0;    
+}
+
+Score_elem::Score_elem(Score_elem const&s)
+{
+    transparent_b_ = s.transparent_b_;
+    empty_b_ = s.empty_b_;
+    x_group_l_ = 0;
+    y_group_l_ = 0;    
     status_ = s.status_;
     assert(!s.output);
     output = 0;
@@ -93,7 +97,7 @@ Score_elem::~Score_elem()
     delete output;
     status_ = DELETED;
     output = 0;
-    assert(!x_group_element_i_ && !y_group_element_i_);
+
 }
 
 void
@@ -192,8 +196,8 @@ Score_elem::print()const
 Score_elem::Score_elem()
 {
     transparent_b_ = empty_b_ = false;
-    x_group_element_i_ = 0;
-    y_group_element_i_ =0;
+    x_group_l_ = 0;
+    y_group_l_ =0;
     pscore_l_=0;
     offset_ = Offset(0,0);
     output = 0;
@@ -240,7 +244,10 @@ Score_elem::breakable_col_processing()
     if (status_ >= PREBROKEN )
        return;
 
-    assert(status_ != PREBREAKING); // cyclic dependency
+    if(status_== PREBREAKING) {
+       status_ = PREBROKEN;
+       return ;
+    }
     status_ = PREBREAKING;
 
     for (int i=0; i < dependency_size(); i++)
@@ -257,7 +264,10 @@ Score_elem::break_processing()
     if (status_ >= BROKEN )
        return;
 
-    assert(status_ != BREAKING); // cyclic dependency
+    if (status_ == BREAKING) {
+       status_ = BROKEN;
+       return;
+    }
     status_ = BREAKING;
 
     for (int i=0; i < dependency_size(); i++)
@@ -266,6 +276,7 @@ Score_elem::break_processing()
     
     do_break_processing();
     status_ = BROKEN;
+
 }
 
 void
@@ -338,8 +349,13 @@ Score_elem::do_substitute_dependency(Score_elem*,Score_elem*)
 {
 }
 void
-Score_elem::do_substitute_dependent(Score_elem*,Score_elem*)
+Score_elem::do_substitute_dependent(Score_elem*o,Score_elem*n)
 {
+    if  ( o== y_group_l_ ) {
+       y_group_l_ = n ?  n->vertical_group() : 0;
+    } else if (o == x_group_l_ ) {
+       x_group_l_ = n ? n->horizontal_group() : 0;
+    }
 }
 
 
@@ -387,6 +403,14 @@ Score_elem::substitute_dependency(Score_elem* old, Score_elem* new_l)
     old->do_substitute_dependent(this, 0);
 }
 
+void
+Score_elem::junk_dependencies()
+{
+    while ( dependency_size() ) {
+       remove_edge_out( dependency( 0 ));
+    }
+}
+
 void
 Score_elem::handle_broken_dependencies()
 {
@@ -421,10 +445,6 @@ Score_elem::handle_broken_dependencies()
     for (int i=0;  i <remove_us_arr.size(); i++)
        remove_dependency(remove_us_arr[i]);
 
-    /* Reset this. If we are a (broken) copy of a spanner, then
-      break_processing() was not called on us (and we are not breaking).  */
-    if (status_ < BROKEN)
-       status_ = BROKEN;
 }
 
 /*
@@ -468,11 +488,6 @@ Score_elem::handle_prebroken_dependencies()
     for (int i=0;  i <remove_us_arr.size(); i++)
        remove_dependency(remove_us_arr[i]);
 
-    /*
-      see comment at handle_broken_dependencies()
-     */
-    if (status_ < PREBROKEN)
-       status_ = PREBROKEN;
 }
 
 
@@ -483,8 +498,8 @@ Score_elem::unlink_all()
     for (int i=0; i < dependency_size(); i++) 
        dependency(i)->unlink_all();
     junk_links();
-    y_group_element_i_ = 0;
-    x_group_element_i_ = 0;
+    y_group_l_ = 0;
+    x_group_l_ = 0;
 }
 
 void
index 531c120f9989ed976b7b070a4337f490e423aa62..861bf4b00f06271b3cdded50be1bef5e73007d3d 100644 (file)
@@ -58,7 +58,7 @@ Score::run_translator(Global_translator * trans_l)
 
     trans_l->start();
     while ( iter->ok() || trans_l->moments_left_i() ) {
-       Moment w = INFTY_f;
+       Moment w = infinity_mom;
        if (iter->ok() ) {
            w = iter->next_moment();
            iter->print();
index 64a7df296d3859fcd2daeff4e92c359764c00575..d4951dbb8317fd9a28ff85a2951043d5546cf0e5 100644 (file)
@@ -101,6 +101,7 @@ Line_of_score::set_breaking(Array<Col_hpositions> const &breaking)
        
        if (breaking.size() >1) {
            line_p = (Line_of_score*)clone()->spanner();
+           line_p->copy_dependencies( *this );
            line_l = line_p;
        } else 
            line_l =  this;
@@ -122,7 +123,7 @@ Line_of_score::set_breaking(Array<Col_hpositions> const &breaking)
 }
 
 void
-Line_of_score::break_into_pieces()
+Line_of_score::break_into_pieces(bool)
 {
 }
 
@@ -131,7 +132,7 @@ Line_of_score::get_lines()const
 {
     Link_array<Line_of_score> ret;
 
-    if(broken_into_l_arr_.size())
+    if (broken_into_l_arr_.size())
        for (int i=0; i < broken_into_l_arr_.size(); i++) {
            ret.push((Line_of_score*)broken_into_l_arr_[i]);
        }
index 1ca347172bda6db6fa9a73820a3c22c76d78760c..0039caefb50735d7f373d0f7d2efccb131ac77ff 100644 (file)
@@ -19,14 +19,11 @@ Spanner::do_print()const
 {
 #ifndef NPRINT
     mtor << "Between col ";
-// huh? this does not work 
-//    mtor << ( left_col_l_ ? left_col_l_->rank_i() : "nop" );
     if ( left_col_l_ )
        mtor << left_col_l_->rank_i();
     else 
        mtor << "nop";
     mtor << ", ";
-//    mtor << ( right_col_l_ ? right_col_l_->rank_i() : "nop" );
     if ( right_col_l_ )
        mtor << right_col_l_->rank_i();
     else 
@@ -37,7 +34,7 @@ Spanner::do_print()const
 }
 
 void
-Spanner::break_into_pieces()
+Spanner::break_into_pieces(bool copy_deps_b)
 {
     PCol * left = left_col_l_;
     PCol * right = right_col_l_;
@@ -53,6 +50,8 @@ Spanner::break_into_pieces()
 
     for (int i=1; i < break_cols.size(); i++) {
        Spanner* span_p = clone()->spanner();
+       if (copy_deps_b)
+           span_p->copy_dependencies( *this );
        left = break_cols[i-1];
        right = break_cols[i];
        if (!right->line_l_)
@@ -68,21 +67,26 @@ Spanner::break_into_pieces()
        pscore_l_->typeset_broken_spanner(span_p);
        broken_into_l_arr.push( span_p );
     }
-    
+     
     broken_into_l_arr_ = broken_into_l_arr;
 }
 
 void
-Spanner::do_break_processing()
+Spanner::set_my_columns()
 {
-    if (!left_col_l_->line_l_)
+  if (!left_col_l_->line_l_)
        left_col_l_ = left_col_l_->postbreak_p_;
     if (!right_col_l_->line_l_)
        right_col_l_ = right_col_l_->prebreak_p_;
-     
+}       
+
+void
+Spanner::do_break_processing()
+{
+    set_my_columns();
     
     if (!line_l()) {
-       break_into_pieces();
+       break_into_pieces(true);
        for (int i=0; i < broken_into_l_arr_.size(); i++)
            broken_into_l_arr_[i]->handle_broken_dependencies();
     } else { 
index 7684e5de5f52bd9751a8cbd62ff710b92295ba33..81196d6b246c1038ba0cbdb43522e3699a73175b 100644 (file)
@@ -19,7 +19,8 @@
 #include "score-column.hh"
 #include "paper-def.hh"
 #include "dimen.hh"
-#include "minterval.hh"
+#include "colhpos.hh"
+
 
 Vector
 Spring_spacer::default_solution()const
@@ -96,8 +97,8 @@ Spring_spacer::position_loose_cols(Vector &sol_vec)const
     assert(sol_vec.dim());
     Array<bool> fix_b_arr;
     fix_b_arr.set_size(cols.size() + loose_col_arr_.size());
-    Real utter_right_f=-INFTY_f;
-    Real utter_left_f =INFTY_f;
+    Real utter_right_f=-infinity_f;
+    Real utter_left_f =infinity_f;
     for (int i=0; i < loose_col_arr_.size(); i++) {
        fix_b_arr[loose_col_arr_[i].rank_i_] = false;
     }
@@ -235,6 +236,16 @@ Spring_spacer::make_matrices(Matrix &quad, Vector &lin, Real &c) const
     }
 }
 
+void
+Spring_spacer::set_fixed_cols(Mixed_qp &qp)const
+{
+    for (int j=0; j < cols.size(); j++) 
+       if (cols[j].fixed()) 
+           qp.add_fixed_var(j,cols[j].fixed_position());           
+       
+    
+}
+
 // put the constraints into the LP problem
 void
 Spring_spacer::make_constraints(Mixed_qp& lp) const
@@ -242,9 +253,6 @@ Spring_spacer::make_constraints(Mixed_qp& lp) const
     int dim=cols.size();
     for (int j=0; j < dim; j++) {
        Colinfo c=cols[j];
-       if (c.fixed()) {
-           lp.add_fixed_var(j,c.fixed_position());         
-       }
        if (j > 0){
            Vector c1(dim);
            
@@ -256,26 +264,44 @@ Spring_spacer::make_constraints(Mixed_qp& lp) const
     }
 }
 
-Array<Real>
-Spring_spacer::solve() const
+void
+Spring_spacer::lower_bound_solution(Col_hpositions*positions)const
+{
+    Mixed_qp lp(cols.size());
+    make_matrices(lp.quad,lp.lin, lp.const_term);
+    set_fixed_cols(lp);
+
+    Vector start(cols.size());
+    start.fill(0.0);
+    Vector solution_vec(lp.solve(start));
+
+    positions->energy_f_ = lp.eval(solution_vec);
+    positions->config = solution_vec;
+    positions->satisfies_constraints_b_ = check_constraints(solution_vec);
+}
+
+void
+Spring_spacer::solve(Col_hpositions*positions) const
 {
     assert(check_feasible());
 
     Mixed_qp lp(cols.size());
     make_matrices(lp.quad,lp.lin, lp.const_term);
     make_constraints(lp);    
+    set_fixed_cols(lp);
     Vector start=find_initial_solution();    
-    Vector sol(lp.solve(start));
-    if (!check_constraints(sol)) {
-       WARN << "solution doesn't satisfy constraints.\n" ;
-    }
-    Real energy_f =lp.eval(sol);
-    position_loose_cols(sol);
+    Vector solution_vec(lp.solve(start));
 
-    Array<Real> posns(sol);
 
-    posns.push(energy_f);
-    return posns;
+    positions->satisfies_constraints_b_ = check_constraints(solution_vec);
+    if (!positions->satisfies_constraints_b_) {
+       WARN << "solution doesn't satisfy constraints.\n" ;
+    }
+    position_loose_cols(solution_vec); 
+    positions->energy_f_ = lp.eval(solution_vec);
+    positions->config = solution_vec;
+    positions->error_col_l_arr_ = error_pcol_l_arr();
+    
 }
 
 /**
@@ -292,7 +318,7 @@ Spring_spacer::add_column(PCol  *col, bool fixed, Real fixpos)
     cols.push(c);
 }
 
-Array<PCol*>
+Line_of_cols
 Spring_spacer::error_pcol_l_arr()const
 {
     Array<PCol*> retval;
@@ -445,7 +471,7 @@ Spring_spacer::calc_idealspacing()
            }
            if ( d_iter.ok() && now >= d_iter.when()) {
                Durations_iter d2 = d_iter;
-               Moment shortest = (Real)INT_MAX; //ugh INFTY;
+               Moment shortest = infinity_mom;
                while (d2.ok() && d2.when() <= now) {
                    shortest = shortest <? d2.duration();
                    d2.next();
@@ -472,14 +498,18 @@ Spring_spacer::calc_idealspacing()
     
     for (int i=0; i < cols.size(); i++) {
        if ( !scol_l(i)->musical_b()) {
-           ideal_arr_[i] = cols[i].minright() + 2 PT;
-           hooke_arr_[i] = 2.0;
+           Real symbol_distance =cols[i].minright() + 2 PT;
+           Real durational_distance = 0;
+
            if (i+1 < cols.size()) {
                Moment delta_t =  scol_l(i+1)->when() - scol_l(i)->when() ;
-               Real dist = delta_t ? paper_l()->duration_to_dist(delta_t) : 0;
-               if (delta_t && dist > ideal_arr_[i])
-                   ideal_arr_[i] = dist;
+               if (delta_t)
+                   durational_distance =  paper_l()->duration_to_dist(delta_t) ;
+               symbol_distance += cols[i+1].minleft();
            }
+           
+           ideal_arr_[i] = symbol_distance >? durational_distance;
+           hooke_arr_[i] = 2.0;
        }
     }
     for (int i=0; i < cols.size(); i++) {
@@ -495,11 +525,14 @@ Spring_spacer::calc_idealspacing()
            dist *= delta_t / shortest_len;
            if (!scol_l(i+1)->musical_b() ) {
 
-               if (ideal_arr_[i+1] + cols[i+1].minleft() < dist) {
-                   ideal_arr_[i+1] = dist/2 + cols[i+1].minleft();
-                   hooke_arr_[i+1] =1.0;
-               } 
-               ideal_arr_[i] = dist/2;
+               Real minimum_dist =   cols[i+1].minleft() + 2 PT + cols[i].minright() ;
+               if (ideal_arr_[i+1] + minimum_dist < dist) {
+                   ideal_arr_[i] = dist - ideal_arr_[i+1];
+                   // hooke_arr_[i+1] =1.0;
+               } else {
+                   ideal_arr_[i] = minimum_dist;
+               }
+                                     
            } else
                ideal_arr_[i] = dist;
        }
@@ -509,7 +542,6 @@ Spring_spacer::calc_idealspacing()
        assert (ideal_arr_[i] >=0 && hooke_arr_[i] >=0);
        connect(i, i+1, ideal_arr_[i], hooke_arr_[i]);
     }
 }
 
 
@@ -527,56 +559,4 @@ Spring_spacer::constructor()
 {
     return new Spring_spacer;
 }
-   
-#if 0
-void obsolete()
-{
-    for (int i=0; i < cols.size(); i++) {
-       if (!scol_l(i)->used_b())
-           continue;
-       
-       
-       int j = i+1;
-
-       if (scol_l(i)->musical_b()) {
-           assert ( j < cols.size());
-           
-           for (int n=0; n < scol_l(i)->durations.size(); n++) {
-               Moment d = scol_l(i)->durations[n];
-               Real dist = paper_l()->duration_to_dist(d);
-               Real strength =  scol_l(i)->durations[0]/scol_l(i)->durations[n];
-               assert(strength <= 1.0);
-               
-               while (j < cols.size()) {
-                   if (scol_l(j)->used_b() 
-                       && scol_l(j)->when() >= d + scol_l(i)->when() )
-                       break;
-                   j++;
-               }
-               if ( j < cols.size() ){
-                   Moment delta_desired = scol_l(j)->when() - (d+scol_l(i)->when());
-                   dist += paper_l()->duration_to_dist(delta_desired);
-                   if (scol_l(j)->musical_b()) {
-                       dist += cols[j].minleft() + 2 PT;
-                   }
-                   connect(i, j, dist, strength);
-               }
-           }
-       } else if (j < cols.size()) {
-           while  (!scol_l(j)->used_b())
-               j++;
-           
-           /* attach i to the next column in use. This exists, since
-             the last col is breakable, and therefore in use
-             */
-           
-           Moment d = scol_l(j)->when() - scol_l(i)->when();
-           Real minimal_f = cols[i].minright()  +cols[j].minleft() + 2 PT;
-           Real durdist_f = (d) ? paper_l()->duration_to_dist(d) : 0; // todo
-           
-           connect(i, j, minimal_f <? durdist_f, (d) ? 1.0:1.0);
-       }
-       // !j.ok() might hold if we're at the last col.
-    }
-}
-#endif
index 7e4aa95741c9483566b1b52f1623b0ebabc9e47c..f8bbcd306bfe21d2fc184ffd7f5210fcebf337a3 100644 (file)
 
 
 IMPLEMENT_IS_TYPE_B2(Line_of_staff,Spanner,Horizontal_vertical_group);
-
-void
-Line_of_staff::add_element(Score_elem*elem_l)
-{
-    if (!elem_l->y_group_element_i_)
-       Horizontal_vertical_group::add_element(elem_l);
-}
index 385fc141605d241443724963e7997653083f31a4..b09b378aee598c06cd2a510b8a91325dd3f49841 100644 (file)
@@ -1,13 +1,13 @@
 /*
-  template2.cc -- instantiate some list templates. 
+  template2.cc -- Instantiate some list templates. 
 
   source file of the GNU LilyPond music typesetter
 
   (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
 */
 
-#include "score-column.hh"
+#include "line-spacer.hh"
 #include "plist.tcc"
 #include "pcursor.tcc"
 
-IPL_instantiate(Score_column);
+IPL_instantiate(Line_spacer);
index bffae6d08019ea74ec56c6caba297f00e467a10d..e57925bf5b38a7057f9fa4a22cb67b21c468c4b7 100644 (file)
 Interval__instantiate(Rational);
 Interval__instantiate(int);
 
-const Real INFTY_f = (Real)INT_MAX;
-#if defined AIX || defined _WIN32
-const Real INFTY = 1e8;        // ARGh. AIX sucks -- so does doze
-#else
-const Real INFTY = HUGE_VAL;
-#endif
-
 Rational
 Interval_t<Rational>::infinity()
 {
-/*
-  windhoze-suck-suck-suck-suck-suck-thank-you-cygnus
-
-  I get tired of all these incompatibilities. We'll just assume:
-
-  that 2^31 is *Big*
-
- */
-
     return Rational(INT_MAX);
 }
 
index 3b8fe8aa20e013eaaeb15728a476f8a571588b96..470dd49ea69077a038e235d4777b7be758f1502f 100644 (file)
@@ -1,7 +1,14 @@
+/*
+  tex.cc -- implement TeX related misc functions
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1996,1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
 #include "dimen.hh"
 #include "tex.hh"
 #include "symbol.hh"
-#include "const.hh"
 #include "varray.hh"
 
 String
index 83cfae7acce35adfe4e37e8fd32850e9b24d1eeb..c6690f6ef1917b3d4fe16e554f8a7cd6709dba42 100644 (file)
@@ -36,7 +36,7 @@ Vertical_align_engraver::acknowledge_element(Score_elem_info i)
 {
     if ( i.origin_grav_l_arr_.size() == 2 && 
         i.elem_l_->is_type_b(Vertical_group::static_name()) &&
-        !i.elem_l_->y_group_element_i_   ) {
+        !i.elem_l_->y_group_l_   ) {
        assert( !valign_p_->contains_b(  i.elem_l_) );
 
        valign_p_->add ( i.elem_l_ );
diff --git a/lily/vertical-group-spanner.cc b/lily/vertical-group-spanner.cc
new file mode 100644 (file)
index 0000000..d858349
--- /dev/null
@@ -0,0 +1,104 @@
+/*
+  vertical-group-spanner.cc -- implement Vertical_group_spanner
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+#include "vertical-group-spanner.hh"
+#include "item.hh"
+#include "p-col.hh"
+
+/**
+  Uncouple all elements of this Vertical_group. Ugh!
+ */
+void
+Vertical_group_spanner::remove_all()
+{
+    for (int i=0; i < elem_l_arr_.size(); i++){
+       elem_l_arr_[i]->y_group_l_ = 0;
+    }
+    elem_l_arr_.set_size(0);
+    junk_dependencies();   
+}
+
+void
+Vertical_group_spanner::do_break_processing()
+{
+    set_my_columns();
+    if ( line_l() ) {
+       return;
+    }
+    break_into_pieces( false );
+
+    Link_array<Score_elem> elem_l_arr = elem_l_arr_;
+    remove_all();
+    
+    
+    
+    for (int i=0; i < elem_l_arr.size(); i++) {
+       Score_elem * elt = elem_l_arr[i];
+       Line_of_score *elt_line = elt->line_l();
+       
+       if  ( elt-> y_group_l_ )
+           continue;
+       
+       if ( ! elt_line ){ 
+           if (elt->spanner()) {
+               Spanner * sp = elt->spanner();
+               
+               for (int j =0; j < broken_into_l_arr_.size(); j++) {
+                   Vertical_group_spanner * my_broken_l
+                        = (Vertical_group_spanner*)broken_into_l_arr_[j];
+                   
+                   Spanner * broken_span_l 
+                       = sp->find_broken_piece(my_broken_l->line_l());
+                   
+                   if (broken_span_l) {
+                       my_broken_l->add_element(broken_span_l );
+                   }
+               }
+           } else if (elt->item() && elt->item()->pcol_l_->breakpoint_b()
+                      && elt->item()->break_status_i() == 0) {
+               for (int j =0; j < 2; j++) {
+                   Item * my_item = elt->item()->broken_to_a_[j];
+                   Line_of_score * item_line_l_ = my_item->line_l() ;
+                   if ( ! item_line_l_ ) 
+                       continue;
+                   
+                   Vertical_group_spanner * v
+                       = (Vertical_group_spanner*)find_broken_piece( item_line_l_);
+                   if (v) {
+                       v->add_element( my_item );
+                   }
+               }
+           }
+       } else {
+           Vertical_group_spanner * my_broken_l
+               = (Vertical_group_spanner*)find_broken_piece( elt->line_l() );
+           my_broken_l->add_element( elt );
+       }
+    }
+    for (int j =0; j < broken_into_l_arr_.size(); j++) 
+       broken_into_l_arr_[j]->break_processing();      
+}
+
+Vertical_group_spanner::Vertical_group_spanner()
+{
+}
+
+void
+Vertical_group_spanner::do_print() const
+{
+    Vertical_group::do_print();
+}
+
+
+
+IMPLEMENT_IS_TYPE_B2(Vertical_group_spanner, Spanner, Vertical_group);
+
+Vertical_group_spanner::Vertical_group_spanner(Vertical_group_spanner const &s)
+    : Spanner(s), Vertical_group(s)
+{
+}
diff --git a/lily/word-wrap.cc b/lily/word-wrap.cc
new file mode 100644 (file)
index 0000000..a2ac4e9
--- /dev/null
@@ -0,0 +1,101 @@
+/*
+  word-wrap.cc -- implement Word_wrap
+
+  source file of the LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+#include "word-wrap.hh"
+#include "p-score.hh"
+#include "debug.hh"
+#include "p-col.hh"
+#include "spring-spacer.hh"
+
+
+/** el stupido. 
+   
+  
+   A Dynamic Programming type of algorithm
+   similar to TeX's is in Gourlay_breaking
+
+   */
+Array<Col_hpositions>
+Word_wrap::do_solve()const
+{
+    problem_OK();
+    
+    PCursor<PCol*> curcol(pscore_l_->col_p_list_.top());
+    Array<Col_hpositions> breaking;
+    Line_of_cols breakpoints(find_breaks());
+    assert(breakpoints.size()>=2);
+
+    int break_idx_i=0;                 
+    while ( break_idx_i < breakpoints.size() -1) {
+       Col_hpositions minimum;
+       Col_hpositions current;
+
+        // do  another line
+       PCol *post = breakpoints[break_idx_i]->postbreak_p_;
+       current.add( post);
+       curcol++;               // skip the breakable.
+       break_idx_i++;
+
+       while (break_idx_i < breakpoints.size()) {
+       
+           // add another measure.
+           while (breakpoints[break_idx_i] != curcol.ptr()){
+               current.add(curcol);
+               curcol++;
+           }
+           current.add(breakpoints[break_idx_i]->prebreak_p_ );
+
+           current.spacer_l_ = generate_spacing_problem( current.cols );
+
+           // try to solve
+           if (!feasible(current.cols)) {
+               if (!minimum.cols.size()) {
+                   warning("Ugh, this measure is too long, breakpoint: "
+                         + String(break_idx_i) +
+                       " (generating stupido solution)");
+                   current.stupid_solution();
+                   current.energy_f_ = - 1; // make sure we break out.
+               } else
+                   current.energy_f_ = infinity_f;     // make sure we go back
+           } else {
+               
+               current.solve_line();
+               current.print();
+           }
+
+           delete current.spacer_l_;
+           current.spacer_l_ =0;
+
+           // update minimum, or backup.
+           if (current.energy_f_ < minimum.energy_f_ || current.energy_f_ < 0) {
+               minimum = current;
+           } else {            // we're one col too far.
+               break_idx_i--;
+               while (curcol.ptr() != breakpoints[break_idx_i])
+                   curcol --;
+               break;          // do the next line.
+           }
+
+
+           // add nobreak version of breakable column
+           current.cols.top()=breakpoints[break_idx_i];
+           curcol ++;
+           break_idx_i++;
+       }
+
+       *mlog << "[" <<break_idx_i<<"]"<<flush;
+       breaking.push(minimum);
+    }
+    print_stats();
+    return breaking;
+}
+
+Word_wrap::Word_wrap()
+{
+    get_line_spacer = Spring_spacer::constructor;
+}
diff --git a/lily/wordwrap.cc b/lily/wordwrap.cc
deleted file mode 100644 (file)
index 7d25bb9..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
-  wordwrap.cc -- implement Word_wrap
-
-  source file of the LilyPond music typesetter
-
-  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
-*/
-
-#include "word-wrap.hh"
-#include "p-score.hh"
-#include "debug.hh"
-#include "p-col.hh"
-#include "spring-spacer.hh"
-
-
-/** el stupido. This should be done more accurately:
-
-   It would be nice to have a Dynamic Programming type of algorithm
-   similar to TeX's
-   
-   */
-Array<Col_hpositions>
-Word_wrap::do_solve()const
-{
-    problem_OK();
-    iter_top(pscore_l_->col_p_list_,curcol);
-    Array<Col_hpositions> breaking;
-    Line_of_cols breakpoints(find_breaks());
-    assert(breakpoints.size()>=2);
-
-    int break_idx_i=0;                 
-    while ( break_idx_i < breakpoints.size() -1) {
-       Col_hpositions minimum;
-       Col_hpositions current;
-
-        // do  another line
-       PCol *post = breakpoints[break_idx_i]->postbreak_p_;
-       current.add( post);
-       curcol++;               // skip the breakable.
-       break_idx_i++;
-
-       while (break_idx_i < breakpoints.size()) {
-
-           // add another measure.
-           while (breakpoints[break_idx_i] != curcol.ptr()){
-               current.add(curcol);
-               curcol++;
-           }
-           current.add(breakpoints[break_idx_i]->prebreak_p_ );
-
-           // try to solve
-           if (!feasible(current.cols)) {
-               if (!minimum.cols.size()) {
-                   warning("Ugh, this measure is too long, breakpoint: "
-                         + String(break_idx_i) +
-                       " (generating stupido solution)");
-                   current = stupid_solution(current.cols);
-                   current.energy = - 1; // make sure we break out.
-               } else
-                   current.energy = INFTY_f;   // make sure we go back
-           } else {
-               current = solve_line(current.cols);
-               current.print();
-           }
-
-           // update minimum, or backup.
-           if (current.energy < minimum.energy || current.energy < 0) {                
-               minimum = current;         
-           } else {            // we're one col too far.
-               break_idx_i--;
-               while (curcol.ptr() != breakpoints[break_idx_i])
-                   curcol --;
-               break;          // do the next line.
-           }
-
-
-           // add nobreak version of breakable column
-           current.cols.top()=breakpoints[break_idx_i];
-           curcol ++;
-           break_idx_i++;
-       }
-
-       *mlog << "[" <<break_idx_i<<"]"<<flush;
-       breaking.push(minimum);
-    }
-    
-    return breaking;
-}
-
-Word_wrap::Word_wrap(PScore&ps)
-    : Break_algorithm(ps)
-{
-    get_line_spacer = Spring_spacer::constructor;
-}
index 8189216cfbbf5704e3c0a7cf687fd433c5ff43ab..491fd2afa8817698fd5b4d4821c75cf3a2e35e9d 100644 (file)
@@ -29,6 +29,9 @@ FIND = @FIND@
 COMPILEINFO = @COMPILEINFO@
 BISON = @BISON@
 FLEX = @FLEX@
+LN = @LN@
+ZIP = @ZIP@
 PERL =@PERL@
+OUTDIR_NAME = @OUTDIR_NAME@
 
 
index e5c0104f3235b8e31f4dcc4f2cd91e017e4e9c4c..99e0bbf008833fa599918532b265f524c33edf12 100644 (file)
@@ -47,6 +47,7 @@ rpmdvis=$(rpmmudocs:.doc=.dvi)
 rpmexamples= $(addprefix input/, $(notdir $(shell ls $(depth)/input/*.{ly,tex})))
 
 
+date = $(shell date '+%d%b%y'|tr a-z A-Z)
 sed-version= sed 's!@TOPLEVEL_VERSION@!${TOPLEVEL_VERSION}!g'
 sed-date=sed 's!@DATE@!${date}!g'
 sed-examples = sed 's!@EXAMPLE_LYS@!${rpmexamples} ${rpmmudocs}!g'
index 1369366262663f69aa5d9c477c6155ef596dbc17..206e2c02679160be445ac73204716ac5094c754f 100644 (file)
@@ -136,9 +136,28 @@ dist:
 # should be trapped
        rm -rf $(distdir)/
 
+# ugh. should generate in out/
+dozedist: doosdist
+doosdist:
+       -mkdir $(distdir)
+#      nogo, SUBDIRS is handed down to subdir...
+#      $(MAKE) SUBDIRS="Documentation init input tex" localdist
+       $(MAKE) localdist
+       chmod -Rf a+rX $(distdir)
+#      ugh, the ugly way, then
+       (cd $(distdir); rm -rf $(NO_DOOS_DIST))
+       cp $(lilyout)/lilypond.exe $(distdir)
+       strip -s $(distdir)/lilypond.exe
+       cp $(mi2muout)/mi2mu.exe $(distdir)
+       strip -s $(distdir)/mi2mu.exe
+       (cd ./$(depth); $(ZIP) $(DIST_NAME).exe.zip $(distdir))
+# should be trapped
+       rm -rf $(distdir)/
+
+
 localdist: $(DISTFILES)
        if [ -d out ]; then mkdir $(distdir)/$(localdir)/out; fi
-       ln $(DISTFILES) $(distdir)/$(localdir)
+       $(LN) $(DISTFILES) $(distdir)/$(localdir)
 ifdef SUBDIRS
        set -e; for i in $(SUBDIRS); do mkdir $(distdir)/$(localdir)/$$i; \
                $(MAKE) localdir=$(localdir)/$$i -C $$i localdist; done
@@ -151,7 +170,7 @@ moduledist:
        rm -rf $(module-distdir)/ 
 
 localmoduledist:
-       ln $(DISTFILES) $(module-distdir)/$(localdir)
+       $(LN) $(DISTFILES) $(module-distdir)/$(localdir)
 ifdef SUBDIRS
        set -e; for i in $(SUBDIRS); do mkdir $(module-distdir)/$(localdir)/$$i; done
        set -e; for i in $(SUBDIRS); do $(MAKE) localdir=$(localdir)/$$i -C $$i localmoduledist; done
@@ -175,12 +194,14 @@ $(outdir)/version.hh: VERSION
 
 
 # should this be in Rules?
-configure: configure.in
+configure: configure.in aclocal.m4
        autoconf - < $<> $@
        chmod +x configure
 
 localclean:
 
+install-strip:
+       $(MAKE) INSTALL="$(INSTALL) -s" install
 
 install: localinstall
 ifdef SUBDIRS
index 8a42ab0f910eaad2346e347ce5e7e38586abc0e6..7e971fcc7237ecb2186f5ea6c514023206c0d9d7 100644 (file)
@@ -1,4 +1,5 @@
 # -*-Makefile-*-
+# @configure_input@
 ########################################################
 # project  LilyPond -- the musical typesetter
 # title           top level makefile for LilyPond  
@@ -32,9 +33,10 @@ SUBDIRS = flower lib lily mi2mu \
 
 # list of distribution files:
 #
-SCRIPTS = configure configure.in install-sh
-README_FILES = BUGS DEDICATION ANNOUNCE COPYING NEWS README TODO INSTALL.text AUTHORS.text
-EXTRA_DISTFILES=  .dstreamrc VERSION $(README_FILES) $(SCRIPTS) $(SYMLINKS)
+SCRIPTS = configure configure.in install-sh aclocal.m4
+README_FILES = BUGS DEDICATION ANNOUNCE COPYING ONEWS NEWS README TODO \
+       INSTALL.text AUTHORS.text
+EXTRA_DISTFILES = .dstreamrc VERSION $(README_FILES) $(SCRIPTS) $(SYMLINKS)
 
 # do not dist ./Makefile (is copied from make/Toplevel.make)
 DISTFILES:=$(EXTRA_DISTFILES)# Makefile $(ALL_SOURCES)
index a3bc6eee5c21725b1b1020bea43d7c98ca38654b..b601cbd8a45afdafcda3a59979463583f4869d01 100644 (file)
@@ -5,8 +5,10 @@
 # abstract 
 #
 # do not change this file for site-wide extensions; please use 
-# make/out/Site.make; 
-# Any change in files in this directory (make/) would be distributed.
+# make/$(OUTDIR_NAME)/Site.make; 
+#
+# Any change in files in this directory (make/) would be distributed, if 
+# you do make dist 
 #
 # Copyright (c) 1997 by    
 #      Jan Nieuwenhuizen <jan@digicash.com>
 # toplevel version info, might be handy?
 #
 include $(depth)/VERSION
-#
+
+
 ifeq (0,${MAKELEVEL})
+
+# Don't try to outsmart us, you puny computer!
 MAKE:=$(MAKE) --no-builtin-rules
 endif
 
-# directory names:
-
+ifndef OUTDIR_NAME
+OUTDIR_NAME=out
+endif
 
-ifdef buildprefix
-top-directory := $(shell  cd $(depth); pwd)
-abs-sub-directory := $(shell pwd)
-relative-sub-directory := $(subst $(top-directory),,$(abs-sub-directory))
-outdir=$(buildprefix)/$(relative-sub-directory)/out/
-else
+# directory names:
 buildprefix=$(depth)
-outdir=out
-endif
+outdir=$(OUTDIR_NAME)
 
 # derived names
 lily_bindir = $(depth)/bin
@@ -39,13 +39,13 @@ distdir = $(depth)/$(DIST_NAME)
 module-distdir = $(depth)/$(MODULE_DIST_NAME)
 depdir = $(outdir)
 
-flowerout = $(buildprefix)/flower/out
-libout = $(buildprefix)/lib/out
-lilyout = $(buildprefix)/lily/out
-mi2muout = $(buildprefix)/mi2mu/out
-makeout = $(buildprefix)/make/out
-docout = $(buildprefix)/Documentation/out
-binout = $(buildprefix)/bin/out
+flowerout = $(buildprefix)/flower/$(OUTDIR_NAME)
+libout = $(buildprefix)/lib/$(OUTDIR_NAME)
+lilyout = $(buildprefix)/lily/$(OUTDIR_NAME)
+mi2muout = $(buildprefix)/mi2mu/$(OUTDIR_NAME)
+makeout = $(buildprefix)/make/$(OUTDIR_NAME)
+docout = $(buildprefix)/Documentation/$(OUTDIR_NAME)
+binout = $(buildprefix)/bin/$(OUTDIR_NAME)
 
 doc-dir = $(depth)/Documentation
 flower-dir = $(depth)/flower
@@ -85,6 +85,7 @@ TOPLEVEL_VERSION=$(TOPLEVEL_MAJOR_VERSION).$(TOPLEVEL_MINOR_VERSION).$(TOPLEVEL_
 # fix naming, use TOPLEVEL_ prefix _or_ MODULE?
 MODULE_DIST_NAME = $(MODULE_NAME)-$(VERSION)
 DIST_NAME = lilypond-$(TOPLEVEL_VERSION)
+NO_DOOS_DIST = bin flower lib lily make mi2mu out
 #
 
 # list of object files:
@@ -122,8 +123,8 @@ mi2mu-version = $(mi2muout)/version.hh
 
 # custom libraries:
 #
-LIBFLOWER = $(depth)/flower/$(outdir)/$(LIB_PREFIX)flower$(LIB_SUFFIX)
-LIBLILY = $(depth)/lib/$(outdir)/$(LIB_PREFIX)lily$(LIB_SUFFIX)
+LIBFLOWER = $(flowerout)/$(LIB_PREFIX)flower$(LIB_SUFFIX)
+LIBLILY = $(libout)/$(LIB_PREFIX)lily$(LIB_SUFFIX)
 #
 
 # compile and link options:
@@ -141,7 +142,7 @@ EXTRA_CXXFLAGS= -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wconversio
 CXXFLAGS = $(CFLAGS) $(USER_CXXFLAGS) $(EXTRA_CXXFLAGS) $(MODULE_CXXFLAGS)
 INCLUDES = -Iinclude -I$(outdir) -I$(include-lib) -I$(libout) -I$(include-flower) -I$(flowerout) 
 CXX_OUTPUT_OPTION = $< -o $@
-LDFLAGS = $(ILDFLAGS) $(USER_LDFLAGS) $(EXTRA_LDFLAGS) $(MODULE_LDFLAGS) -L$(depth)/lib/out -L$(depth)/flower/out
+LDFLAGS = $(ILDFLAGS) $(USER_LDFLAGS) $(EXTRA_LDFLAGS) $(MODULE_LDFLAGS) -L$(depth)/lib/$(OUTDIR_NAME) -L$(depth)/flower/$(OUTDIR_NAME)
 LOADLIBES = $(EXTRA_LIBES) $(MODULE_LIBES) -lg++ # need lg++ for win32, really!
 #
 
@@ -180,7 +181,12 @@ DODEP=rm -f $(depfile); DEPENDENCIES_OUTPUT="$(depfile) $(outdir)/$(notdir $@)"
 
 # generic target names:
 #
+ifdef NAME
 EXECUTABLE = $(outdir)/$(NAME)$(EXE)
+else
+EXECUTABLE =
+endif
+
 EXECUTABLES = $(EXECUTABLE)
 LIB_PREFIX = lib
 
@@ -199,7 +205,7 @@ DOCDIR=$(depth)/$(outdir)
 
 # .hh should be first. Don't know why
 # take some trouble to auto ignore sources and obsolete stuff.
-progdocs=$(shell $(FIND) ./ -name '*.hh' |egrep -v 'out/') $(shell $(FIND) ./ -name '*.cc'|egrep -v 'out/')
+progdocs=$(shell $(FIND) ./ -name '*.hh' |egrep -v '$(OUTDIR_NAME)') $(shell $(FIND) ./ -name '*.cc'|egrep -v '$(OUTDIR_NAME)')
 
 
 pod2html=pod2html
index 6ff4c32b1aacfc4dc4519afa31056bfbb6620366..40fca3decab3272cc0688be9a5ee58789e716308 100644 (file)
@@ -1,7 +1,7 @@
 Begin3
 Title: LilyPond
-Version: 0.1.0
-Entered-date: 08/01/97
+Version: 0.1.1
+Entered-date: 05AUG97
 Description:   GNU LilyPond is a program which converts music
                definition files into visual or auditive output: it can
                typeset formatted sheet music to a TeX file and and
@@ -14,9 +14,8 @@ Author: hanwen@stack.nl (Han-Wen Nienhuys)
        jan@digicash.com (Jan Nieuwenhuizen)
 Maintained-by: hanwen@stack.nl (Han-Wen Nienhuys)
 Primary-site: sunsite.unc.edu /pub/Linux/apps
-       340k lilypond-0.1.0.tar.gz 
+       340k lilypond-0.1.1.tar.gz 
 Original-site: pcnov095.win.tue.nl /pub/lilypond/
-       340k lilypond-0.1.0.tar.gz 
-Platform: Unix/windoze32, GNU C++
+       340k lilypond-0.1.1.tar.gz 
 Copying-policy: GPL
 End
index a3c98fc52332b50a7a09ab5e47958daee45cabd4..aa442688fec5a3118a023258e6977edf47b6ebb7 100644 (file)
@@ -17,6 +17,5 @@ Primary-site: sunsite.unc.edu /pub/Linux/apps
        340k lilypond-@TOPLEVEL_VERSION@.tar.gz 
 Original-site: pcnov095.win.tue.nl /pub/lilypond/
        340k lilypond-@TOPLEVEL_VERSION@.tar.gz 
-Platform: Unix/windoze32, GNU C++
 Copying-policy: GPL
 End
index ffb03cd6fd8620515fa8d8066423023152331bcd..604160109c34dc2fa0046a177f65448d9e5dc8e0 100644 (file)
@@ -1,9 +1,9 @@
 Name: lilypond
-Version: 0.1.0
+Version: 0.1.1
 Release: 1
 Copyright: GPL
 Group: Applications/Publishing
-Source0: pcnov095.win.tue.nl:/pub/lilypond/lilypond-0.1.0.tar.gz
+Source0: pcnov095.win.tue.nl:/pub/lilypond/lilypond-0.1.1.tar.gz
 Summary: A preprocessor to make TeX typeset music.
 URL: http://www.stack.nl/~hanwen/lilypond
 Packager: Han-Wen Nienhuys <hanwen@stack.nl>
@@ -28,7 +28,7 @@ strip lily/out/lilypond mi2mu/out/mi2mu
 make prefix="$RPM_BUILD_ROOT/usr" install
 %files
 %doc Documentation/out/AUTHORS.text Documentation/out/CodingStyle.text Documentation/out/INSTALL.text Documentation/out/MANIFESTO.text Documentation/out/convert-mudela.text Documentation/out/faq.text Documentation/out/gnu-music.text Documentation/out/index.text Documentation/out/language.text Documentation/out/lilygut.text Documentation/out/lilyliterature.text Documentation/out/lilypond.text Documentation/out/links.text Documentation/out/mi2mu.text Documentation/out/mudela-book.text Documentation/out/other-packages.text BUGS TODO NEWS DEDICATION ANNOUNCE README 
-%doc input/beams.ly input/cadenza.ly input/collisions.ly input/coriolan-alto.ly input/header.ly input/keys.ly input/kortjakje.ly input/multi.ly input/pedal.ly input/rhythm.ly input/scales.ly input/scripts.ly input/scsii-menuetto.ly input/scsii-menuetto.tex input/slurs.ly input/standchen.ly input/standchen.tex input/toccata-fuga-E.ly input/twinkle.ly input/wohltemperirt.ly Documentation/mudela-course.doc Documentation/mudela-man.doc 
+%doc input/beams.ly input/cadenza.ly input/collisions.ly input/coriolan-alto.ly input/header.ly input/keys.ly input/kortjakje.ly input/multi.ly input/pedal.ly input/rhythm.ly input/rock.ly input/scales.ly input/scripts.ly input/scsii-menuetto.ly input/scsii-menuetto.tex input/slurs.ly input/standchen.ly input/standchen.tex input/toccata-fuga-E.ly input/twinkle.ly input/wohltemperirt.ly Documentation/mudela-course.doc Documentation/mudela-man.doc 
 %doc Documentation/lelie_logo.gif
 /usr/bin/convert-mudela
 /usr/bin/mudela-book
@@ -43,3 +43,5 @@ make prefix="$RPM_BUILD_ROOT/usr" install
 /usr/share/lilypond/
 %post
 
+texhash                # takes some time...
+
index 5ae3aede2efdc8c71a420fcb5ee6ae69fece3ec1..772371bd2d80aca8b1f05d6cb4f23c7050d3958a 100644 (file)
@@ -43,3 +43,5 @@ make prefix="$RPM_BUILD_ROOT/usr" install
 /usr/share/lilypond/
 %post
 
+texhash                # takes some time...
+
index 2df411c6fa4a0e5c0dc115869107e8939ba71ff4..84286dc182694b9813afcd4c85739f7d8c72b94b 100644 (file)
@@ -79,3 +79,6 @@ localclean:
 localinstall: installexe
 
 localuninstall: uninstallexe
+
+
+$(outdir)/mi2mu-version.o: $(outdir)/version.hh