Difference between revisions of "Mac OS X:Build from source:fink"

From Gramps
Jump to: navigation, search
m (Minor formatting changes)
(Structure the Mac OS pages)
 
(27 intermediate revisions by 9 users not shown)
Line 1: Line 1:
 +
How to install Gramps on OSX using X11. The process uses fink to install the packages that gramps depends on. Gramps does work, although there are some glitches which are described below.
 +
 +
The author of the fink guide thanks the original author from which that part of the guide was written, and for the help of people on the Gramps list for helping them work through the stumbling blocks!
 +
 +
For a guide of a user who has Gramps 3.0.1 working: [[Mac OS X:Build from source:fink:local]]
 +
 +
The following fink guide applies to Mac OS X 10.4.8, and Gramps 2.2.8. It is not possible to get gramps 2.2.9 to work with fink because you get an error "TypeError: object of type `GtkCellRendererText' does not have property `wrap-mode'" because fink does not yet support the pangocairo packages. Some earlier versions of gramps need additional patches that are not mentioned here.
 +
 +
=== General Caveats ===
 +
 +
* As stated above, these instructions were for installing 2.2.8 on Mac OS X 10.4.8, but should work more widely.
 +
* Production of a guide like this should really only be done after repeating the installation from a clean machine, and repeating again till the guide exactly matches the actual process - doing so would take a lot of time; the authors have each only done the installation once, so your experience will almost certainly differ from theirs.
 +
 
== Installing Gramps on Mac OS X via fink to use X11 ==
 
== Installing Gramps on Mac OS X via fink to use X11 ==
  
=== Mac OS X via fink to use X11 ===
+
* You are installing from the 'unstable' fink tree, so the versions of the packages you install may vary from day to day, and there could be problems with them.
  
This page describes how to install Gramps on OSX using X11. The process uses fink to install the packages that gramps depends on. Gramps does work, although there are some glitches which are described below. Many thanks to the original author from which this guide was written, and for the help of people on the Gramps list for helping me work through the stumbling blocks!
+
=== Installation instructions ===
  
This guide applies to Mac OS X 10.3, and Gramps 2.2.6, but might work with other versions.
+
==== Install X11 ====
  
==== Caveats ====
+
If you  have not already installed X11, install it from the Apple OS X installation disks.
  
* As stated, these instructions were for installing 2.2.6 on Mac OS X 10.4.8, but should work more widely.
+
====Install Developer Tools====
* Production of a guide like this should really only be done after repeating the installation from a clean machine, and repeating again till the guide exactly matches the actual process - doing so would take a lot of time; I have only done the installation once, so your experience will almost certainly differ from mine.
+
 
* The process is not very straightforward, and there will almost certainly be problems like unresolved dependencies, files not found on the various servers, download of files just stalls indefinitely and questions asked by scripts to which you don't know the answer. Nevertheless, installation is possible and I think gramps is worth the trouble. I suggest you have a look at the instructions for [http://www.captnswing.net/2004/02/12/nicotine.html|Installing SoulSeek] - this is a similar process, but actually ''SoulSeek'' is easier because it is fully integrated into the fink process. This might give you some idea of the requirements for perseverance. If you don't think you could install ''SoulSeek'' then you certainly won't be able to install Gramps.  '''The converse is not true'''
+
If you have not already installed the Developer Tools, install them from a recent Apple OS X installation disks (there may be a CD labelled XCode Tools, or an XCode folder on the install DVD). If your installation disk is not very recent, it may be better to download the tools from the [http://developer.apple.com/tools/xcode/ Apple web-site] (free registration required to access the development tools) because some of the build process will not work with an old version of the tools.
* You are installing from the 'unstable' fink tree, so the versions of the packages you install may vary from day to day, and there could be problems with them.
+
 
 +
====Install and update fink====
  
==== Installation instructions ====
+
This was much more difficult than it should have been. From reading some of the fink mailing lists, I think there may have been some problems with updates to the fink mirrors at the time.
  
# If you  have not already installed X11, install it from the Apple OS X installation disks.
+
<ol><li> Download the appropriate version of [http://fink.sourceforge.net/download/index.php?phpLang=en fink]. These instructions were tried with fink 0.8.1. You may need the [http://fink.sourceforge.net/doc/users-guide/ Fink User's Guide].
# If you have not already installed the Developer Tools, install them from a recent Apple OS X installation disks (there may be a CD labelled XCode Tools, or an XCode folder on the install DVD). If your installation disk is not very recent, it may be better to download the  tools from the [http://developer.apple.com/tools/xcode/ Apple web-site] (free registration required to access the development tools) because some of the build process will not work with an old version of the tools.
+
<li> Install fink by opening the disk image and double clicking on the installer.pkg.
# Download the appropriate version of [http://fink.sourceforge.net/download/index.php?phpLang=en fink]. These instructions were tried with fink 0.8.1. You may need the [http://fink.sourceforge.net/doc/users-guide/ Fink User's Guide].
+
<ul><li>Update note for Mac OS X 10.5 on an Intel Mac where fink had been copied across from your old PPC (ie. G4 or G3) Mac. You have to delete your entire PPC-based fink and install freshly the fink 0.9. Upgrading first wastes your downloads and time, as the PPC version will not upgrade to the Intel version.</li></ul> 
# Install fink by opening the disk image and double clicking on the installer.pkg.
+
<li> You could use FinkCommander to provide a GUI to fink, but it is not worth the trouble, because I wasn't sure that it actually offered all the packages that I wanted, and sometimes did not allow me to type in responses to questions (this is presumably a bug). I suggest you use Terminal. In Terminal type <tt>'''fink selfupdate'''</tt> This should download package descriptions and update core packages including fink itself. I thought it would be best to do this update before switching from source to binary distribution, but I had to try the whole updating process several times before I actually managed to get it to succeed, so this may be a bad choice.
# You could use FinkCommander to provide a GUI to fink, but it is not worth the trouble, because I wasn't sure that it actually offered all the packages that I wanted, and sometimes did not allow me to type in responses to questions (this is presumably a bug). I suggest you use Terminal. In Terminal type <tt>'''fink self-update'''</tt> This should download package descriptions and update core packages including fink itself. I thought it would be best to do this update before switching from source to binary distribution, but I had to try the whole updating process several times before I actually managed to get it to succeed, so this may be a bad choice.
+
<li> In Terminal type <tt>'''fink configure'''</tt> This should run the fink configuration process (or it may have been run automatically before). You need to choose source distribution (not binary). This will set the list of Trees in <tt>'''/sw/etc/fink.conf'''</tt> to have unstable/main at the end. If not you need to add this manually. Because <tt>fink.conf</tt> is owned by root, if you do this manually you will have to do <tt>'''sudo pico /sw/etc/fink.conf'''</tt>. During the configuration process you will also have to choose between the CVS (Concurrent Versions System or Concurrent Versioning System) and rsync update methods. Rsync is a very fast protocol. It will update the description files faster than the old CVS update method. Furthermore, CVS updates are always done from sourceforge.net while rsync updates can be done from a mirror close to you. I found that CVS often stalled trying to access files, though rsync had the disadvantage that sometimes files were not found (and perhaps as CVS uses the master copy the files should be found). Nevertheless, I suggest you use rsync. If you are behind a firewall (even the firewall in a broadband router), you may need to set ProxyPassiveFTP to true to help get around the firewall.
# In Terminal type <tt>'''fink configure'''</tt> This should run the fink configuration process (or it may have been run automatically before). You need to choose source distribution (not binary). This will set the list of Trees in <tt>'''/sw/etc/fink.conf'''</tt> to have unstable/main at the end. If not you need to add this manually. Because <tt>fink.conf</tt> is owned by root, if you do this manually you will have to do <tt>'''sudo pico /sw/etc/fink.conf'''</tt>. During the configuration process you will also have to choose between the CVS (Concurrent Versions System or Concurrent Versioning System) and rsync update methods. Rsync is a very fast protocol. It will update the description files faster than the old CVS update method. Furthermore, CVS updates are always done from sourceforge.net while rsync updates can be done from a mirror close to you. I found that CVS often stalled trying to access files, though rsync had the disadvantage that sometimes files were not found (and perhaps as CVS uses the master copy the files should be found). Nevertheless, I suggest you use rsync. If you are behind a firewall (even the firewall in a broadband router), you may need to set ProxyPassiveFTP to true to help get around the firewall.
+
<li> In Terminal type <tt>'''fink selfupdate-rsync'''</tt> This should make sure all the package descriptions are downloaded, and the core packages correctly updated. I found I had to repeat this command several times, trying different mirrors when problems arose with accessing files, before the update succeeded. Fortunately, once a file has been downloaded, if you quit the process ({{man key press|ctrl|C}}), then on typing the command again, it starts from where it left off.
# In Terminal type <tt>'''fink selfupdate-rsync'''</tt> This should make sure all the package descriptions are downloaded, and the core packages correctly updated. I found I had to repeat this command several times, trying different mirrors when problems arose with accessing files, before the update succeeded. Fortunately, once a file has been downloaded, if you quit the process (ctrl-C), then on typing the command again, it starts from where it left off.
+
<li> I also got the following error, and carried out the suggested instructions (I had to use sudo apt-get in each case), which installed some extra packages and seemed to work.<pre> The following inconsistencies found:
# I also got the following error, and carried out the suggested instructions (I had to use sudo apt-get in each case), which installed some extra packages and seemed to work.
 
<pre>
 
  The following inconsistencies found:
 
 
   Unsatisfied dependency in gettext-tools: gettext (= 0.10.40-19)
 
   Unsatisfied dependency in gettext-tools: gettext (= 0.10.40-19)
 
+
 
   Trying to resolve dependencies...
 
   Trying to resolve dependencies...
 
   Could not resolve inconsistent dependencies!
 
   Could not resolve inconsistent dependencies!
Line 37: Line 48:
 
   apt-get update
 
   apt-get update
 
   apt-get install gettext=0.10.40-25{CODE}
 
   apt-get install gettext=0.10.40-25{CODE}
</pre>
+
</pre></li></ol>
# In Terminal, successively type in the following instructions:
+
 
 +
====Install the Gramps dependencies====
 +
 
 +
In Terminal, successively type in the following instructions:
  
 
   sudo fink install pygtk2-py24
 
   sudo fink install pygtk2-py24
Line 44: Line 58:
 
   sudo fink install librsvg2-gtk
 
   sudo fink install librsvg2-gtk
  
I found that a number of the files could not be found on the first mirror that was tried, or the files would not download. Sometimes, I could follow the suggestions and get the file from the next mirror that was suggested. However I also quit out of the install process by ctrl-C (twice) and started again. Fortunately files already downloaded are remembered.
+
I found that a number of the files could not be found on the first mirror that was tried, or the files would not download. Sometimes, I could follow the suggestions and get the file from the next mirror that was suggested. However I also quit out of the install process by {{man key press|ctrl|C}} (twice) and started again. Fortunately files already downloaded are remembered.
  
# Later on, I found that the gramps build process complained about another package missing, so in Terminal I had to type:
+
Later on, I found that the gramps build process complained about another package missing, so in Terminal I had to type:
  
 
   sudo fink install gnome-doc-utils
 
   sudo fink install gnome-doc-utils
  
# [http://sourceforge.net/project/showfiles.php?group_id=25770 Download gramps]  for example to <tt>'''~/Downloads'''</tt>. On the Gramps page, you need to scroll down to find a file like '''gramps-2.2.6.tar.gz'''.
+
In attempting to resolve some of the glitches, I also installed a number of other packages. These are not essential and did not resolve the issue with the spell checker, but somewhere along the way I seem to have resolved the assert warnings. In Terminal type:
  
# Unpack the file; assuming  you download to the suggested place, in Terminal type:
+
  sudo fink install gtkspell2
<pre>
+
  sudo install gnome-spell
   cd ~/Downloads
+
  sudo fink install gnome-spell
   tar -xzf gramps-2.2.6.tar.gz
+
   sudo fink install gnome-python2-py24-dev
</pre> [[According to the fink User's Guide "It is important that you don't use '''StuffIt Expander''' to extract the tar archive. For some reason '''StuffIt''' still can't handle long file names. If '''StuffIt Expander''' already extracted the archive, throw away the folder it created"].
+
   sudo fink install gnome-python2-py24-vfsmodule
 +
  sudo fink install gtkspell2-dev
  
# You can either install gramps in the default directory (which is '''/usr/local/share/gramps'''), or you can read the instructions in the gramps files about "how to install in a non-default prefix" so that you can install gramps into your users own folder rather than into /usr/local/. A user has found that it is best not to put things into /usr/local as it can be difficult to uninstall them afterwards. Modify the configuration script in the download directory by changing configure; replace:
+
====Download and install Gramps====
  
  imp.find_module('gnome/ui')
+
<ol><li>[http://sourceforge.net/project/showfiles.php?group_id=25770 Download gramps]  for example to <tt>'''~/Downloads'''</tt>. On the Gramps page, you need to scroll down to find a file like '''gramps-2.2.8.tar.gz'''.
  
with
+
<li>Unpack the file; assuming  you download to the suggested place, in Terminal type:<pre>  cd ~/Downloads
 +
  tar -xzf gramps-2.2.8.tar.gz
 +
</pre> [According to the fink User's Guide "It is important that you don't use '''StuffIt Expander''' to extract the tar archive. For some reason '''StuffIt''' still can't handle long file names. If '''StuffIt Expander''' already extracted the archive, throw away the folder it created"].
  
  imp.find_module('ui', gnome.__path__)
+
<li>'''Optional:''' You can either install gramps in the default directory (which is '''/usr/local/share/gramps'''), or you can read the instructions in the gramps files about "how to install in a non-default prefix" so that you can install gramps into your users own folder rather than into /usr/local/. One user has found that it is best not to put things into /usr/local as it can be difficult to uninstall them afterwards. The following instructions assume you install in the default directory.
  import gnome
 
  
[[Note that I don't understand why ''import gnome'' is added at the end, because it seems to be in the preceding lines, but this part of the instructions are just following the wording in a previous version of the instructions].  
+
<li>Modify the configuration script in the download directory by changing <tt>'''configure'''</tt>. Replace:<pre>  imp.find_module('gnome/ui')</pre>with<pre>  imp.find_module('ui', gnome.__path__)</pre> Also replace:
 
 
Also replace:
 
  
 
   imp.find_module('gtk/glade')
 
   imp.find_module('gtk/glade')
Line 76: Line 90:
  
 
   imp.find_module('glade', [imp.find_module('gtk')[1]])
 
   imp.find_module('glade', [imp.find_module('gtk')[1]])
  import gnome
 
  
# In the file po/Makefile, make sure that ''GMSGFMT'' has the value:
+
<li>For some reason, Fink's install of msgfmt isn't detected properly (even though the configure script says it is). You will have to tell it explicitly where to find it, so configure gramps by typing the following in Terminal:<pre>cd gramps-2.2.8
 +
./configure GMSGFMT="/sw/bin/msgfmt"</pre>
  
  GMSGFMT = /sw/bin/msgfmt
+
<li>Python couldn't find the method <tt>gsignal</tt>, so in src/GrampsWidgets.py replace: <pre>HAVE_2_6 = gtk.pygtk_version[:2] == (2, 6)</pre> with <pre>HAVE_2_6 = False</pre> While I have PyGTK 2.6.3, the code this looks at caused a NameError.</li>
  
[[This file does not seem to be present till part of the build has been done; it needs to be modified after it has been created and before it is used].
+
<li>Build and install gramps by typing in Terminal:<pre> make
 +
  sudo make install</pre>
  
# Build gramps by typing in Terminal:
+
<li>In one of the updates along the way, I had installed Python version 2.5, which is not good because all the library packages are for 2.4. You will need to switch the default version that Python picks up. In Terminal type:<pre>sudo ln -sf /sw/bin/python2.4 python</pre>
 +
</ol>
  
  ./configure
+
====Start Gramps====
  make
 
  sudo make install
 
  
# In attempting to resolve some of the glitches, I also installed a number of other packages: in Terminal type:
+
This is how Gramps has to be started each time, because there is no tool to start X11 and Gramps together. One way to get around this is to have the system launch X11 at startup, and then forget about it. This kills one of the steps and takes up little memory (I think).
 
 
  sudo fink install gtkspell2
 
  sudo install gnome-spell
 
  sudo fink install gnome-spell
 
  sudo fink install gnome-python2-py24-dev
 
  sudo fink install gnome-python2-py24-vfsmodule
 
  sudo fink install gtkspell2-dev
 
 
 
This did not resolve the issue with the spell checker, but somewhere along the way I seem to have resolved the assert warnings.
 
 
 
# In one of the updates along the way, I had installed Python version 2.5, which is not good because all the library packages are for 2.4. You will need to switch the default version that Python picks up. In Terminal type: '''sudo ln -sf /sw/bin/python2.4 python'''
 
 
 
# In '''/usr/local/share/gramps/GrampsWidgets.py''' put:
 
 
 
  try:
 
      INFO_ICON = gtk.STOCK_INFO
 
  except:
 
      INFO_ICON = gtk.STOCK_DIALOG_INFO
 
 
 
Somewhere after 'import gtk' in the section labeled: Constants.  Then change every reference to gtk.STOCK_INFO' to 'INFO_ICON'.  
 
  
 
# Start X11 by double clicking on the X11 icon in Applications/Utilities (or in Applications, depending on the version of Mac OS X).
 
# Start X11 by double clicking on the X11 icon in Applications/Utilities (or in Applications, depending on the version of Mac OS X).
 +
# Start Gramps, by typing, in xterm: <tt>'''gramps'''</tt>. After a pause "Spelling checker is not installed" appears on the xterm, and then Gramps should start.
  
# Start Gramps, by typing, in xterm:
+
== Glitches ==
 
 
  gramps
 
 
 
After a pause "Spelling checker is not installed" appears on the xterm, and then Gramps should start.
 
 
 
  
 
+
There are some problems, some from the fink installation.
====Glitches ====
 
 
 
There are some problems
 
  
 
* Help does not work (clicking Help or FAQ etc on the Help menu does nothing).
 
* Help does not work (clicking Help or FAQ etc on the Help menu does nothing).
 
* 'Enter' or 'return' does not act as OK for closing windows (the button has to be pressed with the mouse). However Esc does work to exit from the window.
 
* 'Enter' or 'return' does not act as OK for closing windows (the button has to be pressed with the mouse). However Esc does work to exit from the window.
 
* The browser and email links under the help menu do nothing.
 
* The browser and email links under the help menu do nothing.
* It is not possible to start Gramps by double clicking on a Mac OS icon, nor by double clicking on a Gramps database that is associated with the application. (It should be possible to create an installation that allows this, just as it is available for OpenOffice).
+
* It is not possible to start Gramps by double clicking on a Mac OS icon, nor by double clicking on a Gramps database that is associated with the application. (It should be possible to create an installation that allows this, just as it is available for [http://www.documentfoundation.org/download/ LibreOffice]).
 
* The PdfDoc.py plugin cannot be installed because ReportLab is not installed.
 
* The PdfDoc.py plugin cannot be installed because ReportLab is not installed.
 +
** For fink, run <code>fink install reportlab-py25</code> (py24 or py23, for earlier versions of python).
 
* The LPRDoc.py plugin cannot be loaded because the python bindings for GNOME print are not installed.
 
* The LPRDoc.py plugin cannot be loaded because the python bindings for GNOME print are not installed.
 
* Spell checking does not work (on starting Gramps, an error warning "Spelling checker is not installed" appears on the xterm). The python "bindings for [GNOME print and spell checking] are probably in fink's gnome-python2-desktop-py24 and gnome-python2-extras-py24 packages. Or would be, if fink had them at all, which we don't. They are only viable for for newer versions of gnome itself than fink presently has, or have other dependencies that are not yet satisfiable within fink. We're working on it".
 
* Spell checking does not work (on starting Gramps, an error warning "Spelling checker is not installed" appears on the xterm). The python "bindings for [GNOME print and spell checking] are probably in fink's gnome-python2-desktop-py24 and gnome-python2-extras-py24 packages. Or would be, if fink had them at all, which we don't. They are only viable for for newer versions of gnome itself than fink presently has, or have other dependencies that are not yet satisfiable within fink. We're working on it".
Line 144: Line 132:
 
             choose.set_current_folder(default_dir)
 
             choose.set_current_folder(default_dir)
 
</pre>
 
</pre>
 +
This is fixed in gramps 2.2.8
 
* (Gramps bug 0000940) When running gramps, the following warning is output on xterm - this appears to be when I open a new window:
 
* (Gramps bug 0000940) When running gramps, the following warning is output on xterm - this appears to be when I open a new window:
  
Line 167: Line 156:
 
  NameError: name 'gsignal' is not defined
 
  NameError: name 'gsignal' is not defined
  
The problem is worked around as described above.
+
The problem is worked around as described at step 6 of "Download and install gramps" (changing HAVE_2_6) above.
* (Gramps-users report 19 Feb 2007) Output of (for example charts) to OpenOffice causes OpenOffice to crash due to a problem with Gramps handling of '&'.
+
 
 +
* (Gramps-users report 19 Feb 2007) Output of (for example charts) to OpenDocument causes OpenOffice to crash due to a problem with Gramps handling of '&'.
 
* (Gramps bug 0000938) Import of a GEDCOM file that contains an invalid date of the form 2 DATE BET ABT 1912 AND 1915 causes the date to appear as blank.
 
* (Gramps bug 0000938) Import of a GEDCOM file that contains an invalid date of the form 2 DATE BET ABT 1912 AND 1915 causes the date to appear as blank.
 
* (Gramps-devel mailing list 11 Feb 2007) Gramps aborts at startup with the following error:
 
* (Gramps-devel mailing list 11 Feb 2007) Gramps aborts at startup with the following error:
Line 178: Line 168:
 
This stock item is added in Gtk 2.8 and fink an older Gtk, for more info see: http://www.pygtk.org/docs/pygtk/gtk-stock-items.html.  
 
This stock item is added in Gtk 2.8 and fink an older Gtk, for more info see: http://www.pygtk.org/docs/pygtk/gtk-stock-items.html.  
  
This is worked around by patching the application as above.
+
This is worked around by patching the application as above, and is fixed in gramps 2.2.8
 +
 
 +
[[Category:Developers/Packaging]]

Latest revision as of 13:11, 24 February 2012

How to install Gramps on OSX using X11. The process uses fink to install the packages that gramps depends on. Gramps does work, although there are some glitches which are described below.

The author of the fink guide thanks the original author from which that part of the guide was written, and for the help of people on the Gramps list for helping them work through the stumbling blocks!

For a guide of a user who has Gramps 3.0.1 working: Mac OS X:Build from source:fink:local

The following fink guide applies to Mac OS X 10.4.8, and Gramps 2.2.8. It is not possible to get gramps 2.2.9 to work with fink because you get an error "TypeError: object of type `GtkCellRendererText' does not have property `wrap-mode'" because fink does not yet support the pangocairo packages. Some earlier versions of gramps need additional patches that are not mentioned here.

General Caveats

  • As stated above, these instructions were for installing 2.2.8 on Mac OS X 10.4.8, but should work more widely.
  • Production of a guide like this should really only be done after repeating the installation from a clean machine, and repeating again till the guide exactly matches the actual process - doing so would take a lot of time; the authors have each only done the installation once, so your experience will almost certainly differ from theirs.

Installing Gramps on Mac OS X via fink to use X11

  • You are installing from the 'unstable' fink tree, so the versions of the packages you install may vary from day to day, and there could be problems with them.

Installation instructions

Install X11

If you have not already installed X11, install it from the Apple OS X installation disks.

Install Developer Tools

If you have not already installed the Developer Tools, install them from a recent Apple OS X installation disks (there may be a CD labelled XCode Tools, or an XCode folder on the install DVD). If your installation disk is not very recent, it may be better to download the tools from the Apple web-site (free registration required to access the development tools) because some of the build process will not work with an old version of the tools.

Install and update fink

This was much more difficult than it should have been. From reading some of the fink mailing lists, I think there may have been some problems with updates to the fink mirrors at the time.

  1. Download the appropriate version of fink. These instructions were tried with fink 0.8.1. You may need the Fink User's Guide.
  2. Install fink by opening the disk image and double clicking on the installer.pkg.
    • Update note for Mac OS X 10.5 on an Intel Mac where fink had been copied across from your old PPC (ie. G4 or G3) Mac. You have to delete your entire PPC-based fink and install freshly the fink 0.9. Upgrading first wastes your downloads and time, as the PPC version will not upgrade to the Intel version.
  3. You could use FinkCommander to provide a GUI to fink, but it is not worth the trouble, because I wasn't sure that it actually offered all the packages that I wanted, and sometimes did not allow me to type in responses to questions (this is presumably a bug). I suggest you use Terminal. In Terminal type fink selfupdate This should download package descriptions and update core packages including fink itself. I thought it would be best to do this update before switching from source to binary distribution, but I had to try the whole updating process several times before I actually managed to get it to succeed, so this may be a bad choice.
  4. In Terminal type fink configure This should run the fink configuration process (or it may have been run automatically before). You need to choose source distribution (not binary). This will set the list of Trees in /sw/etc/fink.conf to have unstable/main at the end. If not you need to add this manually. Because fink.conf is owned by root, if you do this manually you will have to do sudo pico /sw/etc/fink.conf. During the configuration process you will also have to choose between the CVS (Concurrent Versions System or Concurrent Versioning System) and rsync update methods. Rsync is a very fast protocol. It will update the description files faster than the old CVS update method. Furthermore, CVS updates are always done from sourceforge.net while rsync updates can be done from a mirror close to you. I found that CVS often stalled trying to access files, though rsync had the disadvantage that sometimes files were not found (and perhaps as CVS uses the master copy the files should be found). Nevertheless, I suggest you use rsync. If you are behind a firewall (even the firewall in a broadband router), you may need to set ProxyPassiveFTP to true to help get around the firewall.
  5. In Terminal type fink selfupdate-rsync This should make sure all the package descriptions are downloaded, and the core packages correctly updated. I found I had to repeat this command several times, trying different mirrors when problems arose with accessing files, before the update succeeded. Fortunately, once a file has been downloaded, if you quit the process (ctrl+C), then on typing the command again, it starts from where it left off.
  6. I also got the following error, and carried out the suggested instructions (I had to use sudo apt-get in each case), which installed some extra packages and seemed to work.
      The following inconsistencies found:
      Unsatisfied dependency in gettext-tools: gettext (= 0.10.40-19)
     
      Trying to resolve dependencies...
      Could not resolve inconsistent dependencies!
    
      Fink isn't sure how to install the above packages safely.
      You may be able to fix things by running:
    
      fink scanpackages
      apt-get update
      apt-get install gettext=0.10.40-25{CODE}
    

Install the Gramps dependencies

In Terminal, successively type in the following instructions:

 sudo fink install pygtk2-py24
 sudo fink install gnome-python2-py24
 sudo fink install librsvg2-gtk

I found that a number of the files could not be found on the first mirror that was tried, or the files would not download. Sometimes, I could follow the suggestions and get the file from the next mirror that was suggested. However I also quit out of the install process by ctrl+C (twice) and started again. Fortunately files already downloaded are remembered.

Later on, I found that the gramps build process complained about another package missing, so in Terminal I had to type:

 sudo fink install gnome-doc-utils

In attempting to resolve some of the glitches, I also installed a number of other packages. These are not essential and did not resolve the issue with the spell checker, but somewhere along the way I seem to have resolved the assert warnings. In Terminal type:

 sudo fink install gtkspell2
 sudo install gnome-spell
 sudo fink install gnome-spell
 sudo fink install gnome-python2-py24-dev
 sudo fink install gnome-python2-py24-vfsmodule
 sudo fink install gtkspell2-dev

Download and install Gramps

  1. Download gramps for example to ~/Downloads. On the Gramps page, you need to scroll down to find a file like gramps-2.2.8.tar.gz.
  2. Unpack the file; assuming you download to the suggested place, in Terminal type:
      cd ~/Downloads
      tar -xzf gramps-2.2.8.tar.gz
    
    [According to the fink User's Guide "It is important that you don't use StuffIt Expander to extract the tar archive. For some reason StuffIt still can't handle long file names. If StuffIt Expander already extracted the archive, throw away the folder it created"].
  3. Optional: You can either install gramps in the default directory (which is /usr/local/share/gramps), or you can read the instructions in the gramps files about "how to install in a non-default prefix" so that you can install gramps into your users own folder rather than into /usr/local/. One user has found that it is best not to put things into /usr/local as it can be difficult to uninstall them afterwards. The following instructions assume you install in the default directory.
  4. Modify the configuration script in the download directory by changing configure. Replace:
      imp.find_module('gnome/ui')
    with
      imp.find_module('ui', gnome.__path__)
    Also replace:
     imp.find_module('gtk/glade')
    

    with:

     imp.find_module('glade', [imp.find_module('gtk')[1]])
    
  5. For some reason, Fink's install of msgfmt isn't detected properly (even though the configure script says it is). You will have to tell it explicitly where to find it, so configure gramps by typing the following in Terminal:
    cd gramps-2.2.8
    ./configure GMSGFMT="/sw/bin/msgfmt"
  6. Python couldn't find the method gsignal, so in src/GrampsWidgets.py replace:
    HAVE_2_6 = gtk.pygtk_version[:2] == (2, 6)
    with
    HAVE_2_6 = False
    While I have PyGTK 2.6.3, the code this looks at caused a NameError.
  7. Build and install gramps by typing in Terminal:
      make
      sudo make install
  8. In one of the updates along the way, I had installed Python version 2.5, which is not good because all the library packages are for 2.4. You will need to switch the default version that Python picks up. In Terminal type:
    sudo ln -sf /sw/bin/python2.4 python

Start Gramps

This is how Gramps has to be started each time, because there is no tool to start X11 and Gramps together. One way to get around this is to have the system launch X11 at startup, and then forget about it. This kills one of the steps and takes up little memory (I think).

  1. Start X11 by double clicking on the X11 icon in Applications/Utilities (or in Applications, depending on the version of Mac OS X).
  2. Start Gramps, by typing, in xterm: gramps. After a pause "Spelling checker is not installed" appears on the xterm, and then Gramps should start.

Glitches

There are some problems, some from the fink installation.

  • Help does not work (clicking Help or FAQ etc on the Help menu does nothing).
  • 'Enter' or 'return' does not act as OK for closing windows (the button has to be pressed with the mouse). However Esc does work to exit from the window.
  • The browser and email links under the help menu do nothing.
  • It is not possible to start Gramps by double clicking on a Mac OS icon, nor by double clicking on a Gramps database that is associated with the application. (It should be possible to create an installation that allows this, just as it is available for LibreOffice).
  • The PdfDoc.py plugin cannot be installed because ReportLab is not installed.
    • For fink, run fink install reportlab-py25 (py24 or py23, for earlier versions of python).
  • The LPRDoc.py plugin cannot be loaded because the python bindings for GNOME print are not installed.
  • Spell checking does not work (on starting Gramps, an error warning "Spelling checker is not installed" appears on the xterm). The python "bindings for [GNOME print and spell checking] are probably in fink's gnome-python2-desktop-py24 and gnome-python2-extras-py24 packages. Or would be, if fink had them at all, which we don't. They are only viable for for newer versions of gnome itself than fink presently has, or have other dependencies that are not yet satisfiable within fink. We're working on it".
  • (Gramps bug 0000940) On starting Gramps, the following assert warnings are output:
/usr/local/share/gramps/DbLoader.py:99: 
     GtkWarning: gtk_file_system_unix_get_folder: 
         assertion `g_path_is_absolute (filename)' failed
            choose.set_current_folder(get_default_dir())
/usr/local/share/gramps/DbLoader.py:153: 
     GtkWarning: gtk_file_system_unix_get_folder: 
        assertion `g_path_is_absolute (filename)' failed
            choose.set_current_folder(default_dir)

This is fixed in gramps 2.2.8

  • (Gramps bug 0000940) When running gramps, the following warning is output on xterm - this appears to be when I open a new window:
(gramps:516): libglade-WARNING **: unknown property `urgency_hint' 
                                for class `GtkDialog'
  • (Gramps bug 0000939) Detection of the availability of gsignal is flawed. In GrampsWidgets.py, there is some code to cater for different versions of gtk.pygtk. I have fink packages pygtk2-gtk-py* version 2.6.3-1 and pygtk2-py* version 2.6.3-2000 installed, so this certainly seems to be version 2.6, and is presumably causing HAVE_2_6 to be set to true. However, on running gramps, I get:
[name G5:~] name% gramps
Traceback (most recent call last):
  File "/usr/local/share/gramps/gramps.py", line 97, in ? 
    import gramps_main
  File "/usr/local/share/gramps/gramps_main.py", line 47, in ?
    import ViewManager
  File "/usr/local/share/gramps/ViewManager.py", line 68, in ?
    import GrampsCfg
  File "/usr/local/share/gramps/GrampsCfg.py", line 47, in ?
    from GrampsWidgets import *
  File "/usr/local/share/gramps/GrampsWidgets.py", line 1162, in ?
    class MaskedEntry(gtk.Entry):
  File "/usr/local/share/gramps/GrampsWidgets.py", line 1216, in MaskedEntry
    gsignal('size-allocate', 'override')
NameError: name 'gsignal' is not defined

The problem is worked around as described at step 6 of "Download and install gramps" (changing HAVE_2_6) above.

  • (Gramps-users report 19 Feb 2007) Output of (for example charts) to OpenDocument causes OpenOffice to crash due to a problem with Gramps handling of '&'.
  • (Gramps bug 0000938) Import of a GEDCOM file that contains an invalid date of the form 2 DATE BET ABT 1912 AND 1915 causes the date to appear as blank.
  • (Gramps-devel mailing list 11 Feb 2007) Gramps aborts at startup with the following error:
 File "/usr/local/share/gramps/GrampsWidgets.py", line 2010, in ?
   MANDATORY_ICON = gtk.STOCK_INFO
AttributeError: 'module' object has no attribute 'STOCK_INFO'{CODE}

This stock item is added in Gtk 2.8 and fink an older Gtk, for more info see: http://www.pygtk.org/docs/pygtk/gtk-stock-items.html.

This is worked around by patching the application as above, and is fixed in gramps 2.2.8