
Originally Posted by
lly
OK, there might be some problem in build scripts. To see what happens you have to increase verbosity:
Success!
For some reason, with make v=99 it compiles successfully.
The only thing that needs changing in 'make .config' is the default 2.6 kernel source which has your directory specified. I downloaded the latest 2.6 from kernel.org, and voila!
Code:
...
....
.....
ln -sf mipsel-linux-gcc /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-linux-cc
ln -sf mipsel-linux-uclibc-g\+\+ /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-g\+\+
ln -sf mipsel-linux-uclibc-addr2line /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-addr2line
ln -sf mipsel-linux-uclibc-as /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-as
ln -sf mipsel-linux-uclibc-c\+\+filt /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-c\+\+filt
ln -sf mipsel-linux-uclibc-gcov /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-gcov
ln -sf mipsel-linux-uclibc-gprof /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-gprof
ln -sf mipsel-linux-uclibc-readelf /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-readelf
ln -sf mipsel-linux-uclibc-c\+\+ /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-c\+\+
ln -sf mipsel-linux-uclibc-cpp /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-cpp
ln -sf mipsel-linux-uclibc-ar /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-ar
ln -sf mipsel-linux-uclibc-gcc /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-gcc
ln -sf mipsel-linux-uclibc-gcc-4.8.5 /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-gcc-4.8.5
ln -sf mipsel-linux-uclibc-ld /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-ld
ln -sf mipsel-linux-uclibc-nm /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-nm
ln -sf mipsel-linux-uclibc-objcopy /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-objcopy
ln -sf mipsel-linux-uclibc-objdump /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-objdump
ln -sf mipsel-linux-uclibc-ranlib /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-ranlib
ln -sf mipsel-linux-uclibc-size /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-size
ln -sf mipsel-linux-uclibc-strings /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-strings
ln -sf mipsel-linux-uclibc-strip /opt/brcm/hndtools-mipsel-uclibc-4.8.5/bin/mipsel-uclibc-strip
make[1]: Leaving directory '/home/debian/Downloads/toolchain'
Thanks. Now it's time to compile the actual firmware.
lly - Do you think it will be simple enough for me to modify the WL500GP V1 target myself to the BCM4322? Or does that require advanced knowledge? It seems like the firmware should already support BCM4322, because the module is showing as selected in the config.
edit:
Got this error during compiling:
Code:
mipsel-uclibc-gcc -DHAVE_CONFIG_H -I. -I. -I.. -Wall -g -O2 -mips32 -mtune=mips32 -Wno-pointer-sign -mno-branch-likely -DBCMWPA2 -I. -I/home/debian/Downloads/wl500g/broadcom/src/gateway/ppp/pppd/.. -idirafter/home/debian/Downloads/wl500g/broadcom/src/linux/linux-2.6/include -MT pptp.lo -MD -MP -MF .deps/pptp.Tpo -c pptp.c -fPIC -DPIC -o .libs/pptp.o
pptp.c: In function 'pptp_start_client':
pptp.c:151:18: error: 'union <anonymous>' has no member named 'pptp'
dst_addr.sa_addr.pptp.sin_addr=*(struct in_addr*)hostinfo->h_addr;
^
pptp.c:154:29: error: 'union <anonymous>' has no member named 'pptp'
route_add(dst_addr.sa_addr.pptp.sin_addr, &rt);
^
pptp.c:160:33: error: 'union <anonymous>' has no member named 'pptp'
addr.sin_addr=dst_addr.sa_addr.pptp.sin_addr;
^
pptp.c:171:19: error: 'union <anonymous>' has no member named 'pptp'
src_addr.sa_addr.pptp.sin_addr=addr.sin_addr;
^
pptp.c:180:23: error: 'PX_PROTO_PPTP' undeclared (first use in this function)
src_addr.sa_protocol=PX_PROTO_PPTP;
^
pptp.c:180:23: note: each undeclared identifier is reported only once for each function it appears in
pptp.c:181:18: error: 'union <anonymous>' has no member named 'pptp'
src_addr.sa_addr.pptp.call_id=0;
^
pptp.c:185:18: error: 'union <anonymous>' has no member named 'pptp'
dst_addr.sa_addr.pptp.call_id=0;
^
pptp.c:201:26: error: 'union <anonymous>' has no member named 'pptp'
call_ID=src_addr.sa_addr.pptp.call_id;
^
pptp.c:210:47: error: 'union <anonymous>' has no member named 'pptp'
callmgr_sock = open_callmgr(src_addr.sa_addr.pptp.call_id, dst_addr.sa_addr.pptp.sin_addr, pptp_phone, 50);
^
pptp.c:210:78: error: 'union <anonymous>' has no member named 'pptp'
callmgr_sock = open_callmgr(src_addr.sa_addr.pptp.call_id, dst_addr.sa_addr.pptp.sin_addr, pptp_phone, 50);
^
pptp.c:217:74: error: 'union <anonymous>' has no member named 'pptp'
} while (get_call_id(callmgr_sock, getpid(), getpid(), &dst_addr.sa_addr.pptp.call_id) < 0);
^
pptp.c:227:60: error: 'union <anonymous>' has no member named 'pptp'
sprintf(ppp_devnam,"pptp (%s)", inet_ntoa(dst_addr.sa_addr.pptp.sin_addr));
^
pptp.c: At top level:
pptp.c:403:1: warning: 'route_del' defined but not used [-Wunused-function]
route_del(struct rtentry *rt)
^
Makefile:298: recipe for target 'pptp.lo' failed
make[3]: *** [pptp.lo] Error 1
make[3]: Leaving directory '/home/debian/Downloads/wl500g/broadcom/src/gateway/accel-pptp/pppd_plugin/src'
Makefile:257: recipe for target 'all-recursive' failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory '/home/debian/Downloads/wl500g/broadcom/src/gateway/accel-pptp/pppd_plugin'
Makefile:186: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/home/debian/Downloads/wl500g/broadcom/src/gateway/accel-pptp/pppd_plugin'
Makefile:855: recipe for target 'accel-pptp' failed
make: *** [accel-pptp] Error 2
debian@debian:~/Downloads/wl500g/broadcom/src/gateway$
Should I symlink hndtools-mipsel-uclibc-4.6.4 or hndtools-mipsel-uclibc-4.8.5? Compiling toolchain produced both in /opt/brcm.
Thanks
edit: Indeed, the 4.8.5 is the correct version. It will not even start compiling with 4.6.4 symlinked. I will try to remove pptp from menuconfig and see what happens.
edit #2:
Ok, disabled PPTP but now getting this error:
Code:
mipsel-uclibc-gcc -Wall -O2 -DUSB_SUPPORT -DQOS -DWPA2_WMM -DASUS_EXT -mips32 -mtune=mips32 -Wno-pointer-sign -mno-branch-likely -DBCMWPA2 -DBCMWPS -ffunction-sections -fdata-sections -I. -I/home/debian/Downloads/wl500g/broadcom/src/gateway/shared -I/home/debian/Downloads/wl500g/broadcom/src/include -idirafter/home/debian/Downloads/wl500g/broadcom/src/linux/linux-2.6/include -Wall -DWEBSTRFILTER -c -o network.o network.c
network.c: In function 'prepare_wan_unit':
network.c:912:12: error: invalid storage class for function 'add_wan_routes'
static int add_wan_routes(const char *wan_ifname)
^
network.c:923:12: error: invalid storage class for function 'del_wan_routes'
static int del_wan_routes(const char *wan_ifname)
^
network.c:2032:13: error: invalid storage class for function 'lan_up'
static void lan_up(const char *lan_ifname)
^
network.c:2156:12: error: invalid storage class for function 'notify_nas'
static int notify_nas(const char *type, const char *ifname, const char *action)
^
network.c:2371:12: error: invalid storage class for function 'wait_for_ifup'
static int wait_for_ifup(const char *prefix, const char *wan_ifname, struct ifreq *ifr)
^
network.c:2412:1: error: expected declaration or statement at end of input
}
^
network.c: At top level:
network.c:45:13: warning: 'lan_up' used but never defined [enabled by default]
static void lan_up(const char *lan_ifname);
^
network.c:46:12: warning: 'wait_for_ifup' used but never defined [enabled by default]
static int wait_for_ifup(const char *prefix, const char *wan_ifname, struct ifreq *ifr);
^
<builtin>: recipe for target 'network.o' failed
make[1]: *** [network.o] Error 1
make[1]: Leaving directory '/home/debian/Downloads/wl500g/broadcom/src/gateway/rc'
Makefile:621: recipe for target 'rc' failed
make: *** [rc] Error 2
debian@debian:~/Downloads/wl500g/broadcom/src/gateway$