The officially official Devuan Forum!

You are not logged in.

#1 2019-11-21 13:59:37

bgstack15
Member
Registered: 2018-02-04
Posts: 205  

wxGTK2 versus wxGTK3

With https://salsa.debian.org/freewx-team/wx now producing files for GTK3 only, I am unable to resolve

nothing provides wx3.0-headers = 3.0.4+dfsg-14 needed by libwxgtk3.0-dev
nothing provides libwxbase3.0-dev = 3.0.4+dfsg-14 needed by libwxgtk3.0-dev

The package libwxgtk3.0-dev is no longer produced, because it is now only producing libwxgtk3.0-gtk3-dev. When I install libwxgtk3.0-gtk3-dev and try to compile my dpkg (FreeFileSync) I get this classic error:

make -C FreeFileSync/Source/
make: Entering directory '/usr/src/freefilesync/10.18-1/FreeFileSync/Source'
mkdir -p /tmp/FreeFileSync_Make/ffs/src/base/
g++ -std=c++2a -pipe -DWXINTL_NO_GETTEXT_MACRO -I../.. -I../../zenXml -include "zen/i18n.h" -include "zen/warn_static.h" -Wall -Wfatal-errors -Wmissing-include-dirs -Wswitch-enum -Wcast-align -Wshadow -Wnon-virtual-dtor -O3 -DNDEBUG `wx-config --cxxflags --debug=no` -pthread `pkg-config --cflags openssl` `pkg-config --cflags libcurl` `pkg-config --cflags libssh2` `pkg-config --cflags gtk+-2.0` -isystem/usr/include/gtk-2.0 `pkg-config --cflags libselinux` -DHAVE_SELINUX -c base/algorithm.cpp -o /tmp/FreeFileSync_Make/ffs/src/base/algorithm.cpp.o
In file included from /usr/include/gtk-2.0/gdk/gdkscreen.h:32,
                 from /usr/include/gtk-2.0/gdk/gdkapplaunchcontext.h:31,
                 from /usr/include/gtk-2.0/gdk/gdk.h:32,
                 from /usr/include/gtk-2.0/gtk/gtk.h:32,
                 from ../../wx+/dc.h:15,
                 from base/../ui/file_grid_attr.h:12,
                 from base/config.h:13,
                 from base/algorithm.h:11,
                 from base/algorithm.cpp:7:
/usr/include/gtk-2.0/gdk/gdktypes.h:114:39: error: conflicting declaration ‘typedef struct _GdkDrawable GdkWindow’
  114 | typedef struct _GdkDrawable           GdkWindow;
      |                                       ^~~~~~~~~
compilation terminated due to -Wfatal-errors.
make: *** [Makefile:117: /tmp/FreeFileSync_Make/ffs/src/base/algorithm.cpp.o] Error 1
make: Leaving directory '/usr/src/freefilesync/10.18-1/FreeFileSync/Source'

This is a conflict when both gtk2 dev and gtk3 dev packages exist. I am only referencing gtk+-2.0 linking directories, so how is it getting the gtk3 parts? Or how can I get a current gtk2 package on my Devuan box?

I am also investigating compiling the application with gtk3 but that is considered experimental by the app upstream team.


This space intentionally left blank.

Offline

#2 2019-11-27 06:25:55

xunilog
Member
Registered: 2016-12-05
Posts: 26  

Re: wxGTK2 versus wxGTK3

If you clear that gtk2//3 hurdle, here's another

g++ -std=c++2a

which version of gcc is installed? (the installed version may not be able to handle c++2a)

Offline

#3 2019-11-28 01:37:15

bgstack15
Member
Registered: 2018-02-04
Posts: 205  

Re: wxGTK2 versus wxGTK3

My build environment was using gcc-9, which does support the -std=c++2a. I build packages of FreeFileSync for other distros as well, and I know how to patch the program to compile it for -std=c++17 for gcc-8 or lower.

About the error in my OP, I used to get that exact error when building by hand on my dev box when I had gtk3 and gtk2 installed on Fedora; that's why I know this exact error about the "error: conflicting declaration ‘typedef struct _GdkDrawable GdkWindow’".


This space intentionally left blank.

Offline

Board footer