Gtk.jl icon indicating copy to clipboard operation
Gtk.jl copied to clipboard

Build issue with JuliaBox

Open ma-laforge opened this issue 7 years ago • 9 comments

Gtk.jl apparently does not work in JuliaBox. If I run:

Pkg.build("Gtk")

I get:

INFO: Building Cairo
INFO: Building Gtk

Installing dependency libgtk-3-0 via `sudo apt-get install libgtk-3-0`:

sudo: no tty present and no askpass program specified
=================================[ ERROR: Gtk ]=================================

LoadError: failed process: Process(`sudo apt-get install libgtk-3-0`, ProcessExited(1)) [1]
while loading /home/juser/.julia/v0.5/Gtk/deps/build.jl, in expression starting on line 61

ma-laforge avatar Jan 11 '17 15:01 ma-laforge

Using Julia v0.5.0. Also noticed an issue with v6.0-dev.

ma-laforge avatar Jan 11 '17 15:01 ma-laforge

sudo: no tty present and no askpass program specified

This sounds like a JuliaBox issue?

timholy avatar Jan 11 '17 15:01 timholy

It's a BinDeps issue (now that we want to run Pkg.build detached in the background, it can no longer take foreground control over the tty to run sudo)

vtjnash avatar Jan 11 '17 15:01 vtjnash

Users on juliabox won't have sudo anyway even if the tty thing wasn't a problem. A source build fallback here would help, or we can ask for the gtk package to be installed on JuliaBox the next time it gets updated.

tkelman avatar Jan 11 '17 16:01 tkelman

Does the build script not check whether a package is installed before calling apt?

I have the same issue on the system at my university. Calling Pkg.build in the REPL, but don't have sudo-privileges. Ubuntu 16.04, libgtk-3-0 is installed.

anriseth avatar Feb 24 '17 09:02 anriseth

Indeed: I now get the same issue on my Ubuntu system as well (Had not Pkg.update()-ed for a while).

I appear to have the latest version installed on my system. sudo apt-get install libgtk-3-0 yields:

libgtk-3-0 is already the newest version.

...but I keep getting the above ERROR: Gtk message.

Maybe we should give this issue a more generic name??

ma-laforge avatar Mar 01 '17 17:03 ma-laforge

The /deps directory has not changed since the previous release of Gtk.jl.

That's strange. Would this mean what @anriseth discovered should be posted as an issue against BinDeps.jl instead?

I know very little about BinDeps.jl or its direction.

ma-laforge avatar Mar 02 '17 00:03 ma-laforge

Maybe we should give this issue a more generic name??

Yes (Gtk would be useless on JuliaBox).

You should check whether /usr/lib/x86_64-linux-gnu/libgtk-3.so exists (presumably a symlink), and make sure you can dlopen that from Julia. If it does not exist, you may need to figure out what the file is now called on Ubuntu, and add an alias (to deps/build.jl, in the gtk section of the deps list).

ihnorton avatar Mar 02 '17 01:03 ihnorton

Hello. I use Linux Debian unstable and Julia v0.4.7. I modified the file build.jl, line 20, change "libgtk-3-0" to "libgtk3-0" and it works. Still have many Warnings when compiling thought depreciated Base.String floattype redefinition.

duboz avatar Mar 05 '17 14:03 duboz