Build toybox diff.

Necessary to run toybox tests on the device (and presumably any other
command-line testing that wants to compare actual to expected results).

Bug: N/A
Test: ran toybox tests on-device (script coming soon)
Change-Id: Ib7a6044d6d6af4fc34996e66cba0a023b3e8dce4
This commit is contained in:
Elliott Hughes 2017-04-01 09:18:14 -07:00
parent 7602ee6309
commit 98aae74f4a
4 changed files with 37 additions and 35 deletions

View File

@ -83,7 +83,7 @@ CONFIG_DF=y
# CONFIG_DHCP6 is not set
# CONFIG_DHCPD is not set
# CONFIG_DHCP is not set
# CONFIG_DIFF is not set
CONFIG_DIFF=y
CONFIG_DIRNAME=y
CONFIG_DMESG=y
CONFIG_DOS2UNIX=y

View File

@ -137,6 +137,7 @@ common_SRC_FILES := \
toys/other/yes.c \
toys/pending/chrt.c \
toys/pending/dd.c \
toys/pending/diff.c \
toys/pending/dmesg.c \
toys/pending/expr.c \
toys/pending/getfattr.c \
@ -272,6 +273,7 @@ ALL_TOOLS := \
cut \
date \
df \
diff \
dirname \
dmesg \
dos2unix \

View File

@ -140,8 +140,8 @@
#define USE_DHCPD(...)
#define CFG_DHCP 0
#define USE_DHCP(...)
#define CFG_DIFF 0
#define USE_DIFF(...)
#define CFG_DIFF 1
#define USE_DIFF(...) __VA_ARGS__
#define CFG_DIRNAME 1
#define USE_DIRNAME(...) __VA_ARGS__
#define CFG_DMESG 1

View File

@ -525,7 +525,7 @@
#undef FLAG_P
#endif
// diff <2>2B(ignore-blank-lines)d(minimal)b(ignore-space-change)ut(expand-tabs)w(ignore-all-space)i(ignore-case)T(initial-tab)s(report-identical-files)q(brief)a(text)L(label)*S(starting-file):N(new-file)r(recursive)U(unified)#<0=3
// diff <2>2B(ignore-blank-lines)d(minimal)b(ignore-space-change)ut(expand-tabs)w(ignore-all-space)i(ignore-case)T(initial-tab)s(report-identical-files)q(brief)a(text)L(label)*S(starting-file):N(new-file)r(recursive)U(unified)#<0=3 <2>2B(ignore-blank-lines)d(minimal)b(ignore-space-change)ut(expand-tabs)w(ignore-all-space)i(ignore-case)T(initial-tab)s(report-identical-files)q(brief)a(text)L(label)*S(starting-file):N(new-file)r(recursive)U(unified)#<0=3
#undef OPTSTR_diff
#define OPTSTR_diff "<2>2B(ignore-blank-lines)d(minimal)b(ignore-space-change)ut(expand-tabs)w(ignore-all-space)i(ignore-case)T(initial-tab)s(report-identical-files)q(brief)a(text)L(label)*S(starting-file):N(new-file)r(recursive)U(unified)#<0=3"
#ifdef CLEANUP_diff
@ -3635,37 +3635,37 @@
#ifndef TT
#define TT this.diff
#endif
#define FLAG_unified (FORCED_FLAG<<0)
#define FLAG_U (FORCED_FLAG<<0)
#define FLAG_recursive (FORCED_FLAG<<1)
#define FLAG_r (FORCED_FLAG<<1)
#define FLAG_new_file (FORCED_FLAG<<2)
#define FLAG_N (FORCED_FLAG<<2)
#define FLAG_starting_file (FORCED_FLAG<<3)
#define FLAG_S (FORCED_FLAG<<3)
#define FLAG_label (FORCED_FLAG<<4)
#define FLAG_L (FORCED_FLAG<<4)
#define FLAG_text (FORCED_FLAG<<5)
#define FLAG_a (FORCED_FLAG<<5)
#define FLAG_brief (FORCED_FLAG<<6)
#define FLAG_q (FORCED_FLAG<<6)
#define FLAG_report_identical_files (FORCED_FLAG<<7)
#define FLAG_s (FORCED_FLAG<<7)
#define FLAG_initial_tab (FORCED_FLAG<<8)
#define FLAG_T (FORCED_FLAG<<8)
#define FLAG_ignore_case (FORCED_FLAG<<9)
#define FLAG_i (FORCED_FLAG<<9)
#define FLAG_ignore_all_space (FORCED_FLAG<<10)
#define FLAG_w (FORCED_FLAG<<10)
#define FLAG_expand_tabs (FORCED_FLAG<<11)
#define FLAG_t (FORCED_FLAG<<11)
#define FLAG_u (FORCED_FLAG<<12)
#define FLAG_ignore_space_change (FORCED_FLAG<<13)
#define FLAG_b (FORCED_FLAG<<13)
#define FLAG_minimal (FORCED_FLAG<<14)
#define FLAG_d (FORCED_FLAG<<14)
#define FLAG_ignore_blank_lines (FORCED_FLAG<<15)
#define FLAG_B (FORCED_FLAG<<15)
#define FLAG_unified (1<<0)
#define FLAG_U (1<<0)
#define FLAG_recursive (1<<1)
#define FLAG_r (1<<1)
#define FLAG_new_file (1<<2)
#define FLAG_N (1<<2)
#define FLAG_starting_file (1<<3)
#define FLAG_S (1<<3)
#define FLAG_label (1<<4)
#define FLAG_L (1<<4)
#define FLAG_text (1<<5)
#define FLAG_a (1<<5)
#define FLAG_brief (1<<6)
#define FLAG_q (1<<6)
#define FLAG_report_identical_files (1<<7)
#define FLAG_s (1<<7)
#define FLAG_initial_tab (1<<8)
#define FLAG_T (1<<8)
#define FLAG_ignore_case (1<<9)
#define FLAG_i (1<<9)
#define FLAG_ignore_all_space (1<<10)
#define FLAG_w (1<<10)
#define FLAG_expand_tabs (1<<11)
#define FLAG_t (1<<11)
#define FLAG_u (1<<12)
#define FLAG_ignore_space_change (1<<13)
#define FLAG_b (1<<13)
#define FLAG_minimal (1<<14)
#define FLAG_d (1<<14)
#define FLAG_ignore_blank_lines (1<<15)
#define FLAG_B (1<<15)
#endif
#ifdef FOR_dirname