The natural circulation of air in a room hits and warms the walls in the room. The back wall of the closet, however, is not exposed to that heat because it is being blocked by a door. The result is that the closet is colder than the rest of the room. There is probably a lack of insulation at the top of the wall as well, making it cold enough to create frost. There are several things that can be done. Caulk the wall to the floor behind the floorboards, or install some rigid foam insulation on the far wall in the closet and put up some drywall over that. Both measures will reduce the heat being lost outside and thus the amount of cold air entering the closet. In order to increase air circulation, which is a big part of the problem, cut off the bottom 5 cm (2 in.) or so of the closet door and install a vent above the door. These steps should prevent the frost from returning.