Find the answer to your Linux question:
Results 1 to 8 of 8
First of all, I'm VERY new to Ubuntu, and Linux for that matter. I have under 1 weeks worth of experience. However, I am a quick learner. A package I ...
  1. #1
    Just Joined!
    Join Date
    Feb 2007
    Posts
    4

    Broken packages.

    First of all, I'm VERY new to Ubuntu, and Linux for that matter. I have under 1 weeks worth of experience. However, I am a quick learner.

    A package I was recently trying to install needed gcc/g++. After a failed install (due to the base package dependency missing), I had 4 broken packages.

    Runnning apt-get check gave me:
    Code:
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    You might want to run ‘apt-get -f install’ to correct these.
    The following packages have unmet dependencies.
      cpp-4.1: Depends: gcc-4.1-base (= 4.1.1-13ubuntu5) but 4.1.1-21 is installed
      gcc-4.1: Depends: gcc-4.1-base (= 4.1.1-13ubuntu5) but 4.1.1-21 is installed
      libgcc1: Depends: gcc-4.1-base (= 4.1.1-13ubuntu5) but 4.1.1-21 is installed
      libstdc++6: Depends: gcc-4.1-base (= 4.1.1-13ubuntu5) but 4.1.1-21 is installed
    E: Unmet dependencies. Try using -f.
    So, I went on to try apt-get -f install which gave:
    Code:
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    Correcting dependencies...Done
    The following packages were automatically installed and are no longer required:
      xserver-xorg python-crypto xkeyboard-config f-spot libpopt-dev
      libgnomecupsui1.0-1c2a libopenexr2c2a gstreamer0.10-alsa liborbit2-dev
      python-alsaaudio mesa-utils xgamma xserver-xorg-video-rendition gcj-4.1-base
      xclipboard liblaunchpad-integration0 libcamel1.2-8 libopenobex-1.0-0
      libwpd8c2a libarts1c2a libxmlsec1 libstdc++5 libstdc++6 tomboy xf86dga
      libglib-perl evolution-webcal ekiga libglew1 edgy-community-wallpapers 
      gnome-cups-manager bitpim gsfonts-x11 dselect gnome-panel-data
      ssh-askpass-gnome xserver-xorg-video-cirrus linux-headers-2.6.17-10-generic
      sound-juicer libpisync0 hplip-data lftp libsdl-image1.2 libgdl-1-common
      libfaac0 libpanelappletmm-2.6-dev liba52-0.7.4 xditview libxine1 xutils-dev
      libsmpeg0...
    Use 'apt-get autoremove' to remove them.
    The following packages will be REMOVED
      acidrip acpi-support acroread adonthell amarok amarok-xine amsynth apache
      apache-common apache2-common apache2-mpm-prefork apollon apport apport-gtk
      apt apt-utils aptitude ark aspell audacity banshee beast beneath-a-steel-sky
      billard-gl bitpim bitpim-lib bluez-cups cdrdao cpp cpp-4.1 craft cupsys
      cupsys-driver-gutenprint deskbar-applet 
    WARNING: The following essential packages will be removed.
    This should NOT be done unless you know exactly what you are doing!
      apt libgcc1 (due to apt) libstdc++6 (due to apt)
    0 upgraded, 0 newly installed, 308 to remove and 0 not upgraded.
    Need to get 0B of archives.
    After unpacking 1154MB disk space will be freed.
    You are about to do something potentially harmful
    To continue type in the phrase ‘Yes, do as I say!’
    NOTE: For the sake of the length, I shortened the list of packages above.

    Something tells me that shouldn't be happening? Is it ok to confirm? Am I really going to lose practically all my installed packages if I attempt to fix the 4 broken ones? Is there a way around this?

    Any help is appreciated!

  2. #2
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,316
    hi moshdj2uk !

    Welcome to the LinuxForums.

    Something tells me that shouldn't be happening? Is it ok to confirm? Am I really going to lose practically all my installed packages if I attempt to fix the 4 broken ones? Is there a way around this?
    its not OK to confirm it coz you will lose all the base packages and system will become unusable.

    to fix this problem, execute this
    Code:
    sudo dpkg --configure -a
    for gcc and g++, install build-essential package.
    Code:
    sudo apt-get install build-essential




    Casper
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  3. #3
    Just Joined!
    Join Date
    Feb 2007
    Posts
    4
    Thanks for the response.

    I've tried what you suggested but I still get the 'broken packages' message, so can't insall build-essential.

  4. #4
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,316
    try to force it, use -f option.
    Code:
    sudo apt-get -f install <package>






    Casper
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  5. #5
    Just Joined!
    Join Date
    Feb 2007
    Posts
    4
    Same thing I'm afraid.

  6. #6
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,316
    okkk ! did you add any new source in sources.list? i think sources are conflicting.









    Casper
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  7. #7
    Just Joined!
    Join Date
    Feb 2007
    Posts
    4
    I was told to try sudo aptitude install gcc-4.1-base/edgy on the Ubuntu Forums, which appears to have fixed the problem for now.

    The URLs in my sources.list all point to the Ubuntu archive.

  8. #8
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,316
    okk ! it means base/edgy is not in your sources.list.
    generate a new reliable sources.list through source-o-matic. it will resolve all the conflicts in future.







    Casper
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...