'ndiswrapper' written in C, not Perl
January 20, 2012 —
BarryK
I am still on holiday, and don't have the hardware to test this. Help requested!
In this thread, PANZERKOPF posted an ndiswrapper.c that was obtained from the GeexBox Linux project:
http://murga-linux.com/puppy/viewtopic.php?t=51478&start=405
I am looking again at being able to build Puppy distros without Perl. Currently, we have a cutdown Perl in all puppies, needed by ndiswrapper, pplog, one of the partview variants, don't know if anything else.
The ndiswrapper package has /usr/sbin/ndiswrapper, a Perl script. This was the original reason that we were forced to introduce Perl into Puppy.
Note, if we take out cutdown-Perl, the full Perl will still be in the 'devx' SFS, as required for compiling source packages.
I would like to know if the ndiswrapper executable written in C, that PANZERKOPF found, works. Could you test it with your hardware?
There is one issue apparently, the *.inf file must not have multi-byte characters (unicode) -- it would be good if the program could detect that rather than just fail. But, are there any such .inf files out there?
Alternatively, we can pre-process such a .inf file, remove multi-byte chars. I posted how to do that here:
http://bkhome.org/archive/blog2/201112/script-internationalization-by-39t12s39.html
The compiled binary is posted to the Forum. Gunzip it, make sure the executable flags are set, and place it at /usr/sbin. Remove prior files at /etc/ndiswrapper then try your wireless hardware:
http://murga-linux.com/puppy/viewtopic.php?t=75352
Feedback will be greatly appreciated!
Comments
successful in Puppy 3.01Username: dingo
woof woof I use puppy 3.01 everyday. I just tested this executable and it worked fine on my netgear WG311v3 wireless adapter with XP drivers on HP d530c computer (before to try I removed ndiswrapper perl script from /usr/sbin) thanks for Puppy 3.01 it is the best OS I used in my life, it only lacks ipv6, but I'll try to recompile in order to can use puppy 3.01 also in ipv6 age, forever and ever in my life
Ndiswrapper tests
Username: ozsouth
"Tested 1 year old onboard Atheros 9285 (PCI-Exp) & 6 year old Netgear WG111NA (usb), in Lupu-528 (puppy driver modules skiplisted). If I simply substitute the new ndiswrapper, no problems. Starting from scratch (all ndiswrapper files removed), Atheros segfaults, Netgear loads, but ndiswrapper switches -l & -m inactive, meaning /etc/modules.d/ndiswrapper.conf needs creating with manual entry 'alias wlan1 ndiswrapper'. Dhcpcd then run manually - works! This has potential.
ndiswrapper.sh
Username: technosaurus
"Fortunately I have never needed this, but I thought I would take a look anyways. Its not really that complex and most of the code can map directly into shell (actually a lot of stuff would be easier in shell), so it would be fairly simple to just port the perl directly to shell ... even better would be to use lspci, lsusb etc and this data: http://sourceforge.net/apps/mediawiki/ndiswrapper/index.php?title=Main_Page to automatically get the stuff (just one big long case statement really)
cups and perl
Username: disciple
"This might sound familiar: > Aaarrgh! Pakt has just reminded me that CUPS needs Perl! So, before we can dump Perl, any Perl scripts in CUPS would also have to be rewritten
off topic XMBC on Raspberry
Username: bing crosby
"However off topic: Would like to let you know that Dutch tweakers show the XMBC mm suite on Raspberry .. http://tweakers.net/nieuws/79493/xbmc-geport-naar-goedkope-raspberry-pi-pc.html Scroll down for the youtube demo - in English.
Re cups and perl
Username: BarryK
"As far as I know, it was only the foomatic-filters package that had a Perl script, /usr/bin/foomatic-rip, but as from version 4.x that was rewritten in C. However, I just looked through foomatic-filters 4.0.7, and there is still a Perl script, /usr/lib/cups/backend/beh, which is an error-handler script. However, 'beh' is a small script, someone with a bit of Perl capability (not me!) could convert that to Ash script for us. technosaurus? Is there any other CUPS-related Perl script?
perls
Username: technosaurus
"unfortunately I only have a basic understanding of perl - if someone could at least document what each code block is doing, it would go a long way (google already periodically thinks I'm a bot) here is a (maybe outdated) list of perl scripts in {/usr}/{s}bin align bones_diff.pl cups-genppdupdate ndiswrapper newroot width c_rehash dirsplit fixmswrd.pl foomatic-gswrapper foomatic-rip glib-mkenums isohybrid ispellaff2myspell lss16toppm md5pass mp_doccer mtrace normalize-mp3 normalize-ogg perlbug perldoc perlivp perlthanks pnmquant ppmquant ppmrainbow ppmtolss16 sha1pass btw, this is how I found them (I use a variant of this a lot - works for many filetypes, even non-scripts like PNG XPM etc...) A=/initrd/pup_ro2 && for x in $A/bin/* $A/sbin/* $A/usr/sbin/* $A/usr/bin/* ; do read LINE <$x; case "$LINE" in *perl*)echo ${x##*/};;esac; done|tr "n" " "
Re finding Perl scripts
Username: BarryK
"technosaurus, Good, but you have done that with the 'devx' loaded. It will be a shorter list without 'devx', but still formidable for us who don't know Perl. We will need to find a friendly Perl coder who will convert them to shell script for us.
rerere perl scripts
Username: BarryK
"Oh, I didn't look close enough at your search code. Hmmm, rather a lot of scripts. Perhaps we won't be getting rid of perl-tiny anytime soon -- it is about 1MB I think.
Tags: puppy