Heya, just another suggestion: instead of a fixed '-O3' in COMPILERFLAGS just re-use CFLAGS from top of the file to take care of noopt in DEB_BUILD_OPTIONS. You could do it this way: Instead of using CFLAGS up there I'd just define the COMPILERFLAGS and build the static version before the dynamic lib, so you can just use a COMPILERFLAGS+="-fPIC" to compile it the right way. Cheers, Bernd