Bug 245259 - [NEW PORT] multimedia/kodi-addon-game.libretro: Libretro compatibility layer for the Kodi Game API
Summary: [NEW PORT] multimedia/kodi-addon-game.libretro: Libretro compatibility layer ...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Bernhard Froehlich
URL:
Keywords:
Depends on: 253448
Blocks: 245258 245260 245262 245263
  Show dependency treegraph
 
Reported: 2020-04-02 00:36 UTC by Ivan Rozhuk
Modified: 2021-03-19 20:10 UTC (History)
4 users (show)

See Also:


Attachments
patch (2.70 KB, patch)
2020-04-02 00:36 UTC, Ivan Rozhuk
no flags Details | Diff
patch (2.74 KB, patch)
2020-05-30 21:46 UTC, Ivan Rozhuk
no flags Details | Diff
patch (3.21 KB, patch)
2021-03-19 20:04 UTC, Ivan Rozhuk
rozhuk.im: maintainer-approval?
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ivan Rozhuk 2020-04-02 00:36:30 UTC
Created attachment 212958 [details]
patch

This add-on provides a wrapper that allows Libretro cores to be loaded
as game add-ons. Libretro cores are shared libraries that use the
Libretro API, so the wrapper is responsible for translating function
calls between the Libretro API and the Game API.

This port is for multimedia/kodi-devel only.

WWW: https://github.com/kodi-game/game.libretro
Comment 1 Ivan Rozhuk 2020-05-30 21:46:18 UTC
Created attachment 215076 [details]
patch
Comment 2 Bernhard Froehlich freebsd_committer freebsd_triage 2020-12-30 14:00:15 UTC
I have just chosen this PR to discuss the plans for all the kodi addons that you did send.

Is there a specific reason why you created them for the kodi-devel port instead of the kodi port? Are you still interested in the libretro plugins?

If we want to get this into the portstree we definitely need to prepare ourselves for the consequences. Right now when the kodi port is updated (minor version change eg. 18.0->18.1) 3 additional addon ports need a version bump and a pkg-plist change. When the kodi major version changes (eg 18->19) 3 addon ports (and 1-2 additional ports) need a full update at the same time. That doesn't scale well if we add another 10 addon ports.
The result would be that hardly any committers would take that PRs. It's a lot of work to get all maintainers coordinated and to commit all this stuff together.

As you already know the manpower for maintaining the kodi ports is also quite low on our side and we are duplicating a lot of work because we have kodi and kodi-devel in the tree which are similar but different and each with their own set of addons which is just nonsense.

I am not sure yet how to solve this properly but in my opinion we should definitely focus on one kodi port and cleanup that kodi-addon mess before we add more to it.
Comment 3 Bernhard Froehlich freebsd_committer freebsd_triage 2021-01-21 08:35:59 UTC
We've had some discussions about the kodi situation in the FreeBSD portstree and it has become clear that there is not enough manpower to maintain kodi+addons and kodi-devel+addons for both of them individually.

My current proposal is to let kodi-devel and all kodi-devel addons die. Instead we focus on the kodi port and improve the infrastructure for kodi addons.

I think your game addons are really nice and I would like to commit them but let them depend on kodi. What do you think?
Comment 4 Bernhard Froehlich freebsd_committer freebsd_triage 2021-01-21 08:36:36 UTC
I'll take it.
Comment 5 Bernhard Froehlich freebsd_committer freebsd_triage 2021-01-21 12:40:27 UTC
I have done a few changes to all the kodi game addons:
- libretro update to 2.2.0
- Updated all of the addons to the latest version
- Converted to depend on kodi (removed -devel from their names)
- Moved all of them from multimedia category to games

https://github.com/decke/ports/tree/master/games
Comment 6 Patricio Villar 2021-01-21 13:43:28 UTC
(In reply to Bernhard Froehlich from comment #3)
Kudos for cleaning-up/taking care of Kodi ports!
BTW, do you plan to convert multimedia/kodi-addon-inputstream.adaptive-devel as well so it works with non-devel Kodi? That would be nice to have too ;)
Thanks in advance
Comment 7 Bernhard Froehlich freebsd_committer freebsd_triage 2021-01-21 14:38:36 UTC
(In reply to Patricio Villar from comment #6)
Sure, I have prepared a inputstream.adaptive addon port. If you could do a quick test then I can add it to the tree:

https://github.com/decke/ports/tree/master/multimedia/kodi-addon-inputstream.adaptive
Comment 8 Ivan Rozhuk 2021-01-21 16:32:02 UTC
> Is there a specific reason why you created them for the kodi-devel port instead of the kodi port?

Because I use kodi-devel.
I was use kodi, but it have some bugs that was fixed by upstream or maintainer did not get my patches.
I switch to devel and send my pathes to upstream.
Maintainer keep fresh devel, so I have no problems.

Current kodi have problem with AV1 - only one thread used for software decoding.
I am afraid that kodi 19 release will not have this fix, and I do not want wait next few years for update to new release to fix this and probably many other things that I do not know yet.

I have no plans to use 18x kodi, and I prefer to keep use devel version in future.


> Are you still interested in the libretro plugins?

Yes, I use it some times.


> I am not sure yet how to solve this properly but in my opinion we should definitely focus on one kodi port and cleanup that kodi-addon mess before we add more to it.

Yes, but it must be not few years old release.
IMHO, kodi team leave on master and do not care about old staff.
Comment 9 Patricio Villar 2021-01-21 17:37:17 UTC
(In reply to Bernhard Froehlich from comment #7)
Cool! Gonna try it in the next few hours :)
Comment 10 Bernhard Froehlich freebsd_committer freebsd_triage 2021-01-21 19:54:36 UTC
(In reply to rozhuk.im from comment #8)
Currently multimedia/kodi is at 19.0RC1 which was just released a few days ago so it should contain all fixes you can get from upstream. If there are some additional fixes/patches from kodi-devel that are relevant please tell me or send a PR so we can add it to the kodi port as well.

This nonsense to have multiple kodi ports and multiple addons for each of them has to stop because the cost for it is too high and the result is a mess like it is now. Two kodi ports with different options, different patches, different runtime behaviour and different addons - but almost identical code from upstream.

A new kodi major release can usually be expected around every 2 years and minor releases every 2-3 months and this is what we will have in the FreeBSD portstree. We usually don't track development versions unless there is a real need for it. Most of the -devel ports are usually badly outdated and not very well maintained. If we have FreeBSD specific patches/fixes we include them in the port and send them upstream. No need to wait for months.
The only thing we can't have is new features that are currently in their development version.
Comment 11 Bernhard Froehlich freebsd_committer freebsd_triage 2021-01-21 19:56:34 UTC
(In reply to Patricio Villar from comment #9)
Make sure you use the older revision because I already started to convert the addon ports in my repository to USES=kodi.

https://github.com/decke/ports/tree/2969b865fe937dd8c85f6ebbd9e7980e0d93a0ca/multimedia/kodi-addon-inputstream.adaptive
Comment 12 Bernhard Froehlich freebsd_committer freebsd_triage 2021-01-21 21:35:51 UTC
Today I've worked on a kodi.mk [1] which can autogenerate plist and has the standard stuff that we need for addons. It works great and simplifies the addons a bit [2] - but the best is that addon ports don't need a pkg-plist anymore so all the version number worries for .so in pkg-plist are gone :o)

[1] https://github.com/decke/ports/blob/master/Mk/Uses/kodi.mk
[2] https://github.com/decke/ports/tree/master/games
Comment 13 Patricio Villar 2021-01-21 22:39:07 UTC
(In reply to Bernhard Froehlich from comment #11)
That did the trick. Built just fine and everything is working without issues.
Thank you!
Comment 14 Bernhard Froehlich freebsd_committer freebsd_triage 2021-02-12 07:55:15 UTC
A kodi.mk has been submitted in PR 253448. Please have a look and give some feedback.
Comment 15 commit-hook freebsd_committer freebsd_triage 2021-02-28 18:36:09 UTC
A commit references this bug:

Author: decke
Date: Sun Feb 28 18:35:58 UTC 2021
New revision: 566787
URL: https://svnweb.freebsd.org/changeset/ports/566787

Log:
  This add-on provides a wrapper that allows Libretro cores to be loaded
  as game add-ons. Libretro cores are shared libraries that use the
  Libretro API, so the wrapper is responsible for translating function
  calls between the Libretro API and the Game API.

  WWW: https://github.com/kodi-game/game.libretro

  PR:		245259
  Submitted by:	rozhuk.im@gmail.com

Changes:
  head/games/Makefile
  head/games/kodi-addon-game.libretro/
  head/games/kodi-addon-game.libretro/Makefile
  head/games/kodi-addon-game.libretro/distinfo
  head/games/kodi-addon-game.libretro/pkg-descr
Comment 16 Bernhard Froehlich freebsd_committer freebsd_triage 2021-02-28 18:36:39 UTC
Committed. Thanks!
Comment 17 Ivan Rozhuk 2021-03-19 20:04:44 UTC
Created attachment 223427 [details]
patch
Comment 18 Ivan Rozhuk 2021-03-19 20:10:39 UTC
oops, I miss that it already in base but with different path.
Sorry for noise here.