3
votes

I installed cygwin om windows 7.

I also need to install some packages, when I try to use the command-

 apt-get install gstreamer-dbus-media-service gstreamer-tools gstreamer0.10-alsa gstreamer0.10-buzztard gstreamer0.10-buzztard-doc gstreamer0.10-crystalhd gstreamer0.10-doc gstreamer0.10-ffmpeg gstreamer0.10-ffmpeg-dbg gstreamer0.10-fluendo-mp3 gstreamer0.10-gconf gstreamer0.10-gnomevfs gstreamer0.10-gnonlin gstreamer0.10-gnonlin-dbg gstreamer0.10-gnonlin-doc gstreamer0.10-hplugins gstreamer0.10-nice gstreamer0.10-packagekit gstreamer0.10-plugins-bad gstreamer0.10-plugins-bad-doc gstreamer0.10-plugins-bad-multiverse gstreamer0.10-plugins-base gstreamer0.10-plugins-base-apps gstreamer0.10-plugins-base-dbg gstreamer0.10-plugins-base-doc gstreamer0.10-plugins-cutter gstreamer0.10-plugins-good gstreamer0.10-plugins-good-doc gstreamer0.10-plugins-ugly gstreamer0.10-plugins-ugly-doc gstreamer0.10-pocketsphinx gstreamer0.10-pulseaudio gstreamer0.10-qapt gstreamer0.10-sdl gstreamer0.10-tools gstreamer0.10-vaapi gstreamer0.10-vaapi-doc gstreamer0.10-x

I get this error:

bash: apt-get: command not found

I saw similar problems and solutions, for example- this link

https://code.google.com/p/apt-cyg/

but its not working

edit: I followed the command and this is the error I get:

$ apt-cyg install nano
/usr/bin/apt-cyg: line 19: $'\r': command not found
/usr/bin/apt-cyg: line 27: syntax error near unexpected token `||'
'usr/bin/apt-cyg: line 27: `  || test "-$GAWK-" = "--" || test "-$XZ-" = "--"

I will be happy for some help.

thank you.

1
Since this answer (stackoverflow.com/questions/9751845/apt-get-for-cygwin) points at the same link you have linked, and you claim it does not work, we could best help you if you explained why it did not work.merlin2011
I edited my question. thank you. the link I provide is from the answer with the 35 "likes"user3378689
@user3378689 The "likes" are known as upvotes, and their opposite, downvotes.user5413945

1 Answers

3
votes

The error that you show seems to be related to Windows-style newlines messing up cygwin.

If you have dos2unix available, try running dos2unix apt-cyg on wherever apt-cyg is.

If you do not have dos2unix, take a look at this question for where to install it from.

Also, take a look at this related question.

Clarification on Usage:

  1. Run dos2unix on the file apt-cyg only. That is, run the command dos2unix apt-cyg. The purpose is to "fix" the file apt-cyg, so that it will work properly, where it is failing now.
  2. Run apt-cyg the same way you did in your question. Do not prepend the command with dos2unix.