At the peak of its success in the first half of the fourteenth century, Tlemcen was a city of perhaps 40,000 inhabitants. It housed several well-known madrasas and numerous wealthy religious foundations, and become the principal intellectual center of the central Maghreb. At the souq around the Great Mosque, merchants sold woolen fabrics and rugs from the East, slaves and gold from across the Sahara, local earthenware and leather goods, and a variety of Mediterranean maritime goods "redirected" to Tlemcen by corsairs—in addition to the intentional European imports available at the funduk. Merchant houses based in Tlemcen, such as the al-Makkari, maintained regular branch offices in Mali and the Sudan.