Hello, 

Could you tell what would be the easiest way to include additional libraries into the compilation process of MonetDB?
More specifically I'm interested in calling MKL operations inside BAT Algebra operations.
For example, mkl standalone operation of QR decomposition (in file mkl_qr.c all the additional headers are included) is compiled as follows:

gcc -c mkl_qr.c

gcc -o mkl_qr  mkl_qr.o  -L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_gnu_thread -lmkl_core  -lgomp -lpthread -lm -ldl


What would be the proper Makefile to edit and extend with additional libraries if I want to use MKL in batcalc.c,  for example?


Thank you and best regards, 
Oksana