> why all those explicit casts ? is ulong32 even defined somewhere else 
> than on MSVC ? if the cast is necessary, which i doubt, than uint32_t 
> from stdint.h would be the proper type to use, since it's defined in the 
> C standard (introduced in C99).
>

ulong32 is not something specific for MSVC it is defined in tomcrypt_macros.h

The failures look like this:

cl -nologo -c @"libtom-src\ciphers\camellia.ccs" -Fo"libtom-src\ciphers\camellia.obj" "libtom-src\ciphers\camellia.c"
camellia.c
libtom-src\ciphers\camellia.c(459) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(460) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(461) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(466) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(467) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(469) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(481) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(482) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(483) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(488) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(489) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(491) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(505) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(506) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(507) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(512) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(513) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(515) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(555) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(556) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(558) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(562) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(563) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(564) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(579) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(580) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(582) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(586) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(587) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(588) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(601) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(602) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(604) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data
libtom-src\ciphers\camellia.c(608) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(609) : warning C4244: '=' : conversion from 'ulong64' to 'ulong32', possible loss of data
libtom-src\ciphers\camellia.c(610) : warning C4244: 'function' : conversion from 'ulong64' to 'unsigned long', possible loss of data