BestImageViewer / geeqie

claiming to be the best image viewer / photo collection browser
http://www.geeqie.org/
GNU General Public License v2.0
471 stars 77 forks source link

Images fail to render on MacOS (latest OS, latest Geeqie) #644

Closed bablat closed 3 years ago

bablat commented 5 years ago

ISSUE TYPE

GEEQIE VERSION

Geeqie 1.4

OS / DISTRIBUTION

MacOS Mojave 10.14.1

installed using hombrew formula

SUMMARY

Images do not render in the preview window, a single CPU core is stuck at 100% (25% as I have a four core Mac). All I get is a grey rectangle in the correct proportions.

STEPS TO REPRODUCE

Simply run Geeqie and select any image

LOGS

I'm getting the following warning on console:

(Geeqie:1198):` Gtk-WARNING **: 21:19:06.945: Drawing a gadget with negative dimensions. Did you forget to allocate a size? (node separator owner GtkPaned)

Ran Geeqie with debug=2, got this:

main.c:parse_command_line_for_debug_option:490:debugging output enabled (level 2)
main.c:main:829:    0.000803 (+00000.000803) main: gtk_init
main.c:main:850:    0.056072 (+00000.055269) main: pixbuf_inline_register_stock_icons
main.c:main:853:    0.056433 (+00000.000361) main: setting default options before commandline handling
ui_fileops.c:homedir:197:Home directory: /Users/user
ui_fileops.c:homedir:197:Home directory: /Users/user
ui_fileops.c:homedir:197:Home directory: /Users/user
main.c:main:857:    0.056522 (+00000.000089) main: parse_command_line
main.c:main:860:    0.056583 (+00000.000061) main: mkdir_if_not_exists
ui_fileops.c:homedir:197:Home directory: /Users/user
main.c:main:875:    0.057041 (+00000.000458) main: load_options
rcfile.c:start_element:1254:start gq
...
[removed for berevity]
...
rcfile.c:end_element:1267:end toolbar
rcfile.c:end_element:1267:end layout
rcfile.c:end_element:1267:end gq
options.c:load_options:316:Loading options from /Users/user/.config/geeqie/geeqierc.xml ... done
layout_util.c:layout_editors_reload_start:2548:    0.900219 (+00000.036594) layout_editors_reload_start
remote.c:remote_client_open:269:error connecting to socket: Connection refused
main.c:main:978:    0.900647 (+00000.000428) main: gtk_main
renderer-tiles.c:renderer_update_viewport:2050:update size: 0x7fcef58a4df0  0 0   514 646
pixbuf-renderer.c:pr_update_signal:1301:    0.985295 (+00000.084648) pixbuf renderer updated - started drawing 0x7fcef48a6180, img: 200x70
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
layout_util.c:layout_editors_reload_idle_cb:2510:    1.036711 (+00000.051416) layout_editors_reload_idle_cb: get_desktop_files
editors.c:editor_command_parse:775:editor_command_parse: geeqie-import-geeqie.desktop 0 0
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
pixbuf_util.c:register_theme_icon_as_stock:193:Couldn't load icon ufraw: Icon 'ufraw' not present in theme Adwaita
editors.c:editor_command_parse:775:editor_command_parse: geeqie-ufraw.desktop 0 0
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
pixbuf_util.c:register_theme_icon_as_stock:193:Couldn't load icon ufraw: Icon 'ufraw' not present in theme Adwaita
editors.c:editor_command_parse:775:editor_command_parse: geeqie-ufraw-id.desktop 0 0
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
editors.c:editor_command_parse:775:editor_command_parse: geeqie-import-gqview.desktop 0 0
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
pixbuf_util.c:register_theme_icon_as_stock:193:Couldn't load icon ufraw: Icon 'ufraw' not present in theme Adwaita
editors.c:editor_command_parse:775:editor_command_parse: geeqie-ufraw-recursive.desktop 0 0
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
editors.c:editor_command_parse:775:editor_command_parse: rotate.desktop 0 0
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
editors.c:editor_command_parse:775:editor_command_parse: symlink.desktop 0 0
layout_util.c:layout_editors_reload_idle_cb:2523:    1.187163 (+00000.150452) layout_editors_reload_idle_cb: setup_editors
layout_util.c:layout_editors_reload_idle_cb:2538:    1.187416 (+00000.000253) layout_editors_reload_idle_cb: setup_editors done
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
renderer-tiles.c:rt_queue_schedule_next_draw:1522:redraw priority: 2pass
...
[this last line repeats forever, image isn't shown]
mateuszroth commented 5 years ago

Haviing the same issue. Geeqie not working since I updated Macos to Mojave. Reinstalled geeqie and all deps several times using brew and nothing has changed.

caclark commented 5 years ago

I bought a Mac Mini to take a look at this problem, but things do not look good. The cpu load is caused by the "draw" signal continually being emitted and thus triggering rt_draw_cb(). However compiling Geeqie v1.3 with the GTK2 libraries results in the GTK2 equivalent signal "expose_event" also continually being emitted. Unfortunately this is a problem at a level that it is unlikely I can solve it.

Veebers commented 5 years ago

(Sorry to resurrect this thread, but I'm desperate to use geeqie on my Mac, I miss my Linux workflow :-) )

Would this indicate an issue in GTK on Mac? Would you have an idea on how much work would be required to reproduce just the rt_draw_cb or expose_event issue? (outside of the Geeqie codebase). Ideally we could ask the GTK team to take a look at it and help get this sorted.

deimosfr commented 4 years ago

Same for me for Mac OS Catalina

periclestsellos commented 4 years ago

Same issue, just a blank white image when trying to load .png file

lgbouma commented 4 years ago

Same issue on Mac OS Catalina

caclark commented 4 years ago

I mentioned above that this problem is associated with the "draw" signal. I am looking again at #602 which is also caused by the same signal. Attached is a .diff that cures the flicker problem. If anyone is compiling Geeqie from sources on a Mac, I am interested to know if the Mac problem is also cured or improved. N.B. this is not a fix - just a patch to help me understand the problem. 644-1.diff.gz

mo8Zomo0 commented 3 years ago

Is there an update on this case? Is there any fix possible? With big sur and geeqie-1.6 via homebrew (from source) it still shows the white "image". :-(

caclark commented 3 years ago

I've lost track of what's happening here....

What is the result with the following options: Edit/Preferences/Image enable GPU acceleration and restart geeqie. Call by LIBGL_ALWAYS_INDIRECT=1 geeqie Call by geeqie --disable-clutter

lgbouma commented 3 years ago

Hi @caclark -- thank you for looking into this. Regarding your suggested tests, on Geeqie 1.6 (the default homebrew install) Edit/Preferences/Image doesn't have any buttons to click to enable GPU acceleration, from what I can see. Screencap is below. Call by LIBGL_ALWAYS_INDIRECT=1 geeqie doesn't change the behavior. Call by geeqie --disable-clutter doesn't change it either.

System: Geeqie 1.6, from a fresh homebrew install, on macOS Catalina (v 10.15)

Result: Geeqie viewer looks like this (the image should have content, and not be a gray rectangle):

Screen Shot 2021-02-02 at 5 03 27 PM

and the preferences panel looks like

Screen Shot 2021-02-02 at 5 05 30 PM

Finally, geeqie --debug gives

debugging output enabled (level 1)
    0.001487 (+00000.001487) main: gtk_init
    0.101303 (+00000.099816) main: pixbuf_inline_register_stock_icons
    0.101984 (+00000.000681) main: setting default options before commandline handling
Home directory: /Users/luke
Home directory: /Users/luke
Home directory: /Users/luke
    0.102088 (+00000.000104) main: parse_command_line
error connecting to socket: Connection refused
    0.102334 (+00000.000246) main: mkdir_if_not_exists
Home directory: /Users/luke
    0.102827 (+00000.000493) main: load_options
loader reported [ani] [Windows animated cursor] [.ani]
loader reported [bmp] [BMP] [.bmp]
loader reported [gif] [GIF] [.gif]
loader reported [icns] [MacOS X icon] [.icns]
loader reported [ico] [Windows icon] [.ico;.cur]
loader reported [jpeg] [JPEG] [.jpeg;.jpe;.jpg]
loader reported [png] [PNG] [.png]
loader reported [pnm] [PNM/PBM/PGM/PPM] [.pnm;.pbm;.pgm;.ppm]
loader reported [qtif] [QuickTime] [.qtif;.qif]
loader reported [svg] [Scalable Vector Graphics] [.svg;.svgz;.svg.gz]
loader reported [tga] [Targa] [.tga;.targa]
loader reported [tiff] [TIFF] [.tiff;.tif]
loader reported [xbm] [XBM] [.xbm]
loader reported [xpm] [XPM] [.xpm]
    0.103893 (+00000.001066) layout_new: start
    0.141083 (+00000.037190) layout_actions_setup: start
    0.224681 (+00000.083598) layout_actions_setup: add menu
    0.225007 (+00000.000326) layout_actions_setup: add toolbar
    0.225046 (+00000.000039) layout_actions_setup: marks
    0.227496 (+00000.002450) layout_actions_setup: editors
    0.227533 (+00000.000037) layout_actions_setup: status_update_write
    0.227552 (+00000.000019) layout_actions_setup: actions_add_window
    0.227571 (+00000.000019) layout_actions_setup: end
Setting stereo mode 0000 for imd 0x7fa602c8ee10
update size: 0x7fa602c8b7c0  0 0   0 0
    0.448806 (+00000.221235) vflist_refresh: read dir
    0.448820 (+00000.000014) vflist_refresh: populate view
    0.448832 (+00000.000012) vflist_refresh: free filelist
    0.448837 (+00000.000005) vflist_refresh: done
    0.467807 (+00000.018970) pixbuf renderer updated - started drawing 0x7fa6030861a0, img: 200x70
    0.467821 (+00000.000014) pixbuf renderer updated - started drawing 0x7fa6030861a0, img: 200x70
    0.467829 (+00000.000008) pixbuf renderer updated - started drawing 0x7fa6030861a0, img: 200x70
update size: 0x7fa602c8b7c0  0 0   430 496
    0.505207 (+00000.037378) pixbuf renderer updated - started drawing 0x7fa6030861a0, img: 200x70
    0.528170 (+00000.022963) layout_new: end
Register realtime 0 /Users/luke/temp
    0.529514 (+00000.001344) vflist_refresh: read dir
    0.529690 (+00000.000176) vflist_refresh: sort
    0.529701 (+00000.000011) vflist_refresh: populate view
    0.529889 (+00000.000188) vflist_refresh: free filelist
    0.529899 (+00000.000010) vflist_refresh: done
    0.529929 (+00000.000030) image reset
    0.529974 (+00000.000045) image begin
new image loader 0x7fa604057c30, bufsize=4096 idle_loop=1
exif read /Users/luke/temp/some_image_2.png, sidecar: -
Thread pool num threads: 1
Register realtime 0 /Users/luke/temp/some_image_2.png
    0.532404 (+00000.002430) read ahead cancelled for :null
read ahead set to :/Users/luke/temp/some_image.png
    0.556729 (+00000.024325) pixbuf renderer updated - started drawing 0x7fa6030861a0, img: 200x70
Loading options from /Users/luke/.config/geeqie/geeqierc.xml ... done
    0.558142 (+00000.001413) layout_editors_reload_start
    0.558340 (+00000.000198) main: gtk_main
image_load_size_cb: 3000x2000
    0.558828 (+00000.000488) pixbuf renderer updated - started drawing 0x7fa6030861a0, img: 3000x2000
    0.558841 (+00000.000013) pixbuf renderer updated - started drawing 0x7fa6030861a0, img: 3000x2000
    0.895012 (+00000.336171) image load completed "/Users/luke/temp/some_image_2.png" (current)
    0.895034 (+00000.000022) pixbuf renderer done 0x7fa6030861a0
    0.895574 (+00000.000540) layout_editors_reload_idle_cb: get_desktop_files
    0.896133 (+00000.000559) image done
    0.896155 (+00000.000022) read ahead started for :/Users/luke/temp/some_image.png
new image loader 0x7fa604057d60, bufsize=4096 idle_loop=1
exif read /Users/luke/temp/some_image.png, sidecar: -
Thread pool num threads: 1
freeing image loader 0x7fa604057c30 bytes_read=681414
Couldn't load icon ufraw: Icon 'ufraw' not present in theme Adwaita
Couldn't load icon ufraw: Icon 'ufraw' not present in theme Adwaita
Couldn't load icon ufraw: Icon 'ufraw' not present in theme Adwaita
    0.951158 (+00000.055003) layout_editors_reload_idle_cb: setup_editors
    0.951426 (+00000.000268) layout_editors_reload_idle_cb: setup_editors done
    0.989857 (+00000.038431) read ahead done for :/Users/luke/temp/some_image.png
    0.989879 (+00000.000022) image load completed "/Users/luke/temp/some_image.png" (preload)
freeing image loader 0x7fa604057d60 bytes_read=681414
monitor /Users/luke/temp/some_image_2.png
monitor /Users/luke/temp
caclark commented 3 years ago

Geeqie has been compiled with GTK2. Is it possible to compile with GTK3?

caclark commented 3 years ago

OK, I see from here: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/geeqie.rb that GTK3 is used. But is clutter installed?

lgbouma commented 3 years ago

Ran brew install clutter, brew reinstall geeqie, same bug remains!

caclark commented 3 years ago

On Edit/Preferences/Image is the GPU accel. option visible and selectable?

What is the contents of the config.report file?

lgbouma commented 3 years ago

Re: Edit/Preferences/Image, no, it's not visible. It looks like the second screenshot from the above.

Re: config.report, I'm not sure how to access this file -- how might I do this? (Sorry!)

mo8Zomo0 commented 3 years ago

I can confirm that under 11.2 it behaves similar to what Igbouma reported. And also here, no gpu acceleration option.

@caclark as you asked about clutter, here it was not installed, on the other hand as you ask to disable it what should it be, present or not? I installed it mow and it does not make a difference anyhow.

Maybe as an addon, when I hover over the image with my mouse with the rgb picker enabled, even though the shown image is pure white, the colour values of the actual image are shown

2021-02-06 um 00 49 29
caclark commented 3 years ago

I'm sorry, but I have no knowledge of Macs or Homebrew. I am just making suggestions that might (or might not) provide more information about this problem.

This formula for Geeqie: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/geeqie.rb should perhaps include the line: depends-on "clutter"

Somewhere in the Homebrew documentation I see the option --build-from-source. If you compile from sources, you will get the config.report file. The contents of that file will help to understand what is going on.

mo8Zomo0 commented 3 years ago

@caclark Where would I find this info? I could not find it on my filesystem at least.

output install:

==> Installing geeqie ==> ./autogen.sh ==> ./configure --prefix=/usr/local/Cellar/geeqie/1.6 --disable-glibtest --disable-gtktest --enable-gtk3 ==> make install 🍺 /usr/local/Cellar/geeqie/1.6: 82 files, 19.3MB, built in 1 minute 41 seconds

I could find a folder ~/Library/Logs/Homebrew/geeqie containing:

-rw-r--r-- 1 mac staff 6 Feb 7 17:50 00.options.out -rw-r--r-- 1 mac staff 1215 Feb 7 17:50 01.autogen.sh -rw-r--r-- 1 mac staff 13901 Feb 7 17:51 02.configure -rw-r--r-- 1 mac staff 115833 Feb 7 17:51 02.configure.cc -rw-r--r-- 1 mac staff 15171 Feb 7 17:52 03.make -rw-r--r-- 1 mac staff 570390 Feb 7 17:51 03.make.cc -rw-r--r-- 1 mac staff 67419 Feb 7 17:52 config.log

I attached the content of these file here: geeqie-log.txt

caclark commented 3 years ago

Within the geeqie-log.txt file. these lines are significant: checking for clutter-1.0 >= 1.0... no configure: WARNING: No package 'clutter-1.0' found

and: Support: LCMS: yes Exiv2: yes Lirc: no Clutter: no Libchamplain: disabled Libchamplain-gtk: disabled Lua: no FFmpegthumbnailer: no Pdf: no HEIF: yes WebP: yes DjVu: no J2K: yes

and: configure:12665: checking for clutter-1.0 >= 1.0 configure:12672: $PKG_CONFIG --exists --print-errors "clutter-1.0 >= 1.0" Package clutter-1.0 was not found in the pkg-config search path. Perhaps you should add the directory containing "clutter-1.0.pc" to the PKG_CONFIG_PATH environment variable No package 'clutter-1.0' found

So libclutter is not installed on your system. Perhaps you can make further investigations for how to install it.

mo8Zomo0 commented 3 years ago

@caclark thank you for your quick feedback!

Clutter itself is installed by homebrew:

% brew search clutter
==> Formulae
clutter ✔                  clutter-gst                clutter-gtk

but not clutter-gst or clutter-gtk.

possibly the clutter-gtk one is needed here or what would I need to provide (like set some lookup path) here?

I removed clutter it and reinstalled it with the other two, just to show they are all there:

==> Downloading https://homebrew.bintray.com/bottles/clutter-1.26.4.big_sur.bott
Already downloaded: /Users/mac/Library/Caches/Homebrew/downloads/1929f224deefce42af8e0aeeca66b8efc92272b71852776c9212777e8b9c3422--clutter-1.26.4.big_sur.bottle.tar.gz
==> Pouring clutter-1.26.4.big_sur.bottle.tar.gz
🍺  /usr/local/Cellar/clutter/1.26.4: 390 files, 17MB
==> Downloading https://homebrew.bintray.com/bottles/clutter-gst-3.0.27_1.big_su
######################################################################## 100.0%
==> Pouring clutter-gst-3.0.27_1.big_sur.bottle.1.tar.gz
🍺  /usr/local/Cellar/clutter-gst/3.0.27_1: 56 files, 1MB
==> Downloading https://homebrew.bintray.com/bottles/clutter-gtk-1.8.4_4.big_sur
######################################################################## 100.0%
==> Pouring clutter-gtk-1.8.4_4.big_sur.bottle.tar.gz
🍺  /usr/local/Cellar/clutter-gtk/1.8.4_4: 45 files, 340.8KB

and tried to compile geeqie again (still white image) It still shows clutter as missing:

checking for clutter-1.0 >= 1.0... no
configure: WARNING: No package 'clutter-1.0' found
  Clutter:       `no`

full output: geeqie-log.txt

caclark commented 3 years ago

On my system I have installed: libclutter-1.0-0 libclutter-1.0-common libclutter-1.0-dev libclutter-gst-3.0.0 libclutter-gtk-1.0-0 libclutter-gtk-1.0-dev Probably the gst file is not necessary - I believe the dev files are.

mo8Zomo0 commented 3 years ago

@caclark but I assume you do not have a mac?

anyhow, should it even be a problem if clutter is not there? If I see the readme file right this is for cpu acceleration as well as that it is optional, so should it not work without as well?

Btw, gqview behaves the same on my mac (white image)

caclark commented 3 years ago

This is a long-standing problem that I am not able to solve. But yes, clutter should be optional. However if it is installed, it is possible to disable the part of the software that is involved in this problem.

caclark commented 3 years ago

BTW the dev files contain the headers, which are necessary.

mo8Zomo0 commented 3 years ago

@caclark yea, but there are no specific dev packages on homebrew if I see it right and these files exist:

% locate clutter|grep lib /usr/local/Cellar/clutter/1.26.4/lib /usr/local/Cellar/clutter/1.26.4/lib/girepository-1.0 /usr/local/Cellar/clutter/1.26.4/lib/girepository-1.0/Cally-1.0.typelib /usr/local/Cellar/clutter/1.26.4/lib/girepository-1.0/Clutter-1.0.typelib /usr/local/Cellar/clutter/1.26.4/lib/libclutter-1.0.0.dylib /usr/local/Cellar/clutter/1.26.4/lib/libclutter-1.0.dylib /usr/local/Cellar/clutter/1.26.4/lib/pkgconfig /usr/local/Cellar/clutter/1.26.4/lib/pkgconfig/cally-1.0.pc /usr/local/Cellar/clutter/1.26.4/lib/pkgconfig/clutter-1.0.pc /usr/local/Cellar/clutter/1.26.4/lib/pkgconfig/clutter-osx-1.0.pc /usr/local/lib/libclutter-1.0.0.dylib /usr/local/lib/libclutter-1.0.dylib /usr/local/lib/pkgconfig/clutter-1.0.pc /usr/local/lib/pkgconfig/clutter-osx-1.0.pc

caclark commented 3 years ago

I see that there are a few Internet searches such as "Fixing missing headers for homebrew ". Maybe you will have to contact the Homebrew community to get an answer to this.

mo8Zomo0 commented 3 years ago

@caclark

I added a system path to /usr/local/lib and and it finds clutter but not the gtk one es it looks and I checked the files links exist for clutter-gtk as well.

02.configure:checking for clutter-1.0 >= 1.0... yes 02.configure:checking for clutter-gtk-1.0 >= 1.0... no 02.configure:configure: WARNING: No package 'clutter-gtk-1.0' found

/usr/local/lib % ls -la clut lrwxr-xr-x 1 mac admin 51 Feb 7 19:28 libclutter-1.0.0.dylib -> ../Cellar/clutter/1.26.4/lib/libclutter-1.0.0.dylib lrwxr-xr-x 1 mac admin 49 Feb 7 19:28 libclutter-1.0.dylib -> ../Cellar/clutter/1.26.4/lib/libclutter-1.0.dylib lrwxr-xr-x 1 mac admin 61 Feb 7 19:29 libclutter-gst-3.0.0.dylib -> ../Cellar/clutter-gst/3.0.27_1/lib/libclutter-gst-3.0.0.dylib lrwxr-xr-x 1 mac admin 59 Feb 7 19:29 libclutter-gst-3.0.dylib -> ../Cellar/clutter-gst/3.0.27_1/lib/libclutter-gst-3.0.dylib lrwxr-xr-x 1 mac admin 60 Feb 7 20:46 libclutter-gtk-1.0.0.dylib -> ../Cellar/clutter-gtk/1.8.4_4/lib/libclutter-gtk-1.0.0.dylib lrwxr-xr-x 1 mac admin 58 Feb 7 20:46 libclutter-gtk-1.0.dylib -> ../Cellar/clutter-gtk/1.8.4_4/lib/libclutter-gtk-1.0.dylib

mo8Zomo0 commented 3 years ago

@caclark I made some progress, I also added the depends_on "clutter-gtk" to the rb file. it now detects clutter

Support: Clutter: yes

but now it fails to compile

% brew remove geeqie; brew install --build-from-source geeqie
Error: No available formula or cask with the name "geeqie".
==> Downloading http://www.geeqie.org/geeqie-1.6.tar.xz
Already downloaded: /Users/mek/Library/Caches/Homebrew/downloads/d4ed9183f6625d9332cb295d904443ce1a0fe8b8b66693ce46c57454d20f342e--geeqie-1.6.tar.xz
==> ./autogen.sh
==> ./configure --prefix=/usr/local/Cellar/geeqie/1.6 --disable-glibtest --disab
==> make install
Last 15 lines from /Users/mek/Library/Logs/Homebrew/geeqie/03.make:
  CC       view_file/view_file.o
  CC       view_file/view_file_icon.o
  CC       view_file/view_file_list.o
(echo "#include \"gq-marshal.h\"" ; /usr/local/Cellar/glib/2.66.6/bin/glib-genmarshal --prefix=gq_marshal ./gq-marshal.list --body ) >gq-marshal.c
INFO: Reading ./gq-marshal.list...
  CC       gq-marshal.o
  CXXLD    geeqie
Undefined symbols for architecture x86_64:
  "_XInitThreads", referenced from:
      _main in main.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [geeqie] Error 1
make[1]: *** [install-recursive] Error 1
make: *** [install-recursive] Error 1

READ THIS: https://docs.brew.sh/Troubleshooting

geeqie-log.txt

caclark commented 3 years ago

Perhaps you need the X11 headers. I saw this comment somewhere:

you need to manually link in the X11 headers (assumes you have xcode + the command line tools installed) ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers/X11/ /usr/local/include/X11

mo8Zomo0 commented 3 years ago

@caclark hmm, no, that did not help, I had some X11 folder which I removed and as I run Big Sur I used: ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers/X11 /usr/local/include/X11

but also after that I get the same error:

https://gist.github.com/mo8Zomo0/08a9af23095d46f9518352847ccf4eba

==> make install
Last 15 lines from /Users/mek/Library/Logs/Homebrew/geeqie/03.make:
  CC       view_file/view_file.o
  CC       view_file/view_file_icon.o
  CC       view_file/view_file_list.o
(echo "#include \"gq-marshal.h\"" ; /usr/local/Cellar/glib/2.66.6/bin/glib-genmarshal --prefix=gq_marshal ./gq-marshal.list --body ) >gq-marshal.c
INFO: Reading ./gq-marshal.list...
  CC       gq-marshal.o
  CXXLD    geeqie
Undefined symbols for architecture x86_64:
  "_XInitThreads", referenced from:
      _main in main.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [geeqie] Error 1
make[1]: *** [install-recursive] Error 1
make: *** [install-recursive] Error 1
caclark commented 3 years ago

I am sorry, but I have no knowledge of Mac/Homebrew. In my opinion the problem is still the X11 headers. Perhaps there is a Homebrew group you can contact about this problem.

equal-l2 commented 3 years ago

@mo8Zomo0 That error can be fixed by adding the following line onto the top of install method in the formula:

ENV.append "LDFLAGS", "-lX11"

Though this fixes the build, geeqie is still not be able to run with the error below:


(geeqie:41237): Clutter-Gtk-ERROR **: 15:05:48.702: *** Unsupported backend.
zsh: trace trap  geeqie

AFAIK this is because clutter-gtk doesn't support the quartz backend of GTK.

caclark commented 3 years ago

I have an old Mac Mini with Catalina installed, but have never used it.

Could you let me have details of how to replicate what you have achieved e.g. . what relevant software you have installed . how to configure or install HomeBrew . how to compile Geeqie (other than is standard for Linus) . anything else you might think useful

equal-l2 commented 3 years ago

Homebrew official homepage describes how to install it. Once installation completed, download modified geeqie.rb and try installing geeqie with the following command:

brew install -sv geeqie.rb

Homebrew will build geeqie from source and install it.

mo8Zomo0 commented 3 years ago

@caclark it might be dependent on which mac OS version you can run (if it s an old mac mini). I have a old 2011 macbook air (macos high sierra = macos 10.13) , there the installed version works. At least Big Sur (11.2 (thats what I currently run) and 10.15: Catalina (thats what I had before) do not seem to work.

maybe that helps:

caclark commented 3 years ago

Part of the problem is that the formula uses the v1.6 gz on geeqie.org.

Since that version release there have been some commits that may affect this problem. Could you try using the source zip from github?: https://github.com/BestImageViewer/geeqie/archive/master.zip (which is downloaded as geeqie-master.zip)

mo8Zomo0 commented 3 years ago

@caclark I tried to compile it and it has the same error: geeqie-github % ./src/geeqie

(geeqie:39995): Clutter-Gtk-ERROR **: 03:34:43.644: *** Unsupported backend. zsh: trace trap ./src/geeqie

I used this command to compile it, the output is attached.

( echo ---------- make clean; make clean ;echo ---------- autogen; ./autogen.sh && echo -------- configure ; ./configure --disable-dependency-tracking --disable-glibtest --disable-gtktest --enable-gtk3 && echo -------- make ; make && echo --------- geeqie ; ./src/geeqie ) 2>&1 | tee geeqie-master.log

(it also generates a crash report, also included) geeqie-master.log

mo8Zomo0 commented 3 years ago

btw, also tried to compile without clutter, that geeqie starts up but also showed the white area instead of the image.

caclark commented 3 years ago

Attached is a very experimental patch. Its purpose is only to determine if images appear on a system that exhibits this problem. It would be useful if anyone on this thread who is compiling from sources could try this. Apply the patch. Run src/geeqie --disable-clutter. The usual grey screen will show. Select a file in the files pane, right-click and select View in new window. Please let me know whether or not an image is displayed. 644-1.diff.gz

equal-l2 commented 3 years ago

@caclark The patch works well. After applied the patch and rebuilt, now the image is displayed, both in the image pane and the new window.

Screenshot 2021-02-22 at 2 04 42 Screenshot 2021-02-22 at 2 22 39

caclark commented 3 years ago

@equal-l2 Thanks for running the test. I now know how to fix the problem, but it may take a week or so to get something workable.

mo8Zomo0 commented 3 years ago

I also tried to compile it without clutter and clutter-gtk, it succeeded and I could start it without --disable-clutter without crashing/failing.

Maybe not related, but I noticed the following:

caclark commented 3 years ago

Unfortunately the previous patch solved only half the problem... The attached patch runs (mostly) ok on my test setup, but I am interested to know if the display is correct on real-world user systems.

Image viewing should be ok Pan View should be ok Overlay Screen Display does not work (yet)

644-2.diff.gz

mo8Zomo0 commented 3 years ago

@caclark I am not 100% sure how to test these scenarios.

caclark commented 3 years ago

If you can compile the patched source, Geeqie should run correctly (apart from the OSD). Do images appear correctly? Does View/Pan View work? Or do you still get the white screen?

mattdm commented 3 years ago

So, interestingly: there is a similar problem on (prerelease) Fedora Linux 34. The patch 644-1 seems to work here as well. (In that it makes images display again. I didn't test the other things.)

caclark commented 3 years ago

@mattdm The latest sources in the repo. work on Fedora 33. Are you saying that the problem is present again in Fedora 34?

mattdm commented 3 years ago

@mattdm The latest sources in the repo. work on Fedora 33. Are you saying that the problem is present again in Fedora 34?

Unfortunately, that's what I'm saying, yeah. Geeqie 1.6.

mattdm commented 3 years ago

And the patch 644-2.diff.gz above seems to make it work.

mattdm commented 3 years ago

Oh, and it looks like the head of the development branch works too (as of 13aaf78c5fd0af4332ca05c53e2de05342ea883f). Sorry for not checking that earlier.