From eb4c59e2bab7573c8d3cf6496fa38090c169e224 Mon Sep 17 00:00:00 2001 From: fred Date: Wed, 27 Mar 2002 01:02:57 +0000 Subject: [PATCH] lilypond-1.3.150 --- Documentation/windows/GNUmakefile | 94 ++++++++++++++++++++++++- Documentation/windows/fix-suffixes.sh | 32 +++++++++ Documentation/windows/latex-wrapper.sh | 8 +++ Documentation/windows/lily-gs.sh | 31 ++++++++ Documentation/windows/lily-miktex.sh | 22 ++++++ Documentation/windows/lily-python.sh | 21 +++++- Documentation/windows/post-gs.sh | 54 ++++++++++++++ Documentation/windows/post-lily.sh | 8 +++ Documentation/windows/post-miktex.sh | 30 ++++++++ Documentation/windows/post-python.sh | 41 +++++++++++ Documentation/windows/python-wrapper.sh | 13 ++++ Documentation/windows/registry.in | 60 ++++++++++++++++ Documentation/windows/tex-wrapper.sh | 10 +++ Documentation/windows/zlily-profile.sh | 31 ++++++++ ly/german-chords.ly | 47 ------------- make/substitute.make | 1 + scm/chord-name.scm | 5 +- scripts/ly2dvi.py | 7 +- 18 files changed, 459 insertions(+), 56 deletions(-) create mode 100644 Documentation/windows/fix-suffixes.sh create mode 100644 Documentation/windows/latex-wrapper.sh create mode 100644 Documentation/windows/lily-gs.sh create mode 100644 Documentation/windows/lily-miktex.sh create mode 100644 Documentation/windows/post-gs.sh create mode 100644 Documentation/windows/post-lily.sh create mode 100644 Documentation/windows/post-miktex.sh create mode 100644 Documentation/windows/post-python.sh create mode 100644 Documentation/windows/python-wrapper.sh create mode 100644 Documentation/windows/registry.in create mode 100644 Documentation/windows/tex-wrapper.sh create mode 100644 Documentation/windows/zlily-profile.sh diff --git a/Documentation/windows/GNUmakefile b/Documentation/windows/GNUmakefile index 8351c3d69e..ab7e00e733 100644 --- a/Documentation/windows/GNUmakefile +++ b/Documentation/windows/GNUmakefile @@ -3,7 +3,7 @@ depth=../.. EXTRA_DIST_FILES = LilyPond.ico $(wildcard *.sh *.patch) -STEPMAKE_TEMPLATES=documentation texinfo +STEPMAKE_TEMPLATES=documentation texinfo install install-out include $(depth)/make/stepmake.make @@ -11,3 +11,95 @@ default: local-doc local-WWW: +# For cygwin builds only +target=$(shell gcc -dumpmachine) +ifeq ($(target),i686-pc-cygwin) + +POST_INSTALLS=$(wildcard post-*.sh) +OUT_POST_INSTALLS=$(POST_INSTALLS:%=$(outdir)/%) + +# lily-*: rename to '-profile' or so +PROFILES=$(wildcard *lily-*.sh) lilypond-profile.sh +OUT_PROFILES=$(PROFILES:%=$(outdir)/%) + +##as2text.scm +PYTHON_WRAPPERS=\ + abc2ly\ + convert-ly\ + etf2ly\ + lilypond-book\ + ly2dvi\ + mup2ly\ + musedata2ly\ + pmx2ly\ + update-lily\ +# + +OUT_PYTHON_WRAPPERS=$(PYTHON_WRAPPERS:%=$(outdir)/%) + +TEX_WRAPPERS=tex latex +OUT_TEX_WRAPPERS=$(TEX_WRAPPERS:%=$(outdir)/%) + +# profiles +$(outdir)/%.sh: %.sh + cat $< | sed $(sed-atvariables) > $@ + chmod 755 $@ + +# Urg +$(outdir)/lilypond-profile.sh: $(outdir)/../$(depth)/buildscripts/out/lilypond-profile + cp $< $@ + chmod 755 $@ + +# python wrappers +$(outdir)/%: python-wrapper.sh + cat $< | sed $(sed-atvariables) -e "s!@name@!$(*F)!g" > $@ + chmod 755 $@ + +# tex wrappers +#$(outdir)/%: %-wrapper.sh +# cat $< | sed $(sed-atvariables) -e "s!@name@!$(*F)!g" > $@ +# chmod 755 $@ + +$(outdir)/tex: tex-wrapper.sh + cat $< | sed $(sed-atvariables) -e "s!@name@!tex!g" > $@ + chmod 755 $@ + +$(outdir)/latex: latex-wrapper.sh + cat $< | sed $(sed-atvariables) -e "s!@name@!latex!g" > $@ + chmod 755 $@ + +default: $(OUT_PYTHON_WRAPPERS) $(OUT_TEX_WRAPPERS) $(OUT_POST_INSTALLS) $(OUT_PROFILES) + +# urg: change suffixes before overwriting python scripts + +INSTALLATION_OUT_SUFFIXES=1 2 3 4 + +# URG. +# By popular demand, +# LilyPond on windows is configured with --prefix=/usr/lilypond-x.y.x +# The cygwin profile.d dir, however, is in /etc + +INSTALLATION_DIR=$(shell dirname $(shell dirname $(prefix)))/etc/postinstall +INSTALLATION_FILES=$(OUT_POST_INSTALLS) + +INSTALLATION_OUT_DIR1=$(shell dirname $(shell dirname $(prefix)))/etc/profile.d +INSTALLATION_OUT_FILES1=$(OUT_PROFILES) + +INSTALLATION_OUT_DIR2=$(prefix)/wrappers +INSTALLATION_OUT_FILES2=$(OUT_PYTHON_WRAPPERS) $(OUT_TEX_WRAPPERS) + +INSTALLATION_OUT_DIR3=$(datadir)/tex +INSTALLATION_OUT_FILES3=$(shell kpsewhich geometry.sty) + +INSTALLATION_OUT_DIR4=$(datadir)/tfm +INSTALLATION_OUT_FILES4=$(shell kpsewhich cmr10.tfm) + +else + +local-install: + @echo skipping + +local-install-outfiles: + @echo skipping + +endif diff --git a/Documentation/windows/fix-suffixes.sh b/Documentation/windows/fix-suffixes.sh new file mode 100644 index 0000000000..0f8792a552 --- /dev/null +++ b/Documentation/windows/fix-suffixes.sh @@ -0,0 +1,32 @@ +#!/bin/bash +## duh, rename executables, +## for people that use a dumb shell instead of bash + +if [ $# -le 0 ]; then + echo "Usage: fix-suffixes [FILE]..." + exit 2 +fi + +echo `basename $0` + +function fix_extension () +{ + path=$1 + ext=$2 + expr="$3" + dir=`dirname $path` + file=`basename $path` + base=`basename $file $ext` + if [ $base$ext != $file ]; then + type="`file $path`" + if expr "$type" : "$expr"; then + mv -f $path $dir/$base$ext + fi + fi +} + +for i in `/bin/ls -d1 $*`; do + fix_extension $i .exe '.*Windows.*\(executable\).*' + fix_extension $i .py '.*\(python\).*' +done + diff --git a/Documentation/windows/latex-wrapper.sh b/Documentation/windows/latex-wrapper.sh new file mode 100644 index 0000000000..67b805c54c --- /dev/null +++ b/Documentation/windows/latex-wrapper.sh @@ -0,0 +1,8 @@ +#!@SHELL@ +# @name@.sh -- @name@ wrapper for Windows + +MFINPUTS="$WINDOWS_MFINPUTS" +TEXINPUTS="$WINDOWS_TEXINPUTS" +TFMFONTS="$WINDOWS_TFMFONTS" + +@name@ "$*" diff --git a/Documentation/windows/lily-gs.sh b/Documentation/windows/lily-gs.sh new file mode 100644 index 0000000000..3a559ca47c --- /dev/null +++ b/Documentation/windows/lily-gs.sh @@ -0,0 +1,31 @@ +#!@SHELL@ +# /etc/profile.d/lily-gs.sh -- Check for GhostScript and GSView + + +gs550="/usr/windows/gstools/gs5.50" +gs650="/usr/windows/gs/gs6.50" + +gsview26="/usr/windows/gstools/gsview" +gsview36="/usr/windows/Ghostgum/GSview" + +# Maybe read registry, but that may be hairy? +# +# $ regtool get \\HKLM\\Software\\CLASSES\\psfile\\shell\\open\\command\\ +# "C:\GSTOOLS\GSVIEW\gsview32.exe" "%1" + + +if [ -e "$gs550/gswin32.exe" ]; then + PATH="$gs550:$PATH" +fi + +if [ -e "$gs650/gswin32.exe" ]; then + PATH="$gs650:$PATH" +fi + +if [ -e "$gsview26/gsview32.exe" ]; then + PATH="$gsview26:$PATH" +fi + +if [ -e "$gsview36/gsview32.exe" ]; then + PATH="$gsview36:$PATH" +fi diff --git a/Documentation/windows/lily-miktex.sh b/Documentation/windows/lily-miktex.sh new file mode 100644 index 0000000000..c2c1480dd8 --- /dev/null +++ b/Documentation/windows/lily-miktex.sh @@ -0,0 +1,22 @@ +#!@SHELL@ +# /etc/profile.d/lily-miktex.sh -- Check for MiKTeX + + +# Educated guess in case we have no regtool +a="//c/Program Files/MiKTeX" + +# Registry entry +reg="$(regtool -q get 'HKLM\Software\MiK\MiKTeX\CurrentVersion\MiKTeX\Install Root\')" +b="$(cygpath -u ""$reg"")" + +# Where we installed it +c=texmf="/usr/windows/MiKTeX" + +for i in "$a" "$b" "$c"; do + if [ -d "$i" ]; then + texmf="$i" + fi +done + +PATH="$texmf/miktex/bin:$PATH" + diff --git a/Documentation/windows/lily-python.sh b/Documentation/windows/lily-python.sh index c8f71313c6..fdefba7d4b 100644 --- a/Documentation/windows/lily-python.sh +++ b/Documentation/windows/lily-python.sh @@ -1,3 +1,20 @@ -#!/bin/bash +#!@SHELL@ +# /etc/profile.d/post-python.sh -- Check for Python -PATH="//c/Program Files/Python:$PATH" +# Educated guess in case we have no regtool +a="//c/Program Files/Python" + +# Registry entry +reg="$(regtool -q get 'HKLM\Software\Python\PythonCore\1.5\InstallPath\')" +b="$(cygpath -u ""$reg"")" + +# Where we installed it +c="/usr/windows/Python" + +for i in "$a" "$b" "$c"; do + if [ -d "$i" ]; then + python="$i" + fi +done + +PATH="$python:$PATH" diff --git a/Documentation/windows/post-gs.sh b/Documentation/windows/post-gs.sh new file mode 100644 index 0000000000..a460393794 --- /dev/null +++ b/Documentation/windows/post-gs.sh @@ -0,0 +1,54 @@ +#!@SHELL@ +# /etc/postinstall/post-gs.sh -- Install GS and GSView + + +gs550="/usr/windows/gstools/gs5.50" +gs650="/usr/windows/gs/gs6.50" + +gsview26="/usr/windows/gstools/gsview" +gsview36="/usr/windows/Ghostgum/GSview" + +# maybe set this too, but how (what type is value, a list?) +# $ regtool get \\HKLM\\Software\\CLASSES\\psfile\\shell\\open\\command\\ +# "C:\GSTOOLS\GSVIEW\gsview32.exe" "%1" + +# gsview needs gs register entries, so it seems + +if [ -e "$gs550/gswin32.exe" ]; then + regtool -s set 'HKLM\Software\Aladdin Ghostscript\5.50\GS_LIB' \ + "c:\cygwin\windows\gstools\gs5.50;c:\cygwin\windows\gstools\gs5.50\fonts" + regtool -s set 'HKLM\Software\Aladdin Ghostscript\5.50\GS_DLL' \ + "c:\cygwin\windows\gstools\gs5.50\\gsdll32.dll" +fi + +if [ -e "$gs650/gswin32.exe" ]; then + regtool -s set 'HKLM\Software\AFPL Ghostscript\6.50\GS_DLL' \ + "C:\cygwin\windows\gs\gs6.50\bin\gsdll32.dll" + regtool -s set 'HKLM\Software\AFPL Ghostscript\6.50\GS_LIB' \ + "C:\cygwin\windows\gs\gs6.50\lib;C:\cygwin\windows\gs\fonts" +fi + +# nothing to be done +if [ -e "$gsview26/gsview32.exe" ]; then + true +fi + +if [ -e "$gsview36/gsview32.exe" ]; then + regtool -s set 'HKLM\Software\Ghostgum\GSview\3.6' \ + "C:\cygwin\windows\Ghostgum" +fi + +# What's in the registry + +# regtool -v list HKLM\Software\Aladdin Ghostscript\5.50 +# GS_LIB = "c:\cygwin\windows\gstools\gs5.50;c:\cygwin\windows\gstools\gs5.50\fonts" +# GS_DLL = "c:\cygwin\windows\gstools\gs5.50\\gsdll32.dll" + +# regtool -v list HKLM\Software\Ghostgum\GSview +# 3.6 = "C:\cygwin\windows\Ghostgum" + +# regtool -v list HKLM\Software\AFPL Ghostscript\6.50 +# GS_DLL = "C:\cygwin\windows\gs\gs6.50\bin\gsdll32.dll" +# GS_LIB = "C:\cygwin\windows\gs\gs6.50\lib;C:\cygwin\windows\gs\fonts" + + diff --git a/Documentation/windows/post-lily.sh b/Documentation/windows/post-lily.sh new file mode 100644 index 0000000000..8259c90f64 --- /dev/null +++ b/Documentation/windows/post-lily.sh @@ -0,0 +1,8 @@ +#!@SHELL@ +# /etc/profile.d/post-lily.sh -- Setup LilyPond + +rm -f /usr/lilypond +lily=@prefix@ +ln -s $lily /usr/lilypond + + diff --git a/Documentation/windows/post-miktex.sh b/Documentation/windows/post-miktex.sh new file mode 100644 index 0000000000..e8f131d029 --- /dev/null +++ b/Documentation/windows/post-miktex.sh @@ -0,0 +1,30 @@ +#!@SHELL@ +# /etc/profile.d/post-miktex.sh -- Setup MiKTeX + + +# Educated guess in case we have no regtool +a="//c/Program Files/MiKTeX" + +# Registry entry +reg="$(regtool -q get 'HKLM\Software\MiK\MiKTeX\CurrentVersion\MiKTeX\Install Root\')" +b="$(cygpath -u ""$reg"")" + +# Where we installed it +c=texmf="/usr/windows/MiKTeX" + +for i in "$a" "$b" "$c"; do + if [ -d "$i" ]; then + texmf="$i" + fi +done + +rm -f /usr/share/texmf +ln -s "$texmf" /usr/share/texmf + +# What's in the registry +# $ regtool -s set 'HKLM\Software\MiK\MiKTeX\CurrentVersion\MiKTeX\Install Root\' "C:\cygwin\usr\windows\MiKTeX" + +# regtool -v list HKLM\Software\MiK\MiKTeX\CurrentVersion\MiKTeX +# TEXMF Root Directories = "C:\cygwin\usr\windows\miktex\spool\texmf;C:\cygwin\windows\MiKTeX" +# Install Root = "C:\cygwin\usr\windows\MiKTeX" + diff --git a/Documentation/windows/post-python.sh b/Documentation/windows/post-python.sh new file mode 100644 index 0000000000..89b2c6a4df --- /dev/null +++ b/Documentation/windows/post-python.sh @@ -0,0 +1,41 @@ +#!@SHELL@ +# /etc/profile.d/post-python.sh -- Setup Python + +# Educated guess in case we have no regtool +a="//c/Program Files/Python" + +# Registry entry +reg="$(regtool -q get 'HKLM\Software\Python\PythonCore\1.5\InstallPath\')" +b="$(cygpath -u ""$reg"")" + +# Where we installed it +c="/usr/windows/Python" + +for i in "$a" "$b" "$c"; do + if [ -d "$i" ]; then + python="$i" + fi +done + +# What's in the registry + +# regtool -v list HKLM\Software\Python\PythonCore\1.5 +# InstallPath\ () +# PythonPath\ () +# Dll\ () +# Modules\ () + +# regtool -v list HKLM\Software\Python\PythonCore\1.5\InstallPath +# InstallGroup\ () +# = "C:\cygwin\usr\windows\Python" + +# regtool -v list HKLM\Software\Python\PythonCore\1.5\PythonPath +# = "C:\cygwin\usr\windows\Python\Lib\plat-win;C:\cygwin\usr\windows\Python\Lib;C:\cygwin\usr\windows\Python\DLLs;C:\cygwin\usr\windows\Python\Lib\lib-tk" + +# regtool -v list HKLM\Software\Python\PythonCore\1.5\Dll +# = "C:\WINDOWS\SYSTEM\Python15.dll" + +# regtool -v list HKLM\Software\Python\PythonCore\1.5\Modules\ +# = "" + + diff --git a/Documentation/windows/python-wrapper.sh b/Documentation/windows/python-wrapper.sh new file mode 100644 index 0000000000..57bff4ea1d --- /dev/null +++ b/Documentation/windows/python-wrapper.sh @@ -0,0 +1,13 @@ +#!@SHELL@ +# @name@.sh -- @name@ wrapper for Windows + +if echo | python - >/dev/null 2>&1; then + echo +else + cat <; Fri, 13 Apr 2001 13:33:43 +0200 -X-XS4ALL-To: -Received: from pop.xs4all.nl - by localhost with POP3 (fetchmail-5.1.2) - for fred@localhost (single-drop); Fri, 13 Apr 2001 13:33:44 +0200 (CEST) -Received: from smtp5.xs4all.nl (smtp5.xs4all.nl [194.109.6.49]) - by maildrop7.xs4all.nl (8.11.1/8.11.1) with ESMTP id f3DBWCd93235 - for ; Fri, 13 Apr 2001 13:32:12 +0200 (CEST) - (envelope-from rz@daimi.au.dk) -Received: from fencepost.gnu.org (fencepost.gnu.org [199.232.76.164]) - by smtp5.xs4all.nl (8.9.3/8.9.3) with ESMTP id NAA10302 - for ; Fri, 13 Apr 2001 13:31:04 +0200 (CEST) -Received: from nightcrawler.daimi.au.dk ([130.225.18.95]) - by fencepost.gnu.org with esmtp (Exim 3.16 #1 (Debian)) - id 14o1n2-0008Pp-00 - for ; Fri, 13 Apr 2001 07:31:00 -0400 -Received: from daimi.au.dk (localhost [127.0.0.1]) - by nightcrawler.daimi.au.dk (8.11.2/8.11.2) with ESMTP id f3DBUwX31324 - for ; Fri, 13 Apr 2001 13:30:58 +0200 -Sender: rz@daimi.au.dk -Message-ID: <3AD6E372.640DEE61@daimi.au.dk> -Date: Fri, 13 Apr 2001 13:30:58 +0200 -From: Rune Zedeler -X-Mailer: Mozilla 4.76 [en] (X11; U; Linux 2.2.16-3 i686) -X-Accept-Language: en -MIME-Version: 1.0 -To: Jan Nieuwenhuizen -Subject: german-chords -Content-Type: multipart/mixed; - boundary="------------69CC07F348020448DD291CA8" -X-UIDL: 987161532.maildrop7.93237 - -*** EOOH *** \version "1.3.148" % german-chords.ly: @@ -84,5 +39,3 @@ X-UIDL: 987161532.maildrop7.93237 ) ) ) - - \ No newline at end of file diff --git a/make/substitute.make b/make/substitute.make index daae40c8fe..59ca7541a2 100644 --- a/make/substitute.make +++ b/make/substitute.make @@ -16,6 +16,7 @@ ATVARIABLES = \ package\ PATHSEP\ PERL\ + prefix\ program_prefix\ program_suffix\ PYTHON\ diff --git a/scm/chord-name.scm b/scm/chord-name.scm index 1e409e4bc7..75d3253501 100644 --- a/scm/chord-name.scm +++ b/scm/chord-name.scm @@ -64,7 +64,7 @@ (define simple-super ;; duh, no docstrings for ;; "No real superscript, just raised and small" - '((raise . 1) (font-relative-size . -1))) + '((raise . 1) (font-relative-size . -2))) (define (accidental->textp acc pos) (if (= acc 0) @@ -73,8 +73,7 @@ (list pos (string-append "accidentals-" (number->string acc)))))) (define (accidental->text acc) (accidental->textp acc 'columns)) -(define (accidental->text-super acc) - (accidental->textp acc '((raise . 0.6) (font-relative-size . -1)))) +(define (accidental->text-super acc) (accidental->textp acc 'simple-super)) (define (accidental->text-sub acc) (accidental->textp acc 'sub)) (define (pitch->note-name pitch) diff --git a/scripts/ly2dvi.py b/scripts/ly2dvi.py index 26f7bd2635..1b9a948292 100644 --- a/scripts/ly2dvi.py +++ b/scripts/ly2dvi.py @@ -279,6 +279,8 @@ def system (cmd, ignore_error = 0): Exit status of CMD """ + if ( os.name != 'posix' ): + cmd = "sh -c \'%s\'" % cmd if verbose_p: progress (_ ("Invoking `%s\'") % cmd) st = os.system (cmd) >> 8 @@ -563,7 +565,7 @@ None if ( os.name == 'posix' ): cmd = 'latex \\\\nonstopmode \\\\input %s' % latex_fn else: - cmd = 'latex \\nonstopmode \\input %s' % latex_fn + cmd = 'latex \\\\\\\\nonstopmode \\\\\\\\input %s' % latex_fn if not verbose_p: progress ( _("Running %s...") % 'LaTeX') @@ -592,8 +594,7 @@ None. if not verbose_p: progress ( _("Running %s...") % 'dvips') - if os.name == 'posix': - cmd = cmd + ' 1> /dev/null 2> /dev/null' + cmd = cmd + ' 1> /dev/null 2> /dev/null' system (cmd) -- 2.39.5