Moved and renamed GT_ definitions and functions to q_shared