Dragonegg/Cross compile aarch64-apple-darwin

In order to cross compile, e.g. with gfortran, does anybody know if that’s possible? 2 questions, do I need gcc cross compiler to compile Dragonegg, or is e.g. native x86 compile sufficient. Since it only uses the GCC frontend, a x86 compiler should be fine? Is it possible to pass the proper options to the plugin, e.g. using -fplugin-arg-dragonegg-llvm-option, I haven’t had any luck with that yet?

Thanks,
Regards,
Hendrik Greving

Actually, the following seems to work:

g++ -fplugin=…/dragonegg-3.5.0.src/dragonegg.so -fplugin-arg-dragonegg-llvm-codegen-optimize=3 -fplugin-arg-dragonegg-emit-ir -flto -S quicksort.cpp
…/clang+llvm-3.5.0-x86_64-linux-gnu/bin/llc -mtriple aarch64-apple-darwin -filetype=obj quicksort.s

file quicksort.s.o
quicksort.s.o: Mach-O 64-bit 64-bit architecture=12 object

Now I guess I only need a compatible linker.