Bonjour j'ai packagé un wallpaper créer de A-Z par mes soins, je souhaiterais avoir votre avis sur le spec (je me suis inspiré du spec de gnome-backgounds):
ici les sources:
source0: http://bioinformatiques.free.fr/earth_and_moon/earth_and_moon-0.1.tar.bz2
source1: http://bioinformatiques.free.fr/earth_and_moon/earth_and_moon-0.1.xml
le src.rpm: http://bioinformatiques.free.fr/earth_and_moon/earth_and_moon-0.1-1.fc9.src.rpm
le rpm: http://bioinformatiques.free.fr/earth_and_moon/earth_and_moon-0.1-1.fc9.noarch.rpm
le spec:
Name:    earth_and_moon
Version:    0.1
Release:    1%{?dist}
Summary:    Modern background
License:    GPLv2+
Group:          User Interface/Desktops
URL:            http://bioinformatiques.free.fr/
Source0:        http://bioinformatiques.free.fr/earth_and_moon/%{name}-%{version}.tar.bz2
Source1:        http://bioinformatiques.free.fr/earth_and_moon/%{name}-%{version}.xml
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch:      noarch

%description
Earthlooks is beautiful theme. The background change often. You can see earth
rotate on herself and moon rotate around earth. This theme is compatible with
many resolution: eepc: 800x480, normalish: 1280x1024, normal: 1600x1200, wide:
1900x1200

%prep
%setup -q

%build

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_datadir}/backgrounds/earth_and_moon/
mkdir -p $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties/
install -m644 * $RPM_BUILD_ROOT%{_datadir}/backgrounds/earth_and_moon/
install -m664 %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties/

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%{_datadir}/backgrounds/earth_and_moon/*
%{_datadir}/gnome-background-properties/earth_and_moon-%{version}.xml

%changelog
* Sat Oct 25 2008 Jonathan MERCIER <bioinfornatics at gmail.com>
- New release
rpmlint semble renvoyer une erreur, et ton changelog n'est pas complet

epo
j'ai une petite question relative à l'application Système -> Apparence -> Apparence
je dois cliquer sur ajouter pour mettre le fond écran n'est il pas possible d'améliorer le spec afin d'indiquer a ce soft le nouveau wallpaper?
Oui epo tu as raison j'ai apporté les modifications en conséquences:
es sources:
source0: http://bioinformatiques.free.fr/earth-and-moon/earth-and-moon-0.1.tar.bz2
source1: http://bioinformatiques.free.fr/earth-and-moon/earth-and-moon-0.1.xml
le src.rpm: http://bioinformatiques.free.fr/earth-and-moon/earth-and-moon-0.1-1.fc9.src.rpm
le rpm: http://bioinformatiques.free.fr/earth-and-moon/earth-and-moon-0.1-1.fc9.noarch.rpm
le spec:
Name:        earth-and-moon
Version:    0.1
Release:    1%{?dist}
Summary:    Modern background
License:    GPLv2+
Group:          User Interface/Desktops
URL:            http://bioinformatiques.free.fr/
Source0:        http://bioinformatiques.free.fr/earth-and-moon/%{name}-%{version}.tar.bz2
Source1:        http://bioinformatiques.free.fr/earth-and-moon/%{name}-%{version}.xml
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch:      noarch

%description
Earthlooks is beautiful theme. The background change often. You can see earth
rotate on herself and moon rotate around earth. This theme is compatible with
many resolution: eepc: 800x480, normalish: 1280x1024, normal: 1600x1200, wide:
1900x1200

%prep
%setup -q

%build

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_datadir}/backgrounds/%{name}/
mkdir -p $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties/
install -m644 * $RPM_BUILD_ROOT%{_datadir}/backgrounds/%{name}/
install -m664 %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties/

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%{_datadir}/backgrounds/%{name}/*
%{_datadir}/gnome-background-properties/%{name}-%{version}.xml

%changelog
* Sat Oct 25 2008 Jonathan MERCIER <bioinfornatics at gmail.com> - 0.1-1
- Initial release
Rpmlint me renvoie une alerte que je ne comprend pas:
rpmlint ~/rpmbuild/SRPMS/earth-and-moon-0.1-1.fc9.src.rpm 
earth-and-moon.src: W: mixed-use-of-spaces-and-tabs (spaces: line 6, tab: line 1)
1 packages and 0 specfiles checked; 0 errors, 1 warnings.
ok c'est un truc avec les espaces et tabulations mais j'ai pas bien compris quel fichiers était en cause
Merci beaucoup epo j'ai corrigé tous les problèmes
$ rpmlint ~/rpmbuild/SRPMS/earth-and-moon-0.1-1.fc9.src.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings.
Les fichiers src.rpm et rpm sont uploadé, ils sont dispo.
Merci beaucoup epo.

quelqu'un sait comme faire reconnaître à l'application Système -> Apparence -> Apparence, la présence de nouveau wallpaper sans que l'utilisateur ai besoin de l'ajouter lui même?

Edit: j'ai oublié d'éditer mon fichier xml du au changement de nom de fichier ça peut pas marcher encore désolé (tête en l'air)
Edit2: Tout est ok mais toujours la même question si quelqu'un sait y répondre je suis preneur.
Dites moi ce que vous pensez de ce wallpaper toutes critique est bonne
Dans rpmlint, tu dois passer le src.rpm, le rpm, et le debuginfo (mais je doute que tu ai un debuginfo dans ton package).
Pour ta question, recherche ... il y a peut etre une commande a exécuter pour que les wallpapaers soit pris en compte.
regarde sur un autre paquet.

epo
Je pense que :
%postin
gnome-appearance-properties %{_datadir}/backgrounds/%{name}
est ce que tu cherches. Enfin, je n'ai pas testé le code, donc je ne peux rien garantir.
merci bouska j'ai testé mais ça bloque la commande est :
%post
gnome-appearance-properties  -p %{_datadir}/backgrounds/%{name}/
j'ai une fenêtre avec:
Impossible de démarrer le gestionnaire de paramètres « gnome-settings-daemon ».
Sans le gestionnaire de paramètres de GNOME activé, certains paramètres peuvent ne pas prendre effet. Ceci peut être dû à un problème avec Bonobo, ou un gestionnaire de paramètres non-GNOME (par ex. KDE) est déjà actif et entre en conflit avec GNOME.
Une erreur est survenue lors de l'installation du fichier sélectionné
Mon pec à l'heure actuelle est inspiré du paquet fedorainfinity-backgrounds:
Name:        earth-and-moon
Version:    0.1
Release:    1%{?dist}
Summary:    Modern background
License:    GPLv2+
Group:        User Interface/Desktops
URL:        http://bioinformatiques.free.fr/
Source0:    http://bioinformatiques.free.fr/earth-and-moon/%{name}-%{version}.tar.bz2
Source1:    http://bioinformatiques.free.fr/earth-and-moon/metadata.desktop
BuildRoot:    %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch:    noarch

%description
Earthlooks is beautiful theme. The background change often. You can see earth
rotate on herself and moon rotate around earth. This theme is compatible with
many resolution: eepc: 800x480, normalish: 1280x1024, normal: 1600x1200, wide:
1900x1200

%prep
%setup -q

%build

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_datadir}/backgrounds/%{name}/
install -m644 * $RPM_BUILD_ROOT%{_datadir}/backgrounds/%{name}/

mkdir -p $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties/
cp -a $RPM_BUILD_ROOT%{_datadir}/backgrounds/%{name}/%{name}-%{version}.xml $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties/

# earth-and-moon theme for KDE4
mkdir -p $RPM_BUILD_ROOT%{_datadir}/wallpapers/earth-and-moon/contents/images
install -m 644 -p %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/wallpapers/earth-and-moon/metadata.desktop
(cd $RPM_BUILD_ROOT%{_datadir}/wallpapers/earth-and-moon/contents/;
ln -s ../../../backgrounds/earth-and-moon/earth-and-moon-eepc-24.jpeg screenshot.png
cd $RPM_BUILD_ROOT%{_datadir}/wallpapers/earth-and-moon/contents/images
ln -s ../../../../backgrounds/earth-and-moon/earth-and-moon-normalish-24.jpeg 1024x768.png
ln -s ../../../../backgrounds/earth-and-moon/earth-and-moon-normalish-24.jpeg 1280x800.png
# FIXME: there doesn't seem to be a 5:4 image in the latest iteration
ln -s ../../../../backgrounds/earth-and-moon/earth-and-moon-normalish-24.jpeg 1280x1024.png
ln -s ../../../../backgrounds/earth-and-moon/earth-and-moon-normalish-24.jpeg 1440x900.png
ln -s ../../../../backgrounds/earth-and-moon/earth-and-moon-normal-24.jpeg 1600x1200.png
ln -s ../../../../backgrounds/earth-and-moon/earth-and-moon-wide-24.jpeg 1920x1200.png
)

# Compatibility cruft
(cd $RPM_BUILD_ROOT%{_datadir}/backgrounds/images;
ln -s ../earth-and-moon/earth-and-moon-normalish-0.jpeg default.jpeg
ln -s ../earth-and-moon/earth-and-moon-wide-0.jpeg default-wide.jpeg
cd ..
ln -s earth-and-moon/earth-and-moon-normalish-0.jpeg default.jpeg
)


%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%{_datadir}/backgrounds/%{name}/*

%dir %{_datadir}/gnome-background-properties
%{_datadir}/gnome-background-properties/%{name}-%{version}.xml

%{_datadir}/wallpapers/earth-and-moon

%doc README

%changelog
* Sat Oct 25 2008 Jonathan MERCIER <bioinfornatics at gmail.com> - 0.1-1
- Initial release
j'ai mis a jour les liens vers le src.rpm et le rpm
$ rpmlint ~/rpmbuild/SRPMS/earth-and-moon-0.1-1.fc9.src.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings.
$ rpmlint ~/rpmbuild/RPMS/noarch/earth-and-moon-0.1-1.fc9.noarch.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings
.
Alors il faut directement "viser" le fichier xml (sans le "-p") :
%post
gnome-appearance-properties  %{_datadir}/gnome-background-properties/%{name}-%{version}.xml
J'ai testé, ça fonctionne bien pour une image simple. Malheureusement, ça lance quand même une application graphique. Il faudrait réussir à trouver l'équivalent 100% commande, et surtout ne dépendant pas de Gnome.

Par contre, tu n'as pas le droit de mettre ça :
%dir %{_datadir}/gnome-background-properties
puisque normalement, il appartient à fedorainfinity-background. Donc il faudrait éventuellement faire une dépendance sur ce dernier.
3 mois plus tard
ayer le rpm est près je vais le soummettre:
le fichier spec:
Name:        earth-and-moon
Version:    0.1
Release:    1%{?dist}
Summary:    Modern background
License:    GPLv2+
Group:        User Interface/Desktops
URL:        http://bioinformatiques.free.fr/
Source0:    http://bioinformatiques.free.fr/earth-and-moon/%{name}-%{version}.tar.gz
BuildRoot:    %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch:    noarch

%description
Earthlooks is beautiful theme. The background change often. You can see earth
rotate on herself and moon rotate around earth. This theme is compatible with
many resolution: eepc: 800x480, normalish: 1280x1024, normal: 1600x1200, wide:
1900x1200

%prep
%setup -q -n %{name}-%{version}

%build

%install
rm -rf $RPM_BUILD_ROOT
# create wallpaper directorie
mkdir -p $RPM_BUILD_ROOT/%{_datadir}/backgrounds/%{name}/
# copy image files
install -m644 images/* $RPM_BUILD_ROOT/%{_datadir}/backgrounds/%{name}/

# copy xml file
install -m644 %{name}.xml $RPM_BUILD_ROOT/%{_datadir}/backgrounds/%{name}/

# copy metadata xmls file
mkdir -p $RPM_BUILD_ROOT/%{_datadir}/gnome-background-properties/
cp -a desktop-backgrounds-earth-and-moon.xml $RPM_BUILD_ROOT/%{_datadir}/gnome-background-properties/


%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%doc README
%dir %{_datadir}/backgrounds
%dir %{_datadir}/backgrounds/earth-and-moon
%dir %{_datadir}/gnome-background-properties
%{_datadir}/backgrounds/earth-and-moon/*
%{_datadir}/gnome-background-properties/desktop-backgrounds-earth-and-moon.xml

%changelog
* Sat Oct 25 2008 Jonathan MERCIER <bioinfornatics at gmail.com> - 0.1-1
- Initial release
rpmlint issue:
$ rpmlint rpmbuild/SPECS/earth-and-moon.spec 
0 packages and 1 specfiles checked; 0 errors, 0 warnings.

$ rpmlint rpmbuild/SRPMS/earth-and-moon-0.1-1.fc10.src.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings.

$ rpmlint rpmbuild/RPMS/noarch/earth-and-moon-0.1-1.fc10.noarch.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings.
les fichier sont dispo ici:
http://bioinformatiques.free.fr/earth-and-moon.spec
http://bioinformatiques.free.fr/earth-and-moon-0.1-1.fc10.src.rpm
http://bioinformatiques.free.fr/earth-and-moon-0.1-1.fc10.noarch.rpm