Kevin wrote:why would you cross compile from vmware? native is faster, and should work on most architectures..
I think there's a misunderstanding.
"Cross compiling" means using an i386 host to compile for MIPS. This is what OpenWrt's buildroot does when run under i386 Linux (whether that be a "real" i386 machine or a virtual machine)
"Native" means using a MIPS host to compile for MIPS. That's what the OP wanted to do. It will be much slower building packages on a 266MHz MIPS CPU than on a 2GHz i386 (or even a Linux VM running under Windows on a 2GHz i386)
The OP will end up with a lot more work getting native compilation to work, since there's no existing MIPS toolchain to work with. So he/she will first have to cross-compile the toolchain to MIPS, before copying it to the box, before being able to start compiling.
In other words - you have a lot less work to do if you just use a Linux i386 machine (or VM) in the first place.
I can't figure out how to create new packages from source with the buildroot-ng package builder.
If you want to build a real package (a .ipkg) then it will be the same whether or not you perform the compilation under i386 or on the router itself. But you don't need buildroot for this - all you need is the SDK
If you want an example of how to build a package from scratch, try this example - you just unpack it under the SDK and type 'make'
If you want to build a single binary and copy it onto your target, without using ipkg at all, then you can use the toolchain which the SDK is supplied with, or which the buildroot builds from scratch.
candlerb@candlerb-desktop:~/svn/openwrt/trunk$ cat >hello.c
#include <stdio.h>
int main(void)
{
printf("Hello, world!\n");
return 0;
}
^D
candlerb@candlerb-desktop:~/svn/openwrt/trunk$ staging_dir_mips/bin/mips-linux-gcc -Wall -o hello hello.c
candlerb@candlerb-desktop:~/svn/openwrt/trunk$ file hello
hello: ELF 32-bit MSB executable, MIPS, version 1 (SYSV), dynamically linked (uses shared libs), not stripped
candlerb@candlerb-desktop:~/svn/openwrt/trunk$