- move #include busybox.h to the very top so we pull in the config
and eventual platform specific includes in early.
This commit is contained in:
parent
deda6a5c0d
commit
c89982dcd7
@ -1,3 +1,4 @@
|
|||||||
|
/* vi: set sw=4 ts=4: */
|
||||||
/*
|
/*
|
||||||
* adjtimex.c - read, and possibly modify, the Linux kernel `timex' variables.
|
* adjtimex.c - read, and possibly modify, the Linux kernel `timex' variables.
|
||||||
*
|
*
|
||||||
@ -6,16 +7,16 @@
|
|||||||
* Copyright 1997, 2000, 2001 Larry Doolittle <LRDoolittle@lbl.gov>
|
* Copyright 1997, 2000, 2001 Larry Doolittle <LRDoolittle@lbl.gov>
|
||||||
*
|
*
|
||||||
* busyboxed 20 March 2001, Larry Doolittle <ldoolitt@recycle.lbl.gov>
|
* busyboxed 20 March 2001, Larry Doolittle <ldoolitt@recycle.lbl.gov>
|
||||||
*
|
*
|
||||||
* Licensed under GPLv2 or later, see file License in this tarball for details.
|
* Licensed under GPLv2 or later, see file License in this tarball for details.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <sys/timex.h>
|
#include <sys/timex.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
static const struct {int bit; const char *name;} statlist[] = {
|
static const struct {int bit; const char *name;} statlist[] = {
|
||||||
{ STA_PLL, "PLL" },
|
{ STA_PLL, "PLL" },
|
||||||
|
@ -12,6 +12,7 @@
|
|||||||
|
|
||||||
#define VERSION "2.3.2"
|
#define VERSION "2.3.2"
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
@ -29,8 +30,6 @@
|
|||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <sys/resource.h>
|
#include <sys/resource.h>
|
||||||
|
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
#define arysize(ary) (sizeof(ary)/sizeof((ary)[0]))
|
#define arysize(ary) (sizeof(ary)/sizeof((ary)[0]))
|
||||||
|
|
||||||
#ifndef CRONTABS
|
#ifndef CRONTABS
|
||||||
|
@ -10,6 +10,7 @@
|
|||||||
* Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
|
* Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
@ -40,8 +41,6 @@
|
|||||||
#define PATH_VI "/bin/vi" /* location of vi */
|
#define PATH_VI "/bin/vi" /* location of vi */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
static const char *CDir = CRONTABS;
|
static const char *CDir = CRONTABS;
|
||||||
|
|
||||||
static void EditFile(const char *user, const char *file);
|
static void EditFile(const char *user, const char *file);
|
||||||
|
@ -1,11 +1,11 @@
|
|||||||
/* vi: set sw=4 ts=4: */
|
/* vi: set sw=4 ts=4: */
|
||||||
|
#include "busybox.h"
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
/* Tiny RPN calculator, because "expr" didn't give me bitwise operations. */
|
/* Tiny RPN calculator, because "expr" didn't give me bitwise operations. */
|
||||||
|
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vi: set sw=4 ts=4: */
|
||||||
/*
|
/*
|
||||||
* eject implementation for busybox
|
* eject implementation for busybox
|
||||||
*
|
*
|
||||||
@ -12,12 +13,12 @@
|
|||||||
* Most of the dirty work blatantly ripped off from cat.c =)
|
* Most of the dirty work blatantly ripped off from cat.c =)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <sys/ioctl.h>
|
#include <sys/ioctl.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <sys/mount.h>
|
#include <sys/mount.h>
|
||||||
#include <mntent.h>
|
#include <mntent.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
/* various defines swiped from linux/cdrom.h */
|
/* various defines swiped from linux/cdrom.h */
|
||||||
#define CDROMCLOSETRAY 0x5319 /* pendant of CDROMEJECT */
|
#define CDROMCLOSETRAY 0x5319 /* pendant of CDROMEJECT */
|
||||||
|
@ -12,12 +12,12 @@
|
|||||||
* - by Mark Lord (C) 1994-2002 -- freely distributable
|
* - by Mark Lord (C) 1994-2002 -- freely distributable
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
#include <endian.h>
|
|
||||||
#include <sys/ioctl.h>
|
#include <sys/ioctl.h>
|
||||||
#include <sys/sysmacros.h>
|
#include <sys/sysmacros.h>
|
||||||
#include <sys/times.h>
|
#include <sys/times.h>
|
||||||
@ -31,8 +31,6 @@
|
|||||||
#endif
|
#endif
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
/* device types */
|
/* device types */
|
||||||
/* ------------ */
|
/* ------------ */
|
||||||
#define NO_DEV 0xffff
|
#define NO_DEV 0xffff
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
* Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
|
* Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
@ -16,7 +17,6 @@
|
|||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
#ifndef SHUTDOWN_TIME
|
#ifndef SHUTDOWN_TIME
|
||||||
# define SHUTDOWN_TIME 254
|
# define SHUTDOWN_TIME 254
|
||||||
|
@ -30,6 +30,7 @@
|
|||||||
* redirected input has been read from stdin
|
* redirected input has been read from stdin
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
@ -37,8 +38,6 @@
|
|||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
|
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
#ifdef CONFIG_FEATURE_LESS_REGEXP
|
#ifdef CONFIG_FEATURE_LESS_REGEXP
|
||||||
#include "xregex.h"
|
#include "xregex.h"
|
||||||
#endif
|
#endif
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
* known bugs: can't deal with alpha ranges
|
* known bugs: can't deal with alpha ranges
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
@ -16,7 +17,6 @@
|
|||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <sys/sysmacros.h> /* major() and minor() */
|
#include <sys/sysmacros.h> /* major() and minor() */
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
#ifdef CONFIG_FEATURE_MAKEDEVS_LEAF
|
#ifdef CONFIG_FEATURE_MAKEDEVS_LEAF
|
||||||
int makedevs_main(int argc, char **argv)
|
int makedevs_main(int argc, char **argv)
|
||||||
|
@ -9,11 +9,11 @@
|
|||||||
* Based on sysvinit's mountpoint
|
* Based on sysvinit's mountpoint
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <errno.h> /* errno */
|
#include <errno.h> /* errno */
|
||||||
#include <string.h> /* strerror */
|
#include <string.h> /* strerror */
|
||||||
#include <getopt.h> /* optind */
|
#include <getopt.h> /* optind */
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
int mountpoint_main(int argc, char **argv)
|
int mountpoint_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
/* vi: set sw=4 ts=4: */
|
/* vi: set sw=4 ts=4: */
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <sys/mtio.h>
|
#include <sys/mtio.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
struct mt_opcodes {
|
struct mt_opcodes {
|
||||||
char *name;
|
char *name;
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vi: set sw=4 ts=4: */
|
||||||
/*
|
/*
|
||||||
* runlevel Prints out the previous and the current runlevel.
|
* runlevel Prints out the previous and the current runlevel.
|
||||||
*
|
*
|
||||||
@ -11,13 +12,12 @@
|
|||||||
* initially busyboxified by Bernhard Fischer
|
* initially busyboxified by Bernhard Fischer
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <utmp.h>
|
#include <utmp.h>
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
int runlevel_main(int argc, char *argv[])
|
int runlevel_main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
struct utmp *ut;
|
struct utmp *ut;
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
@ -31,7 +32,6 @@
|
|||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
|
|
||||||
#define SOH 0x01
|
#define SOH 0x01
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* vi: set sw=4 ts=4: */
|
||||||
/*
|
/*
|
||||||
* setsid.c -- execute a command in a new session
|
* setsid.c -- execute a command in a new session
|
||||||
* Rick Sladkey <jrs@world.std.com>
|
* Rick Sladkey <jrs@world.std.com>
|
||||||
@ -13,10 +14,10 @@
|
|||||||
* - busyboxed
|
* - busyboxed
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
int setsid_main(int argc, char *argv[])
|
int setsid_main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
|
@ -13,11 +13,11 @@
|
|||||||
* Badly hacked by Tito Ragusa <farmatito@tiscali.it>
|
* Badly hacked by Tito Ragusa <farmatito@tiscali.it>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <getopt.h>
|
#include <getopt.h>
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
#define WHOLE_FILE 1
|
#define WHOLE_FILE 1
|
||||||
#define PRINT_NAME 2
|
#define PRINT_NAME 2
|
||||||
|
@ -21,6 +21,7 @@
|
|||||||
Heavily modified for busybox by Erik Andersen <andersen@codepoet.org>
|
Heavily modified for busybox by Erik Andersen <andersen@codepoet.org>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
@ -35,7 +36,6 @@
|
|||||||
|
|
||||||
#define TV_MSEC tv_usec / 1000
|
#define TV_MSEC tv_usec / 1000
|
||||||
#include <sys/resource.h>
|
#include <sys/resource.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
/* Information on the resources used by a child process. */
|
/* Information on the resources used by a child process. */
|
||||||
typedef struct
|
typedef struct
|
||||||
|
@ -7,12 +7,12 @@
|
|||||||
* Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
|
* Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "busybox.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#include "busybox.h"
|
|
||||||
|
|
||||||
/* Userspace timer duration, in seconds */
|
/* Userspace timer duration, in seconds */
|
||||||
static unsigned int timer_duration = 30;
|
static unsigned int timer_duration = 30;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user