Differences

This shows you the differences between two versions of the page.

Link to this comparison view

package_file_system_hierarchy [2017/03/12 19:24] (current)
0.0.0.0 created
Line 1: Line 1:
 +====== Package_File_System_Hierarchy ======
  
 +======Introduction======
 +In LibreELEC, packages and add-ons are defined by a set of files grouped in a
 +package folder. The package folder of a package is essentially composed of a
 +package.mk file, occasionally accompanied by patches.
 +The package folder of an add-on is more complex.
 +This document describes the file system hierarchy of a package folder.
 +======Rules======
 +*A package name should be lowercase
 +*All files of a package must be stored in a package folder, whose name is the name of the package
 +*A package folder must be stored under the "​packages"​ folder
 +*A package folder of an add-on must be stored under the "​packages/​addons"​ folder
 +*A package folder of a service add-on should be stored under the "​packages/​addons/​service"​ folder
 +======Files======
 +=====changelog.txt=====
 +;​Description
 +:A text file that contains a description of changes made to the add-on
 +;Scope
 +:Add-on
 +;Required
 +:Yes
 +;Reference
 +:​http://​kodi.wiki/​view/​Add-on_structure#​changelog.txt
 +;Example
 +:​https://​github.com/​LibreELEC/​LibreELEC.tv/​blob/​master/​packages/​addons/​service/​docker/​changelog.txt
 +=====icon/​icon.png=====
 +;​Description
 +:An icon used to represent the add-on in various parts of Kodi
 +;Scope
 +:Add-on
 +;Required
 +:No
 +;Reference
 +:​http://​kodi.wiki/​view/​Add-on_structure#​icon.png
 +=====package.mk=====
 +;​Description
 +:package.mk defines variables and functions to build a package
 +;Required
 +:Yes
 +;Reference
 +:​[[https://​wiki.libreelec.tv/​index.php?​title=Package.mk|package.mk]]
 +
 +=====patches/​=====
 +;​Description
 +:Patches
 +;Required
 +:No
 +
 +=====source/​bin/​=====
 +;​Description
 +:Additional programs, usually shell scripts
 +;Scope
 +:Add-on
 +;Required
 +:No
 +=====source/​lib/​=====
 +;​Description
 +:Additional libraries, usually Python libraries
 +;Scope
 +:Add-on
 +;Required
 +:No
 +=====source/​default.py=====
 +;​Description
 +:Main Python code for the add-on
 +;Scope
 +:Add-on
 +;Required
 +:Yes
 +;References
 +:​[[https://​wiki.libreelec.tv/​index.php?​title=Default.py|default.py]]
 +:​http://​kodi.wiki/​view/​Add-on_structure#​addon.py
 +
 +=====source/​resources/​languages/​English/​strings.po=====
 +;​Description
 +:Localized strings used by the addon
 +;Scope
 +:Add-on
 +;Required
 +:No
 +;Reference
 +:​http://​kodi.wiki/​view/​Add-on_structure#​resources.2Flanguage.2F
 +=====source/​resources/​settings.xml=====
 +;​Description
 +:A file that defines user-configurable settings used by the add-on
 +;Scope
 +:Add-on
 +;Required
 +:No
 +;Reference
 +:​http://​kodi.wiki/​view/​Add-on_settings
 +=====source/​settings-default.xml=====
 +;​Description
 +:A file that defines the default user-configurable settings used by the add-on
 +;Scope
 +:Add-on
 +;Required
 +:No
 +;Example
 +:​https://​github.com/​LibreELEC/​LibreELEC.tv/​blob/​master/​packages/​addons/​service/​dispmanx_vnc/​source/​settings-default.xml
 +=====source/​system.d/​pkg_section.pkg_name.service=====
 +;​Description
 +:A file that defines a system.d service for the add-on
 +:The system.d service is automatically enabled/​started/​stopped/​disabled when the add-on is installed/​updated/​uninstalled/​activated/​deactivated
 +;Scope
 +:Add-on
 +;Required
 +:No
 +;Example
 +:​https://​github.com/​LibreELEC/​LibreELEC.tv/​blob/​master/​packages/​addons/​service/​dispmanx_vnc/​source/​system.d/​service.system.dispmanx_vnc.service
 +;Reference
 +:​https://​www.freedesktop.org/​software/​systemd/​man/​systemd.service.html