Added support for TARGET_PLATFORMS filtering.