modify for conditional build
non recursive version