Do we have support for cario lua in conky OM 6

Hello,

Requirements:

I have Searched the forum for my issue and found nothing related or helpful
I have checked the Resources category (Resources Index)
I have reviewed the Wiki for relevant information
I have read the the Release Notes and Errata

OpenMandriva Lx version: 6

Desktop environment (KDE, LXQT…):

Description of the issue (screenshots if relevant):

Relevant informations (hardware involved, software version, logs or output…):

Does openMandrive support cairo lua in conky?
I mean, are there packages for this somewhere in other repositories, maybe some dev branch or something?
Because I didn’t find anything in the default ones.

Is there a possibility to port packages from test, dev branch if they exist.

Thank you in advance

funny you should ask, I’m just looking into this myself.

I can’t find anything in the repo either (I’m running Rock 6, btw)

We’ve got:

  • conky : A lightweight system monitor
  • conky-manager : A simple GUI for managing Conky config files
  • conky-manager2 : A simple GUI for managing Conky config files

According to the github, conky-manager should have been obsoleted 2 years ago and replaced with conky-manager2.

As for conky itself, the spec file on github says:

%bcond_without: lua_cairo
%bcond_without: lua_imlib
%bcond_without: lua_rsvg

so it would have had to be disabled explicitly at compile time.

But when I sift through the repos and github I can’t find anything that would tie them all together.

:man_shrugging:

According to RH, that means it’s enabled. :person_shrugging:

@SomeDudeInAZ Thank you very much for the answer.

I was asking for a friend who creates email notifier for Thunderbird on lua conky phyton and bash. So I asked in his name.

His install script as well as gui installer works on few distros he just made attempt to make it work on open mandriva.
And fails, so here Im with a question

This was also moved to Coffee break because Support is for things that are broken.

1 Like

Hi. I’m not an expert on conky. @mandian and @vuatech have been working on this package recently. However, from what I can see, Cairo and Lua are active in conky.

The macro %bcond_without lua_cairo indicates that something is active. %bcond_with does the opposite. from this it follows that lua cairo is on.

Also build log show also this:

-DBUILD_LUA_CAIRO:BOOL=ON -DBUILD_LUA_IMLIB2:BOOL=ON -DBUILD_LUA_RSVG:BOOL=ON -DBUILD_PULSEAUDIO:BOOL=ON -

It would be easier to have him ask the questions here so there isn’t any miscommunications. I can say that Lua is version specific. So, if the script was written in a version lower than what we ship, it may not work.

I would recommend the Development topic.

1 Like

@zeroability Ups sorry for the mess I’ve created in support. It was unintended

1 Like

@zeroability @AngryPenguin

Thanks

That’s what I thought. %bcond_without meant you had to explicitly set a compiler flag to disable it and that if you did so it would still build (albeit without that particular feature)

Where does one find the build logs? Over in the abf?

I know that the sheer number of issues I’ve resolved just by looking at the rpm spec has me wondering why I never did something like it before my switch to OpenMandriva.

Actually I know why…hanging out in the chat is why I started looking there for info. So thanks again. You’ve made me a better engineer just by my following the discussions.

I almost feel like a real linux user :penguin: :winking_face_with_tongue:

1 Like

It’s no problem. I’m just trying to make things easier to find.

Unless you are building them locally, then yes. Each ID has a set of logs for the build, script, and tests. Any one of those can lead to packages not being published.

In this particular build, it failed to contact the file store. Probably because the tubes were clogged doing other build and store related tasks:

This had a test fail, because certain arch’s packages failed to build:

This one shows a failure in a check in CMake for a dependency (BuildRequires):

thank you

Probably not, rolling repos are copies of what was in Cooker at some point in time, rock repos are copies of what was in ROME(rolling) at some point. That reflects workflow.

Cooker>ROME(rolling)>Rock.

Testing repos are not used much at this time.

It is very easy to see what is in OLMx repos:

OMLx repositories

Users can search OMLx packages using dnf search and dnf info and there is the --help option. Not sure about man pages for those.

Hello grafi

Yes we do support cairo in conky as you can see from the conky -v output which tells you everything it has enabled:

$ conky -v
conky 1.22.1 compiled for Linux x86_64

Compiled in features:

System config file: /etc/conky/conky.conf
Package library path: lib64/conky


 General:
  * math
  * hddtemp
  * IPv6
  * Curl
  * RSS
  * support for IBM/Lenovo notebooks
  * old configuration syntax
  * OSS mixer support
  * apcupsd
  * iostats
  * ncurses
  * Internationalization support
  * PulseAudio

 Lua bindings:
  * Cairo
  * RSVG
 X11:
  * Xdamage extension
  * Xinerama extension (virtual display)
  * Xshape extension (click through)
  * XDBE (double buffer extension)
  * Xft
  * ARGB visual
  * Own window
  * Mouse events
 Wayland:
  * ARGB visual
  * Mouse events

 Music detection:
  * CMUS
  * MPD

 Default values:
  * Netdevice: eno1
  * Local configfile: $HOME/.conkyrc
  * Localedir: /usr/share/locale
  * Maximum netdevices: 256
  * Maximum text size: 16384
  * Size text buffer: 256

I also took a look at it and while I could get lua code to work and display properly I could not get images loading, so I delved a little deeper on that.

I updated the imlib2 library that conky uses and added a bunch more image formats to it thinking maybe we had missed something that was stopping images from loading but no success other than updating the library with more image formats, which isn’t a bad thing.

Next step was updating conky itself which went smoothy but still no Lua image tags were working and conky -v was not showing it as being enabled either, so I went back to its spec file and after some head scratching spotted a single digit typo in a macro that was preventing conky from pulling in imlib2 at all and that was the fix to get images working in conky .

You can see the output from the updated conky -v showing that it now has imlib2 enabled below:

$ conky -v
conky 1.22.2 compiled for Linux x86_64

Compiled in features:

System config file: /etc/conky/conky.conf
Package library path: lib64/conky


 General:
  * math
  * hddtemp
  * IPv6
  * Curl
  * RSS
  * support for IBM/Lenovo notebooks
  * old configuration syntax
  * Imlib2
  * OSS mixer support
  * apcupsd
  * iostats
  * ncurses
  * Internationalization support
  * PulseAudio

 Lua bindings:
  * Cairo
  * Imlib2
  * RSVG
 X11:
  * Xdamage extension
  * Xinerama extension (virtual display)
  * Xshape extension (click through)
  * XDBE (double buffer extension)
  * Xft
  * ARGB visual
  * Own window
  * Mouse events
 Wayland:
  * ARGB visual
  * Mouse events

 Music detection:
  * CMUS
  * MPD

 Default values:
  * Netdevice: eno1
  * Local configfile: $HOME/.conkyrc
  * Localedir: /usr/share/locale
  * Maximum netdevices: 256
  * Maximum text size: 16384
  * Size text buffer: 256

Both updated imlib2 and corky v1.22.2 packages are available in cooker and should make it down to rolling/ROME soon :tm:

Here is a screenshot of it working in a cooker VM with the OpenMandriva Lx logo loading successfully and it is all written in lua:

:melting_face:

2 Likes

I will send the whole thread to my friend. I have no way to be a valuable source of information for you guys about his problems with conky and lua in his project. Hopefully he will contact you, and describe his issues far more better then I ever would

2 Likes

Hello. I am the colleague mentioned by user @grafi :slight_smile:

I am having trouble running my project in the OM 6 ROCK environment. Specifically, I am having trouble initializing the frontend in Lua. I also installed the updated packages from the cooker repository mentioned by @uro, namely conky, and checked if I had imlib2.

I even started installing packages at random, because I assumed that the fragmentation in the packages meant that I hadn’t installed something yet, but unfortunately, nothing worked.

The current list of packages with the name lua:

lib64lua5.3-static-devel.x86_64                    5.3.6-1                   @cooker-x86_64      
lib64lua5.3_5.3.x86_64                             5.3.6-1                   @cooker-x86_64      
lib64lua5.4.x86_64                                 5.4.7-1                   @release-x86_64     
lib64luajit-5.1.x86_64                             2.1.1693350652-1          @release-x86_64     
lib64luajit-5.1-common.x86_64                      2.1.1693350652-1          @release-x86_64     
lib64tree-sitter-lua.x86_64                        0.2.0-1                   @release-x86_64     
lua.x86_64                                         5.4.8-1                   @cooker-x86_64      
lua-lgi.x86_64                                     0.9.2-3                   @rock-x86_64        
lua5.3.x86_64                                      5.3.6-1                   @cooker-x86_64      
luajit.x86_64                                      2.1.1693350652-1          @release-x86_64     
luajit-lpeg.x86_64                                 1.1.0-1                   @release-x86_64     
luajit-mpack.x86_64                                1.0.12-1                  @release-x86_64

and packages for the name cairo:

lib64cairo-devel.x86_64                            1.18.4-1                  @rock-x86_64        
lib64cairo-gir1.0.x86_64                           1.84.0-1                  @release-x86_64     
lib64cairo-gobject2.x86_64                         1.18.4-1                  @release-x86_64     
lib64cairo-script-interpreter2.x86_64              1.18.4-1                  @release-x86_64     
lib64cairo2.x86_64                                 1.18.4-1                  @release-x86_64     
lib64harfbuzz-cairo.x86_64                         11.1.0-1                  @rock-x86_64        
lib64harfbuzz-cairo-devel.x86_64                   11.1.0-1                  @rock-x86_64        
lib64pangocairo-gir1.0.x86_64                      1.56.3-1                  @release-x86_64     
lib64pangocairo1.0_0.x86_64                        1.56.3-1                  @release-x86_64     
libcairo-devel.x86_64                              1.18.4-1                  @rock-x86_64        
libcairo-gobject2.x86_64                           1.18.4-1                  @rock-x86_64        
libcairo-script-interpreter2.x86_64                1.18.4-1                  @rock-x86_64        
libcairo2.x86_64                                   1.18.4-1                  @rock-x86_64        
python-cairo.x86_64                                1.28.0-1                  @release-x86_64   

Conky -v:

conky 1.22.2 compiled for Linux x86_64

Compiled in features:

System config file: /etc/conky/conky.conf
Package library path: lib64/conky


 General:
  * math
  * hddtemp
  * IPv6
  * Curl
  * RSS
  * support for IBM/Lenovo notebooks
  * old configuration syntax
  * Imlib2
  * OSS mixer support
  * apcupsd
  * iostats
  * ncurses
  * Internationalization support
  * PulseAudio

 Lua bindings:
  * Cairo
  * Imlib2
  * RSVG
 X11:
  * Xdamage extension
  * Xinerama extension (virtual display)
  * Xshape extension (click through)
  * XDBE (double buffer extension)
  * Xft
  * ARGB visual
  * Own window
  * Mouse events
 Wayland:
  * ARGB visual
  * Mouse events

 Music detection:
  * CMUS
  * MPD

 Default values:
  * Netdevice: eno1
  * Local configfile: $HOME/.conkyrc
  * Localedir: /usr/share/locale
  * Maximum netdevices: 256
  * Maximum text size: 16384
  * Size text buffer: 256

The error that appears when I start the project is:

conky: desktop window (0x180001e) is subwindow of root window (0x323)
conky: window type - normal
conky: drawing to created window (0x4400002)
conky: drawing to double buffer
conky: llua_load: ...Pulpit/Zupix-Py2Lua-Mail-conky-v1.0.0_DEV/lua/e-mail.lua:338: module 'cairo' not found:
        no field package.preload['cairo']
        no file '/usr/share/lua/5.4/cairo.lua'
        no file '/usr/share/lua/5.4/cairo/init.lua'
        no file '/usr/lib/lua/5.4/cairo.lua'
        no file '/usr/lib/lua/5.4/cairo/init.lua'
        no file '/usr/lib64/lua/5.4/cairo.lua'
        no file '/usr/lib64/lua/5.4/cairo/init.lua'
        no file './cairo.lua'
        no file './cairo/init.lua'
        no file '/home/przemek/Pulpit/Zupix-Py2Lua-Mail-conky-v1.0.0_DEV/lua/cairo.lua'
        no file 'lib64/conky/libcairo.so'
        no file '/usr/lib64/lua/5.4/cairo.so'
        no file '/usr/lib64/lua/5.4/loadall.so'
        no file './cairo.so'
        no file '/usr/lib/lua/5.4/cairo.so'
        no file '/usr/lib/lua/5.4/loadall.so'
        no file './cairo.so'
conky: forked to background, pid is 1607

conky: FOUND: wayland
conky: FOUND: x11
conky: FOUND: file
conky: FOUND: ncurses
conky: FOUND: console
conky: llua_do_call: function conky_cairo_init execution failed: attempt to call a nil value
conky: llua_do_call: function conky_draw_mail_indicator execution failed: attempt to call a nil value
conky: 'KDE' x11 session running
conky: llua_do_call: function conky_cairo_init execution failed: attempt to call a nil value
conky: llua_do_call: function conky_draw_mail_indicator execution failed: attempt to call a nil value
conky: llua_do_call: function conky_cairo_init execution failed: attempt to call a nil value
conky: llua_do_call: function conky_draw_mail_indicator execution failed: attempt to call a nil value
conky: llua_do_call: function conky_cairo_init execution failed: attempt to call a nil value
conky: llua_do_call: function conky_draw_mail_indicator execution failed: attempt to call a nil value
conky: llua_do_call: function conky_cairo_init execution failed: attempt to call a nil value
conky: llua_do_call: function conky_draw_mail_indicator execution failed: attempt to call a nil value
conky: llua_do_call: function conky_cairo_init execution failed: attempt to call a nil value
conky: llua_do_call: function conky_draw_mail_indicator execution failed: attempt to call a nil value
conky: llua_do_call: function conky_cairo_init execution failed: attempt to call a nil value
conky: llua_do_call: function conky_draw_mail_indicator execution failed: attempt to call a nil value
conky: llua_do_call: function conky_cairo_init execution failed: attempt to call a nil value
conky: llua_do_call: function conky_draw_mail_indicator execution failed: attempt to call a nil value

I am familiar with this error, but on other distributions, it was enough to install the meta-packages lua and lua-dev and their dependencies + on Arch-based distributions, add the line pcall(require, ‘cairo_xlib’). That’s all.

I can upload the bare code without customization and account tables, but to run the script without a backend (just to check if cairo works), you need to meet a few minimum dependencies, such as the dkjson.lua library and the basic conkyrcfile. I can provide such a minimal package if anyone is interested. The entire project, including scripts that automate installation, is available on GitHub, but at the moment everything is in Polish, so it doesn’t make sense for anyone to struggle with it and use Google Translate on their phone just to check out the whole project.

To try out the solution, all you need is access to the main frontend.

1 Like

I am uploading the minimum set to run the e-mail.lua frontend, along with a script that will change the absolute paths in the e-mail.luacode and the path to the e-mail.lua file for the conkyrc_zupix file.

TEST.tar.xz (3,6 MB)

PS: I wanted to post a photo showing how it should look after launch, but unfortunately I can’t. The same goes for raw links to the photo.

Hello, I think I spotted the issue:

It is looking in the wrong path for conky/libcairo.so as well as that search path being malformed which seems to be something going awry in the CMake files during the build.

Thanks for providing your config files but I could not get those to work because they have many hardcoded paths and is a crazy amount of lua code for me to attempt refine for a simple repro to see if the conky cairo component is working or not.

I pulled a minimal example from the conky wiki with some modification as the wiki guide’s example is not totally complete and ran it in a terminal which was also failing to find cairo and producing the identical error as you received.

With that local repro now displaying the same error, I had something to proceed with.

A few hours later.. (had other things to do).

After some work I have it running using its cairo, cairo_xlib and rsvg component libraries from the correct paths, it is running the conky config+lua script from the wiki and rendering an svg:

As I was already in the guts of the source code and following a bunch of further local test builds I added a few more build dependencies to enable more extra options that people may find useful:

$ conky -v
conky 1.22.2 compiled for Linux x86_64

Compiled in features:

System config file: /etc/conky/conky.conf
Package library path: /usr/lib64//conky


 General:
  * math
  * hddtemp
  * HTTP
  * IPv6
  * Curl
  * RSS
  * iconv
  * MySQL
  * support for IBM/Lenovo notebooks
  * old configuration syntax
  * Imlib2
  * OSS mixer support
  * apcupsd
  * iostats
  * ncurses
  * Internationalization support
  * PulseAudio

 Lua bindings:
  * Cairo
  * Imlib2
  * RSVG
 X11:
  * Xdamage extension
  * Xinerama extension (virtual display)
  * Xshape extension (click through)
  * XDBE (double buffer extension)
  * Xft
  * ARGB visual
  * Own window
  * Mouse events
 Wayland:
  * ARGB visual
  * Mouse events

 Music detection:
  * CMUS
  * MPD

 Default values:
  * Netdevice: eno1
  * Local configfile: $HOME/.conkyrc
  * Localedir: /usr/share/locale
  * HTTP-port: 10080
  * Maximum netdevices: 256
  * Maximum text size: 16384
  * Size text buffer: 256

The updated conky packages are available in cooker for testing.

I would generally advise not mixing packages between Rock and cooker.

Great! That solves the problem. Now everything works as it should.

I would share a screenshot, but I don’t have permission to upload png files.

PS: When can we expect the latest conky package to be moved from the cooker-extra repo to rome and rock?

1 Like

I cannot help with that, not a forum :ninja:

The package will go down to ROME during the next UM / merge cycle which is not far away.

As for ROCK I am not sure as I do not deal with UM / merge cycles.

In general ROCK only gets bugfixes to its existing packages.

That is the difference between our stable release ROCK and our rolling releases ROME which gets package updates frequently after a period of testing in Cooker and our Cooker rolling release which is essentially bleeding edge and receives package updates as we upgrade, build and publish them.