Section 34. The officer or board having charge of the police in any such city may license persons to keep public lodging houses therein, and shall immediately revoke such license if the licensee violates any provision of sections thirty-five to thirty-eight, inclusive. The fee for such licenses will be established in a town by town meeting action and in a city by city council action, and in a town with no town meeting by town council action, by adoption of appropriate by-laws and ordinances to set such fees, and, subject to the state building code when applicable, it shall expire on the thirtieth day of April next after the granting of the same, but in no event shall any such fee be greater than fifty dollars. Every such license shall specify the street and number, if any, of the building where the business is to be carried on or give some other particular description thereof, and the license shall not protect a licensee who carries on his business in any other place.