aggelopoulos@gmail.com happy to help test Mac versions of modules e.g. export_output.py
Working:
Installable but not yet working properly:
Not installable:
Open SOFA Statistics from Go>Applications>SOFA Statistics
# http://developer.apple.com/library/mac/#documentation/Darwin/Reference/ManPages/man1/hdiutil.1.html # http://www.myersdaily.org/joseph/notes/macosx2/man/hdiutil.1.html # http://ss64.com/osx/cp.html echo "Enter version number e.g. 1.0.7:" read version dmg2make="/Users/g/Desktop/sofastats-${version}_for_mac.dmg" # (no spaces around =) rm -f "$dmg2make" rm -rf "/Users/g/Desktop/sofastatistics/sofastatistics.mpkg" cp -R "/Users/g/sofa_mpkg/build/sofastatistics.mpkg" "/Users/g/Desktop/sofastatistics/" # ov - overwrite if already there hdiutil -verbose create "$dmg2make" -srcfolder "/Users/g/Desktop/sofastatistics" -ov -megabytes 85 -volname "SOFA Statistics" echo "FINISHED"
Handles pkgs and file transfers.
Use same licence file as for Deb
Transfer main sofa scripts under /Library/sofa
Remember subfolders
Also the following subfolders ready for copying for local user:
Install following packages:
Install sofastatistics.app into /Applications (i.e. make an icon)
NB to enable users to opt out of certain parts of the instalation - e.g. skip Python 2.6.5 because they already have 2.6.3 - must have at least one package which is Unselected. If all packages are selected, the user is assumed to want all of them and gets no choice to have a custom install!
Need VirtualBox 3.2 beta 2
Need iDeneb 1.6 10.5.8 Lite Edition
Do not use efi, or it will not boot into the newly installed virtual HDD
Leave iDeneb connected as the CD so it uses that to boot. Necessary, even though booting onto virtual HDD.
Need at least 15GB space. 30GB seems a safe bet with room for databases etc.
python-2.6.5-macosx10.3-2010-03-24.dmg
wxPython2.8-osx-unicode-2.8.10.1-universal-py2.6.dmg
matplotlib-0.99.1.1-py2.6-macosx10.5.dmg
numpy-1.4.1-py2.6-python.org.dmg
PyMySQL is much easier to install in OS X than MySQLdb.
In my virtualised test installation the user is “mysql” and there is a blank password.
From the terminal it is possible to test if mysql is running:
/usr/local/mysql/bin/mysql
NB may want to install MySQL startup as well as MySQL itself.
Presumably you have already installed MySQL and, optionally, the MySQL utility which makes MySQL run automatically on startup.
PyMySQL is the simple library you need to install that lets SOFA Statistics connect to MySQL: http://code.google.com/p/pymysql/downloads/detail?name=PyMySQL-0.4.tar.gz&can=2&q=
Open the downloaded file onto your Desktop
Open terminal (under Applications>Utilities)
cd Desktop/PyMySQL-0.4
python2.6 setup.py install
(NB python2.6 so the package is installed to the version of Python that SOFA Statistics us)
Open SOFA and configure your connection to MySQL as per http://www.sofastatistics.com/wiki/doku.php?id=help:projects
Success?
NB to test if MySQL is running you can run the following command in the terminal:
/usr/local/mysql/bin/mysql Home
NB I have already installed Python 2.6 from the python.org package python-2.6.5-macosx10.3-2010-03-24.dmg. The 10.3 means it will work with everything 10.3 and above. My version of Leopard is 10.5.8.
Download setuptools-0.6c11-py2.6.egg from here: http://pypi.python.org/pypi/setuptools#downloads. Then, in the terminal:
If you don't have gcc and you are running Leopard, install xcode313_2736_developerdvd.dmg. If you are running Snow Leopard, there is a newer version of Xcode to use, but that is easy to find. This step may require registration with Apple. See http://adcdownload.apple.com/Developer_Tools/xcode_3.1.3_developer_tools/xcode313_2736_developerdvd.dmg.
Must have a version of MySQL installed. I used mysql-5.1.47-osx10.5-x86.dmg. If not installed, then setup.py step for MySQLdb will not succeed.
Download MySQL-python-1.2.3c1.tar.gz from here: https://sourceforge.net/projects/mysql-python/files/mysql-python/1.2.3/MySQL-python-1.2.3.tar.gz/download
Extract on desktop. Do this by opening with … Archive utility.
Then open the folder it created on your desktop - MySQL-python-1.2.3c1. Edit setup_posix.py using IDLE (1) so mysql_config.path = “/usr/local/mysql/bin/mysql_config” not just “mysql_config”. There is another way to do this involving PATH and env etc but this is pretty simple.
1) Set preferences of IDLE to 14px otherwise it is unbearably ugly and spoils the OS X experience
In the terminal:
(see http://trentmick.blogspot.com/2009/05/how-to-install-mysql-python-123c1-on_3622.html)
NB if you mess it up, use rm -rf build to get a proper clean start. The setup.py clean approach is not enough.
sudo python setup.py install
Test by opening IDLE, and typing in import MySQLdb. NB case matters - import mysqldb won't work, nor should it.
postgresql-8.4.4-1-osx.dmg
If not installed, then setup.py step for postgreSQL will not succeed.
add/edit 5 lines to set memory correctly e.g.
kern.sysv.shmmax=16777216 kern.sysv.shmmin=1 kern.sysv.shmmni=64 kern.sysv.shmseg=8 kern.sysv.shmall=32768
See http://www.postgresql.org/docs/8.2/static/kernel-resources.html
shmall is measured in pages. Multiply by 4096 and check that is no less than what is allocated to max.
NB may take several minutes before installer will properly display dialog. Wait at least 10 mins.
Install latest tar.gz from http://initd.org/psycopg/ e.g. http://initd.org/psycopg/tarballs/PSYCOPG-2-4/psycopg2-2.4.2.tar.gz
May have to hardwire location of pg_config in broadly similar fashion to old instructions below. See if any errors which give a clue.
Old instructions (which should work given pgdb is supported as a fallback if psycopg can't import):
In PyGreSQL-4.0.tgz (you can get a copy from ftp://ftp.pygresql.org/pub/distrib/PyGreSQL.tgz - see http://www.pygresql.org/readme.html#where-to-get)
f = os.popen(“pg_config –%s” % s) should be … “/Library/PostgreSQL/8.4/bin/pg_config …”
eclipse-SDK-3.5.2-macosx-carbon.tar.gz
extract and then copy under /Library folder
pydev - http://pydev.org/updates (need to add in Help>Install New Software)
project interpreter - /Library/Frameworks/Python.framework/Versions/2.6/bin/Python
When transferring sofa, and sofa.main, set permissions by cd into folder containing both and
Put sofa.main on Desktop.
Put sofa in home folder (not on desktop).
Delete proj_file_customised.txt
Ensure mime.conf for dokuwiki has the following line:
packproj text/xml
Find the following package files in /Users/g/ under sofa_app, sofa_mpkg, and sofa_pkg. Add proj extension.