[FieldTrip] mexa64 files
Burkhard Maess
maess at cbs.mpg.de
Thu Mar 27 12:49:06 CET 2025
Dear Jan-Mathijs,
thank you for your prompt response. Indeed deleting the file
rm ./fileio/private/ft_getopt.mexa64
within the fieldtrip folder solved the issue.
I also checked which files were updated during compile. As you say, most of the standard files were updated (excluding external, all files in the private folders, but ./@config/private/ was updated). It was mentioned in the fieldtrip website, that the files in private folder need running a special script.
source bin/synchronize-private.sh
This scripts kept on asking for confirmation to overwrite one .m file after the other, but although I had confirmed many of these questions, none of the corresponding mex files were updated.
Anyway, now the issue is solved at my side be removing the nuisance ;) Thanks a lot again.
best wishes,
Burkhard
--
Dr. Burkhard Maess
Brain Networks (@brainnetleipzig)
Max Planck Institute for Human Cognitive and Brain Sciences
Stephanstr. 1a, D-04301 Leipzig, Germany
phone/fax: +49 341 9940-2526/-2511 https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.cbs.mpg.de%2F~maess&data=05%7C02%7Cfieldtrip%40science.ru.nl%7Cdaed19fdfe3a4433553b08dd6d25632d%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638786729843745713%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C80000%7C%7C%7C&sdata=B8HOyFEw1O6Yxl6kgPmxUwg4Cxdc76UoP3vdEf%2FsOKI%3D&reserved=0
----- Original Message -----
| From: "FieldTrip discussion list" <fieldtrip at science.ru.nl>
| To: "FieldTrip discussion list" <fieldtrip at science.ru.nl>
| Cc: "Schoffelen, J.M. (Jan Mathijs)" <janmathijs.schoffelen at donders.ru.nl>
| Sent: Wednesday, 26 March, 2025 16:19:56
| Subject: Re: [FieldTrip] mexa64 files
| Dear Burkhard,
|
| From what you describe, it seems as if most of the mex files have compiled
| successfully. We try to stay away from (re)compiling the mex files as long as
| we can, so I haven’t tried the ft_compile_mex function recently on our
| filesystem. We (i.e. our TG) is in the process of upgrading from CentOS Linux
| (hopelessly outdated, so: whoohoo) to Almalinux version 9, which is still not
| exactly the bleeding edge (and will be outdated again relatively soon)…
|
| This being said, when I try ft_compile_mex on our end, we get the same (final)
| error that you got, but the rest compiled just fine. I suspect (and hope) that
| now the relevant mex files start working again. We should look into
| mxSerialize.cpp functions on our end, but we would be happy if one of the
| readers of this thread picks up the challenge… :)
|
| BTW, if ft_getopt still causes problems, you may want to throw away the mexa64
| altogether (note ft_getopt is in overloaded in a bunch of folders in the
| fieldtrip distribution): we have a (slower, yet functional) ft_getopt.m file
| that should have the same functionality as ft_getopt.
|
| BW,
|
| JM
|
|
|
|> On 26 Mar 2025, at 12:56, Dr. Burkhard Maess via fieldtrip
|> <fieldtrip at science.ru.nl> wrote:
|>
|> Dear Fieldtrip-Team,
|>
|> since the upgrade to Linux 6.1.0-32-amd64 my copies of fieldtrip keeps rejecting
|> to work due to this error message:
|>
|> Invalid MEX-file '/software/fieldtrip-20201117/fileio/private/ft_getopt.mexa64':
|> /software/rothirsch2/fieldtrip-20201117/fileio/private/ft_getopt.mexa64: failed
|> to map segment from shared object
|> Error in ft_read_header (line 182)
|> headerformat = ft_getopt(varargin, 'headerformat');
|>
|> I am using matlab R2024b currently, but have tested older version in respect to
|> the above problem. None if the versions R2022a, R2024a or R2024b can use the
|> mex-files anymore. They were usuable with an older installation of the linux
|> machine. However, after the system update it does not work. The version of
|> fieldtrip does not matter either. So, I read on your website and considered
|> recompiling the mex files a good idea.
|>
|> However, this was not completed without errors. It stopped while compiling with
|> g++ (see below). Do you have any hints how to get around this problem?
|>
|> Thank you very much and best wishes,
|>
|> Burkhard
|>
|>
|> in matlab (R2024b)
|>
|> >> ft_compile_mex(true)
|> Compiling MEX file compat/matlablt2010b/@uint64/abs ...
|> Building with 'gcc'.
|> MEX completed successfully.
|> Compiling MEX file compat/matlablt2010b/@uint64/min ...
|> Building with 'gcc'.
|> MEX completed successfully.
|> # .... lots of successes :)
|>
|> Compiling MEX file src/read_24bit ...
|> Building with 'gcc'.
|> MEX completed successfully.
|> Compiling MEX file src/lmoutr ...
|> Building with 'gcc'.
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c: In function
|> â€ltrisect’:
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c:176:15: warning: implicit
|> declaration of function â€mxGetNaN’ [-Wimplicit-function-declaration]
|> 176 | proj[0] = mxGetNaN();
|> | ^~~~~~~~
|> MEX completed successfully.
|> Compiling MEX file src/ltrisect ...
|> Building with 'gcc'.
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c: In function
|> â€ltrisect’:
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c:176:15: warning: implicit
|> declaration of function â€mxGetNaN’ [-Wimplicit-function-declaration]
|> 176 | proj[0] = mxGetNaN();
|> | ^~~~~~~~
|>
|> MEX completed successfully.
|> Compiling MEX file src/plinproj ...
|> Building with 'gcc'.
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c: In function
|> â€ltrisect’:
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c:176:15: warning: implicit
|> declaration of function â€mxGetNaN’ [-Wimplicit-function-declaration]
|> 176 | proj[0] = mxGetNaN();
|> | ^~~~~~~~
|>
|> MEX completed successfully.
|> ompiling MEX file src/ptriproj ...
|> Building with 'gcc'.
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c: In function
|> â€ltrisect’:
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c:176:15: warning: implicit
|> declaration of function â€mxGetNaN’ [-Wimplicit-function-declaration]
|> 176 | proj[0] = mxGetNaN();
|> | ^~~~~~~~
|>
|> MEX completed successfully.
|> Compiling MEX file src/routlm ...
|> Building with 'gcc'.
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c: In function
|> â€ltrisect’:
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c:176:15: warning: implicit
|> declaration of function â€mxGetNaN’ [-Wimplicit-function-declaration]
|> 176 | proj[0] = mxGetNaN();
|> | ^~~~~~~~
|>
|> MEX completed successfully.
|> Compiling MEX file src/solid_angle ...
|> Building with 'gcc'.
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c: In function
|> â€ltrisect’:
|> /nobackup/rothirsch2/fieldtrip-20201117/src/geometry.c:176:15: warning: implicit
|> declaration of function â€mxGetNaN’ [-Wimplicit-function-declaration]
|> 176 | proj[0] = mxGetNaN();
|> | ^~~~~~~~
|>
|> MEX completed successfully.
|> Compiling MEX file src/rfbevent ...
|> Building with 'gcc'.
|> MEX completed successfully.
|> # ... lots of successes again
|>
|> Compiling MEX file external/fileexchange/CalcMD5 ...
|> Building with 'gcc'.
|> MEX completed successfully.
|> Compiling MEX file src/mxSerialize_cpp ...
|> Building with 'g++'.
|> Error using ft_compile_mex>compile_mex_list (line 217)
|> Error using mex
|> /nobackup/rothirsch2/fieldtrip-20201117/src/mxSerialize_cpp.cpp:10:1: error:
|> â€EXTERN_C’ does not name a type
|> 10 | EXTERN_C mxArray* mxSerialize(mxArray const *);
|> | ^~~~~~~~
|> /nobackup/rothirsch2/fieldtrip-20201117/src/mxSerialize_cpp.cpp:11:1: error:
|> â€EXTERN_C’ does not name a type
|> 11 | EXTERN_C mxArray* mxDeserialize(const void *, size_t);
|> | ^~~~~~~~
|> /nobackup/rothirsch2/fieldtrip-20201117/src/mxSerialize_cpp.cpp: In function
|> â€void mexFunction(int, mxArray**, int, const
|> mxArray**)’:
|> /nobackup/rothirsch2/fieldtrip-20201117/src/mxSerialize_cpp.cpp:22:31: error:
|> â€mxSerialize’ was not declared in this scope
|> 22 | plhs[0] = (mxArray *) mxSerialize(prhs[0]);
|> | ^~~~~~~~~~~
|>
|>
|> Error in ft_compile_mex (line 114)
|> compile_mex_list(L, ftpath, force);
|> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|>
|> --
|> Dr. Burkhard Maess
|> Brain Networks (@brainnetleipzig)
|> Max Planck Institute for Human Cognitive and Brain Sciences
|> Stephanstr. 1a, D-04301 Leipzig, Germany
|> phone/fax: +49 341 9940-2526/-2511
|> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.cbs.mpg.de%2F~maess&data=05%7C02%7Cfieldtrip%40science.ru.nl%7Cdaed19fdfe3a4433553b08dd6d25632d%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638786729843768797%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C80000%7C%7C%7C&sdata=KqSNOaRoyqpWp8XJw%2B5DThVv7MVlQ4UVvFBc1%2F2Xm1s%3D&reserved=0
|>
|> _______________________________________________
|> fieldtrip mailing list
|> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fmailman.science.ru.nl%2Fmailman%2Flistinfo%2Ffieldtrip&data=05%7C02%7Cfieldtrip%40science.ru.nl%7Cdaed19fdfe3a4433553b08dd6d25632d%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638786729843788243%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C80000%7C%7C%7C&sdata=gT6pdjN6QoDUUoO7tX7cJvZkQHHmat6hyi%2BizO74IFQ%3D&reserved=0
|> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdoi.org%2F10.1371%2Fjournal.pcbi.1002202&data=05%7C02%7Cfieldtrip%40science.ru.nl%7Cdaed19fdfe3a4433553b08dd6d25632d%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638786729843807775%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C80000%7C%7C%7C&sdata=kl%2FAlNurdMZS4k293xthrZrz%2FuRUNCx0Kc6JWndurXs%3D&reserved=0
|
|
| _______________________________________________
| fieldtrip mailing list
| https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fmailman.science.ru.nl%2Fmailman%2Flistinfo%2Ffieldtrip&data=05%7C02%7Cfieldtrip%40science.ru.nl%7Cdaed19fdfe3a4433553b08dd6d25632d%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638786729843824870%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C80000%7C%7C%7C&sdata=wlPjJ%2F%2BvVMOz5dulHW%2FX5V9%2FXimPzHeKsvk4cLagWrM%3D&reserved=0
| https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdoi.org%2F10.1371%2Fjournal.pcbi.1002202&data=05%7C02%7Cfieldtrip%40science.ru.nl%7Cdaed19fdfe3a4433553b08dd6d25632d%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638786729843838843%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C80000%7C%7C%7C&sdata=ZnJ5fQigrUbFspsPvPTjyzEkf%2ByEYeUOrjdYW1PvjCQ%3D&reserved=0
More information about the fieldtrip
mailing list