Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

generate mex files on build #162

Open
spribitzer opened this issue Nov 7, 2019 · 2 comments
Open

generate mex files on build #162

spribitzer opened this issue Nov 7, 2019 · 2 comments
Assignees
Labels
decision A decision needs to be made

Comments

@spribitzer
Copy link
Contributor

The platform (Windows, Unix, MacOS) dependent mex files need to be compiled manually every time their source code is changed. Is there a way to automatize it?

  1. On every push to master a GitHub action can run that checks if the source code has changed. If yes, mex files are compiled on all three platforms and pushed to the repository for a new commit.

  2. Keep mex files outside of source control and only create and package them up with builds. This has the disadvantage developers need to manually generate them after cloning the repo.

@spribitzer spribitzer added the decision A decision needs to be made label Nov 7, 2019
@spribitzer
Copy link
Contributor Author

this can be revisited once we have the new windows and macOS machines

@cerium1925
Copy link

cerium1925 commented Sep 12, 2024

The generation of this mex file may be related to its generation environment and platform, such as MATLAB's parallel mode: Threads or processes, C/C++'s corresponding mex compiler, Intel oneapi or VS studio? After my personal test, the most basic MATLAB parallel mode is different, the mex cannot be called. Therefore, this part needs to be standardized and rigorously tested.

error code:

Parallel pool is ready.
Error using LineShapes (line 61)
Use of MEX functions is not supported on a thread-based
worker. Use a PARPOOL('Processes') process-based pool or
a different process-based pool instead.

Error in field2line (line 46)
[ranges, Ints] = LineShapes(x0, field, int, Sys);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
decision A decision needs to be made
Development

No branches or pull requests

3 participants