Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
122 lines (113 sloc) 4.46 KB
diff -aur busybox-1.18.4.orig/include/platform.h busybox-1.18.4/include/platform.h
--- busybox-1.18.4.orig/include/platform.h 2011-03-13 02:45:40.000000000 +0100
+++ busybox-1.18.4/include/platform.h 2011-04-05 23:35:30.008509894 +0200
@@ -350,9 +350,7 @@
#endif
-#if defined(__GLIBC__)
-# define fdprintf dprintf
-#endif
+#define fdprintf dprintf
#if defined(__dietlibc__)
# undef HAVE_STRCHRNUL
@@ -374,6 +372,13 @@
# undef HAVE_STRCHRNUL
#endif
+#if defined(__musl__)
+# undef HAVE_SETBIT
+# include <stddef.h>
+# include <termios.h>
+# include <sys/ioctl.h>
+#endif
+
/*
* Now, define prototypes for all the functions defined in platform.c
* These must come after all the HAVE_* macros are defined (or not)
--- busybox-1.18.4.orig/miscutils/man.c 2011-04-18 00:00:00.000000000 +0000
+++ busybox-1.18.4/miscutils/man.c 2011-04-18 09:14:10.863440396 +0000
@@ -109,7 +109,7 @@
/* "2>&1" is added so that nroff errors are shown in pager too.
* Otherwise it may show just empty screen */
cmd = xasprintf(
- man ? "gtbl | nroff -Tlatin1 -mandoc 2>&1 | %s"
+ man ? "nroff -Tutf -man 2>&1 | %s"
: "%s",
pager);
system(cmd);
diff -aur busybox-1.18.4.orig/networking/ifconfig.c busybox-1.18.4/networking/ifconfig.c
--- busybox-1.18.4.orig/networking/ifconfig.c 2011-03-13 02:45:06.000000000 +0100
+++ busybox-1.18.4/networking/ifconfig.c 2011-04-05 23:35:13.391907076 +0200
@@ -40,7 +40,7 @@
#include "inet_common.h"
#if ENABLE_FEATURE_IFCONFIG_SLIP
-# include <net/if_slip.h>
+# include <linux/if_slip.h>
#endif
/* I don't know if this is needed for busybox or not. Anyone? */
diff -aur busybox-1.18.4.orig/networking/libiproute/iplink.c busybox-1.18.4/networking/libiproute/iplink.c
--- busybox-1.18.4.orig/networking/libiproute/iplink.c 2011-03-13 02:45:06.000000000 +0100
+++ busybox-1.18.4/networking/libiproute/iplink.c 2011-04-05 23:35:13.391907076 +0200
@@ -5,7 +5,6 @@
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
*/
#include <net/if.h>
-#include <net/if_packet.h>
#include <netpacket/packet.h>
#include <net/ethernet.h>
diff -aur busybox-1.18.4.orig/networking/libiproute/ll_types.c busybox-1.18.4/networking/libiproute/ll_types.c
--- busybox-1.18.4.orig/networking/libiproute/ll_types.c 2011-03-13 02:45:06.000000000 +0100
+++ busybox-1.18.4/networking/libiproute/ll_types.c 2011-04-05 23:35:13.395240397 +0200
@@ -7,6 +7,7 @@
*
* Authors: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru>
*/
+#include <sys/socket.h>
#include <arpa/inet.h>
#include <linux/if_arp.h>
diff -aur busybox-1.18.4.orig/util-linux/fdisk.c busybox-1.18.4/util-linux/fdisk.c
--- busybox-1.18.4.orig/util-linux/fdisk.c 2011-03-13 02:45:40.000000000 +0100
+++ busybox-1.18.4/util-linux/fdisk.c 2011-04-05 23:35:13.398573718 +0200
@@ -529,7 +529,7 @@
{
#if ENABLE_FDISK_SUPPORT_LARGE_DISKS
off64_t off = (off64_t)secno * sector_size;
- if (lseek64(dev_fd, off, SEEK_SET) == (off64_t) -1)
+ if (lseek(dev_fd, off, SEEK_SET) == (off64_t) -1)
fdisk_fatal(unable_to_seek);
#else
uint64_t off = (uint64_t)secno * sector_size;
--- busybox/include/libbb.h 2011-03-12 19:45:40.000000000 -0600
+++ busybox.new/include/libbb.h 2011-07-23 18:24:06.563634320 -0500
@@ -31,6 +31,7 @@
#include <sys/mman.h>
#include <sys/socket.h>
#include <sys/stat.h>
+#include <sys/sysinfo.h>
#include <sys/time.h>
#include <sys/types.h>
#include <sys/wait.h>
@@ -100,25 +101,6 @@
#if !defined __FreeBSD__
char *dirname(char *path);
#endif
-/* Include our own copy of struct sysinfo to avoid binary compatibility
- * problems with Linux 2.4, which changed things. Grumble, grumble. */
-struct sysinfo {
- long uptime; /* Seconds since boot */
- unsigned long loads[3]; /* 1, 5, and 15 minute load averages */
- unsigned long totalram; /* Total usable main memory size */
- unsigned long freeram; /* Available memory size */
- unsigned long sharedram; /* Amount of shared memory */
- unsigned long bufferram; /* Memory used by buffers */
- unsigned long totalswap; /* Total swap space size */
- unsigned long freeswap; /* swap space still available */
- unsigned short procs; /* Number of current processes */
- unsigned short pad; /* Padding needed for m68k */
- unsigned long totalhigh; /* Total high memory size */
- unsigned long freehigh; /* Available high memory size */
- unsigned int mem_unit; /* Memory unit size in bytes */
- char _f[20 - 2 * sizeof(long) - sizeof(int)]; /* Padding: libc5 uses this.. */
-};
-int sysinfo(struct sysinfo* info);
#ifndef PATH_MAX
# define PATH_MAX 256
#endif