Jesse Keating <[EMAIL PROTECTED]> writes:

> Since all of us distro folks have our own in-distro packaging
> guidelines, wouldn't it make sense to start meeting and discussing these
> things with other distros to try and get some conformity going on?  A
> recent discussion about how to deal with jpackage brought this home, as
> I read mandriva's proposed way of dealing with them which mostly matched
> ours, but ours had filled some holes that theirs could use and vice
> versa.  Also, it seemed a lot of our guidelines were to work around
> flaws in upstream jpackage, and they could also participate here and get
> the flaws fixed as feedback from their consumers.
>
> Plenty of other things apply, java, mono, perl, python, etc...
> Thoughts?

Yes, please!  Btw. as an example: Anicka looked over the Fedora and SUSE
packaging guidelines and wrote up some comments on where they differ
(appended).  This might give us some start - and show also where
problems might be.

Andreas

This document briefly compares differences between the SUSE and Fedora
packaging guidelines from the point of the SUSE packaging guidelines.

For questions please contact Anicka Bernathova <[EMAIL PROTECTED]>.

Important notes:

libexecdir:

SuSE does not allow it. Users should use %{_prefix}/lib or
%{_prefix}/lib/%{name} or a special dedicated directory. Note that it
is %{_prefix}/lib (platform independent), not %{_libdir} (platform
dependent).

changelogs:

Internally we use .changes files, which are converted to spec
changes.

License tag: Compare abbreviations.

Usually, the PreReq tag should be replaced by plain Requires: Yes, if
it is possible. Sometimes it is not. Note that new version of RPM
deprecate PreReq in favor of Requires(pre), Requires(post). But it
does not define Requires(pretrans) and Requires(posttrans), so it is
only a half usable.

The Source tag documents where to find the upstream sources for the
rpm. In most cases this should be a complete URL to the upstream
tarball. SuSE rule prefers recompression to .tar.bz2.

BuildRoot tag: Our standard value is:
BuildRoot:      %{_tmppath}/%{name}-%{version}-build


Prepping BuildRoot For %install
According to SuSE conventions, this is bad and vulnerable to race
condition attacks and should not be used. RPM does it for you in a
secure way (at least in all several years old versions):
%install
rm -rf %{buildroot}
or
%install
rm -rf $RPM_BUILD_ROOT


Second, the Epoch must be listed...

SuSE does not allow Epoch in their packages.

BuildRequires exceptions: Compare lists. (minimal buildsystem)


Summary and description: Discuss use of articles, capitalization,
e. g.:
A Program for Editing
Program for editing
This tool allows you to edit files.


Encoding: SuSE has broken support for UTF-8 in spec files (Authors
list etc.)


Non-ASCII Filenames: OT note: We have glib2 tricks.


Debuginfo packages: Tags added by the build system.


Exclusion of Static Libraries and .la files: SuSE still has it, but
trying to link static often fails (pkg-config does not support mixed
statis/shared library environment). Now .la files are deprecated.

Packager must provide rationale for a -static subpackage: Good idea,
not in SuSE (although deprecated).


Why the %makeinstall macro should not be used: This section is
outdated. At least in SuSE %makeinstall now expands to "make
DESTDIR=%{buildroot} install".

Parallel make:
make %{?_smp_mflags} x make %{?jobs:-j%jobs}

macro %{lang_package} - new rule for SUSE, only in SUSE, although not SUSE 
specific

%suse_update_desktop_file (SUSE, inhouse translation, more features) vs. 
desktop-file-install (Fedora)

gconf scriptlets (our own macros)





Technical problems to discuss:

Is -devel package mandatory for development files or it is allowed to
package it in the main package (e. g. if the -devel package would
contain only one .pc file or one .h file).

Collect -devel dependencies.

Scriptlets and triggers: Implementation in RPM and real needs.

Use of advanced Requirements, Supplements, Recommends. zypp
implementation.

It seems that Fedora has a lot of tools for searching of missing
BuildRequires: SuSE people don't know rpmdev-rmdevelrpms, mock, mach,
rpmdev-rmdevelrpms.

We should discuss, whether to prefer RPM variables or shell variables
in the spec file. There is no consensus in SuSE nor Fedora (e. g.
$RPM_OPT_FLAGS/%{optflags}), whether to prefer brackets etc.


Init scripts and desktop files conventions, desktop-file-install x
%suse_update_desktop_file.

RPM categories, tags, macros.

Directories for server, browser plugins etc.



Configuration files:

AFAIK, Gentoo has the best tool for backporting of configuration
changes. It consists of backup of intact copy of any %config file,
diffing against old copy and patching new copy.



Minor notes:

shareware can be Open Source (e. g. xv)

Removing Rpath: Docs is missing several special variables:
C_INCLUDE_PATH, LIBRARY_PATH,...

-- 
 Andreas Jaeger, Director Platform / openSUSE, [EMAIL PROTECTED]
  SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
   Maxfeldstr. 5, 90409 Nürnberg, Germany
    GPG fingerprint = 93A3 365E CE47 B889 DF7F  FED1 389A 563C C272 A126

Attachment: pgpnX2NhpnYvh.pgp
Description: PGP signature

_______________________________________________
Distributions mailing list
Distributions@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/distributions

Reply via email to