Question: For some reason when I try to compile my code, I get this error:

fatal error: direct.h: No such file or directory
compilation terminated.

I'm on linux using g++ (GCC) 4.6.0 20110509 (Red Hat 4.6.0-7)

Answer: 
`direct.h` is part of the Digital Mars compiler, not gcc.

Most of its functions have similar names on linux that's posix standarized. Read the manpage for e.g. [getcwd](http://pubs.opengroup.org/onlinepubs/009695399/functions/getcwd.html) , [rmdir](http://pubs.opengroup.org/onlinepubs/009695399/functions/rmdir.html), [mkdir](http://pubs.opengroup.org/onlinepubs/009695399/functions/mkdir.html) ,or clarify your question as to which functions you need.

As a start, just remove the include and see what other errors you are getting, and work from there.
I took SWMM5 source code and modify the files following the readme and some small fixes. It seems in linux you do not need direct.h at all for the CLE version. I have tested several of the examples provided by EPA
<https://www.epa.gov/sites/production/files/2014-05/epaswmm5_apps_manual.zip>

You can get the files [from here](https://drive.google.com/open?id=0B6SXwdLnLLLYUjFyZnZzdHBOWnM).

Let me know if something is not working.