summaryrefslogtreecommitdiff
path: root/macros/CCodeGeneration
diff options
context:
space:
mode:
authorsiddhu89902017-06-20 15:26:40 +0530
committersiddhu89902017-06-20 15:26:40 +0530
commitfad32de9c3df04a8fb032f9c604c79c89d062154 (patch)
treeaf5ae0b9047e2591b03215033cb209565e943fc7 /macros/CCodeGeneration
parent0aaa69ac8c8cfc262305a0c93219c72971dc78cd (diff)
downloadScilab2C_fossee_old-fad32de9c3df04a8fb032f9c604c79c89d062154.tar.gz
Scilab2C_fossee_old-fad32de9c3df04a8fb032f9c604c79c89d062154.tar.bz2
Scilab2C_fossee_old-fad32de9c3df04a8fb032f9c604c79c89d062154.zip
Bug fixed for GSL library
Diffstat (limited to 'macros/CCodeGeneration')
-rw-r--r--macros/CCodeGeneration/C_GenerateMakefile.sci19
-rw-r--r--macros/CCodeGeneration/lib2
2 files changed, 20 insertions, 1 deletions
diff --git a/macros/CCodeGeneration/C_GenerateMakefile.sci b/macros/CCodeGeneration/C_GenerateMakefile.sci
index 7dfb4da..893ec93 100644
--- a/macros/CCodeGeneration/C_GenerateMakefile.sci
+++ b/macros/CCodeGeneration/C_GenerateMakefile.sci
@@ -78,6 +78,25 @@ else
PrintStringInfo('CXXFLAGS = -Wall -pedantic -g -I $(HSRCDIR) -I $(ISRCDIR) -L $(LIBDIR)',FileInfo.MakefileFilename,'file','y','y');
PrintStringInfo('LDFLAGS = -lblas -llapack -lm ',FileInfo.MakefileFilename,'file','y','y');
end
+
+ //If ode function is used, add libgsl.
+ if(size(SharedInfo.Includelist) <> 0)
+ if((mtlb_strcmp(part(SharedInfo.Includelist(1),1:5),'odefn') == %T))
+ if(target == 'RPi')
+ PrintStringInfo('LDFLAGS = -lgsl -lcblas',FileInfo.MakefileFilename,'file','y','y');
+ else
+ PrintStringInfo('LDFLAGS = -lgsl',FileInfo.MakefileFilename,'file','y','y');
+ end
+
+ end
+ end
+
+ if (target == 'RPi')
+ PrintStringInfo('LDFLAGS += -llapack -lrefblas -lgfortran -lwiringPi',FileInfo.MakefileFilename,'file','y','y');
+ else
+ PrintStringInfo('LDFLAGS += -lblas -llapack -lm ',FileInfo.MakefileFilename,'file','y','y');
+ end
+
if(SharedInfo.OpenCVUsed == %T)
PrintStringInfo('LDFLAGS += -lopencv_calib3d -lopencv_contrib -lopencv_features2d -lopencv_flann -lopencv_gpu',FileInfo.MakefileFilename,'file','y','y');
PrintStringInfo('LDFLAGS += -lopencv_highgui -lopencv_imgproc -lopencv_legacy -lopencv_ml -lopencv_nonfree',FileInfo.MakefileFilename,'file','y','y');
diff --git a/macros/CCodeGeneration/lib b/macros/CCodeGeneration/lib
index 2db4b8c..28e3346 100644
--- a/macros/CCodeGeneration/lib
+++ b/macros/CCodeGeneration/lib
@@ -6,7 +6,7 @@
<macro name="C_GenDeclarations" file="C_GenDeclarations.bin" md5="ee8ec8971503228c9717c5125fce85f3"/>
<macro name="C_GenerateFunName" file="C_GenerateFunName.bin" md5="085877ab44748da056c79995d3555ec2"/>
<macro name="C_GenerateLaunchScript" file="C_GenerateLaunchScript.bin" md5="6a7eebd266f6ba252a610a9b6e5e12fe"/>
- <macro name="C_GenerateMakefile" file="C_GenerateMakefile.bin" md5="2786ec422a65d735cbeef69d14e1e801"/>
+ <macro name="C_GenerateMakefile" file="C_GenerateMakefile.bin" md5="7874d54e825ecb576f9b3e0d9c7d781b"/>
<macro name="C_GenerateMakefile_msvc" file="C_GenerateMakefile_msvc.bin" md5="d2962ecb30341f5815ddc52e6fc03543"/>
<macro name="C_GenerateSCI2CHeader" file="C_GenerateSCI2CHeader.bin" md5="0718f257ee598048a8c8c0fcdb06c8fc"/>
<macro name="C_IfElseBlocks" file="C_IfElseBlocks.bin" md5="78d53c95511b9b46ea8739a177efd631"/>