Hmmm....after Megaman 9 huh? Didnt Light's robots have experation dates? Maybe Rock was forced to get one after the law was passed and then they scrapped him and the rest of Light's bots. Light secretly took Rock's mind (or whatever he needed) and made X. That's a possible explaination given what news MM9 shows.
They probably kept his expiration date on hold, because the world needed a savior if Wily ever attacks again. But in the end, Mega (Along with other robots) were put into a Robot Musem, for great honor to him when Wily "vanished" so he can begin building Zero, thus removing him from the mind of the public years later. (being in textbooks, perhaps) Light made a copy of his mind (As your point), just in case they needed a savior for the next few centuries. Rock's old data, however, was constantly put on replay on his "holy actions".
Now fast-foward to the X series. Zero was discovered before X (Sigma was there during an escort, meaning that Zero was intentionally the base for some police reploids, as now dubbed. however, during that clash, he went mad, but however, during a scene of MHX, He was probably told to do so by the reploid creator, being Dr Cain himself. however, during that final battle in X8, Axl was belived to be "dead" until his revival in ZXA.
However, now back to the Zero series, the elf wars has passed, "OLD X" has entered the history books, Copy X reigns supreme. Zero defeats him, and a chain of events happen afterward. Now that Weil was returned. Zero may have ententionally completed his task of ending X's life, aka, the copy. therefore, completing Zero's purpose while Wily was in glee in hell. (He has been watching the events from there, possibly)
.. Sorry if I went overboard and if it doesn't make sense, I thought the whole Mega thing needed a rant or two.