Cyrus SASL v2 on Mac OS X (and 9)

The Cyrus SASL v2 distribution now supports Mac OS X, including applications written to Apple's Carbon and Cocoa interfaces, as well as the standard Unix-like API. It includes the following components:

If you are building a Carbon CFM application and intend it to run on both OS 9 and OS X, you should link against the OS 9 Carbon SASL library, since it exports fewer APIs (client side only, specifically) than the OS X CFM glue. Your application should work seamlessly with both libraries if you do this, despite the different implementations underneath.

If you need a Carbon CFM application to support server-side SASL functionality, you need to link against the SASL2GlueCFM library, but be aware that your application will not run on OS 9.

Compiling and Using the Unix library

The Unix library is mostly ready to build on Mac OS X, but it does depend on the dlcompat package in order to load its plugins. dlcompat-20010505 is a relatively simple version known to work with SASL; it is provided with the distribution in a tarball. You should make and make install the dlcompat library (which probably goes into /usr/local/lib/libdl.dylib) before attempting to ./configure the SASL distribution itself. SASL will then pretend it's a real Unix libdl, and link against it.

Since there are, at this point, newer and far more complex versions of dlcompat, you may prefer to use those instead if other software requires their functionality. The dlcompat homepage is located on the OpenDarwin site.

If you are using MIT Kerberos for Macintosh 4.0 or later, which is fully supported by the SASL library, you should ./configure with the added option --enable-krb4=/usr so that it finds the correct location for the header files. KfM will be automatically detected by the configure script, and the correct libraries linked in. Please read the "Known Problems" section at the end of this document for information on working around a problem with OpenSSL's DES headers.

You must be root to make install, since /usr/local is only modifiable by root. You need not enable the root account using NetInfo; the recommended (but underdocumented) method is to use sudo -s from the Terminal window when you are logged into an administrator's account, and enter the password for that account. When building on Mac OS X, make install will automatically add the framework to /Library/Frameworks.

This does not build the CFM glue library. Building the CFM glue library requires Metrowerks CodeWarrior Pro 6 or later (tested with 6), and the files necessary to build it are in the mac/osx_cfm_glue folder.

Changes to the Unix library to make it work on OS X

This is provided for reference purposes only. The build system will automatically take care of all of these issues when building on Darwin or Mac OS X.

Changes to the Mac OS 9 projects to support Carbon

Please read these notes before you attempt to build SASL for OS 9 Carbon!

Known Problems