# Generating Julia binaries with JuMP issue

**URL:** <https://discourse.julialang.org/t/generating-julia-binaries-with-jump-issue/103072>\
**Category:** General Usage\
**Tags:** precompilation, package-compiler\
**Created:** [August 22, 2023, 3:02pm UTC](https://discourse.julialang.org/t/generating-julia-binaries-with-jump-issue/103072 "2023-08-22T15:02:16Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rajender\_Mudigonda](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rajender_mudigonda/32/52396_2.png) [@Rajender\_Mudigonda](https://discourse.julialang.org/u/Rajender_Mudigonda)\
**Post date:** [August 22, 2023, 3:02pm UTC](https://discourse.julialang.org/t/generating-julia-binaries-with-jump-issue/103072/1 "2023-08-22T15:02:17Z")

</div>

I want to create an executable for the julia file., for this i try to follow the instructions from link [Creating a binary from Julia code · PackageCompiler](https://docs.juliahub.com/PackageCompiler/MMV8C/1.2.1/devdocs/binaries_part_2.html)

when i try the below command on windows with julia version 1.9.2, juMP v1.13.0 it fails…

julia --startup-file=no -J"E:\Programs\Julia-1.9.2\lib\julia\sys.dll" --output-o sys.o custom\_sysimage.jl -Wl --export-all-symbols

**fatal: error thrown and no exception handler available.  
ReadOnlyMemoryError()**  
memcpy at C:\WINDOWS\System32\msvcrt.dll (unknown line)  
ios\_write at C:/workdir/src/support\ios.c:432  
unsafe\_write at .\iostream.jl:43  
write at .\strings\io.jl:244 [inlined]  
print at .\strings\io.jl:246 [inlined]  
#with\_output\_color#962 at .\util.jl:80  
with\_output\_color at .\util.jl:71 [inlined]  
#printstyled#963 at .\util.jl:130 [inlined]  
printstyled at .\util.jl:130  
unknown function (ip: 00000255a2d75301)  
display\_error at .\client.jl:110  
unknown function (ip: 00000255a2d7475a)  
display\_error at .\client.jl:114  
unknown function (ip: 00000255a2d72e76)  
jl\_apply at C:/workdir/src\julia.h:1879 [inlined]  
jl\_f\_\_call\_latest at C:/workdir/src\builtins.c:774  
#invokelatest#2 at .\essentials.jl:816 [inlined]  
invokelatest at .\essentials.jl:813 [inlined]  
\_start at .\client.jl:524  
unknown function (ip: 000002559604c673)  
jl\_apply at C:/workdir/src\julia.h:1879 [inlined]  
true\_main at C:/workdir/src\jlapi.c:573  
jl\_repl\_entrypoint at C:/workdir/src\jlapi.c:717  
mainCRTStartup at C:/workdir/cli\loader\_exe.c:59  
BaseThreadInitThunk at C:\WINDOWS\System32\KERNEL32.DLL (unknown line)  
RtlUserThreadStart at C:\WINDOWS\SYSTEM32\ntdll.dll (unknown line)

Am I doing something wrong? How to fix this?

I tried on ubuntu, with commands below

1. julia --startup-file=no -J"/home/rupesh/julia-1.9.2/lib/julia/sys.so" custom\_sysimage.jl  
failed to compile statement: precompile(Tuple{typeof(JuMP.parse\_constraint\_call), Function, Bool, Base.Val{:==}, Symbol, Expr})  
failed to compile statement: precompile(Tuple{typeof(JuMP.parse\_constraint\_call), Function, Bool, Base.Val{:==}, Symbol, Symbol})

but when i run command below file sys.o is not generated, see below?

1. 

rupesh@rupesh-pc:~/juliasampes$ julia --startup-file=no --output-o sys.o -J"/home/rupesh/julia-1.9.2/lib/julia/sys.so" --debug-info=0 custom\_sysimage.jl  
rupesh@rupesh-pc:~/juliasampes$ ls  
custom\_sysimage.jl PipeClient.jl Project.toml taxpayer\_precompile.jl  
Manifest.toml PipeServer.jl taxpayer.jl water.jl  
rupesh@rupesh-pc:~/juliasampes$

is the --output-o flag removed in julia 1.9.2, since with --help the flag is not shown?

Can there be compatibility issues with JuMP? What should be the best version combination to use?

---

<div class="post-metadata">

**Author:** ![guilhermebodin](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/guilhermebodin/32/6982_2.png) [@guilhermebodin](https://discourse.julialang.org/u/guilhermebodin)\
**Post date:** [August 23, 2023, 12:34pm UTC](https://discourse.julialang.org/t/generating-julia-binaries-with-jump-issue/103072/2 "2023-08-23T12:34:36Z")

</div>

I usually create executables using the create\_app function from PackageCompiler [Apps · PackageCompiler](https://julialang.github.io/PackageCompiler.jl/stable/apps.html). If it doesn’t work on your machine, you could try Julia 1.8.5 and the latest version of JuMP

---

<div class="post-metadata">

**Author:** ![Rajender\_Mudigonda](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rajender_mudigonda/32/52396_2.png) [@Rajender\_Mudigonda](https://discourse.julialang.org/u/Rajender_Mudigonda)\
**Post date:** [August 24, 2023, 7:55am UTC](https://discourse.julialang.org/t/generating-julia-binaries-with-jump-issue/103072/3 "2023-08-24T07:55:05Z")

</div>

ok thanks let me try it out.
