Starting with version 0.2 pam_sotp has a autoconf-style build system. This means that you should be able to compile & install pam_sotp with the commands:
./configure make make install
As well as the usual arguments (--prefix, etc..) the configure scripts accepts the following pam_sotp specific arguments:
--with-randondev Device used to gather random data. The default is /dev/random. If the
device given does not exists or is not a character device, glibc's random() will be used instead.
--with-authdir Default authentication directory. If not given, /etc/sotp will be used
--enable-debug Verbose logging with syslog