Skip to content

Advertise Webp support in desktop file. - #15

Merged
N-R-K merged 1 commit into
nsxiv:devfrom
N-R-K:webp_desktop
Sep 12, 2021
Merged

Advertise Webp support in desktop file.#15
N-R-K merged 1 commit into
nsxiv:devfrom
N-R-K:webp_desktop

Conversation

@N-R-K

@N-R-K N-R-K commented Sep 11, 2021

Copy link
Copy Markdown
Member

@eylles

eylles commented Sep 11, 2021

Copy link
Copy Markdown
Contributor

i was thinking of adding a macro on the makefile for the full webp support pr, so that if nsxiv isn't compiled with webp support then it won't be advertised on the .desktop file

@N-R-K

N-R-K commented Sep 11, 2021

Copy link
Copy Markdown
Member Author

Sxiv doesn't have webp compile option, imlib2 does.

@eylles

eylles commented Sep 11, 2021

Copy link
Copy Markdown
Contributor

so we leave undoing this to the mantainers of the distros where imlib2 isn't compiled with webp support?

@eylles
eylles requested a review from XPhyro September 12, 2021 06:44
@N-R-K
N-R-K requested a review from TAAPArthur September 12, 2021 08:42
@XPhyro

XPhyro commented Sep 12, 2021

Copy link
Copy Markdown
Member

Is there a simple way to check if imlib2 has WebP support? If so we could incorporate this in #19.

@TAAPArthur

Copy link
Copy Markdown
Contributor

Is there a simple way to check if imlib2 has WebP support?

We could just have a HAS_WEBP flag for now that builders can manually set. If set to 1, then we add webp to the desktop file. Off hand I don't know of a portable way to check imlib2 compile objects, but there should be plenty of package manager specific solutions like checking the dependencies of imlib2.
Some ideas (that aren't imlib2 specific in anyway0:

  1. Let packages decide
  2. We could could check if libwebp is installed but this would yield a false negative if it was statically compiled and no longer on the system.
  3. Similar to 2 with the same downside is using ldd on the dynamic lib to see if it is linked to libwebp.
  4. Actually try to open a webp image.

Also if the desktop file isn't going to be completely static, may I suggest having a template and then creating and installing the real via the Makefile

@N-R-K

N-R-K commented Sep 12, 2021

Copy link
Copy Markdown
Member Author

Is there a simple way to check if imlib2 has WebP support? If so we could incorporate this in #19.

I think we should leave this upto the distro maintainers. And in the case of a source based distro, the user.

@N-R-K
N-R-K merged commit c6a4320 into nsxiv:dev Sep 12, 2021
@N-R-K
N-R-K deleted the webp_desktop branch September 12, 2021 18:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants