Comments (15)
Could your try to do the following and post the output?
Pkg.clone("https://github.com/dhoegh/BuildExecutable.jl")
Pkg.test("BuildExecutable")
As i have changed a couple of things in the script in this repository. What are your versioninfo()
. If you are on OSX you need to checkout #2. I still need to clean it up, but it works on Travis OSX.
from buildexecutable.jl.
Indeed you were right. Running the tests gave some errors:
INFO: Testing BuildExecutable
running: /usr/bin/julia /usr/share/julia/build_sysimg.jl /usr/lib/julia/libtest_executable native /tmp/tmpTylHkc/userimg.jl --force
ERROR: LoadError: Unable to modify /usr/lib/julia/libtest_executable.ji, ensure parent directory exists and is writable. Absolute paths work best.)
in anonymous at /usr/share/julia/build_sysimg.jl:37
in build_sysimg at /usr/share/julia/build_sysimg.jl:27
while loading /usr/share/julia/build_sysimg.jl, in expression starting on line 175
ERROR: LoadError: test error in expression: build_executable(exename,script,targetdir,"native"; force=false) == 0
failed process: Process(`/usr/bin/julia /usr/share/julia/build_sysimg.jl /usr/lib/julia/libtest_executable native /tmp/tmpTylHkc/userimg.jl --force`, ProcessExited(1)) [1]
in build_executable at /home/gideon/.julia/v0.4/BuildExecutable/src/BuildExecutable.jl:111
in anonymous at test.jl:90
in do_test at test.jl:50
[inlined code] from /home/gideon/.julia/v0.4/BuildExecutable/test/runtests.jl:9
in anonymous at no file:0
in build_executable at /home/gideon/.julia/v0.4/BuildExecutable/src/BuildExecutable.jl:111
in anonymous at test.jl:90
in do_test at test.jl:50
[inlined code] from /home/gideon/.julia/v0.4/BuildExecutable/test/runtests.jl:9
in anonymous at no file:0
while loading /home/gideon/.julia/v0.4/BuildExecutable/test/runtests.jl, in expression starting on line 8
=============================================================================================[ ERROR: BuildExecutable ]=============================================================================================
failed process: Process(`/usr/bin/julia --check-bounds=yes --code-coverage=none --color=yes /home/gideon/.julia/v0.4/BuildExecutable/test/runtests.jl`, ProcessExited(1)) [1]
====================================================================================================================================================================================================================
ERROR: BuildExecutable had test errors
in test at pkg/entry.jl:803
in anonymous at pkg/dir.jl:31
in cd at file.jl:22
in cd at pkg/dir.jl:31
in test at pkg.jl:71
versioninfo()
is
Commit cbe1bee (2015-11-08 10:33 UTC)
Platform Info:
System: Linux (x86_64-unknown-linux-gnu)
CPU: Intel(R) Core(TM) i7-2640M CPU @ 2.80GHz
WORD_SIZE: 64
BLAS: libopenblas (DYNAMIC_ARCH NO_AFFINITY Sandybridge)
LAPACK: libopenblas
LIBM: libm
LLVM: libLLVM-3.3
I'm running arch linux.
from buildexecutable.jl.
A comment on a line just before the error is thrown, states that you need write permission to /usr/lib/julia/
could you try to start julia in sudo
and do Pkg.test("BuildExecutable")
from buildexecutable.jl.
BTW if when you get the test working and afterwards do build_executable(exename, script, targetdir, "native"; force=false)
you should be aware that the machine you transfer the executable to understand the same CPU instructions. You can change the executable to use an older instruction set by doing build_executable(exename, script, targetdir, "core2"; force=false)
from buildexecutable.jl.
Just tried running julia in sudo. Got another error...
julia> Pkg.test("BuildExecutable")
INFO: Initializing package repository /root/.julia/v0.4
INFO: Cloning METADATA from git://github.com/JuliaLang/METADATA.jl
ERROR: BuildExecutable did not provide a test/runtests.jl file
in test at pkg/entry.jl:803
in anonymous at pkg/dir.jl:31
in cd at file.jl:22
in cd at pkg/dir.jl:31
in test at pkg.jl:71
I was originally using contrib/build_executable.jl
and running it in
sudo, but with similar error messages.
Ahh, thanks for the comment about "core2"
. I was wondering about that.
Still not sure what "core2"
refers to though.
On Fri, Nov 20, 2015 at 1:23 AM Daniel Høegh [email protected]
wrote:
BTW if when you get the test working and afterwards do build_executable(exename,
script, targetdir, "native"; force=false) you should be aware that the
machine you transfer the executable to understand the same CPU
instructions. You can change the executable to use an older instruction set
by doing build_executable(exename, script, targetdir, "core2";
force=false)—
Reply to this email directly or view it on GitHub
#5 (comment)
.
from buildexecutable.jl.
It seems like you do not have access to the previous clone of this package. Could you try to start julia in sudo and do
Pkg.clone("https://github.com/dhoegh/BuildExecutable.jl")
Pkg.test("BuildExecutable")
Ahh, thanks for the comment about
"core2"
. I was wondering about that.
Still not sure what"core2"
refers to though.
I am not completely sure either. It has something to do with which instructions the CPU understands in the machine code.
from buildexecutable.jl.
Nice, tests passed and now it works for my "hello world" example!
But,
(1) it doesn't work as soon as I start using DataFrames
error during bootstrap:
LoadError(at "sysimg.jl" line 319: LoadError(at
"/usr/share/julia/base/userimg.jl" line 1: LoadError(at
"/home/gideon/hello_world/hello_world.jl" line 1:
Base.ArgumentError(msg="DataFrames not found in path"))))
(2) the hello world binary doesn't run on my cluster because it can't find
libjulia.so
. I was afraid of this. Does it mean that compiling a simple
binary executable that can be "run anywhere" is beyond reach?
On Fri, Nov 20, 2015 at 1:42 AM Daniel Høegh [email protected]
wrote:
It seems like you do not have access to the previous clone of this
package. Could you try to start julia in sudo and doPkg.clone("https://github.com/dhoegh/BuildExecutable.jl")
Pkg.test("BuildExecutable")Ahh, thanks for the comment about "core2". I was wondering about that.
Still not sure what "core2" refers to though.I am not completely sure either. It has something to do with which
instructions the CPU understands in the machine code.—
Reply to this email directly or view it on GitHub
#5 (comment)
.
from buildexecutable.jl.
I should have fixed the realacation issue for your "hello world" on the server see 6a1e0fd.
from buildexecutable.jl.
Now I'm getting a different error.
ERROR: ArgumentError: '/home/gideon/hello_world/helloworld/helloworld'
exists. `remove_destination=true` is required to remove
'/home/gideon/hello_world/helloworld/helloworld' before moving.
in checkfor_mv_cp_cptree at file.jl:90
in build_executable at
/root/.julia/v0.4/BuildExecutable/src/BuildExecutable.jl:142
But remove_destination
is not an argument to build_executable
.
On Fri, Nov 20, 2015 at 11:35 AM Daniel Høegh [email protected]
wrote:
I should have fixed the realacation issue for your "hello world" on the
server see 6a1e0fd
6a1e0fd
.—
Reply to this email directly or view it on GitHub
#5 (comment)
.
from buildexecutable.jl.
You need to remove the files in the folder targetdir
as it tries to copyfiles to the directory that already exist. BTW the following is working fine for me
import DataFrames
import Base.Test
function main()
df = DataFrames.@data([3, 2, 5, 4]) #Full qualification of names is required
Base.Test.@test maximum(df) == 5
println("It works")
end
Full qualification of names in modules is required see: https://github.com/dhoegh/BuildExecutable.jl#note-on-packages
from buildexecutable.jl.
The error message should be better or not occur with c9d559b commit.
from buildexecutable.jl.
Hooray! Yes, it compiled. Slowly I am learning =)
I copied over everything in targetdir
to the server (a cluster) and tried
to run the helloworld program. Unfortunately, it seems the .so files in the
"package" are still missing one. Have you gotten the binary to run on other
computers?
./helloworld: error while loading shared libraries: libunwind.so.8: cannot
open shared object file: No such file or directory
On Fri, Nov 20, 2015 at 12:35 PM Daniel Høegh [email protected]
wrote:
The error message should be better with c9d559b
c9d559b
commit.—
Reply to this email directly or view it on GitHub
#5 (comment)
.
from buildexecutable.jl.
I have used it to distribute a small program on different windows computers, but not on Linux. I do not have to much time to look into this. You could try to locate and copy libunwind.so.8
to the targetdir
and see if this helps.
from buildexecutable.jl.
Ok. No problem.
Yeah, I tried but to no avail. It throws a bunch of other errors when I do
that. There isn't any sort of window versus linux setting somewhere is
there? My first thought was that libunwind.so
is related to windows.
Thanks for the help. Maybe someday this will become a stable feature of
Julia.
On Fri, Nov 20, 2015 at 1:06 PM Daniel Høegh [email protected]
wrote:
I have used it to distribute a small program on different windows
computers, but not on Linux. I do not have to much time to look into this.
You could try to locate and copy libunwind.so.8 to the targetdir and see
if this helps.—
Reply to this email directly or view it on GitHub
#5 (comment)
.
from buildexecutable.jl.
libunwind is a library for call stack unwinding and is not windows specific.
Thanks for the help. Maybe someday this will become a stable feature of
Julia.
This solution is only a short term hack the Julia team plan to be able to statically compile julia see, JuliaLang/julia#13677.
from buildexecutable.jl.
Related Issues (20)
- Compilation of packages HOT 4
- @windows_only is deprecated in Julia v0.5.0 HOT 2
- Writing to /usr/lib HOT 3
- Whats the point in using inference0? HOT 1
- BuildExecutable use-case question HOT 7
- .juliarc.jl not respected
- Test fails Ubuntu 16 Julia 0.5.2
- Test Failed under julia 0.6
- Fails with "@unix_only not defined" HOT 5
- Adopt approach from JuliaComputing/static-julia? HOT 1
- Tag a new release
- Portable cpu_target on Windows HOT 1
- Build sys.o hangs
- Test failed...
- Wont build with Gtk
- error
- undefined reference to `jl_show' HOT 1
- windows 7 portability issue
- Julia 1.0 Build Error
- Info about upcoming removal of packages in the General registry
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from buildexecutable.jl.