I had the very problem with Redhat EL. This is the reason:
“truecrypt-4.0/Linux/Kernel/Dm-target.c:16:16: dm.h: No such file or directory”
The Redhat Enterprise Linux kernel sources do not include dm.h, so the build fails. I had jump through a bunch of hoops to get it to compile. Please note, I am no expert. This is what worked for me. If anyone can suggest any shortcuts, please do.
1. Obtain and install kernel-2.6.9-22.EL.src.rpm (puts it in /root/src/redhat/)
2. cd /root/src/redhat/SPECS
3. rpmbuild -bp –target=i686 kernel-2.6.spec
4. cd /root/src/redhat/BUILD/kernel-2.6.9/linux-2.6.9/drivers/md/
5. cp * /usr/src/kernels/2.6.9-22.0.1.EL-i686/drivers/md/
The build.sh then worked, once dm.h was found. I'm not sure what other files were necessary, which is the reason I copied md/* over. Hope this helps.