Fix proposed in:
https://github.com/martinpaljak/OpenSC.tokend/issues/1
Merge pull request #1 from pettai/buildfix

bscottm's patch