But when adults (not only parents, but other family, even strangers) recognize and praise "smartness" long before the child can understand that hard work is involved? I'd say this is the problem. And it seems to be so for praise of most any attribute: praise a child constantly for their looks and they seem to have similar self-confidence problems later in life as well.
That's true, but they may also be praising "smartness" before the child knows what that is either. However, given how schools work, it's pretty unlikely that someone will realize what it means to be considered smart after they've realized the value of hard work.