First off, I'll try to answer the questions, with suggested solutions. A "simple" solution is at the bottom of this post.
I have just looked now through the INSTALL document that comes with the distribution. I will highlight extracts from INSTALL below in bold.
I am running Python 2.6.5, according to output from 'python -V' command.
Good. After my post yesterday I tried Python 3.x and it doesn't work. As a side question I'm wondering when I need to do the conversion. I think the conversion itself won't be too much work, but I don't want to maintain 2 versions ...
MMA consists of several parts. They should be installed as follows:
1. The main executable script, mma, should be in /usr/local/bin or
somewhere else in your executable path.
Is 'mma' the same file as 'mma.py'? Am I supposed to rename this file, or set its permissions?
Yes, and yes. It's just easier to type "mma" than "mma.py". In the install scripts I use the main exec is renamed. Your choice. I should add that one reason the exec is distributed as "mma.py" is due to my not-to-bright choice of using "MMA" as the name for the modules directory. If you run mma in a non-case-sensitive environment (DOS, windows) you'll run into a name problem if you have the modules MMA and the exec mma in the same directory.
The linux install scripts just copy "mma.py" to "mma". Permissions are already set.
My $PATH is currently /opt/local/bin:/opt/local/sbin:/sw/bin:/sw/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin:/usr/X11R6/bin
Although my $PATH includes /usr/local/bin, this directory does not, in fact, exist.
You should be able to create the directory /usr/local/bin simply by getting administrator rights. Someone with Mac-knowledge will need to give details here. This might help:
http://support.apple.com/kb/HT4103?viewlocale=en_US2. A number of modules which MMA needs. They should be installed in
/usr/local/share/mma/MMA.
What files are these "modules"? What folder in the distribution contains them? There is no folder named "modules".
Yes, these are the .py files in MMA. The exec looks for these in a number of locations:
- in the directory in which the exec lives,
/usr/local/share/mma,
/usr/share/mma
'.' -- your current directory
3. Some other files used by the library and user extensions. These are
installed in /usr/local/share/mma/includes.
Again, mma looks for this file in the same location as above. This time it's looking for "lib" and "includes". So, wherever MMA lives, so should "lib".
There is currently no /usr/local/share directory on my machine, althogh /usr/local exists. I am unable to create such a directory (presumably a permissions issue). Which files are being referred to above? I am unsure what permissions I should be changing /usr/local to. I don't want to create a security hole on my machine.
Again, I'm not familiar with Mac permissions (to tell the truth, though, there's not a lot of difference between mac and linux in this department). But, I would assume that the default permissions would be fine. Just change to root/admin and create the directory. Most likely: "sudo mkdir /usr/local/bin" or "sudo mkdir /usr/local/share/mma" will do just fine.
4. The standard MMA library. These are a number of style files. They
are installed in /usr/local/share/lib.
Again, this directory doesn't exist, and I don't appear to have permission to create it.
Same issues, see above.
The install scripts supplied point to locations that do not exist by default in Mac OS X version 5.
You might want to try a few "simple" things.
1. try using the cp-install script ... pretend this is linux. You would need to use a command just like on linux "sudo cp-install" or perhaps "sudo python cp-install" If you get errors about the directories not existing, try creating them (above) and run it again.
2. You can run mma from the place you've extracted the tarball.
- not recommended, but it works, is to move your song file to the root mma directory. Now, you can do something like "mma.py mysong" and it should work. Problem: all your songs need to be in the same location.
- better, but I really think a proper install makes more sense, is to write a little script which will find your mma and compile the song. Something like a one line script (you'll need to work on this!): "/usr/MYNAME/MYDIR/somewhere/mma.py %s" should get you started.
However, a proper install should be easy enough! Please work though the suggestions above and let us (me) know what works, etc. We'll figure it out and then update the instructions (in the meantime I'm going to update some the stuff you've pointed out as out-of-date or confusing.
Question: Should the install scripts attempt to create directories? Perhaps I should have a little script "create directories" for new macs to create the /usr/local/share/mma directory, or just add it to the current (perhaps with a prompt). It appears that both linux and mac support the -p options so it'd be easy to have a line in the scripts "mkdir -p /usr/local/share/mma". Someone with a mac please reply!