Wasn't it the case that the Muqaddimah was almost forgotten until the French found it on a bookshelf in Morocco? Sometime I think it's a pity ibn Khaldun lived in the Maghreb frontiers. If he had lived in Baghdad or Egypt, the book might have become more famous.