Is there any equivalent middleware for c like rmi for java or .net for c#?
You can write your own custom protocols, or use SOAP (WebServices).
I would suggest you using WebServices with Apache's AXIS library.
Do you mean you want to communicate between a Java application and .Net application or write and a service layer and application in .Net using C#?
In either case you would probably want to use WCF. If you want to communicate between a Java and .Net application you will want to look at Sun's Project Tango.
Have a look at RPCGEN , that generates C code (client and server) to do remote call and shoulb installed by default on a unix computer. That's really easy to use , and you could find plenty of tutorial on the net. That might be outdated, but I have only try Corba and Soap with C++, so I don't how they fit with plain C.
For use with C and C++ there is gSOAP an open source SOAP framework.