xdict install script fails when dictd absent

Bug #683749 reported by Dennis Walters
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
dict-xdict (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: dict-xdict

I tried to install an English-Chinese dictionary package called xdict. The install failed. I tried to uninstall. That failed too. Synaptic gave me this error message.
>
> E: dict-xdict: subprocess installed post-removal script returned error
> exit status 100
>
> After that, every time I try to do anything with synaptic, I get this same
> error, and it seems my other install actions are not all being done.
 I was able to work around the problem by installing dictd.

Thanks to Jeff Jansen for clarifying the problem as below.

The install script should require dictd to install xdict, or if it doesn't require dictd, then the postinst and
postrm files should *not* assume it's installed.

The problem is probably this section in the postrm script:

   # if [ -x /etc/init.d/dictd ]; then /etc/init.d/dictd restart; fi
   if which invoke-rc.d >/dev/null 2>&1; then
       invoke-rc.d dictd restart
   else
       /etc/init.d/dictd restart
   fi

The script used to check if 'dictd' was installed and if so restarted
it. But they changed it to just restart dictd without checking.

Let's check to see if this package requires dictd - it seems like it should.

#check the requirements of the package
less control

  Package: dict-xdict
  Architecture: all
  Suggests: dictd | serpento, dict | opendict | kdict
  Provides: dictd-dictionary

So it suggests a number of packages, but doesn't actually require any of
them.

Do you have dictd installed? I'm guessing NO, and I bet that's why the
install failed. Let's see if the installer also assumes dictd is installed:

#read the post installation script
less postinst

  # if [ -x /etc/init.d/dictd ]; then /etc/init.d/dictd restart; fi
  if which invoke-rc.d >/dev/null 2>&1; then
      invoke-rc.d dictd restart
  else
      /etc/init.d/dictd restart
  fi

Yup, same problem. The installation script also assumes you have dictd
installed and restarts it to pick up the changes. If it's not
installed, then the installation fails. And then the uninstall fails -
vicious cycle.

ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: dict-xdict 0.1-4
ProcVersionSignature: Ubuntu 2.6.32-26.48-generic 2.6.32.24+drm33.11
Uname: Linux 2.6.32-26-generic x86_64
Architecture: amd64
Date: Wed Dec 1 10:57:11 2010
Dependencies:

EcryptfsInUse: Yes
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=en_US:en
 LANG=en_US.utf8
 SHELL=/bin/bash
SourcePackage: dict-xdict

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.