-
Notifications
You must be signed in to change notification settings - Fork 347
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
opam binary wont execute on my debian machine #2503
Comments
uname -a |
Just guessing try something like:
|
I suspect a binary compatibility issue : (uiserver):u72332:~/bin > cd (uiserver):u72332:~ > cd bin (uiserver):u72332:~/bin > ls -al total 6124 drwx---r-x 2 u72332 ftpusers 17 Apr 5 11:06 . drwx---r-t 27 u72332 ftpusers 4096 Apr 5 11:20 .. -rwxr-xr-x 1 u72332 ftpusers 6265225 Apr 5 11:06 opam (uiserver):u72332:~/bin > (uiserver):u72332:~/bin > ./opam -help -bash: ./opam: No such file or directory (uiserver):u72332:~/bin > |
Did you try to |
-rwxr-xr-x 1 u72332903 ftpusers 6265225 Apr 5 11:06 opam (uiserver):u72332903:~/bin > ldd opam not a dynamic executable (uiserver):u72332:~/bin > less opam "opam" may be a binary file. See it anyway? (uiserver):u72332:~/bin > (uiserver):u72332:~/bin > (uiserver):u72332:~/bin > file opam opam: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.26, not stripped (uiserver):u72332:~/bin > |
No idea. What about my last suggestion ? Are you sure the system allows you to execute binaries at that place ? |
(uiserver):u72332:~/bin > (uiserver):u72332:~/bin > chmod +x hello (uiserver):u72332:~/bin > ./hello hello world (uiserver):u72332:~/bin > cat ./hello #!/bin/sh echo "hello world" (uiserver):u72332:~/bin > |
The interwebs says maybe inspect the output of |
file opam Je soupconne l'aspect "shared library" d'être la cause du problème! Merci |
Well there's nothing to confirm here, on most linux libc will be dynamically linked anways. You should try to figure out the problems by following the steps in the link I gave you above. |
readelf indicated that 3 libraries are NEEDED! (Shared library: [libm.so.6], [libdl.so.2] and [libc.so.6]) Thanks |
First you should follow steps 2-3 of the link I mentionned since it precisely describes your problem. Once you have figured that out I would suggest you get in touch with the support of your provider to resolve any missing installation bit. |
Ok, uname -a |
Btw, I have contacted support. Waiting for their answer. Thanks |
Well it seems that they allow you to compile binaries but they don't provide support to run them. So I'd rather say that it's an install problem with our provider. You could maybe try reproduce and show them on a minimal C hello world example that links against libc. |
Is /lib64/ld-linux-x86-64.so.2 really expected to be present on Linux x86_64 machines (as reported by uname -s -m? |
Here's what I have one of my shared hosting service:
and all files are present at the reported location. To get out of the opam/ocaml whatever argument you should show them that you are not able to compile a simple C program. I suspect this should also fail on your side (try it):
|
Huuummm!!! |
So what does |
ldd a.out |
I guess I need to get an opam version compatible with this environment, but this worries me for compatibility with other tools such as ocaml (which is my goal) which micght also fail at this uname -s -m test!! |
So apparently it gets compiled in 32-bit mode. I don't remember exactly how these things work but
OCaml's configure is certainly detecting that you are on a 64-bit platform so it's trying to compile in 64-bit but apparently the support libraries are not installed on your host. |
Yes, it fails : gcc -m64 -o a.out hello.c |
Ah but in fact |
(Note however that you may often get into trouble with |
Just did that, and it cracked the lid open!! opam is running and trying to compile ocaml-4.02.3 Thanks for your help Henri=-=- Installing compiler 4.02.3 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= [compiler.get] http://caml.inria.fr/pub/distrib/ocaml-4.02/ocaml-4.02.3.tar.gz downloaded Now compiling OCaml. This may take a while, please bear with us... [ERROR] Compiler build failed at "make world.opt": # opam-version 1.2.2 # os linux # command make world.opt # path /kunden/homepages/30/d456759237/htdocs/.opam/4.02.3/build/ocaml # exit-code 2 # env-file /kunden/homepages/30/d456759237/htdocs/.opam/log/log-12029-12ca7e.env # stdout-file /kunden/homepages/30/d456759237/htdocs/.opam/log/log-12029-12ca7e.out # stderr-file /kunden/homepages/30/d456759237/htdocs/.opam/log/log-12029-12ca7e.err ### stdout ### # [...] # gcc -I../byterun -DCAML_NAME_SPACE -DNATIVE_CODE -DTARGET_amd64 -DSYS_linux -O -Wall -D_FILE_OFFSET_BITS=64 -D_REENTRANT -c -o roots.o roots.c # ln -s ../byterun/globroots.c globroots.c # gcc -I../byterun -DCAML_NAME_SPACE -DNATIVE_CODE -DTARGET_amd64 -DSYS_linux -O -Wall -D_FILE_OFFSET_BITS=64 -D_REENTRANT -c -o globroots.o globroots.c # ln -s ../byterun/signals.c signals.c # gcc -I../byterun -DCAML_NAME_SPACE -DNATIVE_CODE -DTARGET_amd64 -DSYS_linux -O -Wall -D_FILE_OFFSET_BITS=64 -D_REENTRANT -c -o signals.o signals.c # gcc -I../byterun -DCAML_NAME_SPACE -DNATIVE_CODE -DTARGET_amd64 -DSYS_linux -O -Wall -D_FILE_OFFSET_BITS=64 -D_REENTRANT -c -o signals_asm.o signals_asm.c # make[4]: Leaving directory `/homepages/30/d456759237/htdocs/.opam/4.02.3/build/ocaml/asmrun' # make[3]: Leaving directory `/homepages/30/d456759237/htdocs/.opam/4.02.3/build/ocaml' # make[2]: Leaving directory `/homepages/30/d456759237/htdocs/.opam/4.02.3/build/ocaml' # make[1]: Leaving directory `/homepages/30/d456759237/htdocs/.opam/4.02.3/build/ocaml' ### stderr ### # [...] # signals_asm.c:207: error: (Each undeclared identifier is reported only once # signals_asm.c:207: error: for each function it appears in.) # signals_asm.c:213: error: 'REG_RIP' undeclared (first use in this function) # signals_asm.c:228: error: 'REG_R14' undeclared (first use in this function) # signals_asm.c:229: error: 'REG_R15' undeclared (first use in this function) # make[4]: *** [signals_asm.o] Error 1 # make[3]: *** [makeruntimeopt] Error 2 # make[2]: *** [opt-core] Error 2 # make[1]: *** [opt.opt] Error 2 # make: *** [world.opt] Error 2 [ERROR] Initialisation failed |
Clearly there's a problem with your host machine. Here OCaml tries to compile in 64 bit mode since that's what it detects but fails to compile since the support libraries for 64-bit are absent, exactly like the simple C program above does. You can try to |
The machine is indeed 64 bits, as reported by uname, but the user environment is 32 bits (as reported by the hosting service!!). I will switch hosting service! Thanks for the help |
No such file or directory when trying to execute the opam binary!
I have added a few echo lines to opam_installer.sh to show explicitly what and where !!!
Thanks for any help
Henri
The text was updated successfully, but these errors were encountered: