Omikron
03-23-2008, 04:49 PM
So after much fighting with cygwin and old scripts, I finally got the mips cross-compiler working. W00t!
Of course, the whole reason I wanted the compiler in the first place was to build a new busybox, since I'm OCD about keeping things up to date. I've tried to use the .config in AlphaWolf's howtobuild.7z file and have been unsuccessful. Apparently a whole lot of options have changed between 1.2 and 1.9 and many of the variables set by the file no longer appear valid.
I have tried to build it both by individually selecting options that seemed appropriate and also by saying "N" to everything, and both seem to result in the following error:
In file included from applets/../include/busybox.h:10,
from applets/applet_tables.c:16:
applets/../include/libbb.h:307: error: `AF_INET6' undeclared here (not in a func
tion)
applets/../include/libbb.h:309: error: `AF_PACKET' undeclared here (not in a fun
ction)
applets/../include/libbb.h:312: error: `AF_NETLINK' undeclared here (not in a fu
nction)
make[1]: *** [applets/applet_tables] Error 1
make: *** [applets] Error 2
Any ideas?
Omikron
03-23-2008, 05:09 PM
For reference I'm running the latest full cygwin and trying to compile BusyBox v1.9.2.
Jamie
03-23-2008, 09:29 PM
All of those #defines come from include/linux/socket.h:
fedora[104] ~/busybox-1.9.2 % egrep -r "#define AF_(INET6|PACKET|NETLINK)" /usr/local/mips-tivo72/include/
/usr/local/mips-tivo72/include/linux/socket.h:#define AF_INET6 10 /* IP version 6 */
/usr/local/mips-tivo72/include/linux/socket.h:#define AF_NETLINK 16
/usr/local/mips-tivo72/include/linux/socket.h:#define AF_PACKET 17 /* Packet family */
It looks to me like you might not have proper linux kernel headers in your installed toolchain include directory.
I had no problem building the latest busybox stable (1.9.2) using the toolchain built with my scripts [link (.http://www.dealdatabase.com/forum/showthread.php?t=46361)]. We'll no problem once I dropped a few utilities that had problems (httpd, setarch, readahead).
Are you sure you're building a cross-compiled busybox and not trying to build a cygwin x86 version? You need to "make CROSS_COMPILE=mips-TiVo-linux-".
Omikron
03-23-2008, 09:52 PM
All of those #defines come from include/linux/socket.h:
fedora[104] ~/busybox-1.9.2 % egrep -r "#define AF_(INET6|PACKET|NETLINK)" /usr/local/mips-tivo72/include/
/usr/local/mips-tivo72/include/linux/socket.h:#define AF_INET6 10 /* IP version 6 */
/usr/local/mips-tivo72/include/linux/socket.h:#define AF_NETLINK 16
/usr/local/mips-tivo72/include/linux/socket.h:#define AF_PACKET 17 /* Packet family */
It looks to me like you might not have proper linux kernel headers in your installed toolchain include directory.
I had no problem building the latest busybox stable (1.9.2) using the toolchain built with my scripts [link (.http://www.dealdatabase.com/forum/showthread.php?t=46361)]. We'll no problem once I dropped a few utilities that had problems (httpd, setarch, readahead).
Are you sure you're building a cross-compiled busybox and not trying to build a cygwin x86 version? You need to "make CROSS_COMPILE=mips-TiVo-linux-".
I've tried using the same command before with identical results. :-/
Jamie
03-23-2008, 10:38 PM
I've tried using the same command before with identical results. :-/Seems that you don't have a proper toolchain installed then.
[Edit: I take it back. I tried it on cygwin, and it looks like busybox simply won't build on a cygwin system. It's compiling applets/applet_tables with the host compiler (HOSTCC), and that's what is needing access to the linux header files. Busybox just doesn't seem to be setup to compile under cygwin. Suggestion: compile busybox on a linux system.]
Omikron
03-26-2008, 03:42 PM
Poo...
VMWare to the rescue!
jt1134
03-27-2008, 04:03 PM
Here's a 1.9.2 busybox binary I compiled under ubuntu. Vi gives a seg fault, but everything else I've tested seems to work fine.
BusyBox v1.9.2 (2008-03-26 16:48:26 CDT) multi-call binary
Copyright (C) 1998-2007 Erik Andersen, Rob Landley, Denys Vlasenko
and others. Licensed under GPLv2.
See source distribution for full notice.
Usage: busybox [function] [arguments]...
or: function [arguments]...
BusyBox is a multi-call binary that combines many common Unix
utilities into a single executable. Most people will create a
link to busybox for each function they wish to use and BusyBox
will act like whatever it was invoked as!
Currently defined functions:
[, [[, adjtimex, arping, awk, basename, bunzip2, bzcat,
bzip2, catv, chattr, chown, chroot, cksum, clear, comm,
crond, cut, date, dc, diff, dirname, dmesg, dos2unix,
echo, ed, env, expr, find, fold, free, fsck, ftpget, ftpput,
fuser, getopt, head, hexdump, hostname, hwclock, inetd,
ipcalc, ipcrm, ipcs, kill, killall, killall5, length,
less, ls, lsattr, lsmod, lzmacat, md5sum, mkfifo, mktemp,
more, mountpoint, nc, netstat, nice, nmeter, nohup, nslookup,
od, patch, pgrep, pidof, ping, pipe_progress, pivot_root,
pkill, printenv, ps, readprofile, realpath, renice, reset,
rm, rmdir, sed, seq, setconsole, setlogcons, setsid, sha1sum,
stat, strings, sum, switch_root, sysctl, tail, tar, tee,
telnet, test, tftp, top, touch, tr, traceroute, tty, uniq,
unix2dos, unlzma, uptime, usleep, uudecode, uuencode,
vconfig, vi, watch, watchdog, wc, wget, which, xargs,
yes, zcip
vBulletin® v3.7.3, Copyright ©2000-2008, Jelsoft Enterprises Ltd.