Exclude tests from all target, build static lib by default, support different endpoints