aboutsummaryrefslogtreecommitdiff
path: root/shell/ash.c
diff options
context:
space:
mode:
Diffstat (limited to 'shell/ash.c')
-rw-r--r--shell/ash.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/shell/ash.c b/shell/ash.c
index 486386a25..9cc2208ab 100644
--- a/shell/ash.c
+++ b/shell/ash.c
@@ -265,7 +265,7 @@ union align {
265#define ALIGN(nbytes) (((nbytes) + sizeof(union align) - 1) & ~(sizeof(union align) - 1)) 265#define ALIGN(nbytes) (((nbytes) + sizeof(union align) - 1) & ~(sizeof(union align) - 1))
266#endif 266#endif
267 267
268#ifdef BB_LOCALE_SUPPORT 268#ifdef CONFIG_LOCALE_SUPPORT
269#include <locale.h> 269#include <locale.h>
270static void change_lc_all(const char *value); 270static void change_lc_all(const char *value);
271static void change_lc_ctype(const char *value); 271static void change_lc_ctype(const char *value);
@@ -1218,7 +1218,7 @@ static struct var vpath;
1218static struct var vps1; 1218static struct var vps1;
1219static struct var vps2; 1219static struct var vps2;
1220static struct var voptind; 1220static struct var voptind;
1221#ifdef BB_LOCALE_SUPPORT 1221#ifdef CONFIG_LOCALE_SUPPORT
1222static struct var vlc_all; 1222static struct var vlc_all;
1223static struct var vlc_ctype; 1223static struct var vlc_ctype;
1224#endif 1224#endif
@@ -1261,7 +1261,7 @@ static const struct varinit varinit[] = {
1261 NULL }, 1261 NULL },
1262 { &voptind, VSTRFIXED|VTEXTFIXED, "OPTIND=1", 1262 { &voptind, VSTRFIXED|VTEXTFIXED, "OPTIND=1",
1263 getoptsreset }, 1263 getoptsreset },
1264#ifdef BB_LOCALE_SUPPORT 1264#ifdef CONFIG_LOCALE_SUPPORT
1265 { &vlc_all, VSTRFIXED|VTEXTFIXED|VUNSET, "LC_ALL=", 1265 { &vlc_all, VSTRFIXED|VTEXTFIXED|VUNSET, "LC_ALL=",
1266 change_lc_all }, 1266 change_lc_all },
1267 { &vlc_ctype, VSTRFIXED|VTEXTFIXED|VUNSET, "LC_CTYPE=", 1267 { &vlc_ctype, VSTRFIXED|VTEXTFIXED|VUNSET, "LC_CTYPE=",
@@ -1556,7 +1556,7 @@ static int hashcmd (int, char **);
1556static int helpcmd (int, char **); 1556static int helpcmd (int, char **);
1557static int jobscmd (int, char **); 1557static int jobscmd (int, char **);
1558static int localcmd (int, char **); 1558static int localcmd (int, char **);
1559#ifndef BB_PWD 1559#ifndef CONFIG_PWD
1560static int pwdcmd (int, char **); 1560static int pwdcmd (int, char **);
1561#endif 1561#endif
1562static int readcmd (int, char **); 1562static int readcmd (int, char **);
@@ -1582,7 +1582,7 @@ static int typecmd (int, char **);
1582static int getoptscmd (int, char **); 1582static int getoptscmd (int, char **);
1583#endif 1583#endif
1584 1584
1585#ifndef BB_TRUE_FALSE 1585#ifndef CONFIG_TRUE_FALSE
1586static int true_main (int, char **); 1586static int true_main (int, char **);
1587static int false_main (int, char **); 1587static int false_main (int, char **);
1588#endif 1588#endif
@@ -1653,7 +1653,7 @@ static const struct builtincmd builtincmds[] = {
1653 { BUILTIN_REGULAR "let", letcmd }, 1653 { BUILTIN_REGULAR "let", letcmd },
1654#endif 1654#endif
1655 { BUILTIN_ASSIGN "local", localcmd }, 1655 { BUILTIN_ASSIGN "local", localcmd },
1656#ifndef BB_PWD 1656#ifndef CONFIG_PWD
1657 { BUILTIN_NOSPEC "pwd", pwdcmd }, 1657 { BUILTIN_NOSPEC "pwd", pwdcmd },
1658#endif 1658#endif
1659 { BUILTIN_REGULAR "read", readcmd }, 1659 { BUILTIN_REGULAR "read", readcmd },
@@ -1938,7 +1938,7 @@ updatepwd(const char *dir)
1938} 1938}
1939 1939
1940 1940
1941#ifndef BB_PWD 1941#ifndef CONFIG_PWD
1942static int 1942static int
1943pwdcmd(argc, argv) 1943pwdcmd(argc, argv)
1944 int argc; 1944 int argc;
@@ -3182,7 +3182,7 @@ returncmd(argc, argv)
3182} 3182}
3183 3183
3184 3184
3185#ifndef BB_TRUE_FALSE 3185#ifndef CONFIG_TRUE_FALSE
3186static int 3186static int
3187false_main(argc, argv) 3187false_main(argc, argv)
3188 int argc; 3188 int argc;
@@ -3224,7 +3224,7 @@ setinteractive(int on)
3224 is_interactive = on; 3224 is_interactive = on;
3225 if (do_banner==0 && is_interactive) { 3225 if (do_banner==0 && is_interactive) {
3226 /* Looks like they want an interactive shell */ 3226 /* Looks like they want an interactive shell */
3227#ifndef BB_FEATURE_SH_EXTRA_QUIET 3227#ifndef CONFIG_FEATURE_SH_EXTRA_QUIET
3228 printf( "\n\n" BB_BANNER " Built-in shell (ash)\n"); 3228 printf( "\n\n" BB_BANNER " Built-in shell (ash)\n");
3229 printf( "Enter 'help' for a list of built-in commands.\n\n"); 3229 printf( "Enter 'help' for a list of built-in commands.\n\n");
3230#endif 3230#endif
@@ -3535,11 +3535,11 @@ tryexec(char *cmd, char **argv, char **envp)
3535{ 3535{
3536 int e; 3536 int e;
3537 3537
3538#ifdef BB_FEATURE_SH_STANDALONE_SHELL 3538#ifdef CONFIG_FEATURE_SH_STANDALONE_SHELL
3539 char *name = cmd; 3539 char *name = cmd;
3540 char** argv_l=argv; 3540 char** argv_l=argv;
3541 int argc_l; 3541 int argc_l;
3542#ifdef BB_FEATURE_SH_APPLETS_ALWAYS_WIN 3542#ifdef CONFIG_FEATURE_SH_APPLETS_ALWAYS_WIN
3543 name = get_last_path_component(name); 3543 name = get_last_path_component(name);
3544#endif 3544#endif
3545 argv_l=envp; 3545 argv_l=envp;
@@ -3766,7 +3766,7 @@ static int helpcmd(int argc, char** argv)
3766 col = 0; 3766 col = 0;
3767 } 3767 }
3768 } 3768 }
3769#ifdef BB_FEATURE_SH_STANDALONE_SHELL 3769#ifdef CONFIG_FEATURE_SH_STANDALONE_SHELL
3770 { 3770 {
3771 extern const struct BB_applet applets[]; 3771 extern const struct BB_applet applets[];
3772 extern const size_t NUM_APPLETS; 3772 extern const size_t NUM_APPLETS;
@@ -6023,7 +6023,7 @@ reset(void) {
6023 * This file implements the input routines used by the parser. 6023 * This file implements the input routines used by the parser.
6024 */ 6024 */
6025 6025
6026#ifdef BB_FEATURE_COMMAND_EDITING 6026#ifdef CONFIG_FEATURE_COMMAND_EDITING
6027static const char * cmdedit_prompt; 6027static const char * cmdedit_prompt;
6028static inline void putprompt(const char *s) { 6028static inline void putprompt(const char *s) {
6029 cmdedit_prompt = s; 6029 cmdedit_prompt = s;
@@ -6090,7 +6090,7 @@ preadfd(void)
6090 parsenextc = buf; 6090 parsenextc = buf;
6091 6091
6092retry: 6092retry:
6093#ifdef BB_FEATURE_COMMAND_EDITING 6093#ifdef CONFIG_FEATURE_COMMAND_EDITING
6094 { 6094 {
6095 if (!iflag || parsefile->fd) 6095 if (!iflag || parsefile->fd)
6096 nr = safe_read(parsefile->fd, buf, BUFSIZ - 1); 6096 nr = safe_read(parsefile->fd, buf, BUFSIZ - 1);
@@ -7718,7 +7718,7 @@ ash_main(argc, argv)
7718 EXECCMD = find_builtin("exec"); 7718 EXECCMD = find_builtin("exec");
7719 EVALCMD = find_builtin("eval"); 7719 EVALCMD = find_builtin("eval");
7720 7720
7721#ifndef BB_FEATURE_SH_FANCY_PROMPT 7721#ifndef CONFIG_FEATURE_SH_FANCY_PROMPT
7722 unsetenv("PS1"); 7722 unsetenv("PS1");
7723 unsetenv("PS2"); 7723 unsetenv("PS2");
7724#endif 7724#endif
@@ -9331,7 +9331,7 @@ getoptsreset(const char *value)
9331 shellparam.optoff = -1; 9331 shellparam.optoff = -1;
9332} 9332}
9333 9333
9334#ifdef BB_LOCALE_SUPPORT 9334#ifdef CONFIG_LOCALE_SUPPORT
9335static void change_lc_all(const char *value) 9335static void change_lc_all(const char *value)
9336{ 9336{
9337 if(value != 0 && *value != 0) 9337 if(value != 0 && *value != 0)
@@ -12730,7 +12730,7 @@ findvar(struct var **vpp, const char *name)
12730/* 12730/*
12731 * Copyright (c) 1999 Herbert Xu <herbert@debian.org> 12731 * Copyright (c) 1999 Herbert Xu <herbert@debian.org>
12732 * This file contains code for the times builtin. 12732 * This file contains code for the times builtin.
12733 * $Id: ash.c,v 1.28 2001/10/19 00:22:22 andersen Exp $ 12733 * $Id: ash.c,v 1.29 2001/10/24 05:00:16 andersen Exp $
12734 */ 12734 */
12735static int timescmd (int argc, char **argv) 12735static int timescmd (int argc, char **argv)
12736{ 12736{