OpenWrt Forum Archive

Topic: Installing ndiswrapper and the complete perl on OpenWRT

The content of this topic has been archived on 28 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

I'm going to skip over a lot of details.

Since you're installing all of perl, space isn't a problem.  Manually install packages from a distro, say.. debian.  You'll need a full libc.  If ldd perl doesn't think perl is an executable, you need to manually install /lib/ld-linux.so.2 and libc.so.6 (maybe some other .<digit>) from the distro packages.

With all the libraries needed installed, you need to set up the perl libraries; my perl expected them in /usr/local/lib/perl/5.8.8/ and /usr/local/share/perl/5.8.8/.  Again, the files that go in here are available in distro packages.  A lot of this is platform independent, so you can just copy it from an existing system.

You can also compile perl statically, but I had some headaches with that.

All of the libraries perl needs take about 1.7 mb and bzip2s to 790k (in the event unpacking in a ram-backed union-fs is an option).


The perl libraries take about 6mb compressed, 25mb uncompressed (they're not all needed for any given script, but it's better to start out with a full lib).

You're on your own for cpan.



ndiswapper needs perl for one of its scripts.

you could port it over to C, but good luck with that.  pp execuatables work (with additions to /lib), but it's slow.  I didn't have any luck with perlcc.

ndiswrapper only works for x86 (so... vmware, soekris, etc).  I suppose you could do something funky with qemu, but that's pretty hard

You need to edit the makefiles (in ndiswrapper-<version> and the utils and drivers dirs)
CC = .../staging_dir_mipsel/bin/x86-linux-uclibc-gcc
LD = .../staging_dir_mipsel/bin/x86-linux-uclibc-ld
manually set KVERS
manually set KBUILD

Once it's built, copy ndiswrapper to /usr/sbin and loadndisdriver to /sbin

make /etc/ndiswapper, while you're at it.

(Last edited by exobyte on 15 Jun 2008, 00:39)

Thinking about it... For ndiswapper, you probably don't need the perl script on the router; it's for getting status info.  Running it on a machine with perl to generate the contents of /etc/ndiswrapper and copying those files over to the router might work.

exobyte wrote:

Thinking about it... For ndiswapper, you probably don't need the perl script on the router; it's for getting status info.  Running it on a machine with perl to generate the contents of /etc/ndiswrapper and copying those files over to the router might work.

Hello Exobyte,

Any luck in ndiswapper?..  pls let me know.
Thanks

ndiswrapper works fine, given an x86 machine.

The discussion might have continued from here.