Crypto++ will not build

Hi, I’m trying to use the crypto++ library, version 5.5.2, available at The build fails with errors in secblock.h and misc.h. I performed a Google search and found an updated secblock.h which fixes many of the errors, but the build still fails. I have tried building with both g++ and qcc. The errors are things like invalid template arguments and parse errors.

I tried installing this on a linux box for the sake of comparison. The installation ran cleanly and all verification tests passed, no problem.

Does anybody else have any experience trying to install crypto++? Any help is appreciated, thanks!

WIthout a specific post, what errors occured, there won´t be much help.

I would post this over at the pkgsrc project at It might already be working there. If you send me an email at, I’ll give it a try on my system. Only would take a few minutes but I don’t have time right now.

Here are the results of my build:


g++ -DNDEBUG -g -O2 -pipe -c 3way.cpp
In file included from seckey.h:9,
from 3way.h:7,
from 3way.cpp:5:
misc.h:111: warning: noinline' attribute directive ignored In file included from 3way.h:8, from 3way.cpp:5: secblock.h:450: parse error before >’
secblock.h:462: T_Align16' was not declared in this scope secblock.h:462: template argument 4 is invalid secblock.h:462: ANSI C++ forbids declaration ’ with no type
secblock.h:464: parse error before ;' secblock.h:471: default argument for template parameter in function template CryptoPP::SecBlockWithHint::SecBlock
WithHint(unsigned int)’
secblock.h: In method CryptoPP::SecBlockWithHint::SecBlockWithHint(unsigned int)': secblock.h:471: expected 2 levels of template parms for CryptoPP::SecBlockWithHint::SecBlockWithHint(unsigned int
)’, got 1
In file included from 3way.cpp:5:
3way.h: At top level:
3way.h:10: confused by earlier errors, bailing out
make: *** [3way.o] Error 1

The updated secblock.h I am using is located at: … secblock.h