gdk-3.0.pc files should be specifying -framework as a linker argument
if you enable quartz-backend and (static or enable-explicit-deps) -framework Cocoa is added to gdk-3.0.pc, this causes issues with cmake using the ldflags, this can be fixed by using -Wl,-framework,Cocoa
Glib already uses this (or similar) format for the framework linker arguments
Libs: -L${libdir} -lglib-2.0 -L/usr/local/opt/gettext/lib -lintl -Wl,-framework -Wl,CoreFoundation
Libs.private: -L/usr/local/Cellar/pcre/8.42/lib -lpcre -lintl -Wl,-framework -Wl,CoreFoundation -liconv -Wl,-framework,Carbon -Wl,-framework,Foundation -Wl,-framework,AppKit