How French surnames began
French surnames became hereditary between the 11th and 15th centuries, and a royal ordinance of 1539 made the keeping of parish records compulsory, which helped fix them. The most common source is a father's personal name — Martin, Bernard, Thomas, Robert, Richard — followed by place names, trades (Lefebvre, the smith; Boulanger, the baker) and nicknames (Petit, Leroy, Lebrun).
French settlers carried their names to Quebec, Louisiana, the Caribbean and Africa, and Norman-French names entered England with William the Conqueror, so many English surnames are of French origin.
How the names work
The particle "de" (of) in names like de Gaulle originally pointed to a place of origin and is sometimes, but not always, a sign of nobility. Names starting with "Le" or "La" (Leroy, Lefèvre) usually began as nicknames or job descriptions with the article attached. Since 2005 French children can receive their father's surname, their mother's, or both.