Compiled trx file won't fit into flash

Discussion about my Wifi Radio project at http://mightyohm.com/wifiradio/ or my WL-520gU talk at NOTACON.
Post Reply
cj6666
Posts: 24
Joined: Fri Apr 24, 2009 8:01 am

Compiled trx file won't fit into flash

Post by cj6666 »

Hi,

Been playing around trying to compiled my own trx file. Using the latest openwrt and including the necessary drivers (usb audio, etc) and programs (mpc, mpd, etc), the resulting file always larger than 4MB.

Does building the component into packages and then opkg them in saves space than compile everything in?

I don't understand how people can include everything and still fit into the 4MB flash memory. What's the secret?

Thanks, CJ
User avatar
mightyohm
Site Admin
Posts: 1064
Joined: Fri Apr 03, 2009 10:29 pm
Location: Seattle, WA
Contact:

Re: Compiled trx file won't fit into flash

Post by mightyohm »

CJ,

I haven't seen this before, but then again I have never tried to compile all packages into the kernel, and also my most recent experience compiling OpenWrt is with a rather old version of Kamikaze.

I suspect that the issue is that the newest version of mpd has some very large dependencies, including glib, and these are causing you to exceed the 4MB limit. If you compile the packages as opkg files, at least you can see the relative sizes of the packages.

ilinux has compiled the latest mpd and may be able to help you with the size problem. I'm not sure what he did to get the size under control, but I would ask on this thread: viewtopic.php?f=2&t=117

Good luck.
cj6666
Posts: 24
Joined: Fri Apr 24, 2009 8:01 am

Re: Compiled trx file won't fit into flash

Post by cj6666 »

Thanks Jeff, for the reply and the effort sharing such fun project with us.
I'll ask ilinux about this problem, CJ
ilinux
Posts: 55
Joined: Mon Jul 06, 2009 2:36 am

Re: Compiled trx file won't fit into flash

Post by ilinux »

I've seen this problem,

Thanks! I'm build a new image wrtradio v0.2 with an older mpd and I will link into forum when ready.


By Ilinux
ilinux
Posts: 55
Joined: Mon Jul 06, 2009 2:36 am

Re: Compiled trx file won't fit into flash

Post by ilinux »

Try the wrtradio firmware 0.3 is only 2.1 MB
jeroen94704
Posts: 109
Joined: Sat Feb 13, 2010 4:27 am
Location: Eindhoven, the Netherlands

Re: Compiled trx file won't fit into flash

Post by jeroen94704 »

Alternatively, you can install packages that don't fit on the router's flash to an external USB drive. That's how I overcame the 4 MB size-limit. This does not require the router to boot from USB, but you do need to set the LD_LIBRARY_PATH variable to point to the /usb/usr/lib and /usb/lib directories, or MPD (and other apps that need them, presumably) won't be able to find the libraries installed there.

Hope this helps, let me know if you getting stuck.

Jeroen
Post Reply