updated for orangered and external headers