1997-04-26 17:21:57 +04:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
|
|
|
#
|
2006-10-22 08:14:26 +04:00
|
|
|
|
|
|
|
datarootdir=@datarootdir@
|
1997-04-26 17:21:57 +04:00
|
|
|
AWK=@AWK@
|
2016-09-02 05:25:22 +03:00
|
|
|
DIR=@datadir@/et
|
ChangeLog, Makefile.in:
Remove libext2fs.info*, not just libext2fs.info*.gz. Add an
uninstall-doc-libs target.
ChangeLog, Makefile.in, compile_et.1, compile_et.sh.in:
Makefile.in: Fix bug where my_dir was set incorrectly. Install the
et_c.awk and et_h.awk files in $(datadir)/et (i.e., /usr/share/et)
directory. Change to use new installation directory variables
convention. Fix uninstall rules to take $(DESTDIR) into account.
compile_et.1: Change man page to reflect the fact that compile_et is
now a awk/sed script, not a yacc script.
compile_et.sh.in: Look in $(datadir)/et for et_c.awk and et_h.awk; if
not found, look in the build directory. Add error checking for
non-existent input file.
ChangeLog, Makefile.in, mk_cmds.sh.in:
Makefile.in: Install the ct_c.awk and ct_c.sed files in $(datadir)/ss
(i.e., /usr/share/ss) directory. Change to use new installation
directory variables convention. Fix uninstall rules to take
$(DESTDIR) into account.
mk_cmds.sh.in: Look in $(datadir)/ss for ct_c.awk and ct_c.sed; if not
found, look in the build directory. Add error checking for
non-existent input file.
ChangeLog, Makefile.in:
Makefile.in: Change to use new installation directory variables
convention. Fix uninstall rules to take $(DESTDIR) into account.
1998-04-01 06:18:45 +04:00
|
|
|
|
2003-03-31 07:26:13 +04:00
|
|
|
if test "$1" = "--build-tree" ; then
|
|
|
|
shift;
|
|
|
|
DIR="$ET_DIR"
|
|
|
|
fi
|
|
|
|
|
ChangeLog, Makefile.in:
Remove libext2fs.info*, not just libext2fs.info*.gz. Add an
uninstall-doc-libs target.
ChangeLog, Makefile.in, compile_et.1, compile_et.sh.in:
Makefile.in: Fix bug where my_dir was set incorrectly. Install the
et_c.awk and et_h.awk files in $(datadir)/et (i.e., /usr/share/et)
directory. Change to use new installation directory variables
convention. Fix uninstall rules to take $(DESTDIR) into account.
compile_et.1: Change man page to reflect the fact that compile_et is
now a awk/sed script, not a yacc script.
compile_et.sh.in: Look in $(datadir)/et for et_c.awk and et_h.awk; if
not found, look in the build directory. Add error checking for
non-existent input file.
ChangeLog, Makefile.in, mk_cmds.sh.in:
Makefile.in: Install the ct_c.awk and ct_c.sed files in $(datadir)/ss
(i.e., /usr/share/ss) directory. Change to use new installation
directory variables convention. Fix uninstall rules to take
$(DESTDIR) into account.
mk_cmds.sh.in: Look in $(datadir)/ss for ct_c.awk and ct_c.sed; if not
found, look in the build directory. Add error checking for
non-existent input file.
ChangeLog, Makefile.in:
Makefile.in: Change to use new installation directory variables
convention. Fix uninstall rules to take $(DESTDIR) into account.
1998-04-01 06:18:45 +04:00
|
|
|
if test "x$1" = x ; then
|
|
|
|
echo "Usage: compile_et file"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2006-11-12 18:43:31 +03:00
|
|
|
for as_var in \
|
|
|
|
LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
|
|
|
|
LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
|
|
|
|
LC_TELEPHONE LC_TIME
|
|
|
|
do
|
|
|
|
if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
|
|
|
|
eval $as_var=C; export $as_var
|
|
|
|
else
|
|
|
|
$as_unset $as_var
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
|
2016-09-02 05:25:22 +03:00
|
|
|
if test -n "$_ET_DIR_OVERRIDE" ; then
|
|
|
|
DIR="$_ET_DIR_OVERRIDE";
|
|
|
|
fi
|
|
|
|
|
2004-09-18 03:54:22 +04:00
|
|
|
if test ! -f "$DIR/et_h.awk" || test ! -f "$DIR/et_c.awk" ; then
|
2016-09-02 05:25:22 +03:00
|
|
|
echo "compile_et: Couldn't find compile_et's template files."
|
|
|
|
exit 1
|
ChangeLog, Makefile.in:
Remove libext2fs.info*, not just libext2fs.info*.gz. Add an
uninstall-doc-libs target.
ChangeLog, Makefile.in, compile_et.1, compile_et.sh.in:
Makefile.in: Fix bug where my_dir was set incorrectly. Install the
et_c.awk and et_h.awk files in $(datadir)/et (i.e., /usr/share/et)
directory. Change to use new installation directory variables
convention. Fix uninstall rules to take $(DESTDIR) into account.
compile_et.1: Change man page to reflect the fact that compile_et is
now a awk/sed script, not a yacc script.
compile_et.sh.in: Look in $(datadir)/et for et_c.awk and et_h.awk; if
not found, look in the build directory. Add error checking for
non-existent input file.
ChangeLog, Makefile.in, mk_cmds.sh.in:
Makefile.in: Install the ct_c.awk and ct_c.sed files in $(datadir)/ss
(i.e., /usr/share/ss) directory. Change to use new installation
directory variables convention. Fix uninstall rules to take
$(DESTDIR) into account.
mk_cmds.sh.in: Look in $(datadir)/ss for ct_c.awk and ct_c.sed; if not
found, look in the build directory. Add error checking for
non-existent input file.
ChangeLog, Makefile.in:
Makefile.in: Change to use new installation directory variables
convention. Fix uninstall rules to take $(DESTDIR) into account.
1998-04-01 06:18:45 +04:00
|
|
|
fi
|
1997-04-26 17:21:57 +04:00
|
|
|
|
|
|
|
ROOT=`echo $1 | sed -e s/.et$//`
|
|
|
|
BASE=`basename $ROOT`
|
|
|
|
|
2001-09-17 07:29:17 +04:00
|
|
|
if test ! -f "$ROOT.et" ; then
|
ChangeLog, Makefile.in:
Remove libext2fs.info*, not just libext2fs.info*.gz. Add an
uninstall-doc-libs target.
ChangeLog, Makefile.in, compile_et.1, compile_et.sh.in:
Makefile.in: Fix bug where my_dir was set incorrectly. Install the
et_c.awk and et_h.awk files in $(datadir)/et (i.e., /usr/share/et)
directory. Change to use new installation directory variables
convention. Fix uninstall rules to take $(DESTDIR) into account.
compile_et.1: Change man page to reflect the fact that compile_et is
now a awk/sed script, not a yacc script.
compile_et.sh.in: Look in $(datadir)/et for et_c.awk and et_h.awk; if
not found, look in the build directory. Add error checking for
non-existent input file.
ChangeLog, Makefile.in, mk_cmds.sh.in:
Makefile.in: Install the ct_c.awk and ct_c.sed files in $(datadir)/ss
(i.e., /usr/share/ss) directory. Change to use new installation
directory variables convention. Fix uninstall rules to take
$(DESTDIR) into account.
mk_cmds.sh.in: Look in $(datadir)/ss for ct_c.awk and ct_c.sed; if not
found, look in the build directory. Add error checking for
non-existent input file.
ChangeLog, Makefile.in:
Makefile.in: Change to use new installation directory variables
convention. Fix uninstall rules to take $(DESTDIR) into account.
1998-04-01 06:18:45 +04:00
|
|
|
echo "compile_et: $ROOT.et: File not found"
|
|
|
|
exit 1;
|
|
|
|
fi
|
|
|
|
|
2005-05-06 17:42:34 +04:00
|
|
|
$AWK -f "${DIR}/et_h.awk" "outfile=${BASE}.h.$$" "outfn=${BASE}.h" "$ROOT.et"
|
|
|
|
if test -f ${BASE}.h && cmp -s ${BASE}.h.$$ ${BASE}.h ; then
|
2006-08-05 22:41:00 +04:00
|
|
|
rm -f ${BASE}.h.$$
|
2005-05-06 17:42:34 +04:00
|
|
|
else
|
2006-08-05 22:41:00 +04:00
|
|
|
mv -f ${BASE}.h.$$ ${BASE}.h
|
2015-01-23 20:05:17 +03:00
|
|
|
chmod a-w ${BASE}.h
|
2005-05-06 17:42:34 +04:00
|
|
|
fi
|
|
|
|
$AWK -f "${DIR}/et_c.awk" "outfile=${BASE}.c.$$" "outfn=${BASE}.c" "$ROOT.et"
|
|
|
|
if test -f ${BASE}.c && cmp -s ${BASE}.c.$$ ${BASE}.c ; then
|
2006-08-05 22:41:00 +04:00
|
|
|
rm -f ${BASE}.c.$$
|
2005-05-06 17:42:34 +04:00
|
|
|
else
|
2006-08-05 22:41:00 +04:00
|
|
|
mv -f ${BASE}.c.$$ ${BASE}.c
|
2015-01-23 20:05:17 +03:00
|
|
|
chmod a-w ${BASE}.c
|
2005-05-06 17:42:34 +04:00
|
|
|
fi
|