expand ~foo to getpwnam("foo")->dir only #if !defined(MKSH_SMALL)

this makes it possible to build a (small) mksh on glibc systems statically
This commit is contained in:
tg
2007-01-11 00:32:31 +00:00
parent 56e8571167
commit e960fabf63
5 changed files with 25 additions and 7 deletions

4
main.c
View File

@ -13,7 +13,7 @@
#include <locale.h>
#endif
__RCSID("$MirOS: src/bin/mksh/main.c,v 1.64 2007/01/06 17:08:14 tg Exp $");
__RCSID("$MirOS: src/bin/mksh/main.c,v 1.65 2007/01/11 00:32:31 tg Exp $");
extern char **environ;
@ -117,7 +117,9 @@ main(int argc, char *argv[])
/* set up variable and command dictionaries */
ktinit(&taliases, APERM, 0);
ktinit(&aliases, APERM, 0);
#ifndef MKSH_SMALL
ktinit(&homedirs, APERM, 0);
#endif
/* define shell keywords */
initkeywords();