Most cultures around North-East Africa and as well throught the Sahara regions are influenced from powerful Mid-Evil Middle Eastern Arab/Persian empires for many different time periods that persisted it's domain to spread long time foothold culturally.
Naturally using the suggestive power of religion of those at the time in charge demanding an integral language (from quranic arabic to developing working spoke dialects among the locals to read and write enough for the society connection.)
One spoken the Arabic language as a first tongue natively with adoption of Quranic customs would at an older point in the world would make one identify as an "Arabic" person [not necessarily though the same as ethnic arabs] which was not under racial heir at the time this world existed.
So for example an Indian, Black, and Jewish man all profess brotherhood under the Shahada swearing oaths to the religion followed by the Quran speaking it's language would make them all ethnically "Arabic" even though their nationality as blood still would be their own (The Indian an Dravidian, The Jewish man a Palestinian, the black being Somali e.t.c.) because at the time of the Quran's early connections the world was more integrated through religious assimilation.
So when a Somali merchant travels to Pakistan he would be welcomed as a Islamic brother with a mutual language & religion that they can use to bring to port (discuss, friendships, intermingle, business)
The modern world isn't this way anymore as more people in this day and age identify by "geographic ethnicity" but pieces of this has vowed continuation by many devout muslims may show these type of mannerisms of "not feeling separate" from others who hold their beliefs.