void tsmMakeDirIfNotExist ( const char *dirname, int isDir ) Create a directory tree
Create a directory tree.Takes a directory name and will create that directory if it does not already exist. This routine will create all of the intermediate directories necessary, e.g. if you ask to create "/a/b/c/d", but only "/a" exists, then this function will create "/a/b", then "/a/b/c", and then finally "/a/b/c/d".
The second parameter specifies whether the string in the first parameter contains a directory name only (TSM_PATH_ONLY), or whether it also contains a filename at the end (TSM_PATH_AND_FILE). This enables you to pass a full filename to the function and it will create all of the directory structure necessary for that file, i.e. if ( isDir==TSM_PATH_AND_FILE ), then the last part of dirname is ignored.