|
From: Corbett, J. <co...@sl...> - 2017-08-18 00:13:44
|
Hi, all,
We are trying to use the matlab compiler to compile m-files that contain lcaGet and lcaPut calls to create executable files on windows.
Does anyone know the correct >>mcc command?
Thanks, Jeff
-----Original Message-----
From: Eugene Tan [mailto:Eug...@sy...]
Sent: Tuesday, August 01, 2017 2:14 AM
To: Zeus Martí
Cc: atc...@li...
Subject: Re: [Atcollab-general] help with AT error
I just checked the symbols in the compiled files using nm and they do not contain the global symbols for passFunction or trackFunction, only local. Matlab has changed the way it MEXs again.
Matlab2016a
[opi@CR01OPI05 ~]$ cd /usr/local/MATLAB/R2016a/extern/lib/glnxa64/
fexport.map mexFunction.map
Matlab2017a
user@asci: /usr/local/MATLAB/R2017a ls extern/lib/glnxa64/
c_exportsmexfileversion.map fexport.map fortran_exportsmexfileversion.map mexFunction.map
It now has a two layer approach with LINKEXPORT(mexFunction.map) followed by LINKEXPORTVER (c_exportsmexfileversion.map). So what works for me is to make some small changes to the *.map file and mexpassmethod.m (attached). The change appears to have happened in R2016b!
Some nitty gritty detail below if you're interested.
Can people also check that these changes don't break anything before I commit this change to AT2.0?
I don't know how to push this out to AT1.4, so if it works can someone please do this?
Eugene
>> !nm /user/home/at14/atintegrators/AperturePass.mexa64
0000000000000b0c t AperturePass
0000000000000ac5 t atGetDoubleArray
0000000000202090 b __bss_start
0000000000202090 b completed.6344
w __cxa_finalize@@GLIBC_2.2.5
00000000000009e0 t deregister_tm_clones
0000000000000a50 t __do_global_dtors_aux
0000000000201d80 t __do_global_dtors_aux_fini_array_entry
0000000000201d90 d __dso_handle
0000000000201d98 d _DYNAMIC
0000000000202090 d _edata
0000000000202098 b _end
0000000000000d04 t _fini
0000000000000a90 t frame_dummy
0000000000201d78 t __frame_dummy_init_array_entry
0000000000000ed0 r __FRAME_END__
0000000000202000 d _GLOBAL_OFFSET_TABLE_
w __gmon_start__
00000000000008c0 t _init
w _ITM_deregisterTMCloneTable
w _ITM_registerTMCloneTable
0000000000201d88 d __JCR_END__
0000000000201d88 d __JCR_LIST__
w _Jv_RegisterClasses
0000000000000000 A MEX
U mexErrMsgIdAndTxt
0000000000000cf1 T mexfilerequiredapiversion
0000000000000bfc T mexFunction
U mexMakeMemoryPersistent
U mxCreateCellMatrix@@v7.3
U mxCreateString
U mxDuplicateArray
U mxGetField@@v7.3
U mxGetInf
U mxGetM
U mxGetN
U mxGetPr
U mxIsNaN
U mxMalloc
U mxSetCell@@v7.3
0000000000000a10 t register_tm_clones
0000000000202090 d __TMC_END__
0000000000000ba2 t trackFunction
(small t means local)
>> !nm /user/home/at14/atintegrators/AperturePass.mexa64
0000000000000b3c t AperturePass
0000000000000af5 t atGetDoubleArray
0000000000202090 b __bss_start
0000000000202090 b completed.6344
w __cxa_finalize@@GLIBC_2.2.5
0000000000000a10 t deregister_tm_clones
0000000000000a80 t __do_global_dtors_aux
0000000000201d80 t __do_global_dtors_aux_fini_array_entry
0000000000201d90 d __dso_handle
0000000000201d98 d _DYNAMIC
0000000000202090 d _edata
0000000000202098 b _end
0000000000000d34 t _fini
0000000000000ac0 t frame_dummy
0000000000201d78 t __frame_dummy_init_array_entry
0000000000000f00 r __FRAME_END__
0000000000202000 d _GLOBAL_OFFSET_TABLE_
w __gmon_start__
00000000000008f0 t _init
w _ITM_deregisterTMCloneTable
w _ITM_registerTMCloneTable
0000000000201d88 d __JCR_END__
0000000000201d88 d __JCR_LIST__
w _Jv_RegisterClasses
0000000000000000 A MEX
U mexErrMsgIdAndTxt
0000000000000d21 T mexfilerequiredapiversion
0000000000000c2c T mexFunction
U mexMakeMemoryPersistent
U mxCreateCellMatrix@@v7.3
U mxCreateString
U mxDuplicateArray
U mxGetField@@v7.3
U mxGetInf
U mxGetM
U mxGetN
U mxGetPr
U mxIsNaN
U mxMalloc
U mxSetCell@@v7.3
0000000000000a40 t register_tm_clones
0000000000202090 d __TMC_END__
0000000000000bd2 T trackFunction
(capital T means global)
Matlab2016a:
LINKEXPORT="-Wl,--version-script,"$MATLABROOT/extern/lib/$ARCH/mexFunction.map""
LDFLAGS="$LDFLAGS $LDTYPE $LINKLIBS $LINKEXPORT"
Matlab2017a:
FUNCTIONMAP=""$MATLABROOT/extern/lib/$ARCH/mexFunction.map""
VERSIONMAP=""$MATLABROOT/extern/lib/$ARCH/c_exportsmexfileversion.map""
LINKEXPORT="-Wl,--version-script,$FUNCTIONMAP"
LINKEXPORTVER="-Wl,--version-script,$VERSIONMAP"
LDFLAGS="-pthread -Wl,--no-undefined -Wl,-rpath-link,$MATLABROOT/bin/$ARCH"
LDFLAGS="$LDFLAGS $LDTYPE $LINKLIBS $LINKEXPORT"
CMDLINE2="$LD $LDFLAGS $LDTYPE $LINKOPTIM $LINKEXPORTVER $OBJS $CLIBS $LINKLIBS -o $EXE"
From: Zeus Martí [mailto:ze...@ce...]
Sent: Tuesday, August 01, 2017 3:47 PM
To: atc...@li...
Subject: Re: [Atcollab-general] help with AT error
Hi there,
We just noticed yesterday some similar problems with a similar configuration "CentOS7 + Matlab2017a + AT1.3". AT1.4 also fails, but AT1.3 has the wonderful ability to crash Matlab2017a every time it is executed. It has been recently updated, the previous version was "CentOS7 + Matlab2015a + AT1.3", so far we workaround using the old release. In our case, the same files are used by different machines with different Matlab versions so we decided not to recompile yet.
Eugene, do you by any chance know if the recompiled files work in earlier versions?
Best regards,
Zeus
On 01/08/2017 5:07, Eugene Tan wrote:
We have been trying to get AT running on CentOS7 + Matlab2017a + AT1.4 and comes up with:
Error using atpass
Element # 0: Library file: /usr/home/at14/atintegrators/AperturePass.mexa64, No passFunction or trackFunction available
I've recompiles all the pass methods using "atmexall" and compiles successfully.
Has anyone had this problem before? Windows + Matlab2016a + AT2.0 is OK.
Eugene
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Atcollab-general mailing list
Atc...@li...
https://lists.sourceforge.net/lists/listinfo/atcollab-general
|