Generally, for such cases, the MACRO guard is not suggested to put in header files.
You can do following in header say `object.h`:
```
Object* CreateObject();
```
In `object_android.cc`
```
#include "object.h"

class ObjectAndroid : public Object {
}
// Impl for CreateObject defined in object.h.
// Although there might be other implementation in object_tizen.h
// But the _android surfix in file name will be filtered by gyp system
// to guarantee only one implementation will be include in compile.
Object CreateObject() {
  return new ObjectAndroid();
}
```