eyelash / xi-gtk

a GTK front-end for the Xi editor
Apache License 2.0
355 stars 23 forks source link

Regression when compiling xi-gtk #41

Closed charlesetc closed 6 years ago

charlesetc commented 6 years ago

I ran into this trying to build xi-gtk. Maybe there's something wrong in my environment but xi-gtk builds from a few commits ago and not on master:

charles#localhost#build (ea13c79...) 
$ ninja
[1/16] Compiling Vala source .....lities.vala ../src/Window.vala.
FAILED: valac -C --debug --pkg gio-unix-2.0 --pkg json-glib-1.0 --pkg gtk+-3.0 --directory xi-gtk@exe --basedir ../ --gresources=../re
sources/gresource.xml ../src/Application.vala ../src/Blinker.vala ../src/CoreConnection.vala ../src/EditView.vala ../src/EditViewConta
iner.vala ../src/FindBar.vala ../src/Line.vala ../src/LineCache.vala ../src/Notebook.vala ../src/Style.vala ../src/StyleMap.vala ../sr
c/Theme.vala ../src/Utilities.vala ../src/Window.vala
../src/EditView.vala:174.7-174.20: error: The name `focus_on_click' does not exist in the context of `Xi.EditView.button_press_event'
                if (focus_on_click && !has_focus) {
                                    ^^^^^^^^^^^^^^
                                    Compilation failed: 1 error(s), 0 warning(s)
                                    ninja: build stopped: subcommand failed.

charles#localhost#build (ea13c79...) 
$ git co HEAD~
Previous HEAD position was ea13c79... require GTK 3.20
HEAD is now at f4af683... don't use Pango to draw the backgrounds

charles#localhost#build (f4af683...) 
$ ninja
[1/1] Regenerating build files.
Warning: You are using 'ANSI_X3.4-1968' which is not a Unicode-compatible locale.
You might see errors if you use UTF-8 strings as filenames, as strings, or as file contents.
Please switch to a UTF-8 locale for your platform.
The Meson build system
Version: 0.43.0
Source dir: /home/charles/code/xi-editor/xi-gtk
Build dir: /home/charles/code/xi-editor/xi-gtk/build
Build type: native build
Project name: xi-gtk
Native C compiler: cc (gcc 5.4.0)
Native Vala compiler: valac (valac 0.30.1)
Build machine cpu family: x86_64
Build machine cpu: x86_64
Library m found: YES
Found pkg-config: /usr/bin/pkg-config (0.29.1)
Native dependency glib-2.0 found: YES 2.54.0
Configuring com.github.eyelash.xi-gtk.service using configuration
Build targets in project: 3
Found ninja-1.5.1 at /usr/bin/ninja
[4/4] Linking target xi-gtk.

Let me know if you want me to test something!

eyelash commented 6 years ago

Can you try a clean build? Just delete the build directory and rerun Meson.

charlesetc commented 6 years ago

Yes just tried it -- it still fails.

eyelash commented 6 years ago

Strange. What distribution are you on and what version of GTK+ and Meson do you have?

charlesetc commented 6 years ago

Ubuntu version Ubuntu 16.04.3 LTS Gtk version 3.18.9-1ubuntu3.3 Meson version 0.43.0

eyelash commented 6 years ago

Yeah, you need GTK+ 3.20 or newer.

charlesetc commented 6 years ago

Whoops! I did attempt to install gtk 3.20+ but I guess it didn't work -- sorry about that!