Stuf
This commit is contained in:
parent
3843e96252
commit
befda6e4ed
@ -1,4 +1,6 @@
|
||||
0.37
|
||||
* Wrote a micro syslogd, and a logger util (to log things to the syslog
|
||||
from the command line or scripts) With both compiled in, costs 4k.
|
||||
* Fixed 'make install' so symlinks are installed in their proper locations.
|
||||
* Changed the build system slightly so that features can now be enabled
|
||||
or disabled from the busybox.defs.h header file, without trying to
|
||||
|
4
Makefile
4
Makefile
@ -17,12 +17,12 @@
|
||||
|
||||
|
||||
PROG=busybox
|
||||
VERSION=0.36
|
||||
VERSION=0.37
|
||||
BUILDTIME=$(shell date "+%Y%m%d-%H%M")
|
||||
|
||||
# Comment out the following to make a debuggable build
|
||||
# Leave this off for production use.
|
||||
DODEBUG=true
|
||||
DODEBUG=false
|
||||
# If you want a static binary, turn this on. I can't think
|
||||
# of many situations where anybody would ever want it static,
|
||||
# but...
|
||||
|
3
TODO
3
TODO
@ -1,6 +1,7 @@
|
||||
TODO list for busybox in no particular order
|
||||
|
||||
* Add in a mini syslogd
|
||||
If you have any good ideas, please let me know.
|
||||
|
||||
* Allow tar to create archives with sockets, devices, and other special files
|
||||
* Add in a mini modprobe, insmod, rmmod
|
||||
* poweroff
|
||||
|
@ -28,7 +28,7 @@
|
||||
#define BB_LN
|
||||
#define BB_LOADFONT
|
||||
#define BB_LOADKMAP
|
||||
#define BB_LOGGER
|
||||
//#define BB_LOGGER
|
||||
#define BB_LS
|
||||
//#define BB_MAKEDEVS
|
||||
//#define BB_MATH
|
||||
@ -54,7 +54,7 @@
|
||||
#define BB_SLEEP
|
||||
#define BB_SWAPONOFF
|
||||
#define BB_SYNC
|
||||
#define BB_SYSLOGD
|
||||
//#define BB_SYSLOGD
|
||||
#define BB_TAR
|
||||
#define BB_TOUCH
|
||||
#define BB_TRUE_FALSE
|
||||
|
@ -1,5 +1,5 @@
|
||||
Name: busybox
|
||||
Version: 0.36
|
||||
Version: 0.37
|
||||
Release: 1
|
||||
Group: System/Utilities
|
||||
Summary: BusyBox is a tiny suite of Unix utilities in a multi-call binary.
|
||||
|
@ -1,5 +1,5 @@
|
||||
Name: busybox
|
||||
Version: 0.36
|
||||
Version: 0.37
|
||||
Release: 1
|
||||
Group: System/Utilities
|
||||
Summary: BusyBox is a tiny suite of Unix utilities in a multi-call binary.
|
||||
|
22
logger.c
22
logger.c
@ -118,13 +118,17 @@ extern int logger_main(int argc, char **argv)
|
||||
{
|
||||
struct sockaddr_un sunx;
|
||||
int fd, pri = LOG_USER|LOG_NOTICE;
|
||||
int fromStdinFlag=FALSE;
|
||||
int toStdErrFlag=FALSE;
|
||||
char *message, buf[1024];
|
||||
char *message, buf[1024], buf1[1024];
|
||||
time_t now;
|
||||
size_t addrLength;
|
||||
|
||||
/* Parse any options */
|
||||
while (--argc > 0 && **(++argv) == '-') {
|
||||
if (*((*argv)+1) == '\0') {
|
||||
fromStdinFlag=TRUE;
|
||||
}
|
||||
while (*(++(*argv))) {
|
||||
switch (**argv) {
|
||||
case 's':
|
||||
@ -146,16 +150,22 @@ extern int logger_main(int argc, char **argv)
|
||||
}
|
||||
}
|
||||
|
||||
if (argc>=1)
|
||||
if (**argv=='-') {
|
||||
if (fromStdinFlag==TRUE) {
|
||||
/* read from stdin */
|
||||
} else {
|
||||
message=*argv;
|
||||
int i=0;
|
||||
char c;
|
||||
while ((c = getc(stdin)) != EOF && i<sizeof(buf1)) {
|
||||
buf1[i++]=c;
|
||||
}
|
||||
else {
|
||||
message=buf1;
|
||||
} else {
|
||||
if (argc>=1) {
|
||||
message=*argv;
|
||||
} else {
|
||||
fprintf(stderr, "No message\n");
|
||||
exit( FALSE);
|
||||
}
|
||||
}
|
||||
|
||||
memset(&sunx, 0, sizeof(sunx));
|
||||
sunx.sun_family = AF_UNIX; /* Unix domain socket */
|
||||
|
@ -118,13 +118,17 @@ extern int logger_main(int argc, char **argv)
|
||||
{
|
||||
struct sockaddr_un sunx;
|
||||
int fd, pri = LOG_USER|LOG_NOTICE;
|
||||
int fromStdinFlag=FALSE;
|
||||
int toStdErrFlag=FALSE;
|
||||
char *message, buf[1024];
|
||||
char *message, buf[1024], buf1[1024];
|
||||
time_t now;
|
||||
size_t addrLength;
|
||||
|
||||
/* Parse any options */
|
||||
while (--argc > 0 && **(++argv) == '-') {
|
||||
if (*((*argv)+1) == '\0') {
|
||||
fromStdinFlag=TRUE;
|
||||
}
|
||||
while (*(++(*argv))) {
|
||||
switch (**argv) {
|
||||
case 's':
|
||||
@ -146,16 +150,22 @@ extern int logger_main(int argc, char **argv)
|
||||
}
|
||||
}
|
||||
|
||||
if (argc>=1)
|
||||
if (**argv=='-') {
|
||||
if (fromStdinFlag==TRUE) {
|
||||
/* read from stdin */
|
||||
} else {
|
||||
message=*argv;
|
||||
int i=0;
|
||||
char c;
|
||||
while ((c = getc(stdin)) != EOF && i<sizeof(buf1)) {
|
||||
buf1[i++]=c;
|
||||
}
|
||||
else {
|
||||
message=buf1;
|
||||
} else {
|
||||
if (argc>=1) {
|
||||
message=*argv;
|
||||
} else {
|
||||
fprintf(stderr, "No message\n");
|
||||
exit( FALSE);
|
||||
}
|
||||
}
|
||||
|
||||
memset(&sunx, 0, sizeof(sunx));
|
||||
sunx.sun_family = AF_UNIX; /* Unix domain socket */
|
||||
|
Loading…
Reference in New Issue
Block a user