How to Modify the Dependency of Debian Package in Ubuntu 14.04

I had added a ppa to run a newer version of mythtv and mysql-server than the current supported software. This led to software update failures due to failed dependencies. I am running mythubuntu 14.04 and this post will show how to change the dependency requirement of a software package so that it will install. This method will use a bash script to save some time. The script uses the nano text editor to change the file. Terminal commands will look like this sentence.

  • Download the script “”
  • Change to the directory you want to download the package to
    • cd ~/Downloads/mythtv-27
  • Download the mythtv package to modify
    • sudo apt-get download mythtv
  • List contents of directory to see file name of the downloaded file
    • ls -l
      • mythtv_2%3a0.27.4+fixes.20150423.8f14d3d-0ubuntu0mythbuntu3_all.deb
        -rw-r–r– 1 root root  77K Apr 25 08:09
  • Modify mythtv package
    • mythtv_2%3a0.27.4+fixes.20150423.8f14d3d-0ubuntu0mythbuntu3_all.deb
      • Change the following line
        • Depends: mysql-server
        • Change to this
          • Depends: mysql-server | mysql-server-5.6
        • This allows the package to use mysql-server or mysql-server-5.6
      • Save file
        • ctrl + o in nano
  • View new modified mythtv file
    • ls -l
      • mythtv_2%3a0.27.4+fixes.20150423.8f14d3d-0ubuntu0mythbuntu3_all.modfied.deb
  • View package contents and order of files (important)
    • less mythtv_2%3a0.27.4+fixes.20150423.8f14d3d-0ubuntu0mythbuntu3_all.modfied.deb
  • Install modified mythtv file
    • sudo dpkg -i mythtv_2%3a0.27.4+fixes.20150423.8f14d3d-0ubuntu0mythbuntu3_all.modfied.deb
  • Done

Leave a Reply

Your email address will not be published. Required fields are marked *