install:mac_compiling_fink

This is an old revision of the document!


Note that version 3.8.2 of make that can be installed via fink does not work. Use the make that comes with Mac OS.

You can configure polymake with one of the following commands. You can also add further custom switches, see below. Open a Terminal window and switch to the folder you want to compile polymake in. All the following commands have to be issued in the same window.

  • Preparation:
    • The variable JAVA_HOME is not set correctly. Please do
      export JAVA_HOME=/Library/Java/JavaVirtualMachines/<java-version-with-minor>/Contents/Home

      where you have to put in the approiate java version directory (which you can find out by checking which folders are in /Library/Java/JavaVirtualMachines/).

  • Configuration: This depends on the compiler you want to use.
    • If you use the standard compiler of XCode:
      ./configure

    • If you installed a compiler via fink or compiled your own:

      ./configure CC=<path-to-your>/gcc CXX=<path-to-your>/g++

      Note that, if you obtained your gcc from fink it will have a different name (some variation of gcc-4 or gcc-fsf-4.7, and similarly for g++, check your /sw/bin directory, this way fink's gcc does not shadow apple's.

    • If during configuration perl complains about wrong architecture of your fink files you can try to help perl by issuing

      export VERSIONER_PERL_PREFER_32_BIT=no

      (or yes, if your fink is a 32bit version). If this helps, you should set this in your .profile file or in the system preferences.

  • Compilation: Once configuration was successful, continue with
    make
    make install

Additional Options

Except for potentially explicitly specifiying the jni header path and the path to the STL headers the installation process is the same as for a Linux system. We list some important options for configuration below, but for a complete list of options please check the configuration section on the Linux installation page.

  • You may choose a different --prefix if you prefer an installation path other than /usr/local.
  • If the fink script is not in your $PATH you have to specify the path via --with-fink
  • The command
    ./configure --help

    prints a complete list of configuration options.

  • On Intel Macs you could take advantage of the dual core processor by using make -j2
  • Depending on your choice for the installation directory you may need admin rights for the installation step (in particular if you did not specify a prefix).
  • You should add the directory <prefix>/bin to your $PATH, where <prefix> is the chosen prefix, or /usr/local/polymake/bin if you did not specify one.
  • If you change your Fink installation to a different directory, or switch from 32bit to 64bit, then you have to recompile polymake

  • install/mac_compiling_fink.1558006688.txt.gz
  • Last modified: 2019/05/16 11:38
  • by paffenholz