cassidyjames / ephemeral

A private-by-default, always-incognito browser for elementary OS
https://cassidyjames.com
GNU General Public License v3.0
154 stars 22 forks source link

Cannot build 7.0.4 on FreeBSD 12.1-RELEASE-p8 amd64 #262

Closed Peter2121 closed 3 years ago

Peter2121 commented 3 years ago

Trying to build with CLANG:

[16/25] Compiling C object com.github.cassidyjames.ephemeral.p/meson-generated_src_MainWindow.c.o
FAILED: com.github.cassidyjames.ephemeral.p/meson-generated_src_MainWindow.c.o
clang -Icom.github.cassidyjames.ephemeral.p -I. -I.. -I/usr/local/include/granite -I/usr/local/include/gee-0.8 -I/usr/local/include/glib-2.0 -I/usr/l
ocal/lib/glib-2.0/include -I/usr/local/include/gio-unix-2.0/ -I/usr/local/include/gtk-3.0 -I/usr/local/include/pango-1.0 -I/usr/local/include/fribidi
 -I/usr/local/include/cairo -I/usr/local/include/pixman-1 -I/usr/local/include/freetype2 -I/usr/local/include/libdrm -I/usr/local/include/libpng16 -I
/usr/local/include/harfbuzz -I/usr/local/include/gdk-pixbuf-2.0 -I/usr/local/include/libepoll-shim -I/usr/local/include/atk-1.0 -I/usr/local/include/
at-spi2-atk/2.0 -I/usr/local/include/dbus-1.0 -I/usr/local/lib/dbus-1.0/include -I/usr/local/include/at-spi-2.0 -I/usr/local/include/libdazzle-1.0 -I
/usr/local/include/webkitgtk-4.0 -I/usr/local/include/libsoup-2.4 -I/usr/local/include/libxml2 -Xclang -fcolor-diagnostics -pipe -D_FILE_OFFSET_BITS=
64 -w -g '-DGETTEXT_PACKAGE="com.github.cassidyjames.ephemeral"' -pthread -D_THREAD_SAFE -MD -MQ com.github.cassidyjames.ephemeral.p/meson-generated_
src_MainWindow.c.o -MF com.github.cassidyjames.ephemeral.p/meson-generated_src_MainWindow.c.o.d -o com.github.cassidyjames.ephemeral.p/meson-generate
d_src_MainWindow.c.o -c com.github.cassidyjames.ephemeral.p/src/MainWindow.c
/usr/home/peter/Programming/ephemeral-7.0.4/src/MainWindow.vala:119:20: error: assignment to cast is illegal, lvalue casts are not supported
        _g_object_unref0 ((GtkWidget*) _tmp107_);
        ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
com.github.cassidyjames.ephemeral.p/src/MainWindow.c:100:56: note: expanded from macro '_g_object_unref0'
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
                                                       ^~~ ~
1 error generated.

Trying to build with GCC:

[11/25] Compiling C object com.github.cassidyjames.ephemeral.p/meson-generated_src_MainWindow.c.o
FAILED: com.github.cassidyjames.ephemeral.p/meson-generated_src_MainWindow.c.o
gcc9 -Icom.github.cassidyjames.ephemeral.p -I. -I.. -I/usr/local/include/granite -I/usr/local/include/gee-0.8 -I/usr/local/include/glib-2.0 -I/usr/lo
cal/lib/glib-2.0/include -I/usr/local/include/gio-unix-2.0/ -I/usr/local/include/gtk-3.0 -I/usr/local/include/pango-1.0 -I/usr/local/include/fribidi
-I/usr/local/include/cairo -I/usr/local/include/pixman-1 -I/usr/local/include/freetype2 -I/usr/local/include/libdrm -I/usr/local/include/libpng16 -I/
usr/local/include/harfbuzz -I/usr/local/include/gdk-pixbuf-2.0 -I/usr/local/include/libepoll-shim -I/usr/local/include/atk-1.0 -I/usr/local/include/a
t-spi2-atk/2.0 -I/usr/local/include/dbus-1.0 -I/usr/local/lib/dbus-1.0/include -I/usr/local/include/at-spi-2.0 -I/usr/local/include/libdazzle-1.0 -I/
usr/local/include/webkitgtk-4.0 -I/usr/local/include/libsoup-2.4 -I/usr/local/include/libxml2 -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64
 -w -g '-DGETTEXT_PACKAGE="com.github.cassidyjames.ephemeral"' -pthread -D_THREAD_SAFE -MD -MQ com.github.cassidyjames.ephemeral.p/meson-generated_sr
c_MainWindow.c.o -MF com.github.cassidyjames.ephemeral.p/meson-generated_src_MainWindow.c.o.d -o com.github.cassidyjames.ephemeral.p/meson-generated_
src_MainWindow.c.o -c com.github.cassidyjames.ephemeral.p/src/MainWindow.c
/usr/home/peter/Programming/ephemeral-7.0.4/src/MainWindow.vala: In function 'ephemeral_main_window_constructor':
com.github.cassidyjames.ephemeral.p/src/MainWindow.c:100:60: error: lvalue required as left operand of assignment
  100 | #define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
      |                                                            ^
/usr/home/peter/Programming/ephemeral-7.0.4/src/MainWindow.vala:119:2: note: in expansion of macro '_g_object_unref0'
  119 |         var settings_button = new Gtk.MenuButton () {
      |  ^      ~~~~~~~~~

Vala 0.40.15

Peter2121 commented 3 years ago

Sorry for noise, with Vala 0.48.10 it builds correctly.