reorganize preprocessor rules a bit