Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Compiling uTox
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
Marcih
Tux's lil' helper
Tux's lil' helper


Joined: 19 Feb 2018
Posts: 147

PostPosted: Sat Feb 23, 2019 5:18 pm    Post subject: [SOLVED] Compiling uTox Reply with quote

Does anyone have any experience with compiling uTox? I tried the precompiled binaries provided but calling doesn't work without DBus installed and the file picker used is the GTK+3 one so I wanted to try to compile.
I followed the build instructions but I can't even get past the
Code:
cmake ..
part (what exactly is happening in that step?), CMake complains about missing libraries. What's odd is that I have all the dependencies installed, or at least all the required ones. First it was complaining about DBus, after that it's about filter_audio.

I quite frankly don't understand what's happening when you compile from source, what CMake does here, all I've ever done was
Code:
./configure
make
make install
Could anyone give me a hand, even if it's only general advice about compiling?
_________________
Bones McCracker wrote:
It wouldn't be so bad, if it didn't suck.

===
I refuse to move on from GTK+2.


Last edited by Marcih on Sat Feb 23, 2019 8:01 pm; edited 1 time in total
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 5583

PostPosted: Sat Feb 23, 2019 6:10 pm    Post subject: Reply with quote

There used to be an ebuild in the main tree, maybe you can dig it up. I switched to qtox because this was causing OOMs during build with 2GB RAM.
Back to top
View user's profile Send private message
Marcih
Tux's lil' helper
Tux's lil' helper


Joined: 19 Feb 2018
Posts: 147

PostPosted: Sat Feb 23, 2019 8:00 pm    Post subject: Reply with quote

Ant P. wrote:
There used to be an ebuild in the main tree, maybe you can dig it up. I switched to qtox because this was causing OOMs during build with 2GB RAM.

Thanks for the tip, there's an ebuild in someone's overlay, turns out the CMake flags were -DENABLE_DBUS/FILTERAUDIO/TESTS=ON/OFF. Why was uTox dropped from the official repos? I suppose chances of getting it back are slim since not even the qTox ebuilds are actively maintained anymore.
It still seems to require GTK+3 file picker but I'll have to inquire the devs directly about that one. I'll mark this one solved.

Won't bump an already-solved thread so I'll just edit this in:
Found a solution for the GTK+ file picker change on the Web, just edit the src/xlib/gtk.c file like the patch says.
Unfortunately the file picker still wouldn't launch, I guess it was because it was trying to load "widget_set_margin_left" and "widget_set_margin_right" from the GTK+ lib, commenting out the lines mentioning it and recompiling did the trick.
The final patch is as follows:
Code:
--- src/xlib/gtk.c.old  2019-02-24 17:23:38.702737879 +0100
+++ src/xlib/gtk.c      2019-02-24 17:15:52.507700317 +0100
@@ -24,8 +24,8 @@
 #include <stdlib.h>
 #include <string.h>

-#define LIBGTK_FILENAME "libgtk-3.so"
-#define LIBGTK_FILENAME_FALLBACK "libgtk-3.so.0"
+#define LIBGTK_FILENAME "libgtk-x11-2.0.so"
+#define LIBGTK_FILENAME_FALLBACK "libgtk-x11-2.0.so.0"

 #define GTK_FILE_CHOOSER_ACTION_OPEN 0
 #define GTK_FILE_CHOOSER_ACTION_SAVE 1
@@ -49,8 +49,8 @@
 void (*utoxGTK_init)(int *, char ***);
 bool (*utoxGTK_events_pending)(void);
 bool (*utoxGTK_main_iteration)(void);
-void (*utoxGTK_widget_set_margin_left)(void *, int);
-void (*utoxGTK_widget_set_margin_right)(void *, int);
+/*void (*utoxGTK_widget_set_margin_left)(void *, int);
+void (*utoxGTK_widget_set_margin_right)(void *, int);*/
 void (*utoxGTK_widget_destroy)(void *);
 void *(*utoxGTK_message_dialog_new)(void *, int, int, int, const char *, ...);
 int (*utoxGTK_dialog_run)(void *);
@@ -107,10 +107,10 @@
         return;
     }

-    // pad to MAX_PREVIEW_SIZE + 3px margins
+/*    // pad to MAX_PREVIEW_SIZE + 3px margins
     int margin = (MAX_PREVIEW_SIZE + 6 - utoxGDK_pixbuf_get_width(pixbuf)) / 2;
     utoxGTK_widget_set_margin_left(image, margin);
-    utoxGTK_widget_set_margin_right(image, margin);
+    utoxGTK_widget_set_margin_right(image, margin);*/

     // set preview
     utoxGTK_image_set_from_pixbuf(image, pixbuf);
@@ -517,8 +517,8 @@
         U_DLLOAD(gtk, file_chooser_set_preview_widget);
         U_DLLOAD(gtk, image_new);
         U_DLLOAD(gtk, image_set_from_pixbuf);
-        U_DLLOAD(gtk, widget_set_margin_left);
-        U_DLLOAD(gtk, widget_set_margin_right);
+/*      U_DLLOAD(gtk, widget_set_margin_left);
+        U_DLLOAD(gtk, widget_set_margin_right);*/

         U_DLLOAD(g, slist_free);
         U_DLLOAD(g, free);

_________________
Bones McCracker wrote:
It wouldn't be so bad, if it didn't suck.

===
I refuse to move on from GTK+2.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum