Ubuntu: sudo dpkg error - blank line in value of field 'Maintainer'



Question:

I am running on Ubuntu 12.04 LTS and am trying to install NX. When using a sudo dpkg command for the plugin (nxplugin_3.5.0-6_i386.deb) I get an error.

I have tried a number of things. Other packages seemed to work but not this one. I have looked around quite a bit and it sounds like it might have something to do with the /var/lib/dpkg/status file but all I see in Line 6 of that is:

Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>  

Here is the error:

sudo dpkg -i nxplugin_3.5.0-6_i386.deb  dpkg: error processing nxplugin_3.5.0-6_i386.deb (--install):   parsing file '/var/lib/dpkg/tmp.ci/control' near line 6 package 'nxplugin':   blank line in value of field 'Maintainer'  Errors were encountered while processing:   nxplugin_3.5.0-6_i386.deb  

Any help is appreciated. Thanks,

Jeff


Solution:1

You can easily edit the Control file to work around this. Open gedit or nano and type or paste:

#!/bin/bash    if [[ -z "$1" ]]; then    echo "Syntax: $0 debfile"    exit 1  fi    DEBFILE="$1"  TMPDIR=`mktemp -d /tmp/deb.XXXXXXXXXX` || exit 1  OUTPUT=`basename "$DEBFILE" .deb`.modfied.deb    if [[ -e "$OUTPUT" ]]; then    echo "$OUTPUT exists."    rm -r "$TMPDIR"    exit 1  fi    dpkg-deb -x "$DEBFILE" "$TMPDIR"  dpkg-deb --control "$DEBFILE" "$TMPDIR"/DEBIAN    if [[ ! -e "$TMPDIR"/DEBIAN/control ]]; then    echo DEBIAN/control not found.      rm -r "$TMPDIR"    exit 1  fi    CONTROL="$TMPDIR"/DEBIAN/control    MOD=`stat -c "%y" "$CONTROL"`  vi "$CONTROL"    if [[ "$MOD" == `stat -c "%y" "$CONTROL"` ]]; then    echo Not modfied.  else    echo Building new deb...    dpkg -b "$TMPDIR" "$OUTPUT"  fi    rm -r "$TMPDIR"  

Same the file as debedit.sh, and make it executable with chmod +x debedit.sh.

Then, run debedit.sh nxplugin_3.5.0-6_i386.deb for the file, and edit the correct line (or add it). Save, and then run sudo dpkg -i nxplugin_3.5.0-6_i386.deb.modified.deb (the name may differ a bit), and enjoy!

Source: http://ubuntuforums.org/showthread.php?t=636724


Solution:2

Sounds like the package is broken (technical: the control file is invalid). Maybe you could ask the author of the package to fix it.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »