On Tue, 5 Jul 2005 08:56:39 +0200
Jesus Climent <[EMAIL PROTECTED]> wrote:
> http://erconde.hispalinux.es/~data/files/
Installed it with:
% feta install
http://erconde.hispalinux.es/~data/files/abcde_2.3.0-1_all.deb
On running it, I see:
% abcde ; echo $?
/usr/bin/abcde: 627: Syntax error: Bad substitution
2
...line #627 is:
% cat -n /usr/bin/abcde | grep " 627"
627 IN=${!TEMPARG}
...where "${!" is a bashism. My '/bin/sh' links to 'dash' -- I prefer
it because 'dash' is often 2x-4x faster.
Here are two ways to fix the bashism:
1) any bashisms should be replaced with POSIX shell code.
2) 'dlocate' should depend on 'bash' and its first line:
#!/bin/sh
should be replaced with:
#!/bin/bash
Unfortunately, after trying step #2 there, I get:
% abcde ; echo $?
/usr/bin/abcde: line 1237: syntax error near unexpected token `}'
/usr/bin/abcde: line 1237: `}'
2
The code in question seems to be an empty function, which 'bash' doesn't like:
% cat -n /usr/bin/abcde | grep -B 3 1237
1234 do_mkcue()
1235 {
1236
1237 }
So I added a 'return' to line #1236, and ran it. And it seems to work
OK, (today, anyway). If its useful, attached is a patch containing
these minor changes.
HTH...
--- abcde 2005-07-05 02:32:36.000000000 -0400
+++ /usr/bin/abcde 2005-07-05 12:09:35.000000000 -0400
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
# Copyright (c) 1998-2001 Robert Woodcock <[EMAIL PROTECTED]>
# Copyright (c) 2003-2004 Jesus Climent <[EMAIL PROTECTED]>
# This code is hereby licensed for public consumption under either the
@@ -1233,7 +1233,7 @@
do_mkcue()
{
-
+ return
}
# do_cddbparse