OKLAHOMA CITY (AP) _ Timothy McVeigh and Terry Nichols were linked to a lethal inventory of bomb-making materials acquired in the months leading up to the federal building bombing and stashed in storage sheds across Kansas, according to an FBI affidavit released Thursday.

The statement also said Nichols wrote McVeigh a letter, to be delivered in the event of Nichols' death, telling McVeigh to clear out two sheds and ``Go for it!'' alone.

The affidavit was unsealed in a court hearing for the 40-year-old Nichols, who along with McVeigh is charged in the deadliest terrorist attack in U.S. history, which claimed 167 lives.

Nichols, who was shackled hand and foot, stared straight ahead when interim U.S. Attorney Patrick Ryan told the court that Nichols faces the death penalty if convicted.

A search of Nichols' house in Herington, Kan., found five 60-foot detonator cords with non-electric blasting caps and several containers of ground ammonium nitrate, which ``can be used as one ingredient of a booster for a fertilizer-fuel oil bomb,'' the affidavit said.

The 10-page document also said FBI agents found a fuel meter which can be used to obtain ``the proper volume of diesel oil to ammonium nitrate for a bomb.''

Nichols' appearance before U.S. Magistrate Ronald Howland in a makeshift courtroom at the federal prison in El Reno came 24 hours after authorities transferred him to Oklahoma City from Kansas, where he had been held as a material witness.

Timothy McVeigh, Nichols' Army buddy, business partner and political compatriot, has been held at the El Reno prison since being charged with the bombing two days after the April 19 attack.

Clad in a dingy white T-shirt and rumpled olive pants, Nichols sat hunched over the defense table, answering the magistrate's questions with ``Yes, your honor'' and ``Yes, sir.''

Defense attorneys did not contest prosecutors' request that Nichols be held until a May 18 preliminary hearing.

According to the affidavit, investigators found a receipt for the September 1994 purchase of a ton of ammonium nitrate fertilizer from a Kansas farm supply store. The receipt, under the name ``Mike Havens,'' bears McVeigh's fingerprint, the FBI said. An additional ton of fertilizer was purchased at the same store the next month by ``Mike Havens.''

The affidavit also linked Nichols and McVeigh with storage units rented in Kansas just before the two fertilzer purchases.

The affidavit submitted by agent Henry C. Gibbons also said that on April 15 and 16, Nichols purchased more than two dozen gallons of diesel fuel from service stations in Manhattan and Junction City, Kan.

James T. Thurman, chief of the FBI explosives laboratory in Washington, concluded the bomb ``would have been constructed over a period of time utilizing a large quantity of bomb paraphernalia,'' including fertilizer, fuel oil, boosters, detonators or blasting caps, detonation cord, fusing systems and containers, the affidavit said.

Thurman said the bomb ``would necessarily have involved the efforts of more than one person.''

Nichols told the FBI during his initial questioning just days after the bombing that he knows how to make a bomb by blending ammonium nitrate with diesel fuel. He said he had ammonium nitrate at his home until April 21, but then put it on his lawn as fertilizer after reading in the newspaper that the substance was used in the Oklahoma City bombing

According to the affidavit, Nichols also said he met McVeigh in downtown Oklahoma City on April 16, and again in Junction City, Kan., on April 18, where he loaned his pickup truck to McVeigh for about five hours.

A Ryder truck was seen behind Nichols' house on April 17, the affidavit said. A Ryder rental truck carried the Oklahoma City bomb.

Nichols gave agents permission to search his house, but said he hoped they ``would not mistake household items'' for bomb-making materials, the affidavit said. He told agents he had several containers of ground ammonium nitrate, which he said he sells as plant food fertilizer at gun shows.

Nichols and his brother, James, also face unrelated charges of making small explosives in Michigan several years ago.

Terry Nichols and McVeigh have a long association. After going through Army basic training together and serving in the same company, they ran a military surplus business, sometimes shared a house and traveled together.

Both are said to feel hatred and distrust for the federal government. Nichols has tried to renounce his citizenship.

Prosecutors have suggested the Alfred P. Murrah Federal Building was deliberately bombed on the second anniversary of the fiery federal raid on the Branch Davidian compound in Waco, Texas, that ended with the deaths of more than 80 cult members.

Also Thursday, the General Services Administration awarded contracts to demolish what's left of the federal building with explosives, and to haul away debris. The GSA said the building will be demolished within the next 10 days, depending on further structural checks, site preparation and logistical and safety concerns.