Texas declared its secession from the U.S. in early 1861 and officially joined the Confederate States of America on March2 of the same year. After the Civil War and the restoration of its representation in the federal government, Texas entered a long period of economic stagnation. Historically, four major industries shaped the Texas economy prior to World War II: cattle and bison, cotton, timber, and oil. Before and after the U.S. Civil War, the cattle industry—which Texas came to dominate—was a major economic driver for the state, and created the traditional image of the Texas cowboy. In the later 19th century, cotton and lumber grew to be major industries as the cattle industry became less lucrative. It was ultimately, though, the discovery of major petroleum deposits (Spindletop in particular) that initiated an economic boom that became the driving force behind the economy for much of the 20th century. Texas developed a diversified economy and high tech industry during the mid-20th century. As of 2022, it has the most Fortune 500 company headquarters (53) in the United States. With a growing base of industry, the state leads in many industries, including tourism, agriculture, petrochemicals, energy, computers and electronics, aerospace, and biomedical sciences. Texas has led the U.S. in state export revenue since 2002 and has the second-highest gross state product. If Texas were a sovereign state, it would have the 10th-largest economy in the world. Etymology The name Texas, based on the Caddo word () 'friend', was applied, in the spelling or , by the Spanish to the Caddo themselves, specifically the Hasinai Confederacy, the final -s representing the Spanish plural. The Mission San Francisco de los Tejas was completed near the Hasinai village of Nabedaches in May 1690, in what is now Houston County, East Texas. During Spanish colonial rule, in the 18th century, the area was known as ('New Philippines') and ('New Kingdom of the Philippines'), or as ('province of the '), later also (or ), ('province of Texas'). It was incorporated as into the Mexican Empire in 1821, and declared a republic in 1836. The Royal Spanish Academy recognizes both spellings, and , as Spanish-language forms of the name of the U.S. state of Texas. The English pronunciation with is unetymological, contrary to the historical value of the letter x () in Spanish orthography. Alternative etymologies of the name advanced in the late 19th century connected the name