Closed prasunanand closed 7 years ago
The order of parameters is important to build the final executable. Changed
ldmd2 -of.dub/build/application-debug-linux.posix-x86_64-ldc_2071-6074926C76AB19CD776BAF78A8198391/gemm .dub/build/application-debug-linux.posix-x86_64-ldc_2071-6074926C76AB19CD776BAF78A8198391/gemm.o ../../../.dub/packages/mir-cpuid-0.4.2/mir-cpuid/.dub/build/library-debug-linux.posix-x86_64-ldc_2071-86B508216A4635809366D4F6A849D4A8/libmir-cpuid.a ../../../.dub/packages/mir-algorithm-0.0.30/mir-algorithm/.dub/build/library-debug-linux.posix-x86_64-ldc_2071-E4991B8128FC4747A767EA630113C462/libmir-algorithm.a ../../../.dub/packages/mir-internal-0.0.2/mir-internal/.dub/build/library-debug-linux.posix-x86_64-ldc_2071-B3B4694625705B637CB91780B7EF9921/libmir-internal.a -L--no-as-needed -L-L/home/prasun/.dub/packages/mir-glas-0.1.1/mir-glas/ -L-L/home/prasun/.dub/packages/mir-cpuid-0.4.2/mir-cpuid/ -L-L/home/prasun/.dub/packages/mir-internal-0.0.2/mir-internal/ -L-lgsl -L-lgslcblas -L-lm -L-lmir-cpuid -L-lmir-glas -L-lgslcblas -g
to
ldmd2 -of.dub/build/application-debug-linux.posix-x86_64-ldc_2071-6074926C76AB19CD776BAF78A8198391/gemm .dub/build/application-debug-linux.posix-x86_64-ldc_2071-6074926C76AB19CD776BAF78A8198391/gemm.o ../../../.dub/packages/mir-cpuid-0.4.2/mir-cpuid/.dub/build/library-debug-linux.posix-x86_64-ldc_2071-86B508216A4635809366D4F6A849D4A8/libmir-cpuid.a ../../../.dub/packages/mir-algorithm-0.0.30/mir-algorithm/.dub/build/library-debug-linux.posix-x86_64-ldc_2071-E4991B8128FC4747A767EA630113C462/libmir-algorithm.a ../../../.dub/packages/mir-internal-0.0.2/mir-internal/.dub/build/library-debug-linux.posix-x86_64-ldc_2071-B3B4694625705B637CB91780B7EF9921/libmir-internal.a -L--no-as-needed -L-L/home/prasun/.dub/packages/mir-glas-0.1.1/mir-glas/ -L-L/home/prasun/.dub/packages/mir-cpuid-0.4.2/mir-cpuid/ -L-L/home/prasun/.dub/packages/mir-internal-0.0.2/mir-internal/ -L-lm -L-lmir-glas -L-lmir-cpuid -L-lgsl -L-lgslcblas -g
and it works.
-L-lmir-glas
should be followed by -L-lmir-cpuid
I am working on a software for mixed-modelling. Currently, I have been using BLAS'
gemm
routine and would like to switch tomir-glas
. However, gsl library doesn't go well withmir-glas
.Here is a sample program that can be used to reproduce the errors. gemm_example.
dub.json => link
If I remove,
gsl
from dependencies andlibs
indub.json
, the program compiles without any errors.dub build --compiler=ldmd2 --parallel --force -v results in
https://gist.github.com/prasunanand/2bfd4b12e5fe43360bf0a0a90369af56
Other info