Question: how to make xpm file?
Answer: Open GIMP. Click File/New. Select 640x480 from the Template dropdown and click OK. Click File/Open As Layers, browse to your image file and click Open. Click OK on the Render Scalable Vector Graphics page. Click Image/Mode/Indexed.