Jump to content


Photo
- - - - -

Cygwin on USB thumbdrive?


  • Please log in to reply
10 replies to this topic

#1 Aghaster

Aghaster

    The Frenchman

  • Agents of the Revolution
  • 2,093 posts
  • Country:
  • Gender:Male
  • Location:Quebec, Canada

Posted 14 November 2006 - 02:16 PM

I've installed MinGW on my usb thumbdrive so that I can plug it in a computer a school, open a command prompt, add it to the path and then start coding C.

Now I'm reading about UNIX programming, and unfortunately there is no UNIX system at school, only Windows computers. Cygwin would be a nice tool that would let me code UNIX programs, so I'd like to install it on my usb thumbdrive.

While installing MinGW on a usb thumbdrive was as simple as copying the files on it, cygwin comes with an installer package - maybe I missed that part, but can we do a manual installation just like with MinGW? this would probably be better for a usb thumdrive, so that the installation doesn't expect the root drive to be C:, for example, but maybe E: or I:.

Any idea?

#2 Alk3

Alk3

    "I Hack, therefore, I am"

  • Binrev Financier
  • 1,003 posts
  • Gender:Not Telling
  • Location:312 Chi-town

Posted 14 November 2006 - 02:38 PM

I have a better option. You can use Windoze and Linux commands. Its a ksh app. Let me dig it up and I will edit and post it.

[EDIT:]
http://linuxhelp.blo...or-windows.html
http://www.research..../sw/tools/uwin/

Is that what you are looking for?

Alk3

Edited by Alk3, 14 November 2006 - 02:43 PM.


#3 Aghaster

Aghaster

    The Frenchman

  • Agents of the Revolution
  • 2,093 posts
  • Country:
  • Gender:Male
  • Location:Quebec, Canada

Posted 14 November 2006 - 02:43 PM

Interesting. I will wait for your post.

EDIT: You edited while I replied, lol ;)

"UWIN contains:

Libraries that emulate a UNIX environment by implementing the UNIX Application Programming Interface (API)
Include files and development tools such as cc(1), yacc(1), lex(1), and make(1).
ksh(1) (the Korn Shell) and over 250 utilities such as ls(1), sed(1), cp(1), stty(1), etc"

Seems like what I'm looking for, but cygwin does that too. I'll give UWIN a try, but if somebody else can answer for cygwin I'd appreciate it.

Edited by Aghaster, 14 November 2006 - 02:47 PM.


#4 Alk3

Alk3

    "I Hack, therefore, I am"

  • Binrev Financier
  • 1,003 posts
  • Gender:Not Telling
  • Location:312 Chi-town

Posted 14 November 2006 - 02:50 PM

I thought it would be a good thing to share, since thats what we are using as a *NIX environment in our scripting class (for those who do not have Linux or the like). Its really powerful since you can use _both_ OS commands. I havent used cygwin, but from what I understand, you can only use *NIX commands, is that right?

#5 Dr. Z2A

Dr. Z2A

    Dangerous free thinker

  • Members
  • 845 posts
  • Gender:Male
  • Location:San Francisco

Posted 14 November 2006 - 07:36 PM

if you are still wanting to use Cygwin on your thumb drive theres nothing special you have to do. I installed it on mine the other day just by running the installer and installing it onto my flash drive and it runs fine. Personally I think I'll take it off though and try out UWIN. Never heard of that one before.

#6 jabzor

jabzor

    hax?

  • Agents of the Revolution
  • 1,146 posts
  • Country:
  • Gender:Male
  • Location:Northern Elbonia, fighting the lefties

Posted 14 November 2006 - 08:21 PM

Doc'Z - will that work at a school where I am assuming he has no admin rights?
Installing to the flashdisk will allow it to work on the machine you installed it with, what about portability?

I havent used cygwin, but from what I understand, you can only use *NIX commands, is that right?

You can use whatever combination of commands you like, in either the cygwin shell or the native windows cmd. :D

Typing 'ipconfig' in cygwin will pull up your windows ip info using the windows exe
Typing 'chmod --help' will bring up the cygwin util in either cygwin or cmd.
Mix and match as you please, what restrictions? :)

I am constantly combining cygwin and windows commands together as I use either win or lin intermediately it's just more natural.

I have NOT done any C posix programming, but I have done perl posix in both win&lin, perl handles sockets and pipes VERY nicely, some of the sub.item functions are busted in Windows as they have had to work around a lot (and they were written originally for *nix using the true posix). ^_^

#7 kitche

kitche

    Hakker addict

  • Members
  • 549 posts

Posted 16 November 2006 - 12:12 PM

I tried this and in reality you can't do it since if you try to run cygwin on a nother machine besides the one that you installed it to the usb on you will get can not find errors

#8 R3c0n

R3c0n

    SUPR3M3 31337 Mack Daddy P1MP

  • Members
  • 411 posts
  • Location:Daytona, Florida

Posted 16 November 2006 - 01:45 PM

Cygwin on a portable drive would sure be gangs'ta

#9 HaNoCr

HaNoCr

    HACK THE PLANET!

  • Members
  • 61 posts
  • Location:Germany

Posted 19 November 2006 - 11:15 AM

Am I wrong, or is UWIN ShareWare?

HaNoCr

#10 Seal

Seal

    Not a fan of clubs.

  • Agents of the Revolution
  • 2,440 posts
  • Country:
  • Gender:Male
  • Location:Canada

Posted 19 November 2006 - 12:35 PM

I tried this and in reality you can't do it since if you try to run cygwin on a nother machine besides the one that you installed it to the usb on you will get can not find errors


That's because Cygwin runs off the Windows shell, and so for it to know where to launch the Cygwin apps from you'd have to edit the environment variables in the OS. That's unlikely to happen unless you have admin access to the box. That is unless instead of doing something like "ls" you'd do "B:\usr\bin\ls.exe" or whatever. Even so, I don't know how well it would function in a system with limited privileges.

I thought it would be a good thing to share, since thats what we are using as a *NIX environment in our scripting class (for those who do not have Linux or the like). Its really powerful since you can use _both_ OS commands. I havent used cygwin, but from what I understand, you can only use *NIX commands, is that right?

Yes it does, actually. To note though that it won't recognize commands with non exe file extensions. Those extensions have to be defined. So for instance, "tree" doesn't work; but "tree.com" will.

#11 Alk3

Alk3

    "I Hack, therefore, I am"

  • Binrev Financier
  • 1,003 posts
  • Gender:Not Telling
  • Location:312 Chi-town

Posted 20 November 2006 - 04:06 PM

Am I wrong, or is UWIN ShareWare?

HaNoCr

UWIN is not released under the GPL but is free to download and use for educational and non-commercial purposes.

http://linuxhelp.blo...or-windows.html
http://www.research..../sw/tools/uwin/

Edited by Alk3, 20 November 2006 - 04:14 PM.





BinRev is hosted by the great people at Lunarpages!