Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.0.5 fails to build with gtkmm-4 #6392

Closed
lfam opened this issue Dec 16, 2023 · 5 comments · Fixed by #6393
Closed

4.0.5 fails to build with gtkmm-4 #6392

lfam opened this issue Dec 16, 2023 · 5 comments · Fixed by #6393
Labels
scope:gtk type:build Changes that affect the build system

Comments

@lfam
Copy link

lfam commented Dec 16, 2023

What is the issue?

Hello,

I am trying to build Transmission 4.0.5 within the GNU Guix package management system.

It fails to build with these error messages:

[ 86%] Building CXX object tests/libtransmission/CMakeFiles/libtransmission-test.dir/handshake-test.cc.o
cd /tmp/guix-build-transmission-4.0.5.drv-0/build/tests/libtransmission && /gnu/store/5lqhcv91ijy82p92ac6g5xw48l0lwwz4-gcc-11.3.0/bin/c++ -DFMT_EXCEPTIONS=0 -DFMT_HEADER_ONLY=1 -DHAVE_GETTEXT -DHAVE_NGETTEXT -DLIBTRANSMISSION_TEST_ASSETS_DIR=\"/tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/tests/libtransmission/assets\" -D__TRANSMISSION__ -I/tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/libtransmission/.. -I/tmp/guix-build-transmission-4.0.5.drv-0/build/libtransmission/.. -isystem /tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/cmake/../third-party/fmt/include -isystem /tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/third-party/googletest/googletest/include -isystem /tmp/guix-build-transmission-4.0.5.drv-0/build/third-party/dht.bld/pfx/include -isystem /tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/cmake/../third-party/wide-integer -O2 -g -DNDEBUG -W -Wall -Wextra -Wcast-align -Wduplicated-cond -Wextra-semi -Wfloat-equal -Winit-self -Wint-in-bool-context -Wlogical-op -Wmissing-format-attribute -Wnull-dereference -Wpointer-arith -Wredundant-decls -Wredundant-move -Wrestrict -Wshadow -Wsign-compare -Wsuggest-override -Wuninitialized -Wunreachable-code -Wunused -Wunused-const-variable -Wunused-parameter -Wunused-result -Wwrite-strings -Wno-sign-compare -std=gnu++17 -MD -MT tests/libtransmission/CMakeFiles/libtransmission-test.dir/handshake-test.cc.o -MF CMakeFiles/libtransmission-test.dir/handshake-test.cc.o.d -o CMakeFiles/libtransmission-test.dir/handshake-test.cc.o -c /tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/tests/libtransmission/handshake-test.cc
In file included from /tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/gtk/OptionsDialog.cc:10:
/tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/gtk/OptionsDialog.cc: In member function ‘void TorrentFileChooserDialog::onOpenDialogResponse(int, Glib::RefPtr<Session>&)’:
/tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/gtk/OptionsDialog.cc:341:38: error: ‘get_files2’ was not declared in this scope; did you mean ‘get_files’?
  341 |         auto const files = IF_GTKMM4(get_files2, get_files)();
      |                                      ^~~~~~~~~~
/tmp/guix-build-transmission-4.0.5.drv-0/transmission-4.0.5/gtk/GtkCompat.h:42:41: note: in definition of macro ‘IF_GTKMM4’
   42 | #define IF_GTKMM4(ThenValue, ElseValue) ThenValue
      |                                         ^~~~~~~~~
At global scope:
cc1plus: note: unrecognized command-line option ‘-Wno-exit-time-destructors’ may have been intended to silence earlier diagnostics
make[2]: *** [gtk/CMakeFiles/transmission-gtk.dir/build.make:353: gtk/CMakeFiles/transmission-gtk.dir/OptionsDialog.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....

We are using gtkmm 4.6.1 with GTK 4.8.1.

Please let me know if I can provide any more information, assist with debugging, etc.

Which application of Transmission?

GTK+ app on Linux, BSD, etc.

Which version of Transmission?

4.0.5

@Coeur Coeur added scope:gtk type:build Changes that affect the build system labels Dec 16, 2023
@Coeur
Copy link
Collaborator

Coeur commented Dec 16, 2023

@GaryElshaw
Copy link
Contributor

From the cmake file

set(GTKMM4_MINIMUM 4.11.1

@Coeur
Copy link
Collaborator

Coeur commented Dec 16, 2023

Ah, my attempt at a GTK PR would be non-useful if GTK 4.8 is below what we support. Anyway, @lfam can you try:
#6393

@lfam
Copy link
Author

lfam commented Dec 17, 2023

@Coeur Thanks, the fix in #6393 works for me!

@tearfur tearfur closed this as completed Dec 19, 2023
@deutrino
Copy link

FYI, the fix in #6393 is sufficient to build Transmission 4.05 on Debian 12 (bookworm) using the procedure at https://wiki.debian.org/SimpleBackportCreation

I haven't tested the resulting packages yet, but they do build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope:gtk type:build Changes that affect the build system
Development

Successfully merging a pull request may close this issue.

5 participants