move code dealing w/ native constructs into clibrary; make native clibrary code private. patch by jbellis