3 # stable LilyPond releases: lilypond-1.6
4 # archive=ftp://lilypond.org/pub/LilyPond/v1.6
6 # LilyPond development: lilypond-1.7
7 # archive=ftp://lilypond.org/pub/LilyPond/v1.7
9 # Guile specific mknetrel overrides
10 # To use this, do something like:
13 wget -P/var/tmp ftp://lilypond.org/pub/LilyPond/v1.6/lilypond-1.6.3.tar.gz
14 rm -rf /home/netrel/src/lilypond-*
15 mkdir -p /home/netrel/src && cd /home/netrel/src
16 ## TODO: look at pimport
17 tar xzf /var/tmp/lilypond-*
18 mv lilypond-* $(echo lilypond-*)-1
20 ./bin/mknetrel -xXC lilypond
28 patch=$mknetrel_root/patch
32 uploads=$here/uploads/$base && mkdir -p $uploads
33 tarstem=$uploads/$package
44 # -*- shell-script -*-
46 # jcn -- unsorted stuff
50 # Patching and configuring
55 # Maybe add to mknetrel or pimport.
58 patch -p1 < $patch/$package.patch
59 [ -d cygwin -a ! -e CYGWIN-PATCHES ] && ln -s cygwin CYGWIN-PATCHES
60 [ -d CYGWIN-PATCHES -a ! -e cygwin ] && ln -s CYGWIN-PATCHES cygwin
61 [ -d CYGWIN-PATCHES ] || mkdir CYGWIN-PATCHES
64 # Maybe add to mknetrel or pimport.
66 [ -r $patch/$package.patch -a ! -r $src/CYGWIN-PATCHES -a ! -r $src/cygwin ] && dopatchsrc
70 for i in bootstrap autogen.sh; do
79 libtoolize --force --copy --automake --ltdl
82 automake --add-missing
86 cat <<EOF > config.cache
88 ac_cv_c_bigendian=${ac_cv_c_bigendian=no}
89 ac_cv_sizeof_char=${ac_cv_sizeof_char=1}
90 ac_cv_sizeof_char_p=${ac_cv_sizeof_char_p=4}
91 ac_cv_sizeof_double=${ac_cv_sizeof_double=8}
92 ac_cv_sizeof_float=${ac_cv_sizeof_float=4}
93 ac_cv_sizeof_int=${ac_cv_sizeof_int=4}
94 ac_cv_sizeof_long=${ac_cv_sizeof_long=4}
95 ac_cv_sizeof_long_double=${ac_cv_sizeof_long_double=12}
96 ac_cv_sizeof_long_long=${ac_cv_sizeof_long_long=8}
97 ac_cv_sizeof_short=${ac_cv_sizeof_short=2}
98 ac_cv_sizeof_void_p=${ac_cv_sizeof_void_p=4}
99 ac_cv_c_long_size_t=${ac_cv_c_long_size_t=no}
100 ac_cv_c_long_time_t=${ac_cv_c_long_time_t=yes}
101 ac_16bit_type=${ac_16bit_type=short}
102 ac_32bit_type=${ac_32bit_type=int}
103 ac_64bit_type=${ac_64bit_type=none}
104 ac_cv_sys_restartable_syscalls=${ac_cv_sys_restartable_syscalls=no}
105 ac_cv_sprintf_count=${ac_cv_sprintf_count=yes}
106 ac_cv_spinlocks=${ac_cv_spinlocks=no}
107 ac_cv_func_getpgrp_void=${ac_cv_func_getpgrp_void=yes}
108 ac_cv_func_setvbuf_reversed=${ac_cv_func_setvbuf_reversed=no}
109 ac_cv_func_mkfifo=yes
111 # Try at preventing to break make rules while crosscompiling. This
112 # used work, but nowadays ./configure thinks it knows better than me.
114 # But what ./configure doesn't know, is that automake and libtool are
115 # broken wrt cross-building, and wrt cc_for_build. See new
118 ac_exeext=${ac_exeext=}
119 ac_cv_exeext=${ac_cv_exeext=}
126 # Subpackage stuff -- Maybe move to mknetrel
129 # Possibly, using file-lists globs is smarter than separate install
130 # prefixes. We'll see what happens when packaging tetex-*.
146 mkdir -p ./$prefix/bin || exit 1
147 mv $inst/$prefix/bin/*.dll ./$prefix/bin
148 mkdir -p ./$prefix/share || exit 1
149 mv $inst/$prefix/share/$base ./$prefix/share
154 mkdir -p ./$prefix/bin || exit 1
155 mv $inst/$prefix/include ./$prefix/include
156 mkdir -p ./$prefix/lib || exit 1
157 mv $inst/$prefix/lib/*.a ./$prefix/lib
158 mv $inst/$prefix/lib/*.la ./$prefix/lib
159 mkdir -p ./$prefix/share || exit 1
160 mv $inst/$prefix/share/aclocal ./$prefix/share
165 mkdir -p ./$prefix || exit 1
166 mv $inst/$prefix/info ./$prefix
171 for i in $sub_packages; do
173 mkdir -p $inst-$i || exit 1
179 # Fix up installation slightly
183 cd usr 2>/dev/null && dousrstuff
186 # Split off any sub-packages. The actual splitting is handled by
187 # a package's specific code in extra/.
189 # To package `foo' in foo, foo-doc and foo-devel, set
190 # sub_packages='doc devel'.
192 # Then provide functions doc_name and devel_name, that return the
193 # full name of the sub-package. Also provide functions doc_split
194 # and devel_split, that mv part of foo's installation in $inst to
195 # the sub-packages' installation roots $inst-doc and $inst-devel.
200 for i in $sub_packages; do
202 cd $inst-$i || exit 1
214 echo creating $tarstem.tar.bz2
217 f=$src/cygwin/setup.hint && test -r $f && cp $f $uploads
218 f=$src/cygwin/$base.hint && test -r $f && cp $f $uploads/setup.hint
219 find * -print | sort | tar -T - --no-recursion -cjf $tarstem.tar.bz2
222 for i in $sub_packages; do
224 subload=$uploads/$subname
225 subtarstem=$subload/$subname-$ver
226 mkdir -p $subload || exit 1
227 echo creating $subtarstem.tar.bz2
228 f=$src/cygwin/$subname.hint && test -r $f && cp $f $subload/setup.hint
230 find * -print | sort | tar -T - --no-recursion -cjf $subtarstem.tar.bz2
235 echo creating "$tarstem"-src.tar.bz2
236 find $package_src/* -print -follow | egrep -v '\.cvsignore|\.bak$|\.orig$|\.o$|~$|^.#|CVS|%redact|/tags$' | egrep -v "$src_exclude" | sort | tar -T - --no-recursion -cjf "$tarstem"-src.tar.bz2
251 preconfig () { # aka libtool_woes ()
261 cat > guile-config <<EOF
263 [ "\$1" == "--version" ] && echo "guile-config - Guile version $GUILE"
264 [ "\$1" == "compile" ] && echo "-I$cygwin_prefix/include"
265 [ "\$1" == "link" ] && echo "-L$cygwin_prefix/lib -lguile"
269 chmod 755 guile-config
272 ##opt='-O2 -g' LDFLAGS='"$cygwin_prefix/bin/libpython2.2.dll"
277 # Configure for build, for generating doc
280 PATH="$HOME/usr/pkg/guile-1.6.0/bin:$PATH" \
282 $src/configure --prefix=/usr --enable-config=for-build)
286 for i in $sub_packages; do
288 mkdir -p $inst-$i || exit 1
291 # Build for build, generating doc
295 cd $src && ln -s GNUmakefile.in GNUmakefile
298 PATH=/bin:/usr/bin:$PATH make conf=for-build all doc html-doc
299 for i in $(find . -path "out-for-build/*.1"); do
300 cp -pv $i $(dirname $(dirname $i))/$(basename $i)
304 cp -pv mf/out-for-build/* mf/out
306 addmakeflags MAKE_PFA_FILES=1 ' ' LDFLAGS="$cygwin_prefix/bin/libpython2.2.dll" ' ' 'target=i686-pc-cygwin'
311 cp -v scripts/out-for-build/midi2ly.1 scripts/out
312 cp -v lily/out-for-build/lilypond.1 lily/out
314 addmakeflags MAKE_PFA_FILES=1 ' ' LDFLAGS="$cygwin_prefix/bin/libpython2.2.dll" ' ' 'target=i686-pc-cygwin'
318 mkdir -p $inst-doc/$prefix
320 docdir=$prefix/share/doc/$base-$ver
322 make conf=for-build docdir=$inst-doc/$docdir install-html-doc
328 install -d -m755 $inst/$docdir
331 find . -maxdepth 1 -type f -exec cp -pv \{\} $inst/$docdir \;
336 #install -m644 $cygwin/README $inst/$docdir/README.Cygwin
337 install -m644 $cygwin/changelog $inst/$docdir/changelog.Cygwin
338 install -d -m755 $inst/$prefix/doc/Cygwin
339 #install -m644 $cygwin/README $inst/$prefix/doc/Cygwin/$package.README
342 install -m644 $cygwin/out/README $inst/$docdir/README.Cygwin
343 install -m644 $cygwin/out/README $inst/$prefix/doc/Cygwin/$package.README
347 cp -prv input $inst/$docdir
349 cd $inst-doc/$prefix/share/doc/$base-$ver &&
350 ln -s $(find html/Documentation -name '*.ps.gz') .
352 ## Cygwin doesn't adhere to FHS (and why should they?)
353 cd $inst/$prefix/share && tar cf - doc | (cd ..; tar xf -) && rm -rf doc
354 cd $inst-doc/$prefix/share && tar cf - doc | (cd ..; tar xf -) && rm -rf doc
358 # docdir=$prefix/share/doc/$base-$ver
359 # mkdir -p $inst-doc/$docdir || exit 1
363 mkdir -p ./$prefix || exit 1
364 mv $inst/$prefix/info ./$prefix
370 # mv $inst/$prefix/bin/guile-* $inst-devel/$prefix/bin