summaryrefslogtreecommitdiffstats
path: root/mdk-stage1/insmod-busybox/messages.c
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2000-12-07 23:15:22 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2000-12-07 23:15:22 +0000
commit71d6a65fa155d25fc325d6a9b83a746f5845922e (patch)
tree6cd57695ffaf8cefa1d4bacfea4bb4510db2195c /mdk-stage1/insmod-busybox/messages.c
parent79ccb1852b0424d003cfbf6d3985aebf6b831cb1 (diff)
downloaddrakx-backup-do-not-use-71d6a65fa155d25fc325d6a9b83a746f5845922e.tar
drakx-backup-do-not-use-71d6a65fa155d25fc325d6a9b83a746f5845922e.tar.gz
drakx-backup-do-not-use-71d6a65fa155d25fc325d6a9b83a746f5845922e.tar.bz2
drakx-backup-do-not-use-71d6a65fa155d25fc325d6a9b83a746f5845922e.tar.xz
drakx-backup-do-not-use-71d6a65fa155d25fc325d6a9b83a746f5845922e.zip
add insmod from busybox (i386 only)
Diffstat (limited to 'mdk-stage1/insmod-busybox/messages.c')
-rw-r--r--mdk-stage1/insmod-busybox/messages.c90
1 files changed, 90 insertions, 0 deletions
diff --git a/mdk-stage1/insmod-busybox/messages.c b/mdk-stage1/insmod-busybox/messages.c
new file mode 100644
index 000000000..81fd9c75c
--- /dev/null
+++ b/mdk-stage1/insmod-busybox/messages.c
@@ -0,0 +1,90 @@
+/* vi: set sw=4 ts=4: */
+/*
+ * Copyright (C) 2000 by BitterSweet Enterprises, LLC.
+ * Written by Karl M. Hegbloom <karlheg@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
+ *
+ */
+
+/*
+ * Let's put all of these messages in one place, and link this in as
+ * a separate object module, so that there are not going to be
+ * multiple non-unique but very similar strings in the binary.
+ * Perhaps this will make it simpler to internationalize also, and
+ * may make the binary slightly smaller.
+ */
+
+// To use this header file, include something like this:
+//
+//#define BB_DECLARE_EXTERN
+//#define bb_need_memory_exhausted
+//#include "messages.c"
+//
+//Then just use the string memory_exhausted when it is needed.
+//
+
+#include "busybox.h"
+#ifndef _BB_MESSAGES_C
+#define _BB_MESSAGES_C
+
+#ifdef BB_DECLARE_EXTERN
+# define BB_DEF_MESSAGE(symbol, string_const) extern const char *symbol;
+#else
+# define BB_DEF_MESSAGE(symbol, string_const) const char *symbol = string_const;
+#endif
+
+
+#if defined bb_need_full_version || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(full_version,
+ "BusyBox v" BB_VER " (" BB_BT ") multi-call binary -- GPL2")
+#endif
+#if defined bb_need_name_too_long || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(name_too_long, "file name too long\n")
+#endif
+#if defined bb_need_omitting_directory || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(omitting_directory, "%s: omitting directory\n")
+#endif
+#if defined bb_need_not_a_directory || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(not_a_directory, "%s: not a directory\n")
+#endif
+#if defined bb_need_memory_exhausted || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(memory_exhausted, "memory exhausted\n")
+#endif
+#if defined bb_need_invalid_date || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(invalid_date, "invalid date `%s'\n")
+#endif
+#if defined bb_need_invalid_option || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(invalid_option, "invalid option -- %c\n")
+#endif
+#if defined bb_need_io_error || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(io_error, "%s: input/output error -- %s\n")
+#endif
+#if defined bb_need_help || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(dash_dash_help, "--help")
+#endif
+#if defined bb_need_write_error || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(write_error, "Write Error\n")
+#endif
+#if defined bb_need_too_few_args || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(too_few_args, "too few arguments\n")
+#endif
+#if defined bb_need_name_longer_then_foo || ! defined BB_DECLARE_EXTERN
+ BB_DEF_MESSAGE(name_longer_then_foo, "Names longer then %d chars not supported.\n")
+#endif
+
+
+#endif /* _BB_MESSAGES_C */
+