diff options
author | Eric Andersen <andersen@codepoet.org> | 2005-09-12 21:42:48 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2005-09-12 21:42:48 +0000 |
commit | 5d38f5ba898c276759f1e404455aad1f3073e730 (patch) | |
tree | 1b646fcf1fccf02a0559c01eb115580082e22e71 | |
parent | 2c6b41812febab045917c0be15ff8427191df0f4 (diff) | |
download | busybox-w32-5d38f5ba898c276759f1e404455aad1f3073e730.tar.gz busybox-w32-5d38f5ba898c276759f1e404455aad1f3073e730.tar.bz2 busybox-w32-5d38f5ba898c276759f1e404455aad1f3073e730.zip |
sysctl was seriously broken. And since in some cases 'CONFIG_SYSCTL'
could be included into application space via the kernel config option
of the same name, nasty compilation problems could result.
-rw-r--r-- | include/applets.h | 2 | ||||
-rw-r--r-- | include/usage.h | 8 | ||||
-rw-r--r-- | procps/Config.in | 2 | ||||
-rw-r--r-- | procps/Makefile.in | 2 | ||||
-rw-r--r-- | sysdeps/linux/defconfig | 2 |
5 files changed, 7 insertions, 9 deletions
diff --git a/include/applets.h b/include/applets.h index a4e78af57..61210bcc3 100644 --- a/include/applets.h +++ b/include/applets.h | |||
@@ -612,7 +612,7 @@ | |||
612 | #ifdef CONFIG_SYNC | 612 | #ifdef CONFIG_SYNC |
613 | APPLET(sync, sync_main, _BB_DIR_BIN, _BB_SUID_NEVER) | 613 | APPLET(sync, sync_main, _BB_DIR_BIN, _BB_SUID_NEVER) |
614 | #endif | 614 | #endif |
615 | #ifdef CONFIG_SYSCTL | 615 | #ifdef CONFIG_BB_SYSCTL |
616 | APPLET(sysctl, sysctl_main, _BB_DIR_SBIN, _BB_SUID_NEVER) | 616 | APPLET(sysctl, sysctl_main, _BB_DIR_SBIN, _BB_SUID_NEVER) |
617 | #endif | 617 | #endif |
618 | #ifdef CONFIG_SYSLOGD | 618 | #ifdef CONFIG_SYSLOGD |
diff --git a/include/usage.h b/include/usage.h index 29d78bbbb..723b97759 100644 --- a/include/usage.h +++ b/include/usage.h | |||
@@ -2654,24 +2654,22 @@ | |||
2654 | # define USAGE_IPC_LOG(a) | 2654 | # define USAGE_IPC_LOG(a) |
2655 | #endif | 2655 | #endif |
2656 | 2656 | ||
2657 | #ifdef CONFIG_SYSCTL | ||
2658 | #define sysctl_trivial_usage \ | 2657 | #define sysctl_trivial_usage \ |
2659 | "[OPTIONS]... [VALUE]..." | 2658 | "[OPTIONS]... [VALUE]..." |
2660 | #define sysctl_full_usage | 2659 | #define sysctl_full_usage \ |
2661 | "sysctl - configure kernel parameters at runtime\n\n" \ | 2660 | "configure kernel parameters at runtime\n\n" \ |
2662 | "Options:\n" \ | 2661 | "Options:\n" \ |
2663 | "\t-n\tUse this option to disable printing of the key name when printing values\n" \ | 2662 | "\t-n\tUse this option to disable printing of the key name when printing values\n" \ |
2664 | "\t-w\tUse this option when you want to change a sysctl setting\n" \ | 2663 | "\t-w\tUse this option when you want to change a sysctl setting\n" \ |
2665 | "\t-p\tLoad in sysctl settings from the file specified or /etc/sysctl.conf if none given\n" \ | 2664 | "\t-p\tLoad in sysctl settings from the file specified or /etc/sysctl.conf if none given\n" \ |
2666 | "\t-a\tDisplay all values currently available\n" \ | 2665 | "\t-a\tDisplay all values currently available\n" \ |
2667 | "\t-A\tDisplay all values currently available in table form" | 2666 | "\t-A\tDisplay all values currently available in table form" |
2668 | #define sysctl_example_usage | 2667 | #define sysctl_example_usage \ |
2669 | "sysctl [-n] variable ...\n" \ | 2668 | "sysctl [-n] variable ...\n" \ |
2670 | "sysctl [-n] -w variable=value ...\n" \ | 2669 | "sysctl [-n] -w variable=value ...\n" \ |
2671 | "sysctl [-n] -a\n" \ | 2670 | "sysctl [-n] -a\n" \ |
2672 | "sysctl [-n] -p <file>\t(default /etc/sysctl.conf)\n" \ | 2671 | "sysctl [-n] -p <file>\t(default /etc/sysctl.conf)\n" \ |
2673 | "sysctl [-n] -A\n" | 2672 | "sysctl [-n] -A\n" |
2674 | #endif | ||
2675 | 2673 | ||
2676 | #define syslogd_trivial_usage \ | 2674 | #define syslogd_trivial_usage \ |
2677 | "[OPTION]..." | 2675 | "[OPTION]..." |
diff --git a/procps/Config.in b/procps/Config.in index 8d557972c..7672582dd 100644 --- a/procps/Config.in +++ b/procps/Config.in | |||
@@ -72,7 +72,7 @@ config CONFIG_UPTIME | |||
72 | the system has been running, how many users are currently logged | 72 | the system has been running, how many users are currently logged |
73 | on, and the system load averages for the past 1, 5, and 15 minutes. | 73 | on, and the system load averages for the past 1, 5, and 15 minutes. |
74 | 74 | ||
75 | config CONFIG_SYSCTL | 75 | config CONFIG_BB_SYSCTL |
76 | bool "sysctl" | 76 | bool "sysctl" |
77 | default n | 77 | default n |
78 | help | 78 | help |
diff --git a/procps/Makefile.in b/procps/Makefile.in index b9eb117fd..5207b801b 100644 --- a/procps/Makefile.in +++ b/procps/Makefile.in | |||
@@ -29,7 +29,7 @@ PROCPS-$(CONFIG_KILL) += kill.o | |||
29 | PROCPS-$(CONFIG_PIDOF) += pidof.o | 29 | PROCPS-$(CONFIG_PIDOF) += pidof.o |
30 | PROCPS-$(CONFIG_PS) += ps.o | 30 | PROCPS-$(CONFIG_PS) += ps.o |
31 | PROCPS-$(CONFIG_RENICE) += renice.o | 31 | PROCPS-$(CONFIG_RENICE) += renice.o |
32 | PROCPS-$(CONFIG_SYSCTL) += sysctl.o | 32 | PROCPS-$(CONFIG_BB_SYSCTL) += sysctl.o |
33 | PROCPS-$(CONFIG_TOP) += top.o | 33 | PROCPS-$(CONFIG_TOP) += top.o |
34 | PROCPS-$(CONFIG_UPTIME) += uptime.o | 34 | PROCPS-$(CONFIG_UPTIME) += uptime.o |
35 | 35 | ||
diff --git a/sysdeps/linux/defconfig b/sysdeps/linux/defconfig index d62cfb903..617e86ba7 100644 --- a/sysdeps/linux/defconfig +++ b/sysdeps/linux/defconfig | |||
@@ -333,7 +333,7 @@ CONFIG_PS=y | |||
333 | # CONFIG_RENICE is not set | 333 | # CONFIG_RENICE is not set |
334 | # CONFIG_TOP is not set | 334 | # CONFIG_TOP is not set |
335 | CONFIG_UPTIME=y | 335 | CONFIG_UPTIME=y |
336 | # CONFIG_SYSCTL is not set | 336 | # CONFIG_BB_SYSCTL is not set |
337 | 337 | ||
338 | # | 338 | # |
339 | # Another Bourne-like Shell | 339 | # Another Bourne-like Shell |