Wednesday, August 31, 2011

Re: Installing on OSX 10.4.7

On 8/31/2011 11:03 AM, Taylor Hedberg wrote:
David Fishburn, Wed 2011-08-31 @ 10:28:51-0400: 
This is where the problem starts. As I am trying to use this from the console (only), the site also provides a shell script to be used to launch Vim.          Also download http://macvim.org/OSX/files/gvim ->         This I copied to /usr/bin/gvim  When I attempt to use it I get:  -bash-2.05b$ ./gvim ./gvim: line 1: basename: command not found dyld: Library not loaded: /System/Library/Perl/lib/5.8/libperl.dylib   Referenced from: /Applications/Vim.app/Contents/MacOS/Vim   Reason: image not found Trace/BPT trap   The script only references basename once:  # Next, peek at the name used to invoke this script, and set options # accordingly. name="`basename "$0"`"   I don't see anything wrong with that, nor do I really know what it is for. 
 I'm not sure why you need a shell script to launch Vim, but ignoring that...  basename is just a simple tool that strips off the "path prefix" of a pathname. So if you type `basename /foo/bar/baz` at a shell prompt, it will print "baz".  The `$0` is shell syntax which is expanded to the name used to invoke the script on the command line. So if you run the script as `./myscript`, then `$0` would be replaced with "./myscript" and `basename $0` would be "myscript".  So if your AppleTV doesn't have basename available, you can replace that line with something like this, and it should do the same thing:      name="myscript"  where "myscript", of course, is the command you're using to invoke the script, minus the /path/to/script/ prefix, if any exists.  
Thanks Taylor.

Perhaps it just boils down to this (without using the shell script):

-bash-2.05b$ /Applications/Vim.app/Contents/MacOS/Vim dave.txt
dyld: Library not loaded: /System/Library/Frameworks/Python.framework/Versions/2.3/Python
  Referenced from: /Applications/Vim.app/Contents/MacOS/Vim
  Reason: image not found
Trace/BPT trap


Looking at the version I downloaded:


vim7.0.224.tar.bz2 (6448148 bytes, last modified 2007/03/30)
vim 7.0.224 Universal Binary: stable
Comments: +cscope +perl +python +ruby +tcl
+atsui and guitab experimental patches


So, it has the +perl, +python and so on.
I was able to create some links to get around the Perl error (Perl is already installed in a different directory), but I wonder if Vim is failing to launch since it cannot file these libraries.

I thought Vim was supposed to just not load it and continue, but perhaps it is different on OSX?  It becomes fatal if it cannot load the libraries.

Anyway, there does not appear to be any command lines switches to disable the attempt to load these libraries.


Dave

No comments: