Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[EBUILD] installer pygtk cvs .(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
man in the hill
Veteran
Veteran


Joined: 15 Dec 2005
Posts: 1552
Location: Madinina

PostPosted: Sun Jul 02, 2006 6:23 pm    Post subject: [EBUILD] installer pygtk cvs .(résolu) Reply with quote

Salut,

Je ne veux pas trop vous soulez mais j'aimerais faire passer cette ebuild :

ebuild de pygtk que j'ai un peu modifié pour la version CVS:
Code:

# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

inherit  cvs  python flag-o-matic


DESCRIPTION="GTK+2 bindings for Python"
HOMEPAGE="http://www.pygtk.org/"


LICENSE="LGPL-2.1"
SLOT="2"
KEYWORDS="-* ~amd64 ~ppc ~x86"
IUSE="opengl doc threads numeric"

unset SRC_URI

S=${WORKDIR}/${ECVS_MODULE}

RDEPEND=">=dev-lang/python-2.3.5
    >=dev-python/pygobject-2.10.1
    >=x11-libs/gtk+-2.9.3
    >=dev-libs/glib-2.11
    >=x11-libs/pango-1.10.0
    >=dev-libs/atk-1.8.0
    >=dev-python/pycairo-1
    !arm? ( dev-python/numeric )
    opengl? ( virtual/opengl
        dev-python/pyopengl
        >=x11-libs/gtkglarea-1.99 )"

DEPEND="${RDEPEND}
    >=dev-util/pkgconfig-0.9"

MAKE_OPTS="-j1"

src_unpack() {
    einfo ""
    einfo "Getting pygtk CVS..."
    einfo ""
    ECVS_SERVER="anoncvs.gnome.org:/cvs/gnome"
    ECVS_USER="anonymous"
    ECVS_AUTH="pserver"
    ECVS_PASS=""
    ECVS_MODULE="gnome-python/pygtk"
#   ECVS_LOCALNAME=""
    ECVS_TOP_DIR="${DISTDIR}/cvs-src/${ECVS_MODULE}"
    cvs_src_unpack
}

src_compile() {
    local myconf

    if use threads ; then
    myconf="${myconf} --enable-thread"
    fi
     if use numeric ; then
    myconf="${myconf} --enable-numpy"
    fi

    cd "${S}"
    ./autogen.sh \
    --host=${CHOST} \
    --libdir=/usr/$(get_libdir) \
    --prefix=/usr \
    ${myconf}   || die "econf failed"
    emake || die "emake failed"
}

src_install() {
    make DESTDIR="${D}" install || die
    dodoc AUTHORS ChangeLog INSTALL MAPPING NEWS README THREADS TODO
    rm examples/Makefile*
    cp -r examples ${D}/usr/share/doc/${PF}/

    python_version
    mv ${D}/usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.py \
        ${D}/usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.py-2.0
    mv ${D}/usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.pth \
        ${D}/usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.pth-2.0

    if use doc; then
        cd ${S}/../
        dodir /usr/share/gtk-doc/html
        cp -pPR pygtk2reference ${D}/usr/share/gtk-doc/html/
    fi
}

src_test() {
    cd tests
    make check-local
}

pkg_postinst() {
    python_version
    python_mod_optimize /usr/share/pygtk/2.0/codegen /usr/$(get_libdir)/python${PYVER}/site-packages/gtk-2.0
    alternatives_auto_makesym /usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.py pygtk.py-[0-9].[0-9]
    alternatives_auto_makesym /usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.pth pygtk.pth-[0-9].[0-9
]
    python_mod_compile /usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.py
    einfo ""
    einfo "You should re-emerge pygtk depended Python libs like pygobject and gnome-python*"
    einfo "Fight for your Right...yehhhhhhhhhhhhhhmannnnnnnnnnnnnnnnnnnnnn"
    einfo ""
}

pkg_postrm() {
    python_version
    python_mod_cleanup /usr/share/pygtk/2.0/codegen
    python_mod_cleanup
    rm -f ${ROOT}/usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.{py,pth}
    alternatives_auto_makesym /usr/$(get_libdir)/python${PYVER}/site-packages/pygtk.py pygtk.py-[0-9].[0-9]
]
}


et je retrouve avec cette sortie :
Code:

gentoo-in-the-mov pygtk %
 emerge pygtk
Calculating dependencies... done!
>>> Emerging (1 of 1) dev-python/pygtk-2.9.2_p20060701 to /
>>> Creating Manifest for /usr/local/overlays/bmg-main/dev-python/pygtk
Traceback (most recent call last):
  File "/usr/bin/emerge", line 3817, in ?
    emerge_main()
  File "/usr/bin/emerge", line 3814, in emerge_main
    action_build(myopts, myaction, myfiles, spinner)
  File "/usr/bin/emerge", line 3403, in action_build
    mydepgraph.merge(pkglist, favorites)
  File "/usr/bin/emerge", line 1905, in merge
    self.pkgsettings, self.edebug, tree="porttree")
  File "/usr/lib/portage/pym/portage.py", line 2847, in doebuild
    digestgen(aalist, mysettings, overwrite=0, myportdb=mydbapi)
  File "/usr/lib/portage/pym/portage.py", line 2286, in digestgen
    mf.write(sign=False)
  File "/usr/lib/portage/pym/portage_manifest.py", line 338, in write
    self._writeDigests()
  File "/usr/lib/portage/pym/portage_manifest.py", line 239, in _writeDigests
    for myfile in new_data["DIST"]:
KeyError: 'DIST'


Si cela vous dit qque ch ose....

Merci d'avance, à ceux qui y jetterons un oeil ds cette période de relaxation 8) ... j'ai dèjà fait passer pycairo-CVS mais pygtk est une autre histoire...les ebuilds se suivent mais ne se resemblent pas :twisted: :D .

Le lien pygtkcvs http://live.gnome.org/PyGTK





@+
_________________
Get Up and Go !


Last edited by man in the hill on Mon Jul 03, 2006 3:28 am; edited 1 time in total
Back to top
View user's profile Send private message
geekounet
Bodhisattva
Bodhisattva


Joined: 11 Oct 2004
Posts: 3772
Location: Wellington, Aotearoa

PostPosted: Sun Jul 02, 2006 7:12 pm    Post subject: Reply with quote

Heu je sais pas si c'est la cause de ton pb, mais les variables ECVS_* doivent être déclarées avant le inherit cvs
Back to top
View user's profile Send private message
man in the hill
Veteran
Veteran


Joined: 15 Dec 2005
Posts: 1552
Location: Madinina

PostPosted: Sun Jul 02, 2006 7:22 pm    Post subject: Reply with quote

Je me suis référé à cette doc http://devmanual.gentoo.org/ebuild-writing/functions/src_unpack/cvs-sources/index.html

mais peut-être as-tu d'autres docs à me proposées et en plus j'ai fais passer pycairo avec la même structure pour le ECVS_*.

Je teste tout de suite .

Merci



@+
_________________
Get Up and Go !
Back to top
View user's profile Send private message
geekounet
Bodhisattva
Bodhisattva


Joined: 11 Oct 2004
Posts: 3772
Location: Wellington, Aotearoa

PostPosted: Sun Jul 02, 2006 7:32 pm    Post subject: Reply with quote

Bah ya mon ebuild CVS qui marche.

Pis sinon man cvs.eclass (emerge portage-manpages)

Mais je sais plus où j'ai lu ça qu'il faut mettre les variables avant :P C'était ptêt une doc out-of-date parce que ça disait que sinon ça pouvait poser qq pb, et que le cvs.eclass devait être réécrit pour corriger ça ...
Back to top
View user's profile Send private message
man in the hill
Veteran
Veteran


Joined: 15 Dec 2005
Posts: 1552
Location: Madinina

PostPosted: Sun Jul 02, 2006 8:01 pm    Post subject: Reply with quote

Ce ne change rien, j'ai déclaré tous les ECVS_* au-dessus de inherit, en laissant
Code:
src_unpack() {
cvs_src_unpack
}
et aussi en commentant ces lignes mais pas de changement...

J'ai regarder directement ds le fichier cvs.eclass mais c'est clair que le man est aussi intéressant :lol: un petit coup d"emerge 8) .
Je m'inspire aussi du tien :wink: !

Merci, je m'en vais lire les pages man !




@+
_________________
Get Up and Go !
Back to top
View user's profile Send private message
man in the hill
Veteran
Veteran


Joined: 15 Dec 2005
Posts: 1552
Location: Madinina

PostPosted: Mon Jul 03, 2006 3:27 am    Post subject: Reply with quote

Beaucoup de bruit pour rien, malgré que j'ai paramétré mon make.conf pour que soit crée les disgests automatiquement , portage butait sur celui la sans que je sache exactement pourquoi, en tout cas , je l'ai créé à la mano et c'est passé tout seul !

Merci ,



@+
_________________
Get Up and Go !
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