Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Frage zum Erstellen von einem ebuild - foo2zjs-20090324.ebui
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German)
View previous topic :: View next topic  
Author Message
hitachi
Guru
Guru


Joined: 20 Feb 2006
Posts: 478
Location: Freiburg / Deutschland

PostPosted: Wed Apr 01, 2009 12:50 pm    Post subject: Frage zum Erstellen von einem ebuild - foo2zjs-20090324.ebui Reply with quote

Hallo,

ich wollte mal ein aktuelles ebuild für foo2zjs erstellen. Ich habe sowas aber noch nie gemacht. Ich habe mir aus diesem Grund mal das alte ebuild angeschaut und verändert. Hier ist das Ergebnis:
Quote:
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-print/foo2zjs/foo2zjs-20090324.ebuild,v0.1 2009/03/24 20:25:50 hitachi Exp $

inherit eutils

DESCRIPTION="Support for printing to ZjStream-based printers"
HOMEPAGE="http://foo2zjs.rkkda.com/"


# extracted by http://gentooexperimental.org/~genstef/dist/foo2zjs-helper.sh

DEVICES=( "hp2600n" "hp1600" "hp1500" "hp1215" "km2530" "km2490" "km2480"
"km1690" "km1680" "km1600w" "xp6115" "km2430" "km2300" "km2200" "kmcpwl" "sa300"
"sa315" "sa3175" "xp6110" "lm500" "oki3100" "oki3200"
"oki3300" "oki3400" "oki3530" "oki5100" "oki5200" "oki5500" "oki5600" "oki5800"
"hp1020" "hp1018" "hp1005" "hp1000" "hpp1505" "hpp1008" "hpp1007" "hpp1006"
"hpp1005" )
#"sa610" has no file to download
#"sa2160" has no file to download
#"sa3160" has no file to download

URIS=(
"http://foo2hp.rkkda.com/icm/hpclj2600n.tar.gz
http://foo2zjs.rkkda.com/icm/km2430.tar.gz
http://foo2hp.rkkda.com/icm/hp1215.tar.gz"
"http://foo2hp.rkkda.com/icm/hpclj2600n.tar.gz
http://foo2zjs.rkkda.com/icm/km2430.tar.gz
http://foo2hp.rkkda.com/icm/hp1215.tar.gz"
"http://foo2hp.rkkda.com/icm/hpclj2600n.tar.gz
http://foo2zjs.rkkda.com/icm/km2430.tar.gz
http://foo2hp.rkkda.com/icm/hp1215.tar.gz"
"http://foo2hp.rkkda.com/icm/hpclj2600n.tar.gz
http://foo2zjs.rkkda.com/icm/km2430.tar.gz
http://foo2hp.rkkda.com/icm/hp1215.tar.gz"
"http://foo2lava.rkkda.com/icm/km2530.tar.gz"
"http://foo2lava.rkkda.com/icm/km2530.tar.gz"
"http://foo2lava.rkkda.com/icm/km2530.tar.gz"
"http://foo2lava.rkkda.com/icm/km2530.tar.gz"
"http://foo2lava.rkkda.com/icm/km2530.tar.gz"
"http://foo2lava.rkkda.com/icm/km2530.tar.gz"
"http://foo2lava.rkkda.com/icm/km2530.tar.gz"
"http://foo2zjs.rkkda.com/icm/km2430.tar.gz"
"ftp://ftp.minolta-qms.com/pub/crc/out_going/other/m23dlicc.exe
http://foo2zjs.rkkda.com/icm/km2430.tar.gz"
"ftp://ftp.minolta-qms.com/pub/crc/out_going/win2000/m22dlicc.exe"
"ftp://ftp.minolta-qms.com/pub/crc/out_going/windows/cpplxp.exe"
"http://foo2qpdl.rkkda.com/icm/samclp300.tar.gz
http://foo2qpdl.rkkda.com/icm/samclp315.tar.gz"
"http://foo2qpdl.rkkda.com/icm/samclp300.tar.gz
http://foo2qpdl.rkkda.com/icm/samclp315.tar.gz"
""
"http://foo2qpdl.rkkda.com/icm/samclp300.tar.gz
http://foo2qpdl.rkkda.com/icm/samclp315.tar.gz"
"http://foo2qpdl.rkkda.com/icm/samclp300.tar.gz
http://foo2qpdl.rkkda.com/icm/samclp315.tar.gz"
"http://foo2qpdl.rkkda.com/icm/samclp300.tar.gz
http://foo2qpdl.rkkda.com/icm/samclp315.tar.gz"
"http://foo2qpdl.rkkda.com/icm/samclp300.tar.gz
http://foo2qpdl.rkkda.com/icm/samclp315.tar.gz"
"http://foo2slx.rkkda.com/icm/lexc500.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic3200.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic3200.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic3400.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic3400.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic3400.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic3200.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic3200.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic5600.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic5600.tar.gz"
"http://foo2hiperc.rkkda.com/icm/okic5600.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihp1020.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihp1018.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihp1005.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihp1000.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihpP1505.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihpP1006.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihpP1005.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihpP1006.tar.gz"
"http://foo2zjs.rkkda.com/firmware/sihpP1005.tar.gz"
)


SRC_URI="http://dev.gentooexperimental.org/~scarabeus/${P}.tar.gz"
IUSE="cups foomaticdb usb"
for ((DEV=0; DEV < ${#DEVICES[*]}; DEV++)); do
SRC_URI="${SRC_URI} foo2zjs_devices_${DEVICES[DEV]}? ( ${URIS[DEV]} )"
IUSE="${IUSE} foo2zjs_devices_${DEVICES[DEV]}"
ALL_BEGIN="${ALL_BEGIN} !foo2zjs_devices_${DEVICES[DEV]}? ("
ALL_MIDDLE="${ALL_MIDDLE} ${URIS[DEV]}"
ALL_END="${ALL_END} )"
done
SRC_URI="${SRC_URI}${ALL_BEGIN}${ALL_MIDDLE}${ALL_END}"

LICENSE="GPL-2"
# due to those firmwares/icms/etc...
RESTRICT="mirror"
SLOT="0"
DEPEND="app-arch/unzip"
RDEPEND="cups? ( net-print/cups )
foomaticdb? ( net-print/foomatic-db-engine )
net-print/foomatic-filters
sys-fs/udev"
KEYWORDS="~x86 ~amd64 ~ppc"
S=${WORKDIR}/${PN}

src_unpack() {
unpack ${P}.tar.gz

# link getweb files in ${S} to get unpacked
for i in ${A}
do
ln -s "${DISTDIR}"/${i} "${S}"
done

cd "${S}"
epatch "${FILESDIR}"/${P}-Makefile.patch
epatch "${FILESDIR}"/${P}-udevfwld.patch
}

src_compile() {
emake getweb || die "Failed building getweb script"

# remove wget as we got the firmware with portage
sed -i -e "s/.*wget .*//" \
-e 's/.*rm $.*//' \
-e "s/error \"Couldn't dow.*//" getweb

# unpack files
GOT=0;
for ((DEV=0; DEV < ${#DEVICES[*]}; DEV++)); do
if use foo2zjs_devices_${DEVICES[DEV]}; then
./getweb ${DEVICES[DEV]:2}
GOT=1
fi
done
if [ ${GOT} == 0 ]; then ./getweb all; fi

emake || die "emake failed"
}

src_install() {
use foomaticdb && dodir /usr/share/foomatic/db/source

use cups && dodir /usr/share/cups/model

emake DESTDIR="${D}" install install-udev \
|| die "emake install failed"
}


So jetzt kommen meine Fragen:
1. Bei URIS sind ein paar mal Anführungszeichen und gelegentlich auch nicht. Wie sollte das richtig aussehen?
2. Wofür sind Makefile und udevfwld da?

Nachdem ich vollkommen unwissend wie ich bin in den beiden Dateien auch ein par Änderungen vorgenommen hatte (und den aktuellen Sourcecode nach /usr/portage/distfiles/foo2zjs-20090324.tar.gz kopiert hatte konnte ich mit folgendem Befehl erfolgreich emergen (ich glaube ich hatte es auch noch auf die keywords gesetzt):
Code:
FEATURES="-strict" emerge -v1 net-print/foo2zjs


Kann das jemand bestätigen?
Ich habe auch einen bug 263494 bei b.g.o erstellt. Wie kommt das Ding dann in den "Baum" von portage?

Ich bin wie immer dankbar für Eure Antworten und Verbesserungsvorschläge.
Back to top
View user's profile Send private message
manuels
Advocate
Advocate


Joined: 22 Nov 2003
Posts: 2146
Location: Europe

PostPosted: Wed Apr 01, 2009 1:12 pm    Post subject: Reply with quote

Quote:
Wofür sind Makefile und udevfwld da?
Das Makefile sagt welche Dateien kompiliert werden muessen und welche dann zusammengelinkt.
udevfwld weiss ich nicht.

Quote:
Wie kommt das Ding dann in den "Baum" von portage?
Erstmal gar nicht. Ausser ein Developer nimmt sich der Sache an, aber fuer solche "einmal" Ebuilds gibt es glaub ich kein Commit in den Portage Tree.
_________________
Build your own live cd with catalyst 2.0!
Back to top
View user's profile Send private message
hitachi
Guru
Guru


Joined: 20 Feb 2006
Posts: 478
Location: Freiburg / Deutschland

PostPosted: Wed Apr 01, 2009 1:20 pm    Post subject: Reply with quote

Was ist ein einmal Ebuild? Was bedeutet "Commit"?
Back to top
View user's profile Send private message
manuels
Advocate
Advocate


Joined: 22 Nov 2003
Posts: 2146
Location: Europe

PostPosted: Wed Apr 01, 2009 1:23 pm    Post subject: Reply with quote

- eins das fuer eine Version erstellt wird und nicht weiter gepflegt wird.
- Commit: die Uebernahme in den Portage Tree
_________________
Build your own live cd with catalyst 2.0!
Back to top
View user's profile Send private message
hitachi
Guru
Guru


Joined: 20 Feb 2006
Posts: 478
Location: Freiburg / Deutschland

PostPosted: Wed Apr 01, 2009 7:48 pm    Post subject: Reply with quote

ich kann mir schon vorstellen, jeden Monat mal zu schauen ob es was neues gibt und dann soweit ich das als unwissender kann was zu tippen.
Back to top
View user's profile Send private message
manuels
Advocate
Advocate


Joined: 22 Nov 2003
Posts: 2146
Location: Europe

PostPosted: Wed Apr 01, 2009 8:48 pm    Post subject: Reply with quote

so hab ich auch mal überlegt.
die anderen meinten aber, dass du erstmal stetig neue sachen liefern musst und du dann irgendwann in den ehrenwerten kreis der developer aufgenommen wirst.
_________________
Build your own live cd with catalyst 2.0!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German) 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