From Fedora Project Wiki
Line 33: Line 33:


== Files section ==
== Files section ==
* Preupgrade Assistant files and directories are installed into
%dir '''%{preupgrade_dir}/Fedora%{preupg_number}_%{postupg_number}/%{name}'''
* All files except text files should be installed like
%{preupgrade_dir}/Fedora%{preupg_number}_%{postupg_number}/%{name}/*.{sh,py}
%{preupgrade_dir}/Fedora%{preupg_number}_%{postupg_number}/%{name}/*.ini
* All text files from content should be installed via
%doc %{preupgrade_dir}/Fedora%{preupg_number}_%{postupg_number}/%{name}/*.txt


== Directory ownership ==
== Directory ownership ==

Revision as of 08:24, 22 January 2015

Warning.png
This is a DRAFT.

PreupgradeAssistant contents Packaging guidelines

How to package a PreupgradeAssistant contents

Naming guidelines

Every Preupgrade Assistant content package must start with preupgrade-assistant-contents which is followed by original package name all lowercase.

For example preupgrade assistant package name mariadb will be named preupgrade-assistant-contents-mariadb in the SPEC file.

Dependencies

  • All packages must Require preupgrade-assistant.
  • All packages must have BuildRequires: preupgrade-assistant-devel. (for macros and checking)

Architecture

  • All preupgrade-assistant-contents must be architecture independent, i. e. BuildArch: noarch.

Macros

  • The macro denoting the parent directory where the package files go is %{_preupgradedir}. This currently expands to /usr/share/preupgrade.

Build section

Nothing special

Install section

Check section

  • You must run %check_preupgrade in check section and it must pass.
%check_preupgrade %{preupgradedir}/Fedora%{preupg_number}_%{postupg_number}/

Files section

  • Preupgrade Assistant files and directories are installed into
%dir %{preupgrade_dir}/Fedora%{preupg_number}_%{postupg_number}/%{name}
  • All files except text files should be installed like
%{preupgrade_dir}/Fedora%{preupg_number}_%{postupg_number}/%{name}/*.{sh,py}
%{preupgrade_dir}/Fedora%{preupg_number}_%{postupg_number}/%{name}/*.ini
  • All text files from content should be installed via
%doc %{preupgrade_dir}/Fedora%{preupg_number}_%{postupg_number}/%{name}/*.txt

Directory ownership

Sample SPEC