Linux Tools in Windows
From JonWiki
Contents |
Cygwin
You'll need Cygwin for most of this. It basically replicates almost all of a Linux environment into Windows and lets you x-forward, ssh tunnel, rsync, and so forth.
I find it's best not to be picky and just install all of Cygwin. By futzing with the package selection manager, you can select the root node and have it install everything. Sure, it installs a bunch of useless stuff, but in the age of $100 500GB hard drives, there really isn't much in the way of complaining to do.
EDA Tools under Cygwin
xcircuit
You'll need tcltk/wish, so grab the tarball from here:
Then grab the xcircuit tarball:
I had some problems extracting the files, but basically just throw them in the root directory and run
tar -zxf *.tgzIt may complain that it's not a gzip file, so just run tar without the -z flag.
Make sure to add the following to your .bash_profile:
export PATH=$PATH:/usr/local/lib export DISPLAY=":0"
You'll also need to run wish before you run xcircuit.
PS to SVG
I do my editing in Inkscape, so I needed a way to get the xcircuit ps files into svg's that Inkscape could read. Apparently now Inkscape can read PS files by default, but here's the guide just in case.
You'll need to run this command:
pstoedit -f plot-svg foo.ps foo.svgIt'll complain that the gs (GhostScript) executable is missing, and give you the path. Just symlink the real path to the one it wants and you'll be all set.
There are some weird funky issues with the generated SVG in Inkscape, but if you cut and paste your figure into a new Inkscape document you'll be all set.
EPS to SVG
When using MATLAB plots in EPS, and you want them in SVG, just use
pstoedit -f plot-svg foo.eps foo.svg
Same caveats as PS to SVG apply.
SSH Tunnels
Tunneling SAMBA over SSH
Note: This is now obsolete if you use OpenVPN. I've detailed my experiences with it in my OpenWRT Guides section.
I bought a NAS system to leave at remote location, and I needed to be able to synchronize with it. It offers the accessibility via FTP, but I've been having some issues with it. Some Googling turned up this: http://www.blisstonia.com/eolson/notes/smboverssh.php
Basically, the gist of what Edwin Olson is saying is you make a new loopback network interface in windows, give it some private IP, and use PuTTY to SSH forward to that interface on port 139. Apparently PuTTY lets you put in an interface IP to bind to. Vista users will have to tunnel 445 to 139 as well (silly Vista). The source IP will be the IP of the loopback interface, and the destination IP will be the IP of the thing you're trying to SMB to, from the remote connection's perspective (you have to connect to the IP first).
The important part of making the loopback interface is turning OFF file and printer sharing, and putting in real IPs for the gateway and the DNS server. You also have to turn on LMHosts lookup and disable NetBIOS over TCP/IP.
Olsen also suggests you get a patch from Microsoft: http://support.microsoft.com/?id=884020, which fixes some problem with XPSP2's loopback interface.
All of this stuff is from Edwin Olson's site, but I paraphrased the important bits here just in case his server dies or somesuch.