next up previous contents index
Next: Installation on FreeBSD Up: Installation instructions Previous: Installation on DEC Alpha   Contents   Index


Installation on Mac OSX / Darwin

As of version 3.2.20, imal should also build on Max OSX (Darwin). The procedure below was contributed by a user. Unfortunately, I don't have access to a Mac, so there is no way to know whether the new standard procedure actually works. If the standard procedure (configure; make; make install ) doesn't work, check the following:

  1. A working version of Motif must be installed. Lesstif reportedly works in OSX and is included in the Fink distribution of OSX.
  2. Test the config.guess script to find out whether it prints ``darwin'' or something similar. If not, replace config.guess with the one in /usr/libexec or /usr/share/libtool/, or with the following one line script:
           echo darwin
    
    Make sure the script is executable.
  3. Type `./configure'
  4. Change `makefile' to contain the following (if necessary):
         OBJS = xmtnimage*.o lex.yy.o y.tab.o
         LDFLAGS=
         INCLUDES=-I.  -I/sw/include  -I/sw/include/Xm -I/usr/X11R6/include \
             -I/usr/X11R6/include/X11 
         LIBS= -lm /sw/lib/libtiff.a /usr/lib/libl.a /sw/lib/libXm.a \
            /usr/X11R6/lib/libICE.a /usr/X11R6/lib/libSM.a /usr/X11R6/lib/libXpm.a \
            /usr/X11R6/lib/libXext.a /usr/X11R6/lib/libXt.a /sw/lib/libfl.a \
            /usr/X11R6/lib/libX11.a /usr/local/lib/libjpeg.a /usr/local/lib/libpng.a \
            /usr/local/lib/libtiff.a
            /usr/lib/libz.dylib /sw/lib/libjpeg.a
         CC=gcc
         CFLAGS=-O3 -fno-common   -Wall  -no-cpp-precomp 
         YACC=yacc -d
    
    Note that your libraries may be in different locations than shown here. If this command doesn't work, use the strings or grep commands to determine which library files are needed for each unresolved symbol.
    For FINK, try the following:
         OBJS = xmtnimage*.o lex.yy.o y.tab.o
         LDFLAGS=
         INCLUDES=-I.  -I/sw/include -I/sw/include/Xbae -I/sw/include/Xm \
             -I/usr/X11R6/include -I/usr/X11R6/include/X11 
         LIBS= -L/sw/lib -ltiff -ljpeg -lpng -lXbae -lXm -L/usr/X11R6/lib -lICE \
             -lXpm -lXt -lSM -lX11 -lXext -lm -fl -ll -lz
         CC=g++
         CFLAGS=-O3 -fno-common   -Wall  -no-cpp-precomp 
         YACC=yacc -d
    

  5. Comment out all the occurrences of fcvt() in config.h, i.e.:
        /* #undef HAVE_FCVT */
    
    Similarly, if gcvt() causes problems, cast it from thee:
        /* #undef HAVE_GCVT */
    

  6. The command `strip readtif' apparently does not work in OSX. This is of no consequence. readtif, which requires the libtiff library, also may not compile. Readtif is only a plugin and is not needed for imal.
  7. Note that there is no `make install'. Installation is performed with the Install script. However, even if this doesn't work for some reason, imal will still run if you copy the binary to someplace in your path, preferably /usr/local/bin.

Thanks to Kurt De Vos for this information and for his persistence in compiling imal on the Mac. Feedback from other Mac users is encouraged.


next up previous contents index
Next: Installation on FreeBSD Up: Installation instructions Previous: Installation on DEC Alpha   Contents   Index
root 2010-04-22