La idea de usar el preprocesador es buena....
#define OPCION 1
#if (OPCION==1)
** //tu codigo para opcion 1**
#endif **
#if (OPCION==2)
** //tu codigo para opcion 2
#endif
O usando #if defined...
En el core Arduino, puedes ver muchos ejemplos de cómo lo hacen dependiendo que micro ha sido seleccionado..... Por ejemplo:
#if defined(AVR_ATmega1280) || defined(AVR_ATmega2560)
** const static uint8_t SS = 53;**
** const static uint8_t MOSI = 51;**
** const static uint8_t MISO = 50;**
** const static uint8_t SCK = 52;**
#else
** const static uint8_t SS = 10;**
** const static uint8_t MOSI = 11;**
** const static uint8_t MISO = 12;**
** const static uint8_t SCK = 13;**
#endif