summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--applets/busybox.c6
-rw-r--r--busybox.c6
-rw-r--r--busybox.def.h3
-rw-r--r--true_false.c36
4 files changed, 41 insertions, 10 deletions
diff --git a/applets/busybox.c b/applets/busybox.c
index cb0e2a7..3af9840 100644
--- a/applets/busybox.c
+++ b/applets/busybox.c
@@ -45,9 +45,6 @@ static const struct Applet applets[] = {
#ifdef BB_DUTMP //usr/sbin
{"dutmp", cat_more_main},
#endif
-#ifdef BB_FALSE //bin
- {"false", false_main},
-#endif
#ifdef BB_FDFLUSH //bin
{"fdflush", fdflush_main},
#endif
@@ -142,8 +139,9 @@ static const struct Applet applets[] = {
#ifdef BB_TOUCH //usr/bin
{"touch", touch_main},
#endif
-#ifdef BB_TRUE //bin
+#ifdef BB_TRUE_FALSE //bin
{"true", true_main},
+ {"false", false_main},
#endif
#ifdef BB_UMOUNT //bin
{"umount", umount_main},
diff --git a/busybox.c b/busybox.c
index cb0e2a7..3af9840 100644
--- a/busybox.c
+++ b/busybox.c
@@ -45,9 +45,6 @@ static const struct Applet applets[] = {
#ifdef BB_DUTMP //usr/sbin
{"dutmp", cat_more_main},
#endif
-#ifdef BB_FALSE //bin
- {"false", false_main},
-#endif
#ifdef BB_FDFLUSH //bin
{"fdflush", fdflush_main},
#endif
@@ -142,8 +139,9 @@ static const struct Applet applets[] = {
#ifdef BB_TOUCH //usr/bin
{"touch", touch_main},
#endif
-#ifdef BB_TRUE //bin
+#ifdef BB_TRUE_FALSE //bin
{"true", true_main},
+ {"false", false_main},
#endif
#ifdef BB_UMOUNT //bin
{"umount", umount_main},
diff --git a/busybox.def.h b/busybox.def.h
index e379168..68d1ec0 100644
--- a/busybox.def.h
+++ b/busybox.def.h
@@ -14,7 +14,6 @@
#define BB_DF
#define BB_DMESG
//#define BB_DUTMP
-#define BB_FALSE
#define BB_FDFLUSH
#define BB_FIND
#define BB_GREP
@@ -46,7 +45,7 @@
#define BB_SYNC
#define BB_TAR
#define BB_TOUCH
-#define BB_TRUE
+#define BB_TRUE_FALSE
#define BB_UMOUNT
#define BB_UPDATE
#define BB_UTILITY
diff --git a/true_false.c b/true_false.c
new file mode 100644
index 0000000..e0ea959
--- /dev/null
+++ b/true_false.c
@@ -0,0 +1,36 @@
+/*
+ * Mini true/false implementation for busybox
+ *
+ * Copyright (C) 1998 by Erik Andersen <andersee@debian.org>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ */
+
+#include "internal.h"
+
+
+extern int
+true_main(int argc, char** argv)
+{
+ return( TRUE);
+}
+
+extern int
+false_main(int argc, char** argv)
+{
+ return( FALSE);
+}
+