Repository navigation
Julia 1.13 release: OMRuntimeExternalC 0.3.3 (step 1) - #18
Merged
Merged
Conversation
OM.jl lives at github.com/OpenModelica/OM.jl. Co-authored-by: SVAGEN26 <247156613+SVAGEN26@users.noreply.github.com> Co-authored-by: JKRT <jtinnerholm@gmail.com> Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The OpenModelica build of these libraries does not work on macOS, so on
macOS every native call failed (54 of 55 tests). deps/build_msl_c_macos.sh
builds libModelica{MatIO,IO,StandardTables,ExternalC} from the Modelica
Standard Library C sources, plus the ModelicaCallbacks shim; that is all
src/api.jl calls. -D_LITTLE_ENDIAN is needed because MatIO's MAT v4 writer
does not recognise arm64 macOS.
deps/build.jl now downloads <arch>-apple-darwin.zip from the libs-*
release on macOS, like on Linux and Windows. If the release has no macOS
zip it warns and goes on, as before.
Installing the downloaded files is also safer on every platform:
- each file is renamed into place instead of written over, so a Julia
session that has the old library loaded keeps working (overwriting a
loaded Mach-O can get that session killed);
- the downloaded archives are removed even when extraction fails;
- a <platform>-callbacks.tar.gz is extracted through a temporary
directory: Tar.extract refuses the non-empty library directory and
needs an IO, not the inflated bytes, so a published callbacks tarball
could never be used before.
Tests: 269/269 on Julia 1.12.7 and 1.13 (Apple silicon), with the
libraries installed by the new build.jl path and by the script.
Assisted-by: Claude Opus 5.5
.github/workflows/macos-libs.yml builds <arch>-apple-darwin.zip for Apple silicon (macos-latest) and Intel (macos-15-intel) from the MSL C sources (tag v4.0.0 by default), tests the package against exactly those libraries on Julia 1.12 and 1.13, and, when run by hand with release_tag, uploads the zips to that libs-* release. It only uploads to an existing libs-* release: deps/build.jl uses the newest libs-* release for every platform, so a new one without the Linux and Windows zips would break them. Pull requests that touch the build script, build.jl, the shim or the workflow run the build and tests. Assisted-by: Claude Opus 5.5
.github/workflows/omjl.yml calls OM.jl's shared integration workflow (JKRT/OM.jl .github/workflows/omjl-ci.yml) on every pull request and on pushes to master and 1.13: this package's tests run against the other OM.jl packages at the matching branch (the PR branch if a sibling has it, else the PR base branch, else master), then OM.jl's test suite runs with it, on Julia 1.12 and 1.13. Assisted-by: Claude Opus 5.5
Base.find_package("OMRuntimeExternalC") resolves the name only where the
active environment lists the package directly. Precompiled under an
environment with OM only (a coverage environment), the package found no
shared libraries, and the cache kept that: every external C function
(MSL tables) then failed. The directory is now the one the source file
is in, as OMParser finds its own.
Assisted-by: Claude Opus 5.5
Pushes to 1.13 and pull requests into it run OM.jl's integration workflow on Julia 1.13 only; master keeps 1.12 and 1.13. Assisted-by: Claude Opus 5.5
MSL's real FFT (Modelica.Math.FastFourierTransform.realFFT) called a stub that raised "FFT support not compiled into this build". It is now ModelicaFFT.c's definition summed over a table of the nu roots of unity: amplitudes |X_k| / nf, phases arg(X_k) in radians, info 1 for an odd nu and 2 for a work array too small. About 7 ms for nu = 4000, the largest in the MSL examples. Tested on a signal with known coefficients. Assisted-by: Claude Opus 5.5
The OM.jl packages are verified on Julia 1.13 only (since 2026-09-28): compat julia = "1.13" (added where it was missing), and every workflow tests on 1.13. Assisted-by: Claude Opus 5.5
One version per package for the release (bumped where the version was already registered in the OpenModelica registry), and every OM.jl sibling dependency bounded below by its release version: the packages are developed in lockstep, and the registry must not pair this version with an older sibling. Assisted-by: Claude Opus 5.5
HTTP 2 dropped HTTP.download. With no compat bound on HTTP, Julia 1.13 resolved HTTP 2.8, and the build downloaded none of the prebuilt libraries on Linux and Windows (CI: "shared libraries not found", every table test errored). On Julia 1.10 the same build had resolved HTTP 1.x. The build now uses the standard library for the release-tag query and the downloads (a non-success status still raises), and HTTP is no longer a dependency. Assisted-by: Claude Opus 5.5
The library paths are looked up when the package precompiles. Julia 1.13's Pkg.instantiate precompiles the active project before Pkg.build has downloaded the libraries, and the tests then loaded a cache that holds "not found" (Linux and Windows). Auto-precompile is off in the install step. Assisted-by: Claude Opus 5.5
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Merges the 1.13 line into master for the Julia 1.13 release of the OM.jl packages: OMRuntimeExternalC 0.3.3.
Changes (9 commits)
Merge order
The OM.jl packages are released in lockstep. Merge in this order, and register each package in the
OpenModelica registry right after its merge, so that the next one resolves against it:
Please use Create a merge commit (not squash): OM.jl's submodule pointers and the sibling checkouts in CI
refer to these commits.
Verification (local, macOS, Julia 1.13 with threads)
OMFrontend 378/378, OMLibraryTesting 25/25, MetaModelica 262/262, OMRuntimeExternalC 274/274).
release-1.13, and OM.jl's integrationworkflow checks out the siblings at that branch.
Notes
julia = "1.13"in compat, and every workflow tests on 1.13.🤖 Generated with Claude Code