Clothing maker VF Corporation is to buy the bankrupt upscale denim brand Rock and Republic, acquiring the company's trademarks and intellectual-property rights.