To elaborate, when European kingdoms invaded the Levant and sought to capture holy cities and sites, there was a clear religious motive behind it. To Muslim powers defending against them, was there a perception of a broader religious conflict between the two faiths or did they look at the crusades simply as invasions meant to be repelled?
Early in the First Crusade, there was not much going on that seemed unusual. The Byzantines hired lots of foreign mercenaries and then sent these mercenaries into Anatolia and Syria and that is all the crusaders looked like at first. It is only after the crusaders took some land without handing it back to the Byzantines and start fighting in a manner that mercenaries would never (like besiege Antioch for 8 months with limited supplies, seriously, no paycheck is worth eating your own horse) that people started wondering what's up. Then the crusaders made a run for the strategically weak position of Jerusalem without conquering the lands along the way and... well, it's clear by the time they are making barefoot processions around the city walls this ain't your average army.
As to whether or not there was a religious motivation for the First Crusade, it depends on whose analysis you believe. Many will say Urban II was looking to support the Byzantines and maybe push a reconciliation of the churches. People who argue this will point out that most of our records of the First Crusade are written after the fall of Jerusalem, with the hindsight that the crusaders were victorious and therefore confident in God's support. On the other hand, archival documents show participants selling land and titles to finance their trip, things you just wouldn't do unless you were expecting a reward greater than money.
On the Muslim side, it's not really until the reign of Nur al-Din (after the Second Crusade) that a rhetoric of jihad and unifying against the crusaders becomes important. Even then, it's not like the crusades were considered all that important in the broader Muslim world. Most of the Muslim world was too busy dealing with things like family fights among the Seljuqs and Mongol invasions to worry about a little strip of Mediterranean coastland.
If you want to read more about the Muslim response to the Crusades, check out Amin Maalouf's The Crusades through Arab Eyes.
If you want something a bit more academic, try Carole Hillenbrand, The Crusades: Islamic Perspectives or the recent book Paul Cobb, The Race for Paradise.
Brian Catlos also has a new book, Infidel Kings and Unholy Warriors: Faith, Power, and Violence in the Age of Crusade and Jihad which focuses on a lot of topics I know this subreddit loves to discuss.
Not at first. Indeed, some Muslim princes maintained alliances with the Crusaders for some time after the crusade. Then as time went on the thinking of the Muslims began to change. Probably the first voice to speak out loudly on the holy war issue was a Damascene preacher called Ali ibn Tahir al-Sulami. He began to preach a Jihad, holy war, against the crusaders. Some of his work survives in his "book of Jihad" but is is incomplete. He died in 1106, the crusade was done by 1100, so quite quickly we can see that the idea of a holy war was beginning to take form. However, he and the idea of holy war were neglected until Saladin united the Muslim world.
Thanks for all the responses guys, they've been really insightful. And thanks for the sources! I'm definitely trying to read up on this subject matter so I appreciate the guidance
One of the problems is these areas is deciding how people thought compared to what they said. Someone claiming their actions are based on Gods Message to liberate the Holy Land may still be having a clear monologue on the inside saying 'and i might get to be king and have all the bitches to myself'. However on the surface its likely that the initial Crusades were reasonably well motivated by true religious fervour. There was a Peoples Crusade and (debatebly) a Childrens Crusade who on the surface had purer motives. Many of the nobles in the FC were significant landowners, many though were second sons and the like. I'll give them the benefit of the doubt.
Most of the locals had been fighting amongst themselves and against the Byzantines for several hundred years by the time of the First Crusade. This new lot were just another factor in the equation, if they wanted your land they were an enemy, if they wanted your neighbours land, they were a gift! Hence why quite of the locals allied with them at various stages.
Only after it became clear that they had a strong agenda involving permanent conquest did the resistance against them harden. And, as is the same today, when things get tougher and meaner people become more resilient and extreme in their response.
Thus I think, religious fervour wise, the Arab side came a bit late to he party but got there in the end.