Preheat an oven to 350°F. Butter a 9-inch square cake pan.
In a large bowl, using an electric mixer on medium speed, beat together the butter and the sugar until creamy. Add the eggs one at a time, beating well after each addition. Stir in the vanilla extract and rum.
In another bowl, stir together the corn meal, baking powder and flour. Add the dry ingredients to the wet ingredients in 2 additions, beating on low speed after each addition until smooth. Spread the batter evenly in the prepared pan.
Bake until a toothpick inserted into the center comes out clean, about 35 minutes. Remove from the oven and let stand for 10 minutes, then turn out onto a rack to cool. Cut into squares.