I don't think the solution (returning "~" if HOME environment variable is not set) is going to fly. "~" is translated by the shell to the user's home directory, but the shell is not involved here. I think the correct solution is to call getpwuid (or its reentrant counterpart getpwuid_r, if available), passing the value of either `getuid()' (real user id) or `geteuid()' (effective user ID). Then get the value of the pw_dir field from the returned struct passwd * pointer, call RTMS on it and return that value. If I manually set the HOME environment variable to "~", the command line compiler runs OK but estudio asks me for an activation code, presumably because it can't find my license since it doesn't know where my home directory is. Reopening report.