ports/113468: print/acroread7 - PATCH (dirty workaround) - acroread shell script produces error when $version is empty
parv at pair.com
parv at pair.com
Fri Jun 8 02:20:03 UTC 2007
>Number: 113468
>Category: ports
>Synopsis: print/acroread7 - PATCH (dirty workaround) - acroread shell script produces error when $version is empty
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Fri Jun 08 02:20:02 GMT 2007
>Closed-Date:
>Last-Modified:
>Originator: Parv
>Release: FreeBSD 6.2-STABLE i386
>Organization:
>Environment:
System: FreeBSD holestein.holy.cow 6.2-STABLE FreeBSD 6.2-STABLE #1: Fri May 25 16:16:36 EDT 2007 root at holestein.holy.cow:/work/obj/misc/src-6/sys/BOVINE-T42.6 i386
Installed version is acroread7-7.0.9_1,1.
Linux ports (base & such) have been recompiled & reinstalled after
installing xorg 7.2.
My interactive shell is zsh 4.3.2_1.
>Description:
acroread (shell script) produces the following message ...
/misc/local/Adobe/Acrobat7.0/ENU/bin/acroread: line 486: [: -ge: unary operator expected
... which does not prevent the actual program to be launched).
Running with -x option around $version assignment ...
480 set -x
481 version=`get_gtk_file_ver "$ifile"`
482 set +x
... produces ...
++ get_gtk_file_ver /misc/local/lib/libgtk-x11-2.0.so
++ '[' -f /misc/local/lib/libgtk-x11-2.0.so ']'
++ '[' -h /misc/local/lib/libgtk-x11-2.0.so ']'
+++ readlink /misc/local/lib/libgtk-x11-2.0.so
++++ /bin/pwd
+++ OLDPWD=/misc/home/parv
+++ lfile=/misc/local/lib/libgtk-x11-2.0.so
+++ '[' -h /misc/local/lib/libgtk-x11-2.0.so -a -f /misc/local/lib/libgtk-x11-2.0.so ']'
++++ dirname /misc/local/lib/libgtk-x11-2.0.so
+++ CWD=/misc/local/lib
++++ expr /misc/local/lib : '\.\.'
+++ '[' 0 = 2 ']'
++++ basename /misc/local/lib/libgtk-x11-2.0.so
+++ lfile=libgtk-x11-2.0.so
+++ cd /misc/local/lib
++++ /bin/ls -l libgtk-x11-2.0.so
++++ sed 's/^.*-> *\(.*\) *$/\1/'
+++ lfile=libgtk-x11-2.0.so.0
+++ '[' -h libgtk-x11-2.0.so.0 -a -f libgtk-x11-2.0.so.0 ']'
+++ '[' -f libgtk-x11-2.0.so.0 ']'
++++ dirname libgtk-x11-2.0.so.0
+++ CWD=.
++++ basename libgtk-x11-2.0.so.0
+++ lfile=libgtk-x11-2.0.so.0
++++ expr . : '\.\.'
+++ '[' 0 = 2 ']'
+++ cd .
++++ /bin/pwd
+++ echo /misc/local/lib/libgtk-x11-2.0.so.0
+++ cd /misc/local/lib
+++ return 0
++ ifile=/misc/local/lib/libgtk-x11-2.0.so.0
++ '[' 0 -eq 1 ']'
+++ basename /misc/local/lib/libgtk-x11-2.0.so.0
++ mfile=libgtk-x11-2.0.so.0
++ echo libgtk-x11-2.0.so.0
++ grep -q 'libgtk-x11-\([0-9]*\).0.so.0.\([0-9]*\).\([0-9]*\)'
++ '[' 1 -ne 0 ']'
++ return 1
+ version=
+ set +x
/misc/local/Adobe/Acrobat7.0/ENU/bin/acroread: line 488: [: -ge: unary operator expected
>How-To-Repeat:
Try to run above acroread version.
>Fix:
This is only a dirty workaround around the actual problem, but should
be considered to make the script robust ...
--- acroread.old Fri Jan 5 14:56:39 2007
+++ acroread Thu Jun 7 16:59:05 2007
@@ -479,6 +479,15 @@
for ifile in `/sbin/ldconfig -p|grep "libgtk-x11-2.0.so$"|sed 's/.*[ \t]*=>[ \t]*\(.*\)/\1/g' 2>/dev/null`; do
version=`get_gtk_file_ver "$ifile"`
+ case "$version" in
+ "" )
+ return 0
+ ;;
+
+ *)
+ ;;
+ esac
+
while [ ${#version} -gt ${#base_version} ]; do
base_version="${base_version}0"
done
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list