I have written a class with protected constructor, so that new instances can only be produced with a static create() function which returns shared_ptr\'s to my class. To provide
I would try without the template
part. After all, you want a specific instantiation of the (template) function to be a friend of your class, aren't you? Does
friend boost::shared_ptr boost::make_shared(const ConnectionManagerPtr&, const std::string&);
work?
If that's not the solution, it might be helpful to give us the compiler messages you're getting ...