542289a3c6
* scaffold/gc.scm: Move from guile/gc.scm. * guile/: Remove. * module/language/paren.mes: Remove. * mes/module/mes/base.mes: Move from module/mes/. * mes/module/mes/boot-0.scm: Likewise. * mes/module/mes/boot-00.scm: Likewise. * mes/module/mes/boot-01.scm: Likewise. * mes/module/mes/boot-02.scm: Likewise. * mes/module/mes/catch.mes: Likewise. * mes/module/mes/display.mes: Likewise. * mes/module/mes/fluids.mes: Likewise. * mes/module/mes/getopt-long.mes: Likewise. * mes/module/mes/guile.mes: Likewise. * mes/module/mes/lalr.mes: Likewise. * mes/module/mes/lalr.scm: Likewise. * mes/module/mes/let.mes: Likewise. * mes/module/mes/match.mes: Likewise. * mes/module/mes/match.scm: Likewise. * mes/module/mes/mescc.mes: Likewise. * mes/module/mes/misc.mes: Likewise. * mes/module/mes/module.mes: Likewise. * mes/module/mes/optargs.mes: Likewise. * mes/module/mes/optargs.scm: Likewise. * mes/module/mes/peg.mes: Likewise. * mes/module/mes/peg/cache.scm: Likewise. * mes/module/mes/peg/codegen.scm: Likewise. * mes/module/mes/peg/simplify-tree.scm: Likewise. * mes/module/mes/peg/string-peg.scm: Likewise. * mes/module/mes/peg/using-parsers.scm: Likewise. * mes/module/mes/pmatch.mes: Likewise. * mes/module/mes/pmatch.scm: Likewise. * mes/module/mes/posix.mes: Likewise. * mes/module/mes/pretty-print.mes: Likewise. * mes/module/mes/pretty-print.scm: Likewise. * mes/module/mes/psyntax-0.mes: Likewise. * mes/module/mes/psyntax-1.mes: Likewise. * mes/module/mes/psyntax.mes: Likewise. * mes/module/mes/psyntax.pp: Likewise. * mes/module/mes/psyntax.ss: Likewise. * mes/module/mes/quasiquote.mes: Likewise. * mes/module/mes/quasisyntax.mes: Likewise. * mes/module/mes/quasisyntax.scm: Likewise. * mes/module/mes/repl.mes: Likewise. * mes/module/mes/scm.mes: Likewise. * mes/module/mes/syntax.mes: Likewise. * mes/module/mes/syntax.scm: Likewise. * mes/module/mes/test.mes: Likewise. * mes/module/mes/tiny-0.mes: Likewise. * mes/module/mes/type-0.mes: Likewise. * mes/module/mescc/M1.mes: Likewise. * mes/module/mescc/as.mes: Likewise. * mes/module/mescc/bytevectors.mes: Likewise. * mes/module/mescc/compile.mes: Likewise. * mes/module/mescc/i386/as.mes: Likewise. * mes/module/mescc/info.mes: Likewise. * mes/module/mescc/mescc.mes: Likewise. * mes/module/mescc/preprocess.mes: Likewise. * mes/module/nyacc/lalr.mes: Likewise. * mes/module/nyacc/lang/c99/cpp.mes: Likewise. * mes/module/nyacc/lang/c99/parser.mes: Likewise. * mes/module/nyacc/lang/c99/pprint.mes: Likewise. * mes/module/nyacc/lang/calc/parser.mes: Likewise. * mes/module/nyacc/lang/util.mes: Likewise. * mes/module/nyacc/lex.mes: Likewise. * mes/module/nyacc/parse.mes: Likewise. * mes/module/nyacc/util.mes: Likewise. * mes/module/rnrs/arithmetic/bitwise.mes: Likewise. * mes/module/srfi/srfi-0.mes: Likewise. * mes/module/srfi/srfi-1.mes: Likewise. * mes/module/srfi/srfi-1.scm: Likewise. * mes/module/srfi/srfi-13.mes: Likewise. * mes/module/srfi/srfi-14.mes: Likewise. * mes/module/srfi/srfi-16.mes: Likewise. * mes/module/srfi/srfi-16.scm: Likewise. * mes/module/srfi/srfi-26.mes: Likewise. * mes/module/srfi/srfi-26.scm: Likewise. * mes/module/srfi/srfi-43.mes: Likewise. * mes/module/srfi/srfi-8.mes: Likewise. * mes/module/srfi/srfi-9.mes: Likewise. * mes/module/srfi/srfi-9/gnu.mes: Likewise. * mes/module/sxml/xpath.mes: Likewise. * mes/module/sxml/xpath.scm: Likewise. * module/mes/mes-0.scm: Likewise. * build-aux/build-guile.sh: Update for new layout. * build-aux/build-mes.sh: Likewise. * build-aux/check-boot.sh: Likewise. * build-aux/check-mescc.sh: Likewise. * install.sh: Likewise. * scaffold/boot/51-module.scm: Likewise. * scaffold/boot/52-define-module.scm: Likewise. * scripts/mescc: Likewise. * src/mes.c: Likewise. * tests/base.test-guile: Likewise. * tests/boot.test: Likewise. * tests/srfi-9.test: Likewise. * mes/include: New symlink. * mes/lib: New symlink. * AUTHORS: Update file names.
88 lines
2.8 KiB
Bash
Executable file
88 lines
2.8 KiB
Bash
Executable file
#! /bin/sh
|
|
|
|
set -e
|
|
if [ -n "$BUILD_DEBUG" ]; then
|
|
set -x
|
|
fi
|
|
|
|
# use bash or lose if pipes fail
|
|
[ -n "$BASH" ] && set -o pipefail
|
|
|
|
SHELL=${SHELL-$(command -v sh)}
|
|
prefix=${prefix-/usr/local}
|
|
|
|
MES_PREFIX=${MES_PREFIX-$prefix/share/mes}
|
|
MES_SEED=${MES_SEED-../MES-SEED}
|
|
TINYCC_SEED=${TINYCC_SEED-../TINYCC-SEED}
|
|
|
|
GUILE_EFFECTIVE_VERSION=${GUILE_EFFECTIVE_VERSION-2.2}
|
|
datadir=${moduledir-$prefix/share/mes}
|
|
docdir=${moduledir-$prefix/share/doc/mes}
|
|
mandir=${mandir-$prefix/share/man}
|
|
moduledir=${moduledir-$datadir/module}
|
|
guile_site_dir=${guile_site_dir-$prefix/share/guile/site/$GUILE_EFFECTIVE_VERSION}
|
|
guile_site_ccache_dir=${guile_site_ccache_dir-$prefix/lib/guile/$GUILE_EFFECTIVE_VERSION/site-ccache}
|
|
docdir=${moduledir-$prefix/share/doc/mes}
|
|
|
|
mkdir -p $DESTDIR$prefix/bin
|
|
cp src/mes $DESTDIR$prefix/bin/mes
|
|
|
|
mkdir -p $DESTDIR$prefix/lib
|
|
mkdir -p $DESTDIR$MES_PREFIX/lib
|
|
cp scripts/mescc $DESTDIR$prefix/bin/mescc
|
|
|
|
mkdir -p $DESTDIR$MES_PREFIX
|
|
tar -cf- doc include lib scaffold | tar -xf- -C $DESTDIR$MES_PREFIX
|
|
tar -cf- --exclude='*.go' module | tar -xf- -C $DESTDIR$MES_PREFIX
|
|
tar -cf- -C mes module | tar -xf- -C $DESTDIR$MES_PREFIX
|
|
|
|
mkdir -p $DESTDIR$guile_site_dir
|
|
mkdir -p $DESTDIR$guile_site_ccache_dir
|
|
tar -cf- -C module --exclude='*.go' . | tar -xf- -C $DESTDIR$guile_site_dir
|
|
tar -cf- -C module --exclude='*.scm' . | tar -xf- -C $DESTDIR$guile_site_ccache_dir
|
|
|
|
chmod +w $DESTDIR$prefix/bin/mescc
|
|
sed \
|
|
-e "s,^#! /bin/sh,#! $SHELL," \
|
|
-e "s,@datadir@,$datadir,g" \
|
|
-e "s,@docdir@,$docdir,g" \
|
|
-e "s,@guile_site_ccache_dir@,$guile_site_ccache_dir,g" \
|
|
-e "s,@guile_site_dir@,$guile_site_dir,g" \
|
|
-e "s,@moduledir@,$moduledir,g" \
|
|
-e "s,@prefix@,$prefix,g" \
|
|
-e "s,@VERSION@,$VERSION,g" \
|
|
scripts/mescc > $DESTDIR$prefix/bin/mescc
|
|
chmod +w $DESTDIR$moduledir/mes/boot-0.scm
|
|
sed \
|
|
-e "s,^#! /bin/sh,#! $SHELL," \
|
|
-e "s,mes/module/,$moduledir/," \
|
|
-e "s,@datadir@,$datadir,g" \
|
|
-e "s,@docdir@,$docdir,g" \
|
|
-e "s,@guile_site_ccache_dir@,$guile_site_ccache_dir,g" \
|
|
-e "s,@guile_site_dir@,$guile_site_dir,g" \
|
|
-e "s,@moduledir@,$moduledir,g" \
|
|
-e "s,@prefix@,$prefix,g" \
|
|
-e "s,@VERSION@,$VERSION,g" \
|
|
mes/module/mes/boot-0.scm > $DESTDIR$moduledir/mes/boot-0.scm
|
|
|
|
sed \
|
|
-e "s,^#! /bin/sh,#! $SHELL," \
|
|
scripts/diff.scm > $DESTDIR$prefix/bin/diff.scm
|
|
chmod -w+x $DESTDIR$prefix/bin/diff.scm
|
|
|
|
if [ -f doc/mes.info ]; then
|
|
mkdir -p $DESTDIR$prefix/share/info
|
|
tar -cf- doc/mes.info* doc/images | tar -xf- --strip-components=1 -C $DESTDIR$prefix/share/info
|
|
install-info --info-dir=$DESTDIR$prefix/share/info doc/mes.info
|
|
fi
|
|
|
|
if [ -f doc/mes.1 ]; then
|
|
mkdir -p $DESTDIR$mandir/man1
|
|
cp doc/mes.1 $DESTDIR$mandir/man1/
|
|
fi
|
|
|
|
if [ -f doc/mescc.1 ]; then
|
|
mkdir -p $DESTDIR$mandir/man1
|
|
cp doc/mescc.1 $DESTDIR$mandir/man1/
|
|
fi
|