mythweb.postinst: 31: Syntax error: Bad substitution (fix is to use Bash instead)

Bug #63493 reported by ironstorm
26
Affects Status Importance Assigned to Milestone
mythplugins (Ubuntu)
Fix Released
High
Reinhard Tartler

Bug Description

Version: 0.20-0.4ubuntu1

Shell should be bash rather then sh, here's the patch:
--- /var/lib/dpkg/info/mythweb.postinst.orig 2006-09-30 01:27:29.000000000 -0400
+++ /var/lib/dpkg/info/mythweb.postinst 2006-09-30 01:25:42.000000000 -0400
@@ -1,4 +1,4 @@
-#! /bin/sh
+#!/bin/bash

 set -e

description: updated
Revision history for this message
ironstorm (ironstorm-gmail) wrote :

Same issue persists in the latest package.... Please look at including the patch in the previous posting.

Setting up mythweb (0.20-0.6ubuntu2) ...
/var/lib/dpkg/info/mythweb.postinst: 31: Syntax error: Bad substitution
dpkg: error processing mythweb (--configure):
 subprocess post-installation script returned error exit status 2
Errors were encountered while processing:
 mythweb

Revision history for this message
ironstorm (ironstorm-gmail) wrote :

It seems the stuff I've reported so far on myth and LCDproc sits unconfirmed/unassigned and I have to re-fix with each package rev update... I'm curious if there there a way to get my bug reports noticed a bit quicker (I do include fixes where I find them)? Is there something else on Launchpad I should be doing also? Do people generally announce their bugs on IRC or something?

Cheers,
-G

aent (aent)
Changed in mythweb:
status: Unconfirmed → Confirmed
Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

Sebastian can we get the bashism fixed or change the shell required for this to work?

Fabio

Changed in mythplugins:
assignee: nobody → slomo
importance: Undecided → High
Revision history for this message
Colin Watson (cjwatson) wrote :

Fixing the bashism would involve changing all lines of the form:

  DEFAULTS=${DEFAULTS/db_server/db_host}

... to:

  DEFAULTS="$(printf %s "$DEFAULTS" | sed 's/db_server/db_host/')"

(Test this first!)

Changed in mythplugins:
assignee: slomo → siretart
status: Confirmed → In Progress
status: In Progress → Fix Committed
Revision history for this message
Mario Limonciello (superm1) wrote :

Attached is a patch to fix this, as well as fix the application detecting the user name, database, password, and mysql server for the machine mythweb is being installed on.

Changed in mythplugins:
status: Fix Committed → In Progress
Revision history for this message
Reinhard Tartler (siretart) wrote :

Changes:
 mythplugins (0.20-0.6ubuntu4) edgy; urgency=low
 .
   * Make mythweb.postinst use bash instead of sh (Closes Ubuntu: #63493)
Files:
 30f21268dc8f28d63862287d17d30f68 1271 graphics optional mythplugins_0.20-0.6ubuntu4.dsc
 920c0ff4beb988d86a19c8229ef3348d 15603 graphics optional mythplugins_0.20-0.6ubuntu4.diff.gz

Changed in mythplugins:
status: In Progress → Fix Released
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.