arturo-lang / arturo

Simple, expressive & portable programming language for efficient scripting
http://arturo-lang.io
MIT License
672 stars 29 forks source link

Arturo is not built on linux #1639

Open Nuxssss opened 1 month ago

Nuxssss commented 1 month ago

Desktop

Logs:

================================================================================

                               _                                     
                              | |                                    
                     __ _ _ __| |_ _   _ _ __ ___                    
                    / _` | '__| __| | | | '__/ _ \                   
                   | (_| | |  | |_| |_| | | | (_) |                  
                    \__,_|_|   \__|\__,_|_|  \___/                   

                     Arturo Programming Language       
                      (c)2024 Yanis Zafirópulos                      

================================================================================
 ► INSTALL
================================================================================

--------------------------------------------------------------------------------
 ● Checking environment...
--------------------------------------------------------------------------------
  os: linux
  compiler: Nim v2.0.4

--------------------------------------------------------------------------------
 ● Building...
--------------------------------------------------------------------------------
  version: 0.9.83/3112
  config: @full
  flags: --define:GMP --define:ssl

Hint: used config file '/nix/store/szgl2s5wybwjfbjxx1pb7zm5nyi0rzd7-x86_64-unknown-linux-gnu-nim-wrapper-2.0.4/etc/nim/nim.cfg' [Conf]
Hint: used config file '/nix/store/szgl2s5wybwjfbjxx1pb7zm5nyi0rzd7-x86_64-unknown-linux-gnu-nim-wrapper-2.0.4/etc/nim/config.nims' [Conf]
Hint: used config file '/home/nuxs/other/arturo/config.nims' [Conf]
..................................................................................................................................................
/nix/store/6lnbm2xybc00slspmlli4prb6dkw5c8r-nim-unwrapped-2.0.4/nim/lib/wrappers/openssl.nim(302, 74) Error: invalid pragma: gimportc
stack trace: (most recent call last)
cli.nims(210, 24)
build.nims(536, 11)      buildTask
build.nims(320, 9)       buildArturo
build.nims(312, 15)      main
build.nims(299, 28)      tryCompilation
build.nims(212, 12)      compile
nimscript.nim(265, 7)    exec
/nix/store/6lnbm2xybc00slspmlli4prb6dkw5c8r-nim-unwrapped-2.0.4/nim/lib/system/nimscript.nim(265, 7) Error: unhandled exception: FAILED: nim c --define:GMP --define:ssl -o:bin/arturo src/arturo.nim [OSError]
github-actions[bot] commented 1 month ago

Thank you for submitting an issue! :)

drkameleon commented 1 month ago

First of all, welcome!

And... thanks for the issue! :)

I admit I'm a bit baffled by it, especially being Linux (which normally gives us zero problems whatsoever...).

Could you please try downloading a Linux binary directly to see if - at least - it works as-is?

For example: https://github.com/arturo-lang/arturo/actions/runs/9139956571/artifacts/1515782308 (full version, amd64)

Also: could you run the exact same command above using --log, to see if there is any other error we might be missing, and post the result here?

Nuxssss commented 1 month ago

@drkameleon I cannot run this binary on my system because it lacks the standard linux file hierarchy and all libraries are in their own isolated directories, for example /nix/store/ddcr4jw70djdxbk78s000wrpr30hjjk2-mpfr-4.2.1/lib/libmpfr.so.6 To avoid having to change paths to dependencies with patchelf, i can usually just compile the program from scratch, and then everything should work. ./build.nims --log writes exactly the same output

drkameleon commented 1 month ago

@drkameleon I cannot run this binary on my system because it lacks the standard linux file hierarchy and all libraries are in their own isolated directories, for example /nix/store/ddcr4jw70djdxbk78s000wrpr30hjjk2-mpfr-4.2.1/lib/libmpfr.so.6 To avoid having to change paths to dependencies with patchelf, i can usually just compile the program from scratch, and then everything should work. ./build.nims --log writes exactly the same output

@Nuxssss I see... 🤔

Could you please try it with ./build.nims --mode mini --log again?

The mini version is the version without any dependencies whatsoever. So, if we get this one to compile, we could see what is going on with the full version 😉

Nuxssss commented 1 month ago

@drkameleon the mini version is being built successfully

RickBarretto commented 1 month ago

@drkameleon the mini version is being built successfully

So, this is simply an issue with nix's file hierarchy...