JuliaGraphics / Gtk.jl

Julia interface to Gtk windowing toolkit.
Other
287 stars 80 forks source link

Build issue with JuliaBox #279

Open ma-laforge opened 7 years ago

ma-laforge commented 7 years ago

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 commented 7 years ago

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

timholy commented 7 years ago

sudo: no tty present and no askpass program specified

This sounds like a JuliaBox issue?

vtjnash commented 7 years ago

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)

tkelman commented 7 years ago

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.

anriseth commented 7 years ago

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.

ma-laforge commented 7 years ago

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 commented 7 years ago

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.

ihnorton commented 7 years ago

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).

duboz commented 7 years ago

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.