started macos port by adapting the old SGL code