add missing define BT_COUNTER
fix several warnings
This commit was generated by cvs2svn to compensate for changes in r2926, which included commits to RCS files with non-trunk default branches.