JuliaInterop / JuliaInterop/MATLAB.jl

filepaths for Window

Open
#216 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Julia
Stars
286
Forks
64
PR merge metrics
No merged PRs in 30d

Description

Based on my comment here, I would like to point out that the filepath conventions as used by MATLAB.jl don't really seem to work with Windows. I had to manually hardcode a few places:
build.jl:

libmx_size = filesize(Libdl.dlpath(joinpath(matlab_libpath, "libmx")))
function check_deps()
  if libmx_size != filesize(Libdl.dlpath("C:\\\\Program Files\\\\MATLAB\\\\R2020b\\\\bin\\\\win64\\\\libmx.dll")) #! JR
    error("MATLAB library has changed, re-run Pkg.build(\\\"MATLAB\\\")")
  end
end

MATLAB.jl

libmx_loc = "C:\\Program Files\\MATLAB\\R2020b\\bin\\win64\\libmx.dll"
libmat_loc = "C:\\Program Files\\MATLAB\\R2020b\\bin\\win64\\libmat.dll"
libeng_loc = "C:\\Program Files\\MATLAB\\R2020b\\bin\\win64\\libeng.dll"

I just needed a quick fix, and this seemed to work for me.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting the filepath handling in build.jl and MATLAB.jl, especially the MATLAB library locations shown in the report. Reproduce the Windows setup described in the issue and trace how those paths are constructed. Done means the package locates the required MATLAB libraries on Windows without manually hardcoded paths.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia, matlab
Domain
backend, operating-systems
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.