Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[portage] créer un ebuild spécial (résolu)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index French
View previous topic :: View next topic  
Author Message
SnowBear
l33t
l33t


Joined: 03 Sep 2005
Posts: 773
Location: France - Bordeaux

PostPosted: Fri Apr 13, 2007 8:15 am    Post subject: [portage] créer un ebuild spécial (résolu) Reply with quote

Bonjour à tous,
un ami vient d'adapter un plugin xmms pour audacious.
Trouvant ce plugin tout simplement génial j'aimerais en faire un ebuild afin que tout les gentoistes puissent l'installer facilement.

Malheureusement (pour le moment) le plugin est un simple fichier .so (pas de fichiers sources, ni de make...). Du coup je ne sais pas trop ce que je pourrais mettre dans mon ebuild, juste un cp ... dans le src_install() ?

Merci d'avance.

EDIT:
ebuild dispo ici : http://www.mousur.org/portage/
Il s'agit du plugin goodnight de xmms qui permet d'éteindre audacious/le pc après un laps de temps que l'on peut définir, à la fin d'une playlist...


Last edited by SnowBear on Fri Apr 13, 2007 9:47 am; edited 1 time in total
Back to top
View user's profile Send private message
Magic Banana
Veteran
Veteran


Joined: 13 Dec 2005
Posts: 1912
Location: Belo Horizonte, Minas Gerais, Brasil

PostPosted: Fri Apr 13, 2007 8:20 am    Post subject: Reply with quote

Oui. :lol:

Le mieux est d'essayer. :wink:

Si tu veux un exemple d'ebuild très simple regarde celui que j'ai conçu pour l'installation de mon script offline-emerge. Là aussi, il n'y a que de la copie (+ la création d'un répertoire et d'une man page).
Back to top
View user's profile Send private message
xaviermiller
Bodhisattva
Bodhisattva


Joined: 23 Jul 2004
Posts: 8723
Location: ~Brussels - Belgique

PostPosted: Fri Apr 13, 2007 8:23 am    Post subject: Reply with quote

ou le [Bac à Sable] Pour apprenti développeur Gentoo dans le sous-forum "Documentation" ;)
_________________
Kind regards,
Xavier Miller
Back to top
View user's profile Send private message
kwenspc
Advocate
Advocate


Joined: 21 Sep 2003
Posts: 4954

PostPosted: Fri Apr 13, 2007 8:59 am    Post subject: Reply with quote

@SnowBear: pourquoi il file la version binaire de son plugin? il veut pas releaser les sources en open-source? (ce qui entre nous serait plutôt dommage vu que c'est fait pour tourner sur des softs open-sources.)
_________________
membre officieux du SAV Ati GEntoo
Back to top
View user's profile Send private message
xaviermiller
Bodhisattva
Bodhisattva


Joined: 23 Jul 2004
Posts: 8723
Location: ~Brussels - Belgique

PostPosted: Fri Apr 13, 2007 9:14 am    Post subject: Reply with quote

surtout que s'il a adapté un plug-in existant qui est GPL, il doit en fournir les sources !
_________________
Kind regards,
Xavier Miller
Back to top
View user's profile Send private message
SnowBear
l33t
l33t


Joined: 03 Sep 2005
Posts: 773
Location: France - Bordeaux

PostPosted: Fri Apr 13, 2007 9:28 am    Post subject: Reply with quote

Il les fournira par la suite, par manque de temps (il vient de partir en vacances) il ne m'a envoyé que le "bin".

Je viens de faire quelques tests et je me paye un access violation :(.

L'ebuild :
Code:
DESCRIPTION="GoodNightPlugin for Audacious"
HOMEPAGE="<a remplir>"
SRC_URI="http://www.mousur.org/portage/distfiles/${P}.tar.bz2"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
IUSE=""

RDEPEND="media-sound/audacious"

src_install() {
    cp ${WORKDIR}/libgoodnight.so /usr/lib/audacious/General/
}


l'erreur :
Code:
>>> Unpacking source...
>>> Unpacking goodnight-0.3.2.tar.bz2 to /var/tmp/portage/media-plugins/goodnight-0.3.2/work
>>> Source unpacked.
>>> Compiling source in /var/tmp/portage/media-plugins/goodnight-0.3.2 ...
>>> Source compiled.
>>> Test phase [not enabled]: media-plugins/goodnight-0.3.2

>>> Install goodnight-0.3.2 into /var/tmp/portage/media-plugins/goodnight-0.3.2/image/ category media-plugins
ACCESS DENIED  open_wr:   /usr/lib/audacious/General/libgoodnight.so
cp: ne peut créer le fichier régulier `/usr/lib/audacious/General/libgoodnight.so': Permission non accordée
>>> Completed installing goodnight-0.3.2 into /var/tmp/portage/media-plugins/goodnight-0.3.2/image/

--------------------------- ACCESS VIOLATION SUMMARY ---------------------------
LOG FILE = "/var/log/sandbox/sandbox-media-plugins_-_goodnight-0.3.2-29386.log"

open_wr:   /usr/lib/audacious/General/libgoodnight.so
--------------------------------------------------------------------------------
!!! This ebuild is from an overlay: '/usr/local/portage'
Back to top
View user's profile Send private message
geekounet
Bodhisattva
Bodhisattva


Joined: 11 Oct 2004
Posts: 3772

PostPosted: Fri Apr 13, 2007 9:36 am    Post subject: Reply with quote

Code:
DESCRIPTION="GoodNightPlugin for Audacious"
HOMEPAGE="<a remplir>"
SRC_URI="http://www.mousur.org/portage/distfiles/${P}.tar.bz2"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
IUSE=""

RDEPEND="media-sound/audacious"

src_install() {
     insinto "/usr/lib/audacious/General"
     doexe ${WORKDIR}/libgoodnight.so
}
Back to top
View user's profile Send private message
SnowBear
l33t
l33t


Joined: 03 Sep 2005
Posts: 773
Location: France - Bordeaux

PostPosted: Fri Apr 13, 2007 9:41 am    Post subject: Reply with quote

bizarre, ça le copie à la racine du système, dans /
Back to top
View user's profile Send private message
Temet
Advocate
Advocate


Joined: 14 Mar 2006
Posts: 2586
Location: 92

PostPosted: Fri Apr 13, 2007 9:41 am    Post subject: Reply with quote

Je ne sais pas pour l'erreur mais tu peux rajouter : RESTRICT="nomirror"
De cette façon, portage téléchargera directement le soft à l'adresse indiquée dans l'ebuild sans d'abord chercher sur les mirroirs du make.conf ;)
Back to top
View user's profile Send private message
SnowBear
l33t
l33t


Joined: 03 Sep 2005
Posts: 773
Location: France - Bordeaux

PostPosted: Fri Apr 13, 2007 9:43 am    Post subject: Reply with quote

J'ai réussi,
en remplaçant dans le script de geekouner doexe par doins,
merci à vous.
Back to top
View user's profile Send private message
kernelsensei
Bodhisattva
Bodhisattva


Joined: 22 Feb 2004
Posts: 5619
Location: Woustviller/Moselle/FRANCE (49.07°N;7.02°E)

PostPosted: Fri Apr 13, 2007 9:43 am    Post subject: Reply with quote

Bonjour ;)

Pour ceux qui voudraient écrire des ebuilds, je vous conseille de lire le devmanual.

Concernant l'access violation, c'est normal. Ta commande essaye de copier le .so directement dans le système ce qu'il ne faut absolument pas faire, c'est pourquoi sandbox l'interdit.

Avant d'être installé "pour de vrai", les composants d'une application sont installés dans un repertoire "image", une sorte de racine virtuelle. Une fois cette installation terminée, cette racine virtuelle est "mergée" au vrai système. Ça permet à portage de savoir exactement où vont les choses et à qui elles appartiennent.
_________________
$ ruby -e'puts " .:@BFegiklnorst".unpack("x4ax7aaX6ax5aX15ax4aax6aaX7ax2aX5aX8 \
axaX3ax8aX4ax6aX3aX6ax3ax3aX9ax4ax2aX9axaX6ax3aX2ax4ax3aX4aXaX12ax10aaX7a").join'
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index French All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum