Asking help for Arduino Due board with Mega2560 code

Hi experts,

Now I met a problem when I explant codes(which runs normal in Mega2560 for FDM device) to Due board. I know the core
chip is different , one is 8-bit, the other is 32-bit. But I don't know which type of hardware I can use for Due Board. For example,
in Mega2560, it defined as :
#ifndef AVR_ATmega1280
#ifndef AVR_ATmega2560
#error Oops! Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu.
#endif
#endif
So, what kind of hardware for Due? Or just defined by myself no matter what I want?
And the other question is , the headfile I included from is AVR or Sam? Maybe I need modified it to Sam?

It's the first time I use the Due board, Please help me and tell me some basic methods or matters need attention.

Thank you so much!

Please do not cross post, it wastes peoples time.