Fixed bugs in external tools API. Now works again on Linux.