BusyBox for OSX
casey
pfourier at mninter.net
Wed Aug 31 09:59:10 UTC 2016
On Aug 30, 2016, at 10:21 AM, casey <pfourier at mninter.net> wrote:
> Hi,
> OS X Version 10.9.5 does NOT compile:
>
> https://github.com/daliworks/busybox-osx
>
> # brew install gnu-sed
> # cp configs/osx_defconfig .config && make
>
> CC util-linux/scriptreplay.o
> clang: warning: argument unused during compilation: '-arch x86_64 -mmacosx-version-min=10.5'
> AR util-linux/lib.a
> LINK busybox_unstripped
> Trying libraries:
> Failed:
> Output of:
> gcc -Wshadow -Wwrite-strings -Wundef -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wdeclaration-after-statement -Wold-style-definition -funsigned-char -Os '-arch x86_64 -mmacosx-version-min=10.5' -o busybox_unstripped applets/built-in.o archival/lib.a archival/libarchive/lib.a console-tools/lib.a coreutils/lib.a coreutils/libcoreutils/lib.a debianutils/lib.a editors/lib.a findutils/lib.a init/lib.a libbb/lib.a libpwdgrp/lib.a loginutils/lib.a mailutils/lib.a miscutils/lib.a networking/lib.a procps/lib.a runit/lib.a shell/lib.a sysklogd/lib.a util-linux/lib.a archival/built-in.o archival/libarchive/built-in.o console-tools/built-in.o coreutils/built-in.o coreutils/libcoreutils/built-in.o debianutils/built-in.o editors/built-in.o findutils/built-in.o init/built-in.o libbb/built-in.o libpwdgrp/built-in.o loginutils/built-in.o mailutils/built-in.o miscutils/built-in.o networking/built-in.o procps/built-in.o runit/built-in.o shell/built-in.o sysklogd/built-in.o util-linux/built-in.o
> ==========
> clang: error: no such file or directory: ''-arch'
> clang: error: no such file or directory: 'x86_64'
> clang: error: invalid version number in '-mmacosx-version-min=10.5''
> make: *** [busybox_unstripped] Error 1
> Sam-MacBook-Pro:busybox Hill$
> ########
> Q: Any chance updating BusyBox for OSX?
> casey
I have no clue about OSX but the ticks around '-arch x86_64 -mmacosx-version-min=10.5'
feel wrong. Can you copy the gcc line, remove the arch and mmacosx, and simply
run the gcc again ?
re,
wh
wh,
REM’d out that build option in /configs/osx_defconfig:
# Build Options
#
# CONFIG_STATIC is not set
# CONFIG_PIE is not set
# CONFIG_NOMMU is not set
# CONFIG_BUILD_LIBBUSYBOX=y
# CONFIG_FEATURE_INDIVIDUAL is not set
# CONFIG_FEATURE_SHARED_BUSYBOX=y
CONFIG_LFS=y
CONFIG_CROSS_COMPILER_PREFIX=""
#CONFIG_EXTRA_CFLAGS=‘-arch x86_64 -mmacosx-version-min=10.5'
# # $
*
ash (ASH) [Y/n/?] y
bash-compatible extensions (ASH_BASH_COMPAT) [Y/n/?] y
Idle timeout variable (ASH_IDLE_TIMEOUT) [N/y/?] n
Job control (ASH_JOB_CONTROL) [Y/n/?] y
Alias support (ASH_ALIAS) [Y/n/?] y
Builtin getopt to parse positional parameters (ASH_GETOPTS) [Y/n/?] y
Builtin version of 'echo' (ASH_BUILTIN_ECHO) [Y/n/?] y
Builtin version of 'printf' (ASH_BUILTIN_PRINTF) [Y/n/?] y
Builtin version of 'test' (ASH_BUILTIN_TEST) [Y/n/?] y
'command' command to override shell builtins (ASH_CMDCMD) [Y/n/?] y
Check for new mail on interactive shells (ASH_MAIL) [N/y/?] n
Optimize for size instead of speed (ASH_OPTIMIZE_FOR_SIZE) [Y/n/?] y
Pseudorandom generator and $RANDOM variable (ASH_RANDOM_SUPPORT) [Y/n/?] y
Expand prompt string (ASH_EXPAND_PRMT) [Y/n/?] y
cttyhack (CTTYHACK) [Y/n/?] y
hush (HUSH) [N/y/?] n
msh (deprecated: aliased to hush) (MSH) [N/y/?] n
Choose which shell is aliased to 'sh' name
> 1. ash (FEATURE_SH_IS_ASH)
2. none (FEATURE_SH_IS_NONE)
choice[1-2?]: 1
Choose which shell is aliased to 'bash' name
1. ash (FEATURE_BASH_IS_ASH)
> 2. none (FEATURE_BASH_IS_NONE)
choice[1-2?]: 2
POSIX math support (SH_MATH_SUPPORT) [Y/n/?] y
Extend POSIX math support to 64 bit (SH_MATH_SUPPORT_64) [Y/n/?] y
Hide message on interactive shell startup (FEATURE_SH_EXTRA_QUIET) [N/y/?] n
Standalone shell (FEATURE_SH_STANDALONE) [N/y/?] (NEW) y
Run 'nofork' applets directly (FEATURE_SH_NOFORK) [N/y/?] (NEW) y
Use $HISTFILESIZE (FEATURE_SH_HISTFILESIZE) [Y/n/?] y
SPLIT include/autoconf.h -> include/config/*
GEN include/bbconfigopts.h
HOSTCC applets/usage
GEN include/usage_compressed.h
HOSTCC applets/applet_tables
GEN include/applet_tables.h
CC applets/applets.o
LD applets/built-in.o
HOSTCC applets/usage_pod
CC archival/ar.o
archival/ar.c:77:4: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
fh->size
^~~~~~~~
archival/ar.c:187:4: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
file_header->size,
^~~~~~~~~~~~~~~~~
2 warnings generated.
CC archival/bbunzip.o
CC archival/bzip2.o
CC archival/cpio.o
CC archival/dpkg.o
CC archival/dpkg_deb.o
CC archival/gzip.o
CC archival/lzop.o
CC archival/rpm.o
CC archival/rpm2cpio.o
CC archival/tar.o
archival/tar.c:170:52: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
width = sprintf(tempBuffer, "%0*"OFF_FMT"o", len, value);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
%0*llo
/usr/include/secure/_stdio.h:47:56: note: expanded from macro 'sprintf'
__builtin___sprintf_chk (str, 0, __darwin_obsz(str), __VA_ARGS__)
^
archival/tar.c:353:15: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
fileName, statbuf->st_size);
^~~~~~~~~~~~~~~~
2 warnings generated.
CC archival/unzip.o
AR archival/lib.a
CC archival/libarchive/data_align.o
CC archival/libarchive/data_extract_all.o
CC archival/libarchive/data_extract_to_command.o
archival/libarchive/data_extract_to_command.c:41:24: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
CC archival/libarchive/data_extract_to_stdout.o
CC archival/libarchive/data_skip.o
CC archival/libarchive/decompress_bunzip2.o
CC archival/libarchive/decompress_uncompress.o
CC archival/libarchive/decompress_unlzma.o
CC archival/libarchive/decompress_unxz.o
CC archival/libarchive/decompress_unzip.o
CC archival/libarchive/filter_accept_all.o
CC archival/libarchive/filter_accept_list.o
CC archival/libarchive/filter_accept_list_reassign.o
CC archival/libarchive/filter_accept_reject_list.o
CC archival/libarchive/find_list_entry.o
CC archival/libarchive/get_header_ar.o
CC archival/libarchive/get_header_cpio.o
CC archival/libarchive/get_header_tar.o
CC archival/libarchive/get_header_tar_bz2.o
CC archival/libarchive/get_header_tar_gz.o
CC archival/libarchive/get_header_tar_lzma.o
CC archival/libarchive/header_list.o
CC archival/libarchive/header_skip.o
CC archival/libarchive/header_verbose_list.o
archival/libarchive/header_verbose_list.c:36:3: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
file_header->size,
^~~~~~~~~~~~~~~~~
1 warning generated.
CC archival/libarchive/init_handle.o
CC archival/libarchive/lzo1x_1.o
CC archival/libarchive/lzo1x_1o.o
CC archival/libarchive/lzo1x_9x.o
CC archival/libarchive/lzo1x_d.o
CC archival/libarchive/open_transformer.o
CC archival/libarchive/seek_by_jump.o
CC archival/libarchive/seek_by_read.o
CC archival/libarchive/unpack_ar_archive.o
AR archival/libarchive/lib.a
CC console-tools/clear.o
CC console-tools/reset.o
CC console-tools/resize.o
CC console-tools/setconsole.o
CC console-tools/setkeycodes.o
AR console-tools/lib.a
CC coreutils/basename.o
CC coreutils/cat.o
CC coreutils/catv.o
CC coreutils/chgrp.o
CC coreutils/chmod.o
CC coreutils/chown.o
CC coreutils/chroot.o
CC coreutils/cksum.o
coreutils/cksum.c:67:10: warning: format specifies type 'long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
crc, filesize, *argv);
^~~~~~~~
coreutils/cksum.c:67:10: warning: format specifies type 'long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
crc, filesize, *argv);
^~~~~~~~
coreutils/cksum.c:67:20: warning: data argument not used by format string [-Wformat-extra-args]
crc, filesize, *argv);
^
3 warnings generated.
CC coreutils/comm.o
CC coreutils/cp.o
CC coreutils/cut.o
CC coreutils/date.o
CC coreutils/dd.o
coreutils/dd.c:92:4: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
G.in_full, G.in_part,
^~~~~~~~~
coreutils/dd.c:74:11: note: expanded from macro 'G'
#define G (*(struct globals*)&bb_common_bufsiz1)
^
coreutils/dd.c:92:15: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
G.in_full, G.in_part,
^~~~~~~~~
coreutils/dd.c:74:11: note: expanded from macro 'G'
#define G (*(struct globals*)&bb_common_bufsiz1)
^
coreutils/dd.c:93:4: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
G.out_full, G.out_part);
^~~~~~~~~~
coreutils/dd.c:74:11: note: expanded from macro 'G'
#define G (*(struct globals*)&bb_common_bufsiz1)
^
coreutils/dd.c:93:16: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
G.out_full, G.out_part);
^~~~~~~~~~
coreutils/dd.c:74:11: note: expanded from macro 'G'
#define G (*(struct globals*)&bb_common_bufsiz1)
^
4 warnings generated.
CC coreutils/dirname.o
CC coreutils/dos2unix.o
CC coreutils/du.o
CC coreutils/echo.o
CC coreutils/env.o
CC coreutils/expand.o
coreutils/expand.c:230:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_perror_msg_and_die(bb_msg_standard_input);
^~~~~~~~~~~~~~~~~~~~~
1 warning generated.
CC coreutils/expr.o
CC coreutils/false.o
CC coreutils/fold.o
CC coreutils/fsync.o
CC coreutils/head.o
CC coreutils/hostid.o
CC coreutils/id.o
CC coreutils/ln.o
CC coreutils/logname.o
CC coreutils/ls.o
coreutils/ls.c:525:37: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
column += printf("%6"OFF_FMT"u ", (off_t) (dn->dn_blocks >> 1));
~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
%6lld
coreutils/ls.c:562:39: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
column += printf("%9"OFF_FMT"u ", dn->dn_size);
~~~~~~~~~~~~ ^~~~~~~~~~~
%9lld
coreutils/ls.c:1036:34: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
printf("total %"OFF_FMT"u\n", calculate_blocks(subdnp));
~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~
%lld
3 warnings generated.
CC coreutils/md5_sha1_sum.o
CC coreutils/mkdir.o
CC coreutils/mkfifo.o
CC coreutils/mv.o
CC coreutils/nice.o
CC coreutils/nohup.o
CC coreutils/od.o
In file included from coreutils/od.c:24:
coreutils/od_bloaty.c:1381:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_perror_msg_and_die(bb_msg_standard_input);
^~~~~~~~~~~~~~~~~~~~~
1 warning generated.
CC coreutils/printenv.o
CC coreutils/printf.o
CC coreutils/pwd.o
CC coreutils/readlink.o
CC coreutils/realpath.o
CC coreutils/rm.o
CC coreutils/rmdir.o
CC coreutils/seq.o
CC coreutils/sleep.o
CC coreutils/sort.o
CC coreutils/split.o
CC coreutils/stty.o
CC coreutils/sum.o
CC coreutils/sync.o
CC coreutils/tac.o
CC coreutils/tail.o
CC coreutils/tee.o
CC coreutils/test.o
CC coreutils/touch.o
CC coreutils/tr.o
CC coreutils/true.o
CC coreutils/tty.o
CC coreutils/uname.o
CC coreutils/uniq.o
CC coreutils/usleep.o
CC coreutils/uudecode.o
CC coreutils/uuencode.o
CC coreutils/wc.o
CC coreutils/whoami.o
CC coreutils/yes.o
AR coreutils/lib.a
CC coreutils/libcoreutils/cp_mv_stat.o
CC coreutils/libcoreutils/getopt_mk_fifo_nod.o
AR coreutils/libcoreutils/lib.a
CC debianutils/mktemp.o
CC debianutils/pipe_progress.o
CC debianutils/run_parts.o
CC debianutils/start_stop_daemon.o
CC debianutils/which.o
AR debianutils/lib.a
CC editors/awk.o
editors/awk.c:2416:9: warning: variable 'L' is uninitialized when used within its own initialization [-Wuninitialized]
} L = L; /* for compiler */
~ ^
editors/awk.c:2420:9: warning: variable 'R' is uninitialized when used within its own initialization [-Wuninitialized]
} R = R;
~ ^
2 warnings generated.
CC editors/cmp.o
CC editors/diff.o
CC editors/ed.o
CC editors/patch.o
CC editors/sed.o
CC editors/vi.o
AR editors/lib.a
CC findutils/find.o
CC findutils/grep.o
CC findutils/xargs.o
AR findutils/lib.a
CC init/mesg.o
AR init/lib.a
CC libbb/appletlib.o
CC libbb/ask_confirmation.o
CC libbb/bb_askpass.o
CC libbb/bb_bswap_64.o
CC libbb/bb_do_delay.o
CC libbb/bb_pwd.o
CC libbb/bb_qsort.o
CC libbb/bb_strtonum.o
CC libbb/change_identity.o
CC libbb/chomp.o
CC libbb/compare_string_array.o
CC libbb/concat_path_file.o
CC libbb/concat_subpath_file.o
CC libbb/copy_file.o
CC libbb/copyfd.o
CC libbb/correct_password.o
CC libbb/crc32.o
CC libbb/create_icmp6_socket.o
libbb/create_icmp6_socket.c:29:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_perm_denied_are_you_root);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
libbb/create_icmp6_socket.c:30:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_perror_msg_and_die(bb_msg_can_not_create_raw_socket);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 warnings generated.
CC libbb/create_icmp_socket.o
libbb/create_icmp_socket.c:28:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_perm_denied_are_you_root);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
libbb/create_icmp_socket.c:29:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_perror_msg_and_die(bb_msg_can_not_create_raw_socket);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 warnings generated.
CC libbb/default_error_retval.o
CC libbb/device_open.o
CC libbb/dump.o
libbb/dump.c:616:15: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
printf(pr->fmt);
^~~~~~~
libbb/dump.c:666:12: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
printf(pr->fmt);
^~~~~~~
2 warnings generated.
CC libbb/execable.o
CC libbb/fclose_nonstdin.o
CC libbb/fflush_stdout_and_exit.o
libbb/fflush_stdout_and_exit.c:19:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_perror_msg_and_die(bb_msg_standard_output);
^~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
CC libbb/fgets_str.o
CC libbb/find_pid_by_name.o
CC libbb/find_root_device.o
CC libbb/full_write.o
CC libbb/get_console.o
CC libbb/get_last_path_component.o
CC libbb/get_line_from_file.o
CC libbb/get_shell_name.o
CC libbb/get_volsize.o
CC libbb/getopt32.o
CC libbb/getpty.o
CC libbb/hash_md5_sha.o
CC libbb/herror_msg.o
CC libbb/human_readable.o
CC libbb/inet_common.o
libbb/inet_common.c:31:6: warning: implicit declaration of function 'inet_aton' is invalid in C99 [-Wimplicit-function-declaration]
if (inet_aton(name, &s_in->sin_addr)) {
^
libbb/inet_common.c:117:18: warning: implicit declaration of function 'inet_ntoa' is invalid in C99 [-Wimplicit-function-declaration]
return xstrdup(inet_ntoa(s_in->sin_addr));
^
libbb/inet_common.c:117:18: warning: incompatible integer to pointer conversion passing 'int' to parameter of type 'const char *' [-Wint-conversion]
return xstrdup(inet_ntoa(s_in->sin_addr));
^~~~~~~~~~~~~~~~~~~~~~~~~
include/libbb.h:647:27: note: passing argument to parameter 's' here
char *xstrdup(const char *s) FAST_FUNC RETURNS_MALLOC;
^
libbb/inet_common.c:153:18: warning: incompatible integer to pointer conversion passing 'int' to parameter of type 'const char *' [-Wint-conversion]
name = xstrdup(inet_ntoa(s_in->sin_addr));
^~~~~~~~~~~~~~~~~~~~~~~~~
include/libbb.h:647:27: note: passing argument to parameter 's' here
char *xstrdup(const char *s) FAST_FUNC RETURNS_MALLOC;
^
libbb/inet_common.c:204:3: warning: implicit declaration of function 'inet_ntop' is invalid in C99 [-Wimplicit-function-declaration]
inet_ntop(AF_INET6, &sin6->sin6_addr, name, sizeof(name));
^
5 warnings generated.
CC libbb/info_msg.o
CC libbb/inode_hash.o
CC libbb/isdirectory.o
CC libbb/kernel_version.o
CC libbb/last_char_is.o
CC libbb/lineedit.o
CC libbb/llist.o
CC libbb/login.o
CC libbb/make_directory.o
CC libbb/match_fstype.o
CC libbb/messages.o
CC libbb/mode_string.o
CC libbb/parse_config.o
CC libbb/parse_mode.o
CC libbb/percent_decode.o
CC libbb/perror_msg.o
CC libbb/pidfile.o
CC libbb/platform.o
CC libbb/print_flags.o
CC libbb/printable.o
CC libbb/printable_string.o
CC libbb/process_escape_sequence.o
CC libbb/procps.o
CC libbb/progress.o
CC libbb/pw_encrypt.o
CC libbb/read.o
CC libbb/read_key.o
CC libbb/read_printf.o
CC libbb/recursive_action.o
CC libbb/remove_file.o
CC libbb/rtc.o
CC libbb/run_shell.o
CC libbb/safe_gethostname.o
CC libbb/safe_poll.o
CC libbb/safe_strncpy.o
CC libbb/safe_write.o
CC libbb/setup_environment.o
CC libbb/signals.o
CC libbb/simplify_path.o
CC libbb/single_argv.o
CC libbb/skip_whitespace.o
CC libbb/speed_table.o
libbb/speed_table.c:46:3: warning: implicit conversion from 'int' to 'unsigned short' changes value from 115200 to 49664 [-Wconstant-conversion]
{B115200, 115200/256 + 0x8000U},
~^~~~~~~
/usr/include/sys/termios.h:313:17: note: expanded from macro 'B115200'
#define B115200 115200
^~~~~~
libbb/speed_table.c:49:3: warning: implicit conversion from 'int' to 'unsigned short' changes value from 230400 to 33792 [-Wconstant-conversion]
{B230400, 230400/256 + 0x8000U},
~^~~~~~~
/usr/include/sys/termios.h:314:17: note: expanded from macro 'B230400'
#define B230400 230400
^~~~~~
2 warnings generated.
CC libbb/str_tolower.o
CC libbb/strrstr.o
CC libbb/systemd_support.o
CC libbb/time.o
CC libbb/trim.o
CC libbb/u_signal_names.o
CC libbb/udp_io.o
CC libbb/uuencode.o
CC libbb/vdprintf.o
CC libbb/verror_msg.o
CC libbb/vfork_daemon_rexec.o
CC libbb/warn_ignoring_args.o
CC libbb/wfopen.o
libbb/wfopen.c:46:24: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
CC libbb/wfopen_input.o
CC libbb/write.o
CC libbb/xatonum.o
CC libbb/xconnect.o
libbb/xconnect.c:88:5: warning: implicit declaration of function 'inet_ntoa' is invalid in C99 [-Wimplicit-function-declaration]
inet_ntoa(((struct sockaddr_in *)s_addr)->sin_addr));
^
libbb/xconnect.c:88:5: warning: format specifies type 'char *' but the argument has type 'int' [-Wformat]
inet_ntoa(((struct sockaddr_in *)s_addr)->sin_addr));
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
libbb/xconnect.c:235:7: warning: implicit declaration of function 'inet_aton' is invalid in C99 [-Wimplicit-function-declaration]
if (inet_aton(host, &in4) != 0) {
^
libbb/xconnect.c:248:7: warning: implicit declaration of function 'inet_pton' is invalid in C99 [-Wimplicit-function-declaration]
if (inet_pton(AF_INET6, host, &in6) > 0) {
^
4 warnings generated.
CC libbb/xfunc_die.o
CC libbb/xfuncs.o
CC libbb/xfuncs_printf.o
libbb/xfuncs_printf.c:40:16: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
libbb/xfuncs_printf.c:49:24: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
libbb/xfuncs_printf.c:60:24: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
libbb/xfuncs_printf.c:84:24: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
libbb/xfuncs_printf.c:237:48: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
bb_perror_msg_and_die("lseek(%"OFF_FMT"u)", offset);
~~~~~~~~~~~ ^~~~~~
%lld
libbb/xfuncs_printf.c:302:24: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
libbb/xfuncs_printf.c:309:24: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_error_msg_and_die(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
libbb/xfuncs_printf.c:621:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_perror_msg_and_die("vfork"+1);
^~~~~~~~~
8 warnings generated.
CC libbb/xgetcwd.o
CC libbb/xgethostbyname.o
CC libbb/xreadlink.o
CC libbb/xrealloc_vector.o
CC libbb/xregcomp.o
AR libbb/lib.a
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libbb/lib.a(bb_bswap_64.o) has no symbols
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libbb/lib.a(makedev.o) has no symbols
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libbb/lib.a(match_fstype.o) has no symbols
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libbb/lib.a(vdprintf.o) has no symbols
CC libpwdgrp/pwd_grp.o
CC libpwdgrp/uidgid_get.o
AR libpwdgrp/lib.a
CC loginutils/cryptpw.o
CC loginutils/getty.o
CC loginutils/login.o
AR loginutils/lib.a
CC mailutils/mail.o
CC mailutils/makemime.o
CC mailutils/popmaildir.o
CC mailutils/reformime.o
CC mailutils/sendmail.o
AR mailutils/lib.a
CC miscutils/bbconfig.o
CC miscutils/dc.o
CC miscutils/less.o
CC miscutils/microcom.o
CC miscutils/rx.o
CC miscutils/setsid.o
CC miscutils/strings.o
miscutils/strings.c:71:32: warning: format specifies type 'unsigned long' but the argument has type 'long long' [-Wformat]
printf("%7"OFF_FMT"o ", offset - n);
~~~~~~~~~~~~ ^~~~~~~~~~
%7llo
1 warning generated.
CC miscutils/time.o
CC miscutils/timeout.o
CC miscutils/ttysize.o
AR miscutils/lib.a
CC networking/ftpd.o
networking/ftpd.c:597:14: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
G.ftp_arg, statbuf.st_size);
^~~~~~~~~~~~~~~
networking/ftpd.c:819:56: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
sprintf(buf, STR(FTP_STATFILE_OK)" %"OFF_FMT"u\r\n", statbuf.st_size);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~
%lld
/usr/include/secure/_stdio.h:47:56: note: expanded from macro 'sprintf'
__builtin___sprintf_chk (str, 0, __darwin_obsz(str), __VA_ARGS__)
^
2 warnings generated.
CC networking/ftpgetput.o
networking/ftpgetput.c:251:36: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
sprintf(buf, "REST %"OFF_FMT"u", beg_range);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~
%lld
/usr/include/secure/_stdio.h:47:56: note: expanded from macro 'sprintf'
__builtin___sprintf_chk (str, 0, __darwin_obsz(str), __VA_ARGS__)
^
1 warning generated.
CC networking/hostname.o
networking/hostname.c:156:20: warning: implicit declaration of function 'inet_ntoa' is invalid in C99 [-Wimplicit-function-declaration]
printf("%s ", inet_ntoa(**h_addr_list));
^
networking/hostname.c:156:20: warning: format specifies type 'char *' but the argument has type 'int' [-Wformat]
printf("%s ", inet_ntoa(**h_addr_list));
~~ ^~~~~~~~~~~~~~~~~~~~~~~~
%d
2 warnings generated.
CC networking/inetd.o
networking/inetd.c:1331:20: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_perror_msg("vfork"+1);
^~~~~~~~~
1 warning generated.
CC networking/ipcalc.o
CC networking/isrv.o
CC networking/isrv_identd.o
CC networking/nc.o
CC networking/pscan.o
CC networking/tcpudp.o
networking/tcpudp.c:500:5: warning: data argument not used by format string [-Wformat-extra-args]
local_hostname, remote_hostname);
^
1 warning generated.
CC networking/tcpudp_perhost.o
CC networking/telnet.o
CC networking/telnetd.o
CC networking/tftp.o
networking/tftp.c:426:37: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
cp += sprintf(cp, "%"OFF_FMT"u", (off_t)st.st_size) + 1;
~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
%lld
/usr/include/secure/_stdio.h:47:56: note: expanded from macro 'sprintf'
__builtin___sprintf_chk (str, 0, __darwin_obsz(str), __VA_ARGS__)
^
1 warning generated.
CC networking/wget.o
networking/wget.c:202:25: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
bb_perror_msg_and_die(bb_msg_memory_exhausted);
^~~~~~~~~~~~~~~~~~~~~~~
networking/wget.c:419:43: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
sprintf(G.wget_buf, "REST %"OFF_FMT"u", G.beg_range);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
%lld
networking/wget.c:83:11: note: expanded from macro 'G'
#define G (*ptr_to_globals)
^
/usr/include/secure/_stdio.h:47:56: note: expanded from macro 'sprintf'
__builtin___sprintf_chk (str, 0, __darwin_obsz(str), __VA_ARGS__)
^
networking/wget.c:679:50: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
fprintf(sfp, "Range: bytes=%"OFF_FMT"u-\r\n", G.beg_range);
~~~~~~~~~~~ ^~~~~~~~~~~
%lld
networking/wget.c:83:11: note: expanded from macro 'G'
#define G (*ptr_to_globals)
^
3 warnings generated.
CC networking/whois.o
AR networking/lib.a
CC procps/kill.o
CC procps/renice.o
CC procps/watch.o
AR procps/lib.a
CC runit/chpst.o
CC runit/runsvdir.o
runit/runsvdir.c:166:19: warning: equality comparison with extraneous parentheses [-Wparentheses-equality]
if ((sv[i].ino == s.st_ino)
~~~~~~~~~~^~~~~~~~~~~
runit/runsvdir.c:166:19: note: remove extraneous parentheses around the comparison to silence this warning
if ((sv[i].ino == s.st_ino)
~ ^ ~
runit/runsvdir.c:166:19: note: use '=' to turn this equality comparison into an assignment
if ((sv[i].ino == s.st_ino)
^~
=
1 warning generated.
CC runit/sv.o
CC runit/svlogd.o
AR runit/lib.a
CC shell/ash.o
shell/ash.c:3929:23: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
col = fmtstr(s, 32, strsignal(st));
^~~~~~~~~~~~~
shell/ash.c:4410:16: warning: adding 'int' to a string does not append to the string [-Wstring-plus-int]
str = "\"}" + !(quoted & 1);
~~~~~~^~~~~~~~~~~~~~~
shell/ash.c:4410:16: note: use array indexing to silence this warning
str = "\"}" + !(quoted & 1);
^
& [ ]
shell/ash.c:12967:9: warning: expression which evaluates to zero treated as a null pointer constant of type 'const char *' [-Wnon-literal-null-conversion]
p = '\0';
^~~~
3 warnings generated.
CC shell/cttyhack.o
shell/cttyhack.c:69:3: warning: cttyhack will not be able to detect a controlling tty on this system [-W#warnings]
# warning cttyhack will not be able to detect a controlling tty on this system
^
1 warning generated.
CC shell/math.o
CC shell/random.o
CC shell/shell_common.o
AR shell/lib.a
CC sysklogd/syslogd_and_logger.o
AR sysklogd/lib.a
CC util-linux/flock.o
CC util-linux/getopt.o
CC util-linux/hexdump.o
CC util-linux/more.o
util-linux/more.c:129:7: warning: format specifies type 'unsigned long' but the argument has type 'off_t' (aka 'long long') [-Wformat]
st.st_size);
^~~~~~~~~~
1 warning generated.
CC util-linux/rdate.o
CC util-linux/rdev.o
CC util-linux/rev.o
CC util-linux/rtcwake.o
CC util-linux/script.o
CC util-linux/scriptreplay.o
AR util-linux/lib.a
LINK busybox_unstripped
Trying libraries:
Final link with: <none>
DOC busybox.pod
DOC BusyBox.txt
DOC busybox.1
DOC BusyBox.html
Sam-MacBook-Pro:busybox Hill$
# # #
I’d be curious if you see any other RED flags? BusyBox now launches from CLI!
Q: How can other functions/applets be added to the compile, along with upgrading the BusyBox SRC from 1.20.0 to 1.25.0?
thx
casey
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/busybox/attachments/20160831/d021312c/attachment-0001.html>
More information about the busybox
mailing list