[tex-live] The adforn package.

Maxwell, Adam R adam.maxwell at pnl.gov
Tue Oct 5 01:51:25 CEST 2010

On Oct 4, 2010, at 15:41, Martin Schröder wrote:

> 2010/10/4 C.M. Connelly <cmc at math.hmc.edu>:
>> (For added fun, some sloppily coded apps break if you switch to a
>> case-sensitive file system (e.g., Office, Adobe apps).)
> Why am I not surprised?

It doesn't help that parts of Apple's frameworks are case-sensitive
(NSBundle and CFBundle) even on case-insensitive file systems, and
others (e.g., NSFileManager) respect file system case-sensitivity.
As long as you don't hardcode paths or accept them as user input
directly, it's manageable; using FSRef objects instead of paths is
even better.

Sort-of-on-topic, this is an example of how things that work in the
shell on OS X might work differently in other languages or APIs, so
there are plenty of ways to shoot yourself in the foot.

If you speak Python and Cocoa, there's a short PyObjC example below
that demonstrates the NSFileManager end.  It should fail on a UFS
or HFSX volume.

#!/usr/bin/env python

from Foundation import NSFileManager, NSString
from Foundation import NSUTF8StringEncoding

import os

if __name__ == '__main__':
    fm = NSFileManager.defaultManager()

    path = "/tmp/casetest"
    if os.path.exists(path):
    fileExists, isDirectory = fm.fileExistsAtPath_isDirectory_(path, None)
    assert fileExists is False, "file exists"
    content = NSString.stringWithString_("junk").dataUsingEncoding_(NSUTF8StringEncoding)
    didCreate = fm.createFileAtPath_contents_attributes_(path, content, None)
    assert didCreate is True, "failed to create file"
    print "created file %s" % (path)
    print "Python API check:", os.path.abspath(path), os.path.exists(path)
    print ""
    path = "/tmp/CASEtest"
    fileExists, isDirectory = fm.fileExistsAtPath_isDirectory_(path, None)
    print "%s %s" % (path, "exists" if fileExists else "does not exist")
    print "display name of %s = %s" % (path, fm.displayNameAtPath_(path))
    print "Python API check:", os.path.abspath(path), os.path.exists(path)

More information about the tex-live mailing list