Melt butter in a large saucepan over medium heat. Add onion and cook until softened and translucent (reduce heat if browning). Add garlic and ginger, cook a minute more. Add remaining ingredients, cover, and bring to a boil, then reduce to a simmer and cook until carrot and apple are very tender, about 25 minutes.