Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH: module setup() fix
- X-seq: zsh-workers 4815
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxxx
- Subject: PATCH: module setup() fix
- Date: Wed, 16 Dec 1998 10:17:56 +0100 (MET)
Hello
On my way home yesterday I remembered that we have to make sure that a
setup_foo() function defined by a module is called if the module is
linked statically into zsh.
The patch below changes mkbltnmlst.sh to ensure this. But this works
*only* if the `.mdd' file for the module contains the line
`hassetup=1', this isn't fully automated (should it be?).
Bye
Sven
*** os/mkbltnmlst.sh Wed Dec 16 10:07:35 1998
--- Src/mkbltnmlst.sh Wed Dec 16 10:10:19 1998
***************
*** 45,50 ****
--- 45,51 ----
echo "/* linked-in module \`$bin_mod' */"
eval "loc=\$loc_$bin_mod"
unset moddeps
+ hassetup=0
. $srcdir/../$loc/${bin_mod}.mdd
for dep in $moddeps; do
case $done_mods in
***************
*** 55,60 ****
exit 1 ;;
esac
done
! echo " mod.nam = \"$bin_mod\"; boot_$bin_mod(&mod);"
done_mods="$done_mods$bin_mod "
done
--- 56,65 ----
exit 1 ;;
esac
done
! if [ $hassetup != 0 ]; then
! echo " mod.nam = \"$bin_mod\"; setup_$bin_mod(&mod); boot_$bin_mod(&mod);"
! else
! echo " mod.nam = \"$bin_mod\"; boot_$bin_mod(&mod);"
! fi
done_mods="$done_mods$bin_mod "
done
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author