You will need an ISP programmer. If you don’t have a programmer, you can use a spare Arduino board as an "Arduino as ISP" programmer. Although the "Arduino as ISP" only works for programming targets of the AVR architecture, you can use boards of any architecture as an "Arduino as ISP" programmer.
The following instructions are for using an Arduino board as an "Arduino as ISP" programmer. If you have a dedicated programmer, you can skip to the next set of instructions.
Make the following connections between the Arduino board you will be using as the programmer and the target. Refer to the "Connections" table on the SPI library reference page to determine the pins: