summaryrefslogtreecommitdiff
path: root/package/busybox/patches
diff options
context:
space:
mode:
Diffstat (limited to 'package/busybox/patches')
-rw-r--r--package/busybox/patches/001-ipkg.patch1370
-rw-r--r--package/busybox/patches/002-find-empty.patch105
-rw-r--r--package/busybox/patches/003-ip-config.patch18
-rw-r--r--package/busybox/patches/patch-Makefile12
-rw-r--r--package/busybox/patches/patch-Makefile_flags21
-rw-r--r--package/busybox/patches/patch-include_libbb_h80
-rw-r--r--package/busybox/patches/patch-include_platform_h30
-rw-r--r--package/busybox/patches/patch-networking_traceroute_c12
-rw-r--r--package/busybox/patches/patch-networking_udhcp_dhcpd_c11
-rw-r--r--package/busybox/patches/patch-runit_runit_lib_h16
-rw-r--r--package/busybox/patches/patch-util-linux_fdisk_osf_c12
11 files changed, 689 insertions, 998 deletions
diff --git a/package/busybox/patches/001-ipkg.patch b/package/busybox/patches/001-ipkg.patch
index ca7059acc..d2acebb35 100644
--- a/package/busybox/patches/001-ipkg.patch
+++ b/package/busybox/patches/001-ipkg.patch
@@ -1,20 +1,9 @@
-diff -Nur busybox-1.13.4.orig/Makefile busybox-1.13.4/Makefile
---- busybox-1.13.4.orig/Makefile 2009-04-15 02:11:01.000000000 +0200
-+++ busybox-1.13.4/Makefile 2009-05-31 15:40:37.158023800 +0200
-@@ -444,6 +444,7 @@
-
- libs-y := \
- archival/ \
-+ archival/libipkg/ \
- archival/libunarchive/ \
- console-tools/ \
- coreutils/ \
-diff -Nur busybox-1.13.4.orig/archival/Config.in busybox-1.13.4/archival/Config.in
---- busybox-1.13.4.orig/archival/Config.in 2008-11-09 18:28:02.000000000 +0100
-+++ busybox-1.13.4/archival/Config.in 2009-05-31 15:40:36.993689729 +0200
-@@ -158,6 +158,14 @@
- gzip is used to compress files.
- It's probably the most widely used UNIX compression program.
+diff -Nur busybox-1.15.2.orig/archival/Config.in busybox-1.15.2/archival/Config.in
+--- busybox-1.15.2.orig/archival/Config.in 2009-10-08 02:59:09.000000000 +0200
++++ busybox-1.15.2/archival/Config.in 2009-11-26 11:10:12.799860030 +0100
+@@ -180,6 +180,14 @@
+ are actually slower than gzip at equivalent compression ratios
+ and take up 3.2K of code.
+config IPKG
+ bool "ipkg"
@@ -27,21 +16,10 @@ diff -Nur busybox-1.13.4.orig/archival/Config.in busybox-1.13.4/archival/Config.
config RPM2CPIO
bool "rpm2cpio"
default n
-diff -Nur busybox-1.13.4.orig/archival/Kbuild busybox-1.13.4/archival/Kbuild
---- busybox-1.13.4.orig/archival/Kbuild 2008-11-09 18:28:02.000000000 +0100
-+++ busybox-1.13.4/archival/Kbuild 2009-05-31 15:40:36.997989438 +0200
-@@ -16,6 +16,7 @@
- lib-$(CONFIG_DPKG_DEB) += dpkg_deb.o
- lib-$(CONFIG_GUNZIP) += bbunzip.o
- lib-$(CONFIG_GZIP) += gzip.o bbunzip.o
-+lib-$(CONFIG_IPKG) += ipkg.o
- lib-$(CONFIG_RPM2CPIO) += rpm2cpio.o
- lib-$(CONFIG_RPM) += rpm.o
- lib-$(CONFIG_TAR) += tar.o
-diff -Nur busybox-1.13.4.orig/archival/dpkg.c busybox-1.13.4/archival/dpkg.c
---- busybox-1.13.4.orig/archival/dpkg.c 2008-11-09 18:28:02.000000000 +0100
-+++ busybox-1.13.4/archival/dpkg.c 2009-05-31 15:40:36.993689729 +0200
-@@ -1485,16 +1485,7 @@
+diff -Nur busybox-1.15.2.orig/archival/dpkg.c busybox-1.15.2/archival/dpkg.c
+--- busybox-1.15.2.orig/archival/dpkg.c 2009-10-08 02:59:09.000000000 +0200
++++ busybox-1.15.2/archival/dpkg.c 2009-11-26 11:10:12.863858133 +0100
+@@ -1481,16 +1481,7 @@
return ar_handle->sub_archive->buffer;
}
@@ -59,9 +37,9 @@ diff -Nur busybox-1.13.4.orig/archival/dpkg.c busybox-1.13.4/archival/dpkg.c
static void unpack_package(deb_file_t *deb_file)
{
-diff -Nur busybox-1.13.4.orig/archival/ipkg.c busybox-1.13.4/archival/ipkg.c
---- busybox-1.13.4.orig/archival/ipkg.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/ipkg.c 2009-05-31 15:40:36.993689729 +0200
+diff -Nur busybox-1.15.2.orig/archival/ipkg.c busybox-1.15.2/archival/ipkg.c
+--- busybox-1.15.2.orig/archival/ipkg.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/ipkg.c 2009-11-26 11:10:12.867860320 +0100
@@ -0,0 +1,28 @@
+/* ipkg.c - the itsy package management system
+
@@ -91,73 +69,20 @@ diff -Nur busybox-1.13.4.orig/archival/ipkg.c busybox-1.13.4/archival/ipkg.c
+{
+ return ipkg_op(argc, argv);
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/Kbuild busybox-1.13.4/archival/libipkg/Kbuild
---- busybox-1.13.4.orig/archival/libipkg/Kbuild 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/Kbuild 2009-05-31 15:40:37.069994700 +0200
-@@ -0,0 +1,60 @@
-+# Makefile for busybox
-+#
-+# Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org>
-+# Copyright (C) 2006 OpenWrt.org
-+#
-+# Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
-+
-+LIBIPKG_CORE_OBJS:= \
-+ args.o \
-+ libipkg.o \
-+ user.o \
-+
-+LIBIPKG_CMD_OBJS:= \
-+ ipkg_cmd.o \
-+ ipkg_configure.o \
-+ ipkg_download.o \
-+ ipkg_install.o \
-+ ipkg_remove.o \
-+ ipkg_upgrade.o \
-+
-+LIBIPKG_DB_OBJS:= \
-+ hash_table.o \
-+ ipkg_conf.o \
-+ ipkg_utils.o \
-+ pkg.o \
-+ pkg_depends.o \
-+ pkg_extract.o \
-+ pkg_hash.o \
-+ pkg_parse.o \
-+ pkg_vec.o \
-+
-+LIBIPKG_LIST_OBJS:= \
-+ conffile.o \
-+ conffile_list.o \
-+ nv_pair.o \
-+ nv_pair_list.o \
-+ pkg_dest.o \
-+ pkg_dest_list.o \
-+ pkg_src.o \
-+ pkg_src_list.o \
-+ str_list.o \
-+ void_list.o \
-+
-+LIBIPKG_UTIL_OBJS:= \
-+ file_util.o \
-+ ipkg_message.o \
-+ str_util.o \
-+ xsystem.o \
-+
-+lib-y :=
-+lib-$(CONFIG_IPKG) += $(LIBIPKG_CORE_OBJS)
-+lib-$(CONFIG_IPKG) += $(LIBIPKG_CMD_OBJS)
-+lib-$(CONFIG_IPKG) += $(LIBIPKG_DB_OBJS)
-+lib-$(CONFIG_IPKG) += $(LIBIPKG_LIST_OBJS)
-+lib-$(CONFIG_IPKG) += $(LIBIPKG_UTIL_OBJS)
-+
-+ifeq ($(strip $(IPKG_ARCH)),)
-+IPKG_ARCH:=$(TARGET_ARCH)
-+endif
-+CFLAGS += -DIPKG_LIB -DIPKGLIBDIR="\"/usr/lib\"" -DHOST_CPU_STR="\"$(IPKG_ARCH)\""
-diff -Nur busybox-1.13.4.orig/archival/libipkg/args.c busybox-1.13.4/archival/libipkg/args.c
---- busybox-1.13.4.orig/archival/libipkg/args.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/args.c 2009-05-31 15:40:36.997989438 +0200
+diff -Nur busybox-1.15.2.orig/archival/Kbuild busybox-1.15.2/archival/Kbuild
+--- busybox-1.15.2.orig/archival/Kbuild 2009-09-26 15:14:56.000000000 +0200
++++ busybox-1.15.2/archival/Kbuild 2009-11-26 11:11:08.370253633 +0100
+@@ -16,6 +16,7 @@
+ lib-$(CONFIG_DPKG_DEB) += dpkg_deb.o
+ lib-$(CONFIG_GUNZIP) += bbunzip.o
+ lib-$(CONFIG_GZIP) += gzip.o bbunzip.o
++lib-$(CONFIG_IPKG) += ipkg.o
+ lib-$(CONFIG_LZOP) += lzop.o lzo1x_1.o lzo1x_1o.o lzo1x_d.o bbunzip.o
+ lib-$(CONFIG_LZOP_COMPR_HIGH) += lzo1x_9x.o
+ lib-$(CONFIG_RPM2CPIO) += rpm2cpio.o
+diff -Nur busybox-1.15.2.orig/archival/libipkg/args.c busybox-1.15.2/archival/libipkg/args.c
+--- busybox-1.15.2.orig/archival/libipkg/args.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/args.c 2009-11-26 11:10:13.027859475 +0100
@@ -0,0 +1,242 @@
+/* args.c - parse command-line args
+
@@ -401,9 +326,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/args.c busybox-1.13.4/archival/li
+{
+ bb_error_msg("version %s\n", IPKG_VERSION);
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/args.h busybox-1.13.4/archival/libipkg/args.h
---- busybox-1.13.4.orig/archival/libipkg/args.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/args.h 2009-05-31 15:40:36.997989438 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/args.h busybox-1.15.2/archival/libipkg/args.h
+--- busybox-1.15.2.orig/archival/libipkg/args.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/args.h 2009-11-26 11:10:13.111859002 +0100
@@ -0,0 +1,72 @@
+/* args.h - parse command-line args
+
@@ -477,9 +402,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/args.h busybox-1.13.4/archival/li
+void args_usage(const char *complaint);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/conffile.c busybox-1.13.4/archival/libipkg/conffile.c
---- busybox-1.13.4.orig/archival/libipkg/conffile.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/conffile.c 2009-05-31 15:40:36.997989438 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/conffile.c busybox-1.15.2/archival/libipkg/conffile.c
+--- busybox-1.15.2.orig/archival/libipkg/conffile.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/conffile.c 2009-11-26 11:10:13.115859512 +0100
@@ -0,0 +1,65 @@
+/* conffile.c - the itsy package management system
+
@@ -546,9 +471,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/conffile.c busybox-1.13.4/archiva
+
+ return ret;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/conffile.h busybox-1.13.4/archival/libipkg/conffile.h
---- busybox-1.13.4.orig/archival/libipkg/conffile.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/conffile.h 2009-05-31 15:40:36.997989438 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/conffile.h busybox-1.15.2/archival/libipkg/conffile.h
+--- busybox-1.15.2.orig/archival/libipkg/conffile.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/conffile.h 2009-11-26 11:10:13.115859512 +0100
@@ -0,0 +1,30 @@
+/* conffile.h - the itsy package management system
+
@@ -580,9 +505,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/conffile.h busybox-1.13.4/archiva
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/conffile_list.c busybox-1.13.4/archival/libipkg/conffile_list.c
---- busybox-1.13.4.orig/archival/libipkg/conffile_list.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/conffile_list.c 2009-05-31 15:40:37.001989668 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/conffile_list.c busybox-1.15.2/archival/libipkg/conffile_list.c
+--- busybox-1.15.2.orig/archival/libipkg/conffile_list.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/conffile_list.c 2009-11-26 11:10:13.171857147 +0100
@@ -0,0 +1,47 @@
+/* conffile_list.c - the itsy package management system
+
@@ -631,9 +556,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/conffile_list.c busybox-1.13.4/ar
+ return nv_pair_list_pop(list);
+}
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/conffile_list.h busybox-1.13.4/archival/libipkg/conffile_list.h
---- busybox-1.13.4.orig/archival/libipkg/conffile_list.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/conffile_list.h 2009-05-31 15:40:37.005990736 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/conffile_list.h busybox-1.15.2/archival/libipkg/conffile_list.h
+--- busybox-1.15.2.orig/archival/libipkg/conffile_list.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/conffile_list.h 2009-11-26 11:10:13.171857147 +0100
@@ -0,0 +1,36 @@
+/* conffile_list.h - the itsy package management system
+
@@ -671,10 +596,10 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/conffile_list.h busybox-1.13.4/ar
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/file_util.c busybox-1.13.4/archival/libipkg/file_util.c
---- busybox-1.13.4.orig/archival/libipkg/file_util.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/file_util.c 2009-05-31 15:40:37.005990736 +0200
-@@ -0,0 +1,132 @@
+diff -Nur busybox-1.15.2.orig/archival/libipkg/file_util.c busybox-1.15.2/archival/libipkg/file_util.c
+--- busybox-1.15.2.orig/archival/libipkg/file_util.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/file_util.c 2009-11-27 18:30:35.846386159 +0100
+@@ -0,0 +1,186 @@
+/* file_util.c - convenience routines for common stat operations
+
+ Carl D. Worth
@@ -802,14 +727,68 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/file_util.c busybox-1.13.4/archiv
+ return bb_make_directory(path, mode, FILEUTILS_RECUR);
+}
+
++static unsigned char *hash_bin_to_hex(unsigned char *hash_value,
++ unsigned hash_length)
++{
++ /* xzalloc zero-terminates */
++ char *hex_value = xzalloc((hash_length * 2) + 1);
++ bin2hex(hex_value, (char*)hash_value, hash_length);
++ return (unsigned char *)hex_value;
++}
++
++static uint8_t *hash_file(const char *filename, hash_algo_t hash_algo)
++{
++ int src_fd, hash_len, count;
++ union _ctx_ {
++ sha1_ctx_t sha1;
++ md5_ctx_t md5;
++ } context;
++ uint8_t *hash_value = NULL;
++ RESERVE_CONFIG_UBUFFER(in_buf, 4096);
++ void FAST_FUNC (*update)(const void*, size_t, void*);
++ void FAST_FUNC (*final)(void*, void*);
++
++ src_fd = open_or_warn_stdin(filename);
++ if (src_fd < 0) {
++ return NULL;
++ }
++
++ /* figure specific hash algorithims */
++ if (ENABLE_MD5SUM && hash_algo == HASH_MD5) {
++ md5_begin(&context.md5);
++ update = (void*)md5_hash;
++ final = (void*)md5_end;
++ hash_len = 16;
++ } else {
++ bb_error_msg_and_die("algorithm not supported");
++ }
++
++ while (0 < (count = safe_read(src_fd, in_buf, 4096))) {
++ update(in_buf, count, &context);
++ }
++
++ if (count == 0) {
++ final(in_buf, &context);
++ hash_value = hash_bin_to_hex(in_buf, hash_len);
++ }
++
++ RELEASE_CONFIG_BUFFER(in_buf);
++
++ if (src_fd != STDIN_FILENO) {
++ close(src_fd);
++ }
++
++ return hash_value;
++}
++
+uint8_t *file_md5sum_alloc(const char *file_name)
+{
+ return hash_file(file_name, HASH_MD5);
+}
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/file_util.h busybox-1.13.4/archival/libipkg/file_util.h
---- busybox-1.13.4.orig/archival/libipkg/file_util.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/file_util.h 2009-05-31 15:40:37.005990736 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/file_util.h busybox-1.15.2/archival/libipkg/file_util.h
+--- busybox-1.15.2.orig/archival/libipkg/file_util.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/file_util.h 2009-11-26 11:10:13.231859479 +0100
@@ -0,0 +1,29 @@
+/* file_util.h - convenience routines for common file operations
+
@@ -840,9 +819,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/file_util.h busybox-1.13.4/archiv
+uint8_t *file_md5sum_alloc(const char *file_name);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/hash_table.c busybox-1.13.4/archival/libipkg/hash_table.c
---- busybox-1.13.4.orig/archival/libipkg/hash_table.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/hash_table.c 2009-05-31 15:40:37.005990736 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/hash_table.c busybox-1.15.2/archival/libipkg/hash_table.c
+--- busybox-1.15.2.orig/archival/libipkg/hash_table.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/hash_table.c 2009-11-26 11:10:13.311857371 +0100
@@ -0,0 +1,155 @@
+/* hash.c - hash tables for ipkg
+
@@ -999,9 +978,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/hash_table.c busybox-1.13.4/archi
+ }
+}
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/hash_table.h busybox-1.13.4/archival/libipkg/hash_table.h
---- busybox-1.13.4.orig/archival/libipkg/hash_table.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/hash_table.h 2009-05-31 15:40:37.005990736 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/hash_table.h busybox-1.15.2/archival/libipkg/hash_table.h
+--- busybox-1.15.2.orig/archival/libipkg/hash_table.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/hash_table.h 2009-11-26 11:10:13.311857371 +0100
@@ -0,0 +1,44 @@
+/* hash.h - hash tables for ipkg
+
@@ -1047,79 +1026,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/hash_table.h busybox-1.13.4/archi
+void hash_table_foreach(hash_table_t *hash, void (*f)(const char *key, void *entry, void *data), void *data);
+
+#endif /* _HASH_TABLE_H_ */
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg.h busybox-1.13.4/archival/libipkg/ipkg.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg.h 2009-05-31 15:40:37.037992297 +0200
-@@ -0,0 +1,66 @@
-+/* ipkg.h - the itsy package management system
-+
-+ Carl D. Worth
-+
-+ Copyright (C) 2001 University of Southern California
-+
-+ 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, 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.
-+*/
-+
-+#ifndef IPKG_H
-+#define IPKG_H
-+
-+#include "libbb.h"
-+
-+#include "ipkg_includes.h"
-+#include "ipkg_conf.h"
-+#include "ipkg_message.h"
-+
-+#define IPKG_PKG_EXTENSION ".ipk"
-+#define DPKG_PKG_EXTENSION ".deb"
-+
-+#define IPKG_LEGAL_PKG_NAME_CHARS "abcdefghijklmnopqrstuvwxyz0123456789.+-"
-+#define IPKG_PKG_VERSION_SEP_CHAR '_'
-+
-+#define IPKG_STATE_DIR_PREFIX IPKGLIBDIR"/ipkg"
-+#define IPKG_LISTS_DIR_SUFFIX "lists"
-+#define IPKG_INFO_DIR_SUFFIX "info"
-+#define IPKG_STATUS_FILE_SUFFIX "status"
-+
-+#define IPKG_BACKUP_SUFFIX "-ipkg.backup"
-+
-+#define IPKG_LIST_DESCRIPTION_LENGTH 128
-+
-+#define IPKG_VERSION "1.00"
-+
-+
-+enum ipkg_error {
-+ IPKG_SUCCESS = 0,
-+ IPKG_PKG_DEPS_UNSATISFIED,
-+ IPKG_PKG_IS_ESSENTIAL,
-+ IPKG_PKG_HAS_DEPENDENTS,
-+ IPKG_PKG_HAS_NO_CANDIDATE
-+};
-+typedef enum ipkg_error ipkg_error_t;
-+
-+extern int ipkg_state_changed;
-+
-+
-+struct errlist {
-+ char * errmsg;
-+ struct errlist * next;
-+} ;
-+
-+extern struct errlist* error_list;
-+
-+extern ipkg_conf_t *global_conf;
-+
-+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_cmd.c busybox-1.13.4/archival/libipkg/ipkg_cmd.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_cmd.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_cmd.c 2009-05-31 15:40:37.013991196 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_cmd.c busybox-1.15.2/archival/libipkg/ipkg_cmd.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_cmd.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_cmd.c 2009-11-26 11:10:13.403858760 +0100
@@ -0,0 +1,1433 @@
+/* ipkg_cmd.c - the itsy package management system
+
@@ -2554,9 +2463,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_cmd.c busybox-1.13.4/archiva
+}
+
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_cmd.h busybox-1.13.4/archival/libipkg/ipkg_cmd.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_cmd.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_cmd.h 2009-05-31 15:40:37.021990539 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_cmd.h busybox-1.15.2/archival/libipkg/ipkg_cmd.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_cmd.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_cmd.h 2009-11-26 11:10:13.403858760 +0100
@@ -0,0 +1,46 @@
+/* ipkg_cmd.h - the itsy package management system
+
@@ -2604,9 +2513,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_cmd.h busybox-1.13.4/archiva
+int pkg_mark_provides(pkg_t *pkg);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_conf.c busybox-1.13.4/archival/libipkg/ipkg_conf.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_conf.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_conf.c 2009-05-31 15:40:37.021990539 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_conf.c busybox-1.15.2/archival/libipkg/ipkg_conf.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_conf.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_conf.c 2009-11-26 11:10:13.459858355 +0100
@@ -0,0 +1,711 @@
+/* ipkg_conf.c - the itsy package management system
+
@@ -3319,9 +3228,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_conf.c busybox-1.13.4/archiv
+ sprintf_alloc(&root_filename, "%s%s", (conf->offline_root ? conf->offline_root : ""), filename);
+ return root_filename;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_conf.h busybox-1.13.4/archival/libipkg/ipkg_conf.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_conf.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_conf.h 2009-05-31 15:40:37.025991328 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_conf.h busybox-1.15.2/archival/libipkg/ipkg_conf.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_conf.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_conf.h 2009-11-26 11:10:13.463859703 +0100
@@ -0,0 +1,107 @@
+/* ipkg_conf.h - the itsy package management system
+
@@ -3430,9 +3339,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_conf.h busybox-1.13.4/archiv
+char *root_filename_alloc(ipkg_conf_t *conf, char *filename);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_configure.c busybox-1.13.4/archival/libipkg/ipkg_configure.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_configure.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_configure.c 2009-05-31 15:40:37.025991328 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_configure.c busybox-1.15.2/archival/libipkg/ipkg_configure.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_configure.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_configure.c 2009-11-26 11:10:13.463859703 +0100
@@ -0,0 +1,40 @@
+/* ipkg_configure.c - the itsy package management system
+
@@ -3474,9 +3383,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_configure.c busybox-1.13.4/a
+ return 0;
+}
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_configure.h busybox-1.13.4/archival/libipkg/ipkg_configure.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_configure.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_configure.h 2009-05-31 15:40:37.025991328 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_configure.h busybox-1.15.2/archival/libipkg/ipkg_configure.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_configure.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_configure.h 2009-11-26 11:10:13.516657768 +0100
@@ -0,0 +1,25 @@
+/* ipkg_configure.h - the itsy package management system
+
@@ -3503,9 +3412,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_configure.h busybox-1.13.4/a
+int ipkg_configure(ipkg_conf_t *ipkg_conf, pkg_t *pkg);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_download.c busybox-1.13.4/archival/libipkg/ipkg_download.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_download.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_download.c 2009-05-31 15:42:41.497770134 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_download.c busybox-1.15.2/archival/libipkg/ipkg_download.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_download.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_download.c 2009-11-26 11:10:13.519859294 +0100
@@ -0,0 +1,195 @@
+/* ipkg_download.c - the itsy package management system
+
@@ -3702,9 +3611,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_download.c busybox-1.13.4/ar
+ }
+ return 0;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_download.h busybox-1.13.4/archival/libipkg/ipkg_download.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_download.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_download.h 2009-05-31 15:40:37.033992625 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_download.h busybox-1.15.2/archival/libipkg/ipkg_download.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_download.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_download.h 2009-11-26 11:10:13.519859294 +0100
@@ -0,0 +1,30 @@
+/* ipkg_download.h - the itsy package management system
+
@@ -3736,9 +3645,81 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_download.h busybox-1.13.4/ar
+int ipkg_prepare_url_for_install(ipkg_conf_t *conf, const char *url, char **namep);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_includes.h busybox-1.13.4/archival/libipkg/ipkg_includes.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_includes.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_includes.h 2009-05-31 15:40:37.041993644 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg.h busybox-1.15.2/archival/libipkg/ipkg.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg.h 2009-11-27 18:16:56.974265578 +0100
+@@ -0,0 +1,68 @@
++/* ipkg.h - the itsy package management system
++
++ Carl D. Worth
++
++ Copyright (C) 2001 University of Southern California
++
++ 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, 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.
++*/
++
++#ifndef IPKG_H
++#define IPKG_H
++
++#include "libbb.h"
++
++#include "ipkg_includes.h"
++#include "ipkg_conf.h"
++#include "ipkg_message.h"
++
++#define IPKG_PKG_EXTENSION ".ipk"
++#define DPKG_PKG_EXTENSION ".deb"
++
++#define IPKG_LEGAL_PKG_NAME_CHARS "abcdefghijklmnopqrstuvwxyz0123456789.+-"
++#define IPKG_PKG_VERSION_SEP_CHAR '_'
++
++#define IPKG_STATE_DIR_PREFIX IPKGLIBDIR"/ipkg"
++#define IPKG_LISTS_DIR_SUFFIX "lists"
++#define IPKG_INFO_DIR_SUFFIX "info"
++#define IPKG_STATUS_FILE_SUFFIX "status"
++
++#define IPKG_BACKUP_SUFFIX "-ipkg.backup"
++
++#define IPKG_LIST_DESCRIPTION_LENGTH 128
++
++#define IPKG_VERSION "1.00"
++
++
++enum ipkg_error {
++ IPKG_SUCCESS = 0,
++ IPKG_PKG_DEPS_UNSATISFIED,
++ IPKG_PKG_IS_ESSENTIAL,
++ IPKG_PKG_HAS_DEPENDENTS,
++ IPKG_PKG_HAS_NO_CANDIDATE
++};
++typedef enum ipkg_error ipkg_error_t;
++
++extern int ipkg_state_changed;
++
++
++struct errlist {
++ char * errmsg;
++ struct errlist * next;
++} ;
++
++extern struct errlist* error_list;
++
++extern ipkg_conf_t *global_conf;
++
++typedef enum { HASH_SHA1, HASH_MD5 } hash_algo_t;
++
++#endif
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_includes.h busybox-1.15.2/archival/libipkg/ipkg_includes.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_includes.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_includes.h 2009-11-26 11:10:13.635857588 +0100
@@ -0,0 +1,79 @@
+#ifndef IPKG_INCLUDES_H
+#define IPKG_INCLUDES_H
@@ -3819,9 +3800,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_includes.h busybox-1.13.4/ar
+#endif
+
+#endif /* IPKG_INCLUDES_H */
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_install.c busybox-1.13.4/archival/libipkg/ipkg_install.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_install.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_install.c 2009-05-31 15:40:37.045994712 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_install.c busybox-1.15.2/archival/libipkg/ipkg_install.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_install.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_install.c 2009-11-26 11:10:13.659857013 +0100
@@ -0,0 +1,1982 @@
+/* ipkg_install.c - the itsy package management system
+
@@ -5805,9 +5786,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_install.c busybox-1.13.4/arc
+}
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_install.h busybox-1.13.4/archival/libipkg/ipkg_install.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_install.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_install.h 2009-05-31 15:40:37.049992428 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_install.h busybox-1.15.2/archival/libipkg/ipkg_install.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_install.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_install.h 2009-11-26 11:10:13.699857638 +0100
@@ -0,0 +1,35 @@
+/* ipkg_install.h - the itsy package management system
+
@@ -5844,9 +5825,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_install.h busybox-1.13.4/arc
+int name_mark_dependencies_for_installation(ipkg_conf_t *conf, const char *pkg_name, pkg_vec_t *pkgs_needed);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_message.c busybox-1.13.4/archival/libipkg/ipkg_message.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_message.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_message.c 2009-05-31 15:40:37.053992938 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_message.c busybox-1.15.2/archival/libipkg/ipkg_message.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_message.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_message.c 2009-11-26 11:10:13.699857638 +0100
@@ -0,0 +1,61 @@
+/* ipkg_message.c - the itsy package management system
+
@@ -5909,9 +5890,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_message.c busybox-1.13.4/arc
+ }
+}
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_message.h busybox-1.13.4/archival/libipkg/ipkg_message.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_message.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_message.h 2009-05-31 15:40:37.057994007 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_message.h busybox-1.15.2/archival/libipkg/ipkg_message.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_message.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_message.h 2009-11-26 11:10:13.795857012 +0100
@@ -0,0 +1,32 @@
+/* ipkg_message.h - the itsy package management system
+
@@ -5945,9 +5926,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_message.h busybox-1.13.4/arc
+extern void ipkg_message(ipkg_conf_t *conf, message_level_t level, const char *fmt, ...);
+
+#endif /* _IPKG_MESSAGE_H_ */
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_remove.c busybox-1.13.4/archival/libipkg/ipkg_remove.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_remove.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_remove.c 2009-05-31 15:40:37.061994238 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_remove.c busybox-1.15.2/archival/libipkg/ipkg_remove.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_remove.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_remove.c 2009-11-26 11:10:13.795857012 +0100
@@ -0,0 +1,385 @@
+/* ipkg_remove.c - the itsy package management system
+
@@ -6334,9 +6315,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_remove.c busybox-1.13.4/arch
+
+ return 0;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_remove.h busybox-1.13.4/archival/libipkg/ipkg_remove.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_remove.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_remove.h 2009-05-31 15:40:37.061994238 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_remove.h busybox-1.15.2/archival/libipkg/ipkg_remove.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_remove.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_remove.h 2009-11-26 11:10:13.855859353 +0100
@@ -0,0 +1,33 @@
+/* ipkg_remove.h - the itsy package management system
+
@@ -6371,9 +6352,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_remove.h busybox-1.13.4/arch
+
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_upgrade.c busybox-1.13.4/archival/libipkg/ipkg_upgrade.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_upgrade.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_upgrade.c 2009-05-31 15:40:37.061994238 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_upgrade.c busybox-1.15.2/archival/libipkg/ipkg_upgrade.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_upgrade.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_upgrade.c 2009-11-26 11:10:13.863859535 +0100
@@ -0,0 +1,79 @@
+/* ipkg_upgrade.c - the itsy package management system
+
@@ -6454,9 +6435,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_upgrade.c busybox-1.13.4/arc
+ new->state_flag |= SF_USER;
+ return ipkg_install_pkg(conf, new,1);
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_upgrade.h busybox-1.13.4/archival/libipkg/ipkg_upgrade.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_upgrade.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_upgrade.h 2009-05-31 15:40:37.061994238 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_upgrade.h busybox-1.15.2/archival/libipkg/ipkg_upgrade.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_upgrade.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_upgrade.h 2009-11-26 11:10:13.863859535 +0100
@@ -0,0 +1,18 @@
+/* ipkg_upgrade.c - the itsy package management system
+
@@ -6476,9 +6457,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_upgrade.h busybox-1.13.4/arc
+#include "ipkg.h"
+
+int ipkg_upgrade_pkg(ipkg_conf_t *conf, pkg_t *old);
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_utils.c busybox-1.13.4/archival/libipkg/ipkg_utils.c
---- busybox-1.13.4.orig/archival/libipkg/ipkg_utils.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_utils.c 2009-05-31 15:40:37.065994189 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_utils.c busybox-1.15.2/archival/libipkg/ipkg_utils.c
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_utils.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_utils.c 2009-11-26 11:10:13.863859535 +0100
@@ -0,0 +1,185 @@
+/* ipkg_utils.c - the itsy package management system
+
@@ -6665,9 +6646,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_utils.c busybox-1.13.4/archi
+}
+
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_utils.h busybox-1.13.4/archival/libipkg/ipkg_utils.h
---- busybox-1.13.4.orig/archival/libipkg/ipkg_utils.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/ipkg_utils.h 2009-05-31 15:40:37.065994189 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/ipkg_utils.h busybox-1.15.2/archival/libipkg/ipkg_utils.h
+--- busybox-1.15.2.orig/archival/libipkg/ipkg_utils.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/ipkg_utils.h 2009-11-26 11:10:13.912271293 +0100
@@ -0,0 +1,29 @@
+/* ipkg_utils.h - the itsy package management system
+
@@ -6698,9 +6679,73 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/ipkg_utils.h busybox-1.13.4/archi
+int line_is_blank(const char *line);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/libipkg.c busybox-1.13.4/archival/libipkg/libipkg.c
---- busybox-1.13.4.orig/archival/libipkg/libipkg.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/libipkg.c 2009-05-31 15:40:37.069994700 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/Kbuild busybox-1.15.2/archival/libipkg/Kbuild
+--- busybox-1.15.2.orig/archival/libipkg/Kbuild 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/Kbuild 2009-11-26 11:10:13.027859475 +0100
+@@ -0,0 +1,60 @@
++# Makefile for busybox
++#
++# Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org>
++# Copyright (C) 2006 OpenWrt.org
++#
++# Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
++
++LIBIPKG_CORE_OBJS:= \
++ args.o \
++ libipkg.o \
++ user.o \
++
++LIBIPKG_CMD_OBJS:= \
++ ipkg_cmd.o \
++ ipkg_configure.o \
++ ipkg_download.o \
++ ipkg_install.o \
++ ipkg_remove.o \
++ ipkg_upgrade.o \
++
++LIBIPKG_DB_OBJS:= \
++ hash_table.o \
++ ipkg_conf.o \
++ ipkg_utils.o \
++ pkg.o \
++ pkg_depends.o \
++ pkg_extract.o \
++ pkg_hash.o \
++ pkg_parse.o \
++ pkg_vec.o \
++
++LIBIPKG_LIST_OBJS:= \
++ conffile.o \
++ conffile_list.o \
++ nv_pair.o \
++ nv_pair_list.o \
++ pkg_dest.o \
++ pkg_dest_list.o \
++ pkg_src.o \
++ pkg_src_list.o \
++ str_list.o \
++ void_list.o \
++
++LIBIPKG_UTIL_OBJS:= \
++ file_util.o \
++ ipkg_message.o \
++ str_util.o \
++ xsystem.o \
++
++lib-y :=
++lib-$(CONFIG_IPKG) += $(LIBIPKG_CORE_OBJS)
++lib-$(CONFIG_IPKG) += $(LIBIPKG_CMD_OBJS)
++lib-$(CONFIG_IPKG) += $(LIBIPKG_DB_OBJS)
++lib-$(CONFIG_IPKG) += $(LIBIPKG_LIST_OBJS)
++lib-$(CONFIG_IPKG) += $(LIBIPKG_UTIL_OBJS)
++
++ifeq ($(strip $(IPKG_ARCH)),)
++IPKG_ARCH:=$(TARGET_ARCH)
++endif
++CFLAGS += -DIPKG_LIB -DIPKGLIBDIR="\"/usr/lib\"" -DHOST_CPU_STR="\"$(IPKG_ARCH)\""
+diff -Nur busybox-1.15.2.orig/archival/libipkg/libipkg.c busybox-1.15.2/archival/libipkg/libipkg.c
+--- busybox-1.15.2.orig/archival/libipkg/libipkg.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/libipkg.c 2009-11-26 11:10:13.915860298 +0100
@@ -0,0 +1,532 @@
+/* ipkglib.c - the itsy package management system
+
@@ -7234,9 +7279,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/libipkg.c busybox-1.13.4/archival
+}
+
+#endif /* IPKG_LIB */
-diff -Nur busybox-1.13.4.orig/archival/libipkg/libipkg.h busybox-1.13.4/archival/libipkg/libipkg.h
---- busybox-1.13.4.orig/archival/libipkg/libipkg.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/libipkg.h 2009-05-31 15:40:37.069994700 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/libipkg.h busybox-1.15.2/archival/libipkg/libipkg.h
+--- busybox-1.15.2.orig/archival/libipkg/libipkg.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/libipkg.h 2009-11-26 11:10:13.923858524 +0100
@@ -0,0 +1,87 @@
+/* ipkglib.h - the itsy package management system
+
@@ -7325,9 +7370,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/libipkg.h busybox-1.13.4/archival
+
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/nv_pair.c busybox-1.13.4/archival/libipkg/nv_pair.c
---- busybox-1.13.4.orig/archival/libipkg/nv_pair.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/nv_pair.c 2009-05-31 15:40:37.073994372 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/nv_pair.c busybox-1.15.2/archival/libipkg/nv_pair.c
+--- busybox-1.15.2.orig/archival/libipkg/nv_pair.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/nv_pair.c 2009-11-26 11:10:13.987858580 +0100
@@ -0,0 +1,40 @@
+/* nv_pair.c - the itsy package management system
+
@@ -7369,9 +7414,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/nv_pair.c busybox-1.13.4/archival
+}
+
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/nv_pair.h busybox-1.13.4/archival/libipkg/nv_pair.h
---- busybox-1.13.4.orig/archival/libipkg/nv_pair.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/nv_pair.h 2009-05-31 15:40:37.073994372 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/nv_pair.h busybox-1.15.2/archival/libipkg/nv_pair.h
+--- busybox-1.15.2.orig/archival/libipkg/nv_pair.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/nv_pair.h 2009-11-26 11:10:13.987858580 +0100
@@ -0,0 +1,32 @@
+/* nv_pair.h - the itsy package management system
+
@@ -7405,9 +7450,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/nv_pair.h busybox-1.13.4/archival
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/nv_pair_list.c busybox-1.13.4/archival/libipkg/nv_pair_list.c
---- busybox-1.13.4.orig/archival/libipkg/nv_pair_list.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/nv_pair_list.c 2009-05-31 15:40:37.073994372 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/nv_pair_list.c busybox-1.15.2/archival/libipkg/nv_pair_list.c
+--- busybox-1.15.2.orig/archival/libipkg/nv_pair_list.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/nv_pair_list.c 2009-11-26 11:10:14.043859011 +0100
@@ -0,0 +1,98 @@
+/* nv_pair_list.c - the itsy package management system
+
@@ -7507,9 +7552,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/nv_pair_list.c busybox-1.13.4/arc
+ }
+ return NULL;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/nv_pair_list.h busybox-1.13.4/archival/libipkg/nv_pair_list.h
---- busybox-1.13.4.orig/archival/libipkg/nv_pair_list.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/nv_pair_list.h 2009-05-31 15:40:37.085996181 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/nv_pair_list.h busybox-1.15.2/archival/libipkg/nv_pair_list.h
+--- busybox-1.15.2.orig/archival/libipkg/nv_pair_list.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/nv_pair_list.h 2009-11-26 11:10:14.047859242 +0100
@@ -0,0 +1,60 @@
+/* nv_pair_list.h - the itsy package management system
+
@@ -7571,9 +7616,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/nv_pair_list.h busybox-1.13.4/arc
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg.c busybox-1.13.4/archival/libipkg/pkg.c
---- busybox-1.13.4.orig/archival/libipkg/pkg.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg.c 2009-05-31 15:40:37.089995574 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg.c busybox-1.15.2/archival/libipkg/pkg.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg.c 2009-11-26 11:10:14.055858306 +0100
@@ -0,0 +1,1757 @@
+/* pkg.c - the itsy package management system
+
@@ -9332,242 +9377,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg.c busybox-1.13.4/archival/lib
+ }
+ return 0;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg.h busybox-1.13.4/archival/libipkg/pkg.h
---- busybox-1.13.4.orig/archival/libipkg/pkg.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg.h 2009-05-31 15:40:37.109997565 +0200
-@@ -0,0 +1,229 @@
-+/* pkg.h - the itsy package management system
-+
-+ Carl D. Worth
-+
-+ Copyright (C) 2001 University of Southern California
-+
-+ 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, 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.
-+*/
-+
-+#ifndef PKG_H
-+#define PKG_H
-+
-+#include <sys/types.h>
-+#include <sys/stat.h>
-+#include <unistd.h>
-+
-+#include "pkg_vec.h"
-+#include "str_list.h"
-+#include "pkg_src.h"
-+#include "pkg_dest.h"
-+#include "ipkg_conf.h"
-+#include "conffile_list.h"
-+
-+struct ipkg_conf;
-+
-+/* I think "Size" is currently the shortest field name */
-+#define PKG_MINIMUM_FIELD_NAME_LEN 4
-+
-+enum pkg_state_want
-+{
-+ SW_UNKNOWN = 1,
-+ SW_INSTALL,
-+ SW_DEINSTALL,
-+ SW_PURGE,
-+ SW_LAST_STATE_WANT
-+};
-+typedef enum pkg_state_want pkg_state_want_t;
-+
-+enum pkg_state_flag
-+{
-+ SF_OK = 0,
-+ SF_REINSTREQ = 1,
-+ SF_HOLD = 2, /* do not upgrade version */
-+ SF_REPLACE = 4, /* replace this package */
-+ SF_NOPRUNE = 8, /* do not remove obsolete files */
-+ SF_PREFER = 16, /* prefer this version */
-+ SF_OBSOLETE = 32, /* old package in upgrade pair */
-+ SF_MARKED = 64, /* temporary mark */
-+ SF_FILELIST_CHANGED = 128, /* needs filelist written */
-+ SF_USER = 256,
-+ SF_LAST_STATE_FLAG
-+};
-+typedef enum pkg_state_flag pkg_state_flag_t;
-+#define SF_NONVOLATILE_FLAGS (SF_HOLD|SF_NOPRUNE|SF_PREFER|SF_OBSOLETE|SF_USER)
-+
-+enum pkg_state_status
-+{
-+ SS_NOT_INSTALLED = 1,
-+ SS_UNPACKED,
-+ SS_HALF_CONFIGURED,
-+ SS_INSTALLED,
-+ SS_HALF_INSTALLED,
-+ SS_CONFIG_FILES,
-+ SS_POST_INST_FAILED,
-+ SS_REMOVAL_FAILED,
-+ SS_LAST_STATE_STATUS
-+};
-+typedef enum pkg_state_status pkg_state_status_t;
-+
-+struct abstract_pkg{
-+ char * name;
-+ int dependencies_checked;
-+ pkg_vec_t * pkgs;
-+ pkg_state_status_t state_status;
-+ pkg_state_flag_t state_flag;
-+ struct abstract_pkg ** depended_upon_by; /* @@@@ this should be abstract_pkg_vec_t -Jamey */
-+ abstract_pkg_vec_t * provided_by;
-+ abstract_pkg_vec_t * replaced_by;
-+};
-+
-+#include "pkg_depends.h"
-+
-+/* XXX: CLEANUP: I'd like to clean up pkg_t in several ways:
-+
-+ The 3 version fields should go into a single version struct. (This
-+ is especially important since, currently, pkg->version can easily
-+ be mistaken for pkg_verson_str_alloc(pkg) although they are very
-+ distinct. This has been the source of multiple bugs.
-+
-+ The 3 state fields could possibly also go into their own struct.
-+
-+ All fields which deal with lists of packages, (Depends,
-+ Pre-Depends, Provides, Suggests, Recommends, Enhances), should each
-+ be handled by a single struct in pkg_t
-+
-+ All string fields for which there is a small set of possible
-+ values, (section, maintainer, architecture, maybe version?), that
-+ are reused among different packages -- for all such packages we
-+ should move from "char *"s to some atom datatype to share data
-+ storage and use less memory. We might even do reference counting,
-+ but probably not since most often we only create new pkg_t structs,
-+ we don't often free them. */
-+struct pkg
-+{
-+ char *name;
-+ unsigned long epoch;
-+ char *version;
-+ char *revision;
-+ char *familiar_revision;
-+ pkg_src_t *src;
-+ pkg_dest_t *dest;
-+ char *architecture;
-+ char *section;
-+ char *maintainer;
-+ char *description;
-+ pkg_state_want_t state_want;
-+ pkg_state_flag_t state_flag;
-+ pkg_state_status_t state_status;
-+ char **depends_str;
-+ int depends_count;
-+ char **pre_depends_str;
-+ int pre_depends_count;
-+ char **recommends_str;
-+ int recommends_count;
-+ char **suggests_str;
-+ int suggests_count;
-+ compound_depend_t * depends;
-+
-+ /* Abhaya: new conflicts */
-+ char **conflicts_str;
-+ compound_depend_t * conflicts;
-+ int conflicts_count;
-+
-+ char **replaces_str;
-+ int replaces_count;
-+ abstract_pkg_t ** replaces;
-+
-+ char **provides_str;
-+ int provides_count;
-+ abstract_pkg_t ** provides;
-+
-+ abstract_pkg_t *parent;
-+
-+ pkg_t *old_pkg; /* during upgrade, points from installee to previously installed */
-+
-+ char *filename;
-+ char *local_filename;
-+ char *url;
-+ char *tmp_unpack_dir;
-+ char *md5sum;
-+ char *size;
-+ char *installed_size;
-+ char *priority;
-+ char *source;
-+ conffile_list_t conffiles;
-+ time_t installed_time;
-+ /* As pointer for lazy evaluation */
-+ str_list_t *installed_files;
-+ /* XXX: CLEANUP: I'd like to perhaps come up with a better
-+ mechanism to avoid the problem here, (which is that the
-+ installed_files list was being freed from an inner loop while
-+ still being used within an outer loop. */
-+ int installed_files_ref_cnt;
-+ int essential;
-+ int arch_priority;
-+/* Adding this flag, to "force" ipkg to choose a "provided_by_hand" package, if there are multiple choice */
-+ int provided_by_hand;
-+};
-+
-+pkg_t *pkg_new(void);
-+int pkg_init(pkg_t *pkg);
-+void pkg_deinit(pkg_t *pkg);
-+int pkg_init_from_file(pkg_t *pkg, const char *filename);
-+abstract_pkg_t *abstract_pkg_new(void);
-+int abstract_pkg_init(abstract_pkg_t *ab_pkg);
-+
-+/*
-+ * merges fields from newpkg into oldpkg.
-+ * Forcibly sets oldpkg state_status, state_want and state_flags if set_status is nonzero
-+ */
-+int pkg_merge(pkg_t *oldpkg, pkg_t *newpkg, int set_status);
-+
-+char *pkg_version_str_alloc(pkg_t *pkg);
-+
-+int pkg_compare_versions(const pkg_t *pkg, const pkg_t *ref_pkg);
-+int pkg_name_version_and_architecture_compare(pkg_t *a, pkg_t *b);
-+int abstract_pkg_name_compare(abstract_pkg_t *a, abstract_pkg_t *b);
-+
-+char * pkg_formatted_info(pkg_t *pkg );
-+char * pkg_formatted_field(pkg_t *pkg, const char *field );
-+
-+void set_flags_from_control(ipkg_conf_t *conf, pkg_t *pkg);
-+
-+void pkg_print_info(pkg_t *pkg, FILE *file);
-+void pkg_print_status(pkg_t * pkg, FILE * file);
-+void pkg_print_field(pkg_t *pkg, FILE *file, const char *field);
-+str_list_t *pkg_get_installed_files(pkg_t *pkg);
-+int pkg_free_installed_files(pkg_t *pkg);
-+int pkg_remove_installed_files_list(ipkg_conf_t *conf, pkg_t *pkg);
-+conffile_t *pkg_get_conffile(pkg_t *pkg, const char *file_name);
-+int pkg_run_script(struct ipkg_conf *conf, pkg_t *pkg,
-+ const char *script, const char *args);
-+
-+/* enum mappings */
-+char *pkg_state_want_to_str(pkg_state_want_t sw);
-+pkg_state_want_t pkg_state_want_from_str(char *str);
-+char *pkg_state_flag_to_str(pkg_state_flag_t sf);
-+pkg_state_flag_t pkg_state_flag_from_str(char *str);
-+char *pkg_state_status_to_str(pkg_state_status_t ss);
-+pkg_state_status_t pkg_state_status_from_str(char *str);
-+
-+int pkg_version_satisfied(pkg_t *it, pkg_t *ref, const char *op);
-+
-+int pkg_arch_supported(ipkg_conf_t *conf, pkg_t *pkg);
-+int pkg_info_preinstall_check(ipkg_conf_t *conf);
-+int pkg_free_installed_files(pkg_t *pkg);
-+
-+int pkg_write_filelist(ipkg_conf_t *conf, pkg_t *pkg);
-+int pkg_write_changed_filelists(ipkg_conf_t *conf);
-+
-+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_depends.c busybox-1.13.4/archival/libipkg/pkg_depends.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_depends.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_depends.c 2009-05-31 15:40:37.093995246 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_depends.c busybox-1.15.2/archival/libipkg/pkg_depends.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_depends.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_depends.c 2009-11-26 11:10:14.115858127 +0100
@@ -0,0 +1,1032 @@
+/* pkg_depends.c - the itsy package management system
+
@@ -10601,9 +10413,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_depends.c busybox-1.13.4/arch
+
+ return 0;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_depends.h busybox-1.13.4/archival/libipkg/pkg_depends.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_depends.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_depends.h 2009-05-31 15:40:37.093995246 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_depends.h busybox-1.15.2/archival/libipkg/pkg_depends.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_depends.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_depends.h 2009-11-26 11:10:14.177333554 +0100
@@ -0,0 +1,105 @@
+/* pkg_depends.h - the itsy package management system
+
@@ -10710,9 +10522,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_depends.h busybox-1.13.4/arch
+int pkg_dependence_satisfied(depend_t *depend);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_dest.c busybox-1.13.4/archival/libipkg/pkg_dest.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_dest.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_dest.c 2009-05-31 15:40:37.093995246 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_dest.c busybox-1.15.2/archival/libipkg/pkg_dest.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_dest.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_dest.c 2009-11-26 11:10:14.177333554 +0100
@@ -0,0 +1,92 @@
+/* pkg_dest.c - the itsy package management system
+
@@ -10806,9 +10618,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_dest.c busybox-1.13.4/archiva
+
+ dest->root_dir = NULL;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_dest.h busybox-1.13.4/archival/libipkg/pkg_dest.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_dest.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_dest.h 2009-05-31 15:40:37.097996035 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_dest.h busybox-1.15.2/archival/libipkg/pkg_dest.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_dest.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_dest.h 2009-11-26 11:10:14.177333554 +0100
@@ -0,0 +1,38 @@
+/* pkg_dest.h - the itsy package management system
+
@@ -10848,9 +10660,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_dest.h busybox-1.13.4/archiva
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_dest_list.c busybox-1.13.4/archival/libipkg/pkg_dest_list.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_dest_list.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_dest_list.c 2009-05-31 15:40:37.097996035 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_dest_list.c busybox-1.15.2/archival/libipkg/pkg_dest_list.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_dest_list.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_dest_list.c 2009-11-26 11:10:14.251858126 +0100
@@ -0,0 +1,85 @@
+/* pkg_dest_list.c - the itsy package management system
+
@@ -10937,9 +10749,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_dest_list.c busybox-1.13.4/ar
+{
+ return (pkg_dest_list_elt_t *) void_list_pop((void_list_t *) list);
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_dest_list.h busybox-1.13.4/archival/libipkg/pkg_dest_list.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_dest_list.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_dest_list.h 2009-05-31 15:40:37.097996035 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_dest_list.h busybox-1.15.2/archival/libipkg/pkg_dest_list.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_dest_list.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_dest_list.h 2009-11-26 11:10:14.255858914 +0100
@@ -0,0 +1,50 @@
+/* pkg_dest_list.h - the itsy package management system
+
@@ -10991,9 +10803,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_dest_list.h busybox-1.13.4/ar
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_extract.c busybox-1.13.4/archival/libipkg/pkg_extract.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_extract.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_extract.c 2009-05-31 15:40:37.097996035 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_extract.c busybox-1.15.2/archival/libipkg/pkg_extract.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_extract.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_extract.c 2009-11-26 11:10:14.259859982 +0100
@@ -0,0 +1,225 @@
+/* pkg_extract.c - the itsy package management system
+
@@ -11220,9 +11032,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_extract.c busybox-1.13.4/arch
+
+ return 0;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_extract.h busybox-1.13.4/archival/libipkg/pkg_extract.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_extract.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_extract.h 2009-05-31 15:40:37.105997055 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_extract.h busybox-1.15.2/archival/libipkg/pkg_extract.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_extract.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_extract.h 2009-11-26 11:10:14.323857515 +0100
@@ -0,0 +1,32 @@
+/* pkg_extract.c - the itsy package management system
+
@@ -11256,9 +11068,242 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_extract.h busybox-1.13.4/arch
+int pkg_extract_data_file_names_to_stream(pkg_t *pkg, FILE *file);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_hash.c busybox-1.13.4/archival/libipkg/pkg_hash.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_hash.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_hash.c 2009-05-31 15:40:37.109997565 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg.h busybox-1.15.2/archival/libipkg/pkg.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg.h 2009-11-26 11:10:14.107861019 +0100
+@@ -0,0 +1,229 @@
++/* pkg.h - the itsy package management system
++
++ Carl D. Worth
++
++ Copyright (C) 2001 University of Southern California
++
++ 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, 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.
++*/
++
++#ifndef PKG_H
++#define PKG_H
++
++#include <sys/types.h>
++#include <sys/stat.h>
++#include <unistd.h>
++
++#include "pkg_vec.h"
++#include "str_list.h"
++#include "pkg_src.h"
++#include "pkg_dest.h"
++#include "ipkg_conf.h"
++#include "conffile_list.h"
++
++struct ipkg_conf;
++
++/* I think "Size" is currently the shortest field name */
++#define PKG_MINIMUM_FIELD_NAME_LEN 4
++
++enum pkg_state_want
++{
++ SW_UNKNOWN = 1,
++ SW_INSTALL,
++ SW_DEINSTALL,
++ SW_PURGE,
++ SW_LAST_STATE_WANT
++};
++typedef enum pkg_state_want pkg_state_want_t;
++
++enum pkg_state_flag
++{
++ SF_OK = 0,
++ SF_REINSTREQ = 1,
++ SF_HOLD = 2, /* do not upgrade version */
++ SF_REPLACE = 4, /* replace this package */
++ SF_NOPRUNE = 8, /* do not remove obsolete files */
++ SF_PREFER = 16, /* prefer this version */
++ SF_OBSOLETE = 32, /* old package in upgrade pair */
++ SF_MARKED = 64, /* temporary mark */
++ SF_FILELIST_CHANGED = 128, /* needs filelist written */
++ SF_USER = 256,
++ SF_LAST_STATE_FLAG
++};
++typedef enum pkg_state_flag pkg_state_flag_t;
++#define SF_NONVOLATILE_FLAGS (SF_HOLD|SF_NOPRUNE|SF_PREFER|SF_OBSOLETE|SF_USER)
++
++enum pkg_state_status
++{
++ SS_NOT_INSTALLED = 1,
++ SS_UNPACKED,
++ SS_HALF_CONFIGURED,
++ SS_INSTALLED,
++ SS_HALF_INSTALLED,
++ SS_CONFIG_FILES,
++ SS_POST_INST_FAILED,
++ SS_REMOVAL_FAILED,
++ SS_LAST_STATE_STATUS
++};
++typedef enum pkg_state_status pkg_state_status_t;
++
++struct abstract_pkg{
++ char * name;
++ int dependencies_checked;
++ pkg_vec_t * pkgs;
++ pkg_state_status_t state_status;
++ pkg_state_flag_t state_flag;
++ struct abstract_pkg ** depended_upon_by; /* @@@@ this should be abstract_pkg_vec_t -Jamey */
++ abstract_pkg_vec_t * provided_by;
++ abstract_pkg_vec_t * replaced_by;
++};
++
++#include "pkg_depends.h"
++
++/* XXX: CLEANUP: I'd like to clean up pkg_t in several ways:
++
++ The 3 version fields should go into a single version struct. (This
++ is especially important since, currently, pkg->version can easily
++ be mistaken for pkg_verson_str_alloc(pkg) although they are very
++ distinct. This has been the source of multiple bugs.
++
++ The 3 state fields could possibly also go into their own struct.
++
++ All fields which deal with lists of packages, (Depends,
++ Pre-Depends, Provides, Suggests, Recommends, Enhances), should each
++ be handled by a single struct in pkg_t
++
++ All string fields for which there is a small set of possible
++ values, (section, maintainer, architecture, maybe version?), that
++ are reused among different packages -- for all such packages we
++ should move from "char *"s to some atom datatype to share data
++ storage and use less memory. We might even do reference counting,
++ but probably not since most often we only create new pkg_t structs,
++ we don't often free them. */
++struct pkg
++{
++ char *name;
++ unsigned long epoch;
++ char *version;
++ char *revision;
++ char *familiar_revision;
++ pkg_src_t *src;
++ pkg_dest_t *dest;
++ char *architecture;
++ char *section;
++ char *maintainer;
++ char *description;
++ pkg_state_want_t state_want;
++ pkg_state_flag_t state_flag;
++ pkg_state_status_t state_status;
++ char **depends_str;
++ int depends_count;
++ char **pre_depends_str;
++ int pre_depends_count;
++ char **recommends_str;
++ int recommends_count;
++ char **suggests_str;
++ int suggests_count;
++ compound_depend_t * depends;
++
++ /* Abhaya: new conflicts */
++ char **conflicts_str;
++ compound_depend_t * conflicts;
++ int conflicts_count;
++
++ char **replaces_str;
++ int replaces_count;
++ abstract_pkg_t ** replaces;
++
++ char **provides_str;
++ int provides_count;
++ abstract_pkg_t ** provides;
++
++ abstract_pkg_t *parent;
++
++ pkg_t *old_pkg; /* during upgrade, points from installee to previously installed */
++
++ char *filename;
++ char *local_filename;
++ char *url;
++ char *tmp_unpack_dir;
++ char *md5sum;
++ char *size;
++ char *installed_size;
++ char *priority;
++ char *source;
++ conffile_list_t conffiles;
++ time_t installed_time;
++ /* As pointer for lazy evaluation */
++ str_list_t *installed_files;
++ /* XXX: CLEANUP: I'd like to perhaps come up with a better
++ mechanism to avoid the problem here, (which is that the
++ installed_files list was being freed from an inner loop while
++ still being used within an outer loop. */
++ int installed_files_ref_cnt;
++ int essential;
++ int arch_priority;
++/* Adding this flag, to "force" ipkg to choose a "provided_by_hand" package, if there are multiple choice */
++ int provided_by_hand;
++};
++
++pkg_t *pkg_new(void);
++int pkg_init(pkg_t *pkg);
++void pkg_deinit(pkg_t *pkg);
++int pkg_init_from_file(pkg_t *pkg, const char *filename);
++abstract_pkg_t *abstract_pkg_new(void);
++int abstract_pkg_init(abstract_pkg_t *ab_pkg);
++
++/*
++ * merges fields from newpkg into oldpkg.
++ * Forcibly sets oldpkg state_status, state_want and state_flags if set_status is nonzero
++ */
++int pkg_merge(pkg_t *oldpkg, pkg_t *newpkg, int set_status);
++
++char *pkg_version_str_alloc(pkg_t *pkg);
++
++int pkg_compare_versions(const pkg_t *pkg, const pkg_t *ref_pkg);
++int pkg_name_version_and_architecture_compare(pkg_t *a, pkg_t *b);
++int abstract_pkg_name_compare(abstract_pkg_t *a, abstract_pkg_t *b);
++
++char * pkg_formatted_info(pkg_t *pkg );
++char * pkg_formatted_field(pkg_t *pkg, const char *field );
++
++void set_flags_from_control(ipkg_conf_t *conf, pkg_t *pkg);
++
++void pkg_print_info(pkg_t *pkg, FILE *file);
++void pkg_print_status(pkg_t * pkg, FILE * file);
++void pkg_print_field(pkg_t *pkg, FILE *file, const char *field);
++str_list_t *pkg_get_installed_files(pkg_t *pkg);
++int pkg_free_installed_files(pkg_t *pkg);
++int pkg_remove_installed_files_list(ipkg_conf_t *conf, pkg_t *pkg);
++conffile_t *pkg_get_conffile(pkg_t *pkg, const char *file_name);
++int pkg_run_script(struct ipkg_conf *conf, pkg_t *pkg,
++ const char *script, const char *args);
++
++/* enum mappings */
++char *pkg_state_want_to_str(pkg_state_want_t sw);
++pkg_state_want_t pkg_state_want_from_str(char *str);
++char *pkg_state_flag_to_str(pkg_state_flag_t sf);
++pkg_state_flag_t pkg_state_flag_from_str(char *str);
++char *pkg_state_status_to_str(pkg_state_status_t ss);
++pkg_state_status_t pkg_state_status_from_str(char *str);
++
++int pkg_version_satisfied(pkg_t *it, pkg_t *ref, const char *op);
++
++int pkg_arch_supported(ipkg_conf_t *conf, pkg_t *pkg);
++int pkg_info_preinstall_check(ipkg_conf_t *conf);
++int pkg_free_installed_files(pkg_t *pkg);
++
++int pkg_write_filelist(ipkg_conf_t *conf, pkg_t *pkg);
++int pkg_write_changed_filelists(ipkg_conf_t *conf);
++
++#endif
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_hash.c busybox-1.15.2/archival/libipkg/pkg_hash.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_hash.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_hash.c 2009-11-26 11:10:14.327858863 +0100
@@ -0,0 +1,623 @@
+/* ipkg_hash.c - the itsy package management system
+
@@ -11883,9 +11928,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_hash.c busybox-1.13.4/archiva
+}
+
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_hash.h busybox-1.13.4/archival/libipkg/pkg_hash.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_hash.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_hash.h 2009-05-31 15:40:37.113996958 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_hash.h busybox-1.15.2/archival/libipkg/pkg_hash.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_hash.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_hash.h 2009-11-26 11:10:14.331859652 +0100
@@ -0,0 +1,61 @@
+/* pkg_hash.h - the itsy package management system
+
@@ -11948,9 +11993,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_hash.h busybox-1.13.4/archiva
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_parse.c busybox-1.13.4/archival/libipkg/pkg_parse.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_parse.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_parse.c 2009-05-31 15:40:37.113996958 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_parse.c busybox-1.15.2/archival/libipkg/pkg_parse.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_parse.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_parse.c 2009-11-26 11:10:14.855857952 +0100
@@ -0,0 +1,368 @@
+/* pkg_parse.c - the itsy package management system
+
@@ -12320,9 +12365,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_parse.c busybox-1.13.4/archiv
+
+ return 0;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_parse.h busybox-1.13.4/archival/libipkg/pkg_parse.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_parse.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_parse.h 2009-05-31 15:40:37.113996958 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_parse.h busybox-1.15.2/archival/libipkg/pkg_parse.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_parse.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_parse.h 2009-11-26 11:10:14.855857952 +0100
@@ -0,0 +1,31 @@
+/* pkg_parse.h - the itsy package management system
+
@@ -12355,9 +12400,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_parse.h busybox-1.13.4/archiv
+int pkg_valorize_other_field(pkg_t *pkg, char ***raw);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_src.c busybox-1.13.4/archival/libipkg/pkg_src.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_src.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_src.c 2009-05-31 15:40:37.113996958 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_src.c busybox-1.15.2/archival/libipkg/pkg_src.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_src.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_src.c 2009-11-26 11:10:14.859859580 +0100
@@ -0,0 +1,43 @@
+/* pkg_src.c - the itsy package management system
+
@@ -12402,9 +12447,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_src.c busybox-1.13.4/archival
+}
+
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_src.h busybox-1.13.4/archival/libipkg/pkg_src.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_src.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_src.h 2009-05-31 15:40:37.117996909 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_src.h busybox-1.15.2/archival/libipkg/pkg_src.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_src.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_src.h 2009-11-26 11:10:14.859859580 +0100
@@ -0,0 +1,34 @@
+/* pkg_src.h - the itsy package management system
+
@@ -12440,9 +12485,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_src.h busybox-1.13.4/archival
+void pkg_src_deinit(pkg_src_t *src);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_src_list.c busybox-1.13.4/archival/libipkg/pkg_src_list.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_src_list.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_src_list.c 2009-05-31 15:40:37.117996909 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_src_list.c busybox-1.15.2/archival/libipkg/pkg_src_list.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_src_list.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_src_list.c 2009-11-26 11:10:14.931856745 +0100
@@ -0,0 +1,75 @@
+/* pkg_src_list.c - the itsy package management system
+
@@ -12519,9 +12564,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_src_list.c busybox-1.13.4/arc
+{
+ return (pkg_src_list_elt_t *) void_list_pop((void_list_t *) list);
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_src_list.h busybox-1.13.4/archival/libipkg/pkg_src_list.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_src_list.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_src_list.h 2009-05-31 15:40:37.117996909 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_src_list.h busybox-1.15.2/archival/libipkg/pkg_src_list.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_src_list.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_src_list.h 2009-11-26 11:10:14.931856745 +0100
@@ -0,0 +1,57 @@
+/* pkg_src_list.h - the itsy package management system
+
@@ -12580,9 +12625,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_src_list.h busybox-1.13.4/arc
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_vec.c busybox-1.13.4/archival/libipkg/pkg_vec.c
---- busybox-1.13.4.orig/archival/libipkg/pkg_vec.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_vec.c 2009-05-31 15:40:37.117996909 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_vec.c busybox-1.15.2/archival/libipkg/pkg_vec.c
+--- busybox-1.15.2.orig/archival/libipkg/pkg_vec.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_vec.c 2009-11-26 11:10:14.935859211 +0100
@@ -0,0 +1,231 @@
+/* pkg_vec.c - the itsy package management system
+
@@ -12815,9 +12860,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_vec.c busybox-1.13.4/archival
+ qsort(vec->pkgs, vec->len, sizeof(pkg_t *), (compare_fcn_t)compar);
+}
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_vec.h busybox-1.13.4/archival/libipkg/pkg_vec.h
---- busybox-1.13.4.orig/archival/libipkg/pkg_vec.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/pkg_vec.h 2009-05-31 15:40:37.121997140 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/pkg_vec.h busybox-1.15.2/archival/libipkg/pkg_vec.h
+--- busybox-1.15.2.orig/archival/libipkg/pkg_vec.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/pkg_vec.h 2009-11-26 11:10:14.939859721 +0100
@@ -0,0 +1,62 @@
+/* pkg_vec.h - the itsy package management system
+
@@ -12881,9 +12926,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/pkg_vec.h busybox-1.13.4/archival
+void abstract_pkg_vec_sort(pkg_vec_t *vec, int (*compar)(abstract_pkg_t *, abstract_pkg_t *));
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/sprintf_alloc.h busybox-1.13.4/archival/libipkg/sprintf_alloc.h
---- busybox-1.13.4.orig/archival/libipkg/sprintf_alloc.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/sprintf_alloc.h 2009-05-31 15:40:37.121997140 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/sprintf_alloc.h busybox-1.15.2/archival/libipkg/sprintf_alloc.h
+--- busybox-1.15.2.orig/archival/libipkg/sprintf_alloc.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/sprintf_alloc.h 2009-11-26 11:10:14.999857591 +0100
@@ -0,0 +1,25 @@
+/* sprintf_alloca.c -- like sprintf with memory allocation
+
@@ -12910,9 +12955,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/sprintf_alloc.h busybox-1.13.4/ar
+#define sprintf_alloc(str, fmt, args...) *str = xasprintf(fmt, ## args)
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/str_list.c busybox-1.13.4/archival/libipkg/str_list.c
---- busybox-1.13.4.orig/archival/libipkg/str_list.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/str_list.c 2009-05-31 15:40:37.121997140 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/str_list.c busybox-1.15.2/archival/libipkg/str_list.c
+--- busybox-1.15.2.orig/archival/libipkg/str_list.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/str_list.c 2009-11-26 11:10:14.999857591 +0100
@@ -0,0 +1,76 @@
+/* str_list.c - the itsy package management system
+
@@ -12990,9 +13035,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/str_list.c busybox-1.13.4/archiva
+ (void *)target_str,
+ (void_list_cmp_t)strcmp);
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/str_list.h busybox-1.13.4/archival/libipkg/str_list.h
---- busybox-1.13.4.orig/archival/libipkg/str_list.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/str_list.h 2009-05-31 15:40:37.121997140 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/str_list.h busybox-1.15.2/archival/libipkg/str_list.h
+--- busybox-1.15.2.orig/archival/libipkg/str_list.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/str_list.h 2009-11-26 11:10:15.071857267 +0100
@@ -0,0 +1,51 @@
+/* str_list.h - the itsy package management system
+
@@ -13045,9 +13090,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/str_list.h busybox-1.13.4/archiva
+char *str_list_remove_elt(str_list_t *list, const char *target_str);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/str_util.c busybox-1.13.4/archival/libipkg/str_util.c
---- busybox-1.13.4.orig/archival/libipkg/str_util.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/str_util.c 2009-05-31 15:40:37.125998767 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/str_util.c busybox-1.15.2/archival/libipkg/str_util.c
+--- busybox-1.15.2.orig/archival/libipkg/str_util.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/str_util.c 2009-11-26 11:10:15.075858615 +0100
@@ -0,0 +1,69 @@
+/* str_utils.c - the itsy package management system
+
@@ -13118,9 +13163,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/str_util.c busybox-1.13.4/archiva
+ return str ? strdup(str) : NULL;
+}
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/str_util.h busybox-1.13.4/archival/libipkg/str_util.h
---- busybox-1.13.4.orig/archival/libipkg/str_util.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/str_util.h 2009-05-31 15:40:37.125998767 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/str_util.h busybox-1.15.2/archival/libipkg/str_util.h
+--- busybox-1.15.2.orig/archival/libipkg/str_util.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/str_util.h 2009-11-26 11:10:15.075858615 +0100
@@ -0,0 +1,27 @@
+/* str_utils.h - the itsy package management system
+
@@ -13149,9 +13194,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/str_util.h busybox-1.13.4/archiva
+char *str_dup_safe(const char *str);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/user.c busybox-1.13.4/archival/libipkg/user.c
---- busybox-1.13.4.orig/archival/libipkg/user.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/user.c 2009-05-31 15:40:37.129998160 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/user.c busybox-1.15.2/archival/libipkg/user.c
+--- busybox-1.15.2.orig/archival/libipkg/user.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/user.c 2009-11-26 11:10:15.147857730 +0100
@@ -0,0 +1,61 @@
+/* user.c - the itsy package management system
+
@@ -13214,9 +13259,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/user.c busybox-1.13.4/archival/li
+
+ return response;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/user.h busybox-1.13.4/archival/libipkg/user.h
---- busybox-1.13.4.orig/archival/libipkg/user.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/user.h 2009-05-31 15:40:37.129998160 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/user.h busybox-1.15.2/archival/libipkg/user.h
+--- busybox-1.15.2.orig/archival/libipkg/user.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/user.h 2009-11-26 11:10:15.147857730 +0100
@@ -0,0 +1,23 @@
+/* user.c - the itsy package management system
+
@@ -13241,9 +13286,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/user.h busybox-1.13.4/archival/li
+
+char *get_user_response(const char *format, ...);
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/void_list.c busybox-1.13.4/archival/libipkg/void_list.c
---- busybox-1.13.4.orig/archival/libipkg/void_list.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/void_list.c 2009-05-31 15:40:37.129998160 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/void_list.c busybox-1.15.2/archival/libipkg/void_list.c
+--- busybox-1.15.2.orig/archival/libipkg/void_list.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/void_list.c 2009-11-26 11:10:15.151858798 +0100
@@ -0,0 +1,194 @@
+/* void_list.c - the itsy package management system
+
@@ -13439,9 +13484,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/void_list.c busybox-1.13.4/archiv
+ else
+ return NULL;
+}
-diff -Nur busybox-1.13.4.orig/archival/libipkg/void_list.h busybox-1.13.4/archival/libipkg/void_list.h
---- busybox-1.13.4.orig/archival/libipkg/void_list.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/void_list.h 2009-05-31 15:40:37.129998160 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/void_list.h busybox-1.15.2/archival/libipkg/void_list.h
+--- busybox-1.15.2.orig/archival/libipkg/void_list.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/void_list.h 2009-11-26 11:10:15.251858401 +0100
@@ -0,0 +1,59 @@
+/* void_list.h - the itsy package management system
+
@@ -13502,9 +13547,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/void_list.h busybox-1.13.4/archiv
+void *void_list_remove_elt(void_list_t *list, const void *target_data, void_list_cmp_t cmp);
+
+#endif
-diff -Nur busybox-1.13.4.orig/archival/libipkg/xsystem.c busybox-1.13.4/archival/libipkg/xsystem.c
---- busybox-1.13.4.orig/archival/libipkg/xsystem.c 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/xsystem.c 2009-05-31 15:40:37.133998111 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/xsystem.c busybox-1.15.2/archival/libipkg/xsystem.c
+--- busybox-1.15.2.orig/archival/libipkg/xsystem.c 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/xsystem.c 2009-11-26 11:10:15.251858401 +0100
@@ -0,0 +1,64 @@
+/* xsystem.c - system(3) with error messages
+
@@ -13570,9 +13615,9 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/xsystem.c busybox-1.13.4/archival
+ return -1;
+}
+
-diff -Nur busybox-1.13.4.orig/archival/libipkg/xsystem.h busybox-1.13.4/archival/libipkg/xsystem.h
---- busybox-1.13.4.orig/archival/libipkg/xsystem.h 1970-01-01 01:00:00.000000000 +0100
-+++ busybox-1.13.4/archival/libipkg/xsystem.h 2009-05-31 15:40:37.133998111 +0200
+diff -Nur busybox-1.15.2.orig/archival/libipkg/xsystem.h busybox-1.15.2/archival/libipkg/xsystem.h
+--- busybox-1.15.2.orig/archival/libipkg/xsystem.h 1970-01-01 01:00:00.000000000 +0100
++++ busybox-1.15.2/archival/libipkg/xsystem.h 2009-11-26 11:10:15.323857513 +0100
@@ -0,0 +1,34 @@
+/* xsystem.h - system(3) with error messages
+
@@ -13608,21 +13653,10 @@ diff -Nur busybox-1.13.4.orig/archival/libipkg/xsystem.h busybox-1.13.4/archival
+
+#endif
+
-diff -Nur busybox-1.13.4.orig/archival/libunarchive/Kbuild busybox-1.13.4/archival/libunarchive/Kbuild
---- busybox-1.13.4.orig/archival/libunarchive/Kbuild 2008-11-09 18:28:02.000000000 +0100
-+++ busybox-1.13.4/archival/libunarchive/Kbuild 2009-05-31 15:40:37.133998111 +0200
-@@ -39,6 +39,7 @@
- lib-$(CONFIG_DPKG) += $(DPKG_FILES)
- lib-$(CONFIG_DPKG_DEB) += $(DPKG_FILES)
- lib-$(CONFIG_GUNZIP) += decompress_unzip.o
-+lib-$(CONFIG_IPKG) += open_transformer.o get_header_tar.o get_header_tar_gz.o
- lib-$(CONFIG_RPM2CPIO) += decompress_unzip.o get_header_cpio.o
- lib-$(CONFIG_RPM) += open_transformer.o decompress_unzip.o get_header_cpio.o
- lib-$(CONFIG_TAR) += get_header_tar.o
-diff -Nur busybox-1.13.4.orig/archival/libunarchive/data_extract_all.c busybox-1.13.4/archival/libunarchive/data_extract_all.c
---- busybox-1.13.4.orig/archival/libunarchive/data_extract_all.c 2008-11-09 18:28:02.000000000 +0100
-+++ busybox-1.13.4/archival/libunarchive/data_extract_all.c 2009-05-31 15:40:37.133998111 +0200
-@@ -146,3 +146,16 @@
+diff -Nur busybox-1.15.2.orig/archival/libunarchive/data_extract_all.c busybox-1.15.2/archival/libunarchive/data_extract_all.c
+--- busybox-1.15.2.orig/archival/libunarchive/data_extract_all.c 2009-10-08 02:59:09.000000000 +0200
++++ busybox-1.15.2/archival/libunarchive/data_extract_all.c 2009-11-26 11:10:15.327858023 +0100
+@@ -147,3 +147,16 @@
}
}
}
@@ -13639,69 +13673,32 @@ diff -Nur busybox-1.13.4.orig/archival/libunarchive/data_extract_all.c busybox-1
+ data_extract_all(archive_handle);
+ }
+}
-diff -Nur busybox-1.13.4.orig/coreutils/md5_sha1_sum.c busybox-1.13.4/coreutils/md5_sha1_sum.c
---- busybox-1.13.4.orig/coreutils/md5_sha1_sum.c 2008-11-09 18:28:07.000000000 +0100
-+++ busybox-1.13.4/coreutils/md5_sha1_sum.c 2009-05-31 15:40:37.141999131 +0200
-@@ -8,14 +8,12 @@
-
- #include "libbb.h"
-
--typedef enum { HASH_SHA1, HASH_MD5 } hash_algo_t;
--
- #define FLAG_SILENT 1
- #define FLAG_CHECK 2
- #define FLAG_WARN 4
-
- /* This might be useful elsewhere */
--static unsigned char *hash_bin_to_hex(unsigned char *hash_value,
-+unsigned char *hash_bin_to_hex(unsigned char *hash_value,
- unsigned hash_length)
- {
- /* xzalloc zero-terminates */
-@@ -24,7 +22,7 @@
- return (unsigned char *)hex_value;
- }
-
--static uint8_t *hash_file(const char *filename, hash_algo_t hash_algo)
-+uint8_t *hash_file(const char *filename, hash_algo_t hash_algo)
- {
- int src_fd, hash_len, count;
- union _ctx_ {
-diff -Nur busybox-1.13.4.orig/include/applets.h busybox-1.13.4/include/applets.h
---- busybox-1.13.4.orig/include/applets.h 2008-11-09 18:28:17.000000000 +0100
-+++ busybox-1.13.4/include/applets.h 2009-05-31 15:40:37.145999641 +0200
-@@ -203,6 +203,7 @@
- USE_IPCALC(APPLET(ipcalc, _BB_DIR_BIN, _BB_SUID_NEVER))
- USE_IPCRM(APPLET(ipcrm, _BB_DIR_USR_BIN, _BB_SUID_ALWAYS))
- USE_IPCS(APPLET(ipcs, _BB_DIR_USR_BIN, _BB_SUID_ALWAYS))
-+USE_IPKG(APPLET(ipkg, _BB_DIR_USR_BIN, _BB_SUID_NEVER))
- USE_IPLINK(APPLET(iplink, _BB_DIR_BIN, _BB_SUID_NEVER))
- USE_IPROUTE(APPLET(iproute, _BB_DIR_BIN, _BB_SUID_NEVER))
- USE_IPRULE(APPLET(iprule, _BB_DIR_BIN, _BB_SUID_NEVER))
-diff -Nur busybox-1.13.4.orig/include/libbb.h busybox-1.13.4/include/libbb.h
---- busybox-1.13.4.orig/include/libbb.h 2009-04-15 02:09:42.000000000 +0200
-+++ busybox-1.13.4/include/libbb.h 2009-05-31 15:40:37.149999313 +0200
-@@ -1309,6 +1309,7 @@
- extern const char bb_uuenc_tbl_std[];
- void bb_uuencode(char *store, const void *s, int length, const char *tbl) FAST_FUNC;
-
-+typedef enum { HASH_SHA1, HASH_MD5 } hash_algo_t;
- typedef struct sha1_ctx_t {
- uint32_t count[2];
- uint32_t hash[5];
-@@ -1317,6 +1318,8 @@
- void sha1_begin(sha1_ctx_t *ctx) FAST_FUNC;
- void sha1_hash(const void *data, size_t length, sha1_ctx_t *ctx) FAST_FUNC;
- void *sha1_end(void *resbuf, sha1_ctx_t *ctx) FAST_FUNC;
-+unsigned char *hash_bin_to_hex(unsigned char *hash_value, unsigned hash_length);
-+uint8_t *hash_file(const char *filename, hash_algo_t hash_algo);
-
- typedef struct md5_ctx_t {
- uint32_t A;
-diff -Nur busybox-1.13.4.orig/include/unarchive.h busybox-1.13.4/include/unarchive.h
---- busybox-1.13.4.orig/include/unarchive.h 2008-11-09 18:28:17.000000000 +0100
-+++ busybox-1.13.4/include/unarchive.h 2009-05-31 15:40:37.149999313 +0200
-@@ -94,6 +94,7 @@
+diff -Nur busybox-1.15.2.orig/archival/libunarchive/Kbuild busybox-1.15.2/archival/libunarchive/Kbuild
+--- busybox-1.15.2.orig/archival/libunarchive/Kbuild 2009-09-26 15:14:57.000000000 +0200
++++ busybox-1.15.2/archival/libunarchive/Kbuild 2009-11-26 11:10:15.323857513 +0100
+@@ -41,6 +41,7 @@
+ lib-$(CONFIG_DPKG) += $(DPKG_FILES)
+ lib-$(CONFIG_DPKG_DEB) += $(DPKG_FILES)
+ lib-$(CONFIG_GUNZIP) += decompress_unzip.o
++lib-$(CONFIG_IPKG) += open_transformer.o get_header_tar.o get_header_tar_gz.o
+ lib-$(CONFIG_RPM2CPIO) += decompress_unzip.o get_header_cpio.o
+ lib-$(CONFIG_RPM) += open_transformer.o decompress_unzip.o get_header_cpio.o
+ lib-$(CONFIG_TAR) += get_header_tar.o
+diff -Nur busybox-1.15.2.orig/include/applets.h busybox-1.15.2/include/applets.h
+--- busybox-1.15.2.orig/include/applets.h 2009-09-26 15:14:57.000000000 +0200
++++ busybox-1.15.2/include/applets.h 2009-11-26 11:32:09.719980839 +0100
+@@ -213,6 +213,7 @@
+ IF_IPCALC(APPLET(ipcalc, _BB_DIR_BIN, _BB_SUID_DROP))
+ IF_IPCRM(APPLET(ipcrm, _BB_DIR_USR_BIN, _BB_SUID_REQUIRE))
+ IF_IPCS(APPLET(ipcs, _BB_DIR_USR_BIN, _BB_SUID_REQUIRE))
++IF_IPKG(APPLET(ipkg, _BB_DIR_USR_BIN, _BB_SUID_DROP))
+ IF_IPLINK(APPLET(iplink, _BB_DIR_BIN, _BB_SUID_DROP))
+ IF_IPROUTE(APPLET(iproute, _BB_DIR_BIN, _BB_SUID_DROP))
+ IF_IPRULE(APPLET(iprule, _BB_DIR_BIN, _BB_SUID_DROP))
+diff -Nur busybox-1.15.2.orig/include/unarchive.h busybox-1.15.2/include/unarchive.h
+--- busybox-1.15.2.orig/include/unarchive.h 2009-10-08 02:59:09.000000000 +0200
++++ busybox-1.15.2/include/unarchive.h 2009-11-26 11:10:15.547858684 +0100
+@@ -93,6 +93,7 @@
extern void data_skip(archive_handle_t *archive_handle) FAST_FUNC;
extern void data_extract_all(archive_handle_t *archive_handle) FAST_FUNC;
@@ -13709,10 +13706,10 @@ diff -Nur busybox-1.13.4.orig/include/unarchive.h busybox-1.13.4/include/unarchi
extern void data_extract_to_stdout(archive_handle_t *archive_handle) FAST_FUNC;
extern void data_extract_to_buffer(archive_handle_t *archive_handle) FAST_FUNC;
-diff -Nur busybox-1.13.4.orig/include/usage.h busybox-1.13.4/include/usage.h
---- busybox-1.13.4.orig/include/usage.h 2008-11-09 18:28:17.000000000 +0100
-+++ busybox-1.13.4/include/usage.h 2009-05-31 15:40:37.154000102 +0200
-@@ -1425,6 +1425,82 @@
+diff -Nur busybox-1.15.2.orig/include/usage.h busybox-1.15.2/include/usage.h
+--- busybox-1.15.2.orig/include/usage.h 2009-10-08 02:59:09.000000000 +0200
++++ busybox-1.15.2/include/usage.h 2009-11-26 11:10:15.551859473 +0100
+@@ -1557,6 +1557,82 @@
"$ ls -la /tmp/busybox*\n" \
"-rw-rw-r-- 1 andersen andersen 554058 Apr 14 17:49 /tmp/busybox.tar.gz\n"
@@ -13793,5 +13790,16 @@ diff -Nur busybox-1.13.4.orig/include/usage.h busybox-1.13.4/include/usage.h
+ "\teg: ipkg info 'libstd*' or ipkg search '*libop*' or ipkg remove 'libncur*'\n"
+
#define halt_trivial_usage \
- "[-d delay] [-n] [-f]" USE_FEATURE_WTMP(" [-w]")
+ "[-d delay] [-n] [-f]" IF_FEATURE_WTMP(" [-w]")
#define halt_full_usage "\n\n" \
+diff -Nur busybox-1.15.2.orig/Makefile busybox-1.15.2/Makefile
+--- busybox-1.15.2.orig/Makefile 2009-10-08 03:06:38.000000000 +0200
++++ busybox-1.15.2/Makefile 2009-11-26 11:10:12.791856498 +0100
+@@ -445,6 +445,7 @@
+
+ libs-y := \
+ archival/ \
++ archival/libipkg/ \
+ archival/libunarchive/ \
+ console-tools/ \
+ coreutils/ \
diff --git a/package/busybox/patches/002-find-empty.patch b/package/busybox/patches/002-find-empty.patch
deleted file mode 100644
index 4e0cc67fa..000000000
--- a/package/busybox/patches/002-find-empty.patch
+++ /dev/null
@@ -1,105 +0,0 @@
-diff -Nur busybox-1.12.3/findutils/Config.in busybox-1.12.3-find/findutils/Config.in
---- busybox-1.12.3/findutils/Config.in 2008-09-28 20:04:28.000000000 +0200
-+++ busybox-1.12.3-find/findutils/Config.in 2009-01-06 22:24:46.086215240 +0100
-@@ -81,6 +81,14 @@
- help
- Support the 'find -inum' option for searching by inode number.
-
-+config FEATURE_FIND_EMPTY
-+ bool "Enable -empty option matching empty files and directories"
-+ default y
-+ depends on FIND
-+ help
-+ Support the 'find -empty' option for searching empty files
-+ and directories.
-+
- config FEATURE_FIND_EXEC
- bool "Enable -exec option allowing execution of commands"
- default y
-diff -Nur busybox-1.12.3/findutils/find.c busybox-1.12.3-find/findutils/find.c
---- busybox-1.12.3/findutils/find.c 2008-09-28 20:04:28.000000000 +0200
-+++ busybox-1.12.3-find/findutils/find.c 2009-01-06 23:33:53.201386585 +0100
-@@ -93,6 +93,7 @@
- USE_FEATURE_FIND_CONTEXT(ACTS(context, security_context_t context;))
- USE_FEATURE_FIND_PAREN( ACTS(paren, action ***subexpr;))
- USE_FEATURE_FIND_PRUNE( ACTS(prune))
-+USE_FEATURE_FIND_EMPTY( ACTS(empty))
- USE_FEATURE_FIND_DELETE( ACTS(delete))
- USE_FEATURE_FIND_EXEC( ACTS(exec, char **exec_argv; unsigned *subst_count; int exec_argc;))
- USE_FEATURE_FIND_GROUP( ACTS(group, gid_t gid;))
-@@ -318,6 +319,34 @@
- return exec_actions(ap->subexpr, fileName, statbuf);
- }
- #endif
-+#if ENABLE_FEATURE_FIND_EMPTY
-+ACTF(empty)
-+{
-+ DIR *d;
-+ struct dirent *dp;
-+ bool empty = TRUE;
-+
-+ if (S_ISDIR(statbuf->st_mode)) {
-+ d = opendir(fileName);
-+ if (d == NULL)
-+ bb_simple_perror_msg(fileName);
-+ for (dp = readdir(d); dp; dp = readdir(d)) {
-+ if (dp->d_name[0] != '.' ||
-+ (dp->d_name[1] != '\0' &&
-+ (dp->d_name[1] != '.' ||
-+ dp->d_name[2] != '\0'))) {
-+ empty = FALSE;
-+ break;
-+ }
-+ }
-+ closedir(d);
-+ return(empty);
-+ } else if (S_ISREG(statbuf->st_mode))
-+ return (statbuf->st_size == 0);
-+ else
-+ return FALSE;
-+}
-+#endif
- #if ENABLE_FEATURE_FIND_SIZE
- ACTF(size)
- {
-@@ -459,6 +488,7 @@
- USE_FEATURE_FIND_PRINT0( PARM_print0 ,)
- USE_FEATURE_FIND_DEPTH( PARM_depth ,)
- USE_FEATURE_FIND_PRUNE( PARM_prune ,)
-+ USE_FEATURE_FIND_EMPTY( PARM_empty ,)
- USE_FEATURE_FIND_DELETE( PARM_delete ,)
- USE_FEATURE_FIND_EXEC( PARM_exec ,)
- USE_FEATURE_FIND_PAREN( PARM_char_brace,)
-@@ -492,6 +522,7 @@
- USE_FEATURE_FIND_PRINT0( "-print0\0" )
- USE_FEATURE_FIND_DEPTH( "-depth\0" )
- USE_FEATURE_FIND_PRUNE( "-prune\0" )
-+ USE_FEATURE_FIND_EMPTY( "-empty\0" )
- USE_FEATURE_FIND_DELETE( "-delete\0" )
- USE_FEATURE_FIND_EXEC( "-exec\0" )
- USE_FEATURE_FIND_PAREN( "(\0" )
-@@ -610,6 +641,12 @@
- (void) ALLOC_ACTION(prune);
- }
- #endif
-+#if ENABLE_FEATURE_FIND_EMPTY
-+ else if (parm == PARM_empty) {
-+ USE_FEATURE_FIND_NOT( invert_flag = 0; )
-+ (void) ALLOC_ACTION(empty);
-+ }
-+#endif
- #if ENABLE_FEATURE_FIND_DELETE
- else if (parm == PARM_delete) {
- need_print = 0;
-diff -Nur busybox-1.12.3/include/usage.h busybox-1.12.3-find/include/usage.h
---- busybox-1.12.3/include/usage.h 2008-09-28 20:04:26.000000000 +0200
-+++ busybox-1.12.3-find/include/usage.h 2009-01-07 00:07:49.832669156 +0100
-@@ -1140,6 +1140,8 @@
- "\n -group NAME File belongs to group NAME (numeric group ID allowed)") \
- USE_FEATURE_FIND_DEPTH( \
- "\n -depth Process directory name after traversing it") \
-+ USE_FEATURE_FIND_EMPTY( \
-+ "\n -empty File or directory is empty") \
- USE_FEATURE_FIND_SIZE( \
- "\n -size N[bck] File size is N (c:bytes,k:kbytes,b:512 bytes(def.))." \
- "\n +/-N: file size is bigger/smaller than N") \
diff --git a/package/busybox/patches/003-ip-config.patch b/package/busybox/patches/003-ip-config.patch
deleted file mode 100644
index 8c32dafe6..000000000
--- a/package/busybox/patches/003-ip-config.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-diff -Nur busybox-1.13.4.orig/networking/Config.in busybox-1.13.4/networking/Config.in
---- busybox-1.13.4.orig/networking/Config.in 2008-11-09 18:27:59.000000000 +0100
-+++ busybox-1.13.4/networking/Config.in 2009-08-12 23:12:27.132893048 +0200
-@@ -338,10 +338,10 @@
- bool "Use busybox ip applet"
- default y
- depends on FEATURE_IFUPDOWN_IP
-- select IP
-- select FEATURE_IP_ADDRESS
-- select FEATURE_IP_LINK
-- select FEATURE_IP_ROUTE
-+ #select IP
-+ #select FEATURE_IP_ADDRESS
-+ #select FEATURE_IP_LINK
-+ #select FEATURE_IP_ROUTE
- help
- Use the busybox iproute "ip" applet to implement "ifupdown".
-
diff --git a/package/busybox/patches/patch-Makefile b/package/busybox/patches/patch-Makefile
deleted file mode 100644
index 45b8f75a9..000000000
--- a/package/busybox/patches/patch-Makefile
+++ /dev/null
@@ -1,12 +0,0 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- busybox-1.13.4.orig/Makefile 2009-04-15 02:11:01.000000000 +0200
-+++ busybox-1.13.4/Makefile 2009-05-06 20:30:25.953125000 +0200
-@@ -277,7 +277,7 @@ HOSTCXXFLAGS :=
- # We need some generic definitions
- include $(srctree)/scripts/Kbuild.include
-
--HOSTCFLAGS += $(call hostcc-option,-Wall -Wstrict-prototypes -O2 -fomit-frame-pointer,)
-+HOSTCFLAGS += $(call hostcc-option,-Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -DHOSTCOMPILE=1,)
- HOSTCXXFLAGS += -O2
-
- # For maximum performance (+ possibly random breakage, uncomment
diff --git a/package/busybox/patches/patch-Makefile_flags b/package/busybox/patches/patch-Makefile_flags
deleted file mode 100644
index 72eb6b709..000000000
--- a/package/busybox/patches/patch-Makefile_flags
+++ /dev/null
@@ -1,21 +0,0 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- busybox-1.12.3.orig/Makefile.flags 2008-09-28 20:04:30.000000000 +0200
-+++ busybox-1.12.3/Makefile.flags 2008-12-25 20:27:43.092824157 +0100
-@@ -46,15 +46,12 @@ CFLAGS += $(call cc-option,-falign-funct
- # be fixed..
- #CFLAGS += $(call cc-option,-Wconversion,)
-
--ifneq ($(CONFIG_DEBUG),y)
--CFLAGS += $(call cc-option,-Os,)
--else
-+ifeq ($(CONFIG_DEBUG),y)
- CFLAGS += $(call cc-option,-g,)
-+else
- #CFLAGS += "-D_FORTIFY_SOURCE=2"
- ifeq ($(CONFIG_DEBUG_PESSIMIZE),y)
- CFLAGS += $(call cc-option,-O0,)
--else
--CFLAGS += $(call cc-option,-Os,)
- endif
- endif
-
diff --git a/package/busybox/patches/patch-include_libbb_h b/package/busybox/patches/patch-include_libbb_h
deleted file mode 100644
index 37c500bdc..000000000
--- a/package/busybox/patches/patch-include_libbb_h
+++ /dev/null
@@ -1,80 +0,0 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- busybox-1.13.4.orig/include/libbb.h 2009-04-15 02:09:42.000000000 +0200
-+++ busybox-1.13.4/include/libbb.h 2009-05-09 02:06:09.000000000 +0200
-@@ -44,6 +44,7 @@
- #define PATH_MAX 256
- #endif
-
-+#if !(defined __APPLE__ || defined __FreeBSD__)
- #ifdef HAVE_MNTENT_H
- #include <mntent.h>
- #endif
-@@ -58,6 +59,7 @@
- #include <selinux/flask.h>
- #include <selinux/av_permissions.h>
- #endif
-+#endif
-
- #if ENABLE_LOCALE_SUPPORT
- #include <locale.h>
-@@ -71,9 +73,11 @@
-
- #include <pwd.h>
- #include <grp.h>
-+#ifndef HOSTCOMPILE
- #if ENABLE_FEATURE_SHADOWPASSWDS
- # include <shadow.h>
- #endif
-+#endif
-
- /* Some libc's forget to declare these, do it ourself */
-
-@@ -409,7 +413,9 @@ struct BUG_too_small {
- char BUG_family_t_too_small[(0
- | AF_UNSPEC
- | AF_INET
-+#ifndef HOSTCOMPILE
- | AF_INET6
-+#endif
- | AF_UNIX
- #ifdef AF_PACKET
- | AF_PACKET
-@@ -810,7 +816,9 @@ enum {
- # define bb_daemonize_or_rexec(flags, argv) bb_daemonize_or_rexec(flags)
- # define bb_daemonize(flags) bb_daemonize_or_rexec(flags, bogus)
- #else
-+#ifndef HOSTCOMPILE
- void re_exec(char **argv) NORETURN FAST_FUNC;
-+#endif
- void forkexit_or_rexec(char **argv) FAST_FUNC;
- extern bool re_execed;
- int BUG_fork_is_unavailable_on_nommu(void) FAST_FUNC;
-@@ -1003,10 +1011,12 @@ extern void run_applet_and_exit(const ch
- extern void run_applet_no_and_exit(int a, char **argv) NORETURN FAST_FUNC;
- #endif
-
-+#if !(defined __APPLE__ || defined __FreeBSD__)
- #ifdef HAVE_MNTENT_H
- extern int match_fstype(const struct mntent *mt, const char *fstypes) FAST_FUNC;
- extern struct mntent *find_mount_point(const char *name, const char *table) FAST_FUNC;
- #endif
-+#endif
- extern void erase_mtab(const char * name) FAST_FUNC;
- extern unsigned int tty_baud_to_value(speed_t speed) FAST_FUNC;
- extern speed_t tty_value_to_baud(unsigned int value) FAST_FUNC;
-@@ -1084,6 +1094,7 @@ extern void bb_do_delay(int seconds) FAS
- extern void change_identity(const struct passwd *pw) FAST_FUNC;
- extern void run_shell(const char *shell, int loginshell, const char *command, const char **additional_args) NORETURN FAST_FUNC;
- extern void run_shell(const char *shell, int loginshell, const char *command, const char **additional_args) FAST_FUNC;
-+#if !(defined __APPLE__ || defined __FreeBSD__)
- #if ENABLE_SELINUX
- extern void renew_current_security_context(void) FAST_FUNC;
- extern void set_current_security_context(security_context_t sid) FAST_FUNC;
-@@ -1094,6 +1105,7 @@ extern void selinux_preserve_fcontext(in
- #else
- #define selinux_preserve_fcontext(fdesc) ((void)0)
- #endif
-+#endif
- extern void selinux_or_die(void) FAST_FUNC;
- extern int restricted_shell(const char *shell) FAST_FUNC;
-
diff --git a/package/busybox/patches/patch-include_platform_h b/package/busybox/patches/patch-include_platform_h
deleted file mode 100644
index b3c9ffd7f..000000000
--- a/package/busybox/patches/patch-include_platform_h
+++ /dev/null
@@ -1,30 +0,0 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- busybox-1.13.4.orig/include/platform.h 2008-11-09 18:28:17.000000000 +0100
-+++ busybox-1.13.4/include/platform.h 2009-05-08 22:48:50.000000000 +0200
-@@ -116,7 +116,7 @@
- # include <sex.h>
- # define __BIG_ENDIAN__ (BYTE_ORDER == BIG_ENDIAN)
- # define __BYTE_ORDER BYTE_ORDER
--#elif !defined __APPLE__
-+#elif !(defined __APPLE__ || defined __FreeBSD__)
- # include <byteswap.h>
- # include <endian.h>
- #endif
-@@ -162,7 +162,7 @@
-
- /* ---- Networking ------------------------------------------ */
-
--#ifndef __APPLE__
-+#if !(defined __APPLE__ || defined __FreeBSD__)
- # include <arpa/inet.h>
- # ifndef __socklen_t_defined
- typedef int socklen_t;
-@@ -210,7 +210,7 @@ __extension__ typedef unsigned long long
- #define HAVE_FEATURES_H
- #include <stdint.h>
- #define HAVE_STDINT_H
--#elif !defined __APPLE__
-+#elif !(defined __APPLE__ || defined __FreeBSD__)
- /* Largest integral types. */
- #if __BIG_ENDIAN__
- typedef long intmax_t;
diff --git a/package/busybox/patches/patch-networking_traceroute_c b/package/busybox/patches/patch-networking_traceroute_c
deleted file mode 100644
index 081bf9232..000000000
--- a/package/busybox/patches/patch-networking_traceroute_c
+++ /dev/null
@@ -1,12 +0,0 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- busybox-1.13.4.orig/networking/traceroute.c 2008-11-09 18:27:59.000000000 +0100
-+++ busybox-1.13.4/networking/traceroute.c 2009-05-12 16:26:08.000000000 +0200
-@@ -273,7 +273,7 @@ typedef struct outdata {
- unsigned char seq; /* sequence number of this packet */
- unsigned char ttl; /* ttl packet left with */
- // UNUSED. Retaining to have the same packet size.
-- struct timeval tv_UNUSED PACKED; /* time packet left */
-+ struct timeval tv_UNUSED; /* time packet left */
- } outdata_t;
-
- struct IFADDRLIST {
diff --git a/package/busybox/patches/patch-networking_udhcp_dhcpd_c b/package/busybox/patches/patch-networking_udhcp_dhcpd_c
deleted file mode 100644
index 26b6590c3..000000000
--- a/package/busybox/patches/patch-networking_udhcp_dhcpd_c
+++ /dev/null
@@ -1,11 +0,0 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- busybox-1.13.4.orig/networking/udhcp/dhcpd.c 2008-11-09 18:27:58.000000000 +0100
-+++ busybox-1.13.4/networking/udhcp/dhcpd.c 2009-05-12 16:32:40.000000000 +0200
-@@ -196,7 +196,6 @@ int udhcpd_main(int argc UNUSED_PARAM, c
- if (lease) {
- if (server_id) {
- /* SELECTING State */
-- DEBUG("server_id = %08x", ntohl(server_id_align));
- if (server_id_align == server_config.server && requested
- && requested_align == lease->yiaddr
- ) {
diff --git a/package/busybox/patches/patch-runit_runit_lib_h b/package/busybox/patches/patch-runit_runit_lib_h
deleted file mode 100644
index da6327854..000000000
--- a/package/busybox/patches/patch-runit_runit_lib_h
+++ /dev/null
@@ -1,16 +0,0 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- busybox-1.13.4.orig/runit/runit_lib.h 2008-11-09 18:28:19.000000000 +0100
-+++ busybox-1.13.4/runit/runit_lib.h 2009-05-12 16:34:56.000000000 +0200
-@@ -88,9 +88,9 @@ extern unsigned pmatch(const char *, con
- * runsv / supervise / sv stuff
- */
- typedef struct svstatus_t {
-- uint64_t time_be64 PACKED;
-- uint32_t time_nsec_be32 PACKED;
-- uint32_t pid_le32 PACKED;
-+ uint64_t time_be64;
-+ uint32_t time_nsec_be32;
-+ uint32_t pid_le32;
- uint8_t paused;
- uint8_t want;
- uint8_t got_term;
diff --git a/package/busybox/patches/patch-util-linux_fdisk_osf_c b/package/busybox/patches/patch-util-linux_fdisk_osf_c
deleted file mode 100644
index 75c8a858a..000000000
--- a/package/busybox/patches/patch-util-linux_fdisk_osf_c
+++ /dev/null
@@ -1,12 +0,0 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- busybox-1.13.4.orig/util-linux/fdisk_osf.c 2008-11-09 18:28:22.000000000 +0100
-+++ busybox-1.13.4/util-linux/fdisk_osf.c 2009-05-12 16:39:12.000000000 +0200
-@@ -45,7 +45,7 @@
-
- #if defined(i386) || defined(__sparc__) || defined(__arm__) \
- || defined(__m68k__) || defined(__mips__) || defined(__s390__) \
-- || defined(__sh__) || defined(__x86_64__)
-+ || defined(__sh__) || defined(__x86_64__) || defined(__cris__)
- #define BSD_LABELSECTOR 1
- #define BSD_LABELOFFSET 0
- #elif defined(__alpha__) || defined(__powerpc__) || defined(__ia64__) \