1 |
Hi |
2 |
|
3 |
It is hard to answer many of these questions without seeing the package and |
4 |
ebuild. However I'll try. |
5 |
|
6 |
On Wednesday 17 April 2002 23:13, Avi Schwartz wrote: |
7 |
> I am trying to create an ebuild for wingide. I have couple of problems |
8 |
> I trying to solve here: |
9 |
> |
10 |
> 1. The name of the archive is wingide-1.1.3-1.tar.gz. I tried to call |
11 |
> the ebuild file wingide-1.1.3-1.ebuild but ebuild doesn't like it since |
12 |
> it thinks there are two version numbers. So I changed the name to |
13 |
> wingide-1.1.3-r1.ebuild and I am sticking the -1 in the code: |
14 |
[skipped] |
15 |
> Is this an acceptable practice? The problem with this is that if they |
16 |
> come out with a -2 version, it will not be enough to rename the ebuild |
17 |
> file (although the bug fix files are breaking this anyway). |
18 |
At least this is what you can find in some ebuilds. And it seems to be the |
19 |
easiest way to go around here. You also would probably want to set your |
20 |
${S}=${WORKDIR}/${P}-1. |
21 |
|
22 |
> |
23 |
> BTW, PV and ${D} are not documented in the developers HOWTO. What else |
24 |
> is missing? |
25 |
I hope I finally will get some time to update this part of instructions. I was |
26 |
going to prepare the list of all vars portage generates when it parses ebuild |
27 |
and link to it from the existing ebuild composition howto. I would appreciate |
28 |
suggestion on what else should be covered. |
29 |
|
30 |
> |
31 |
> 2. Wingide comes with its own installation program which can be |
32 |
> controlled through the command line. When its archive is expanded, it |
33 |
> creates a wingide-1.1.3-1 directory in which there is the installation |
34 |
> program and the program files. Ho do I point to the installation |
35 |
> program? I tried the following ${WORKDIR}/${P}-1/wing-install.py, is |
36 |
> this correct? |
37 |
Does it work? In order to check this you can issue ebuild |
38 |
wingide-1.1.3-1.ebuild unpack and then go to |
39 |
/var/tmp/portage/wingide-1.1.3-1/work and see what goes where. |
40 |
|
41 |
> |
42 |
> 3. The parameters it expects are the installation directory and binary |
43 |
> directory: |
44 |
> |
45 |
> ${WORKDIR}/${P}-1/wing-install.py \ |
46 |
> --winghome ${D}/usr/lib/wingide \ |
47 |
> --bin-dir ${D}/usr/bin |
48 |
> |
49 |
> again, does this make sense? |
50 |
Is this analog of configure script or of make install? |
51 |
You do not want anything that gets compiled or somehow setup to get an idea |
52 |
that it lives under ${D}. However you do want it to be installed under ${D}. |
53 |
|
54 |
> 5. The last 3 files are archives that have to be extracted over the root |
55 |
> installation directory which will be ${D}/usr/lib/wingide. Again, how |
56 |
> does one achieve this? |
57 |
what about this? |
58 |
cd ${D}/usr/lib/wingide |
59 |
tar xzpf file |
60 |
|
61 |
> 6. The compile stage extracts all 4 files while I really want only the |
62 |
> main file to be extracted since the other 3 need to be extracted over |
63 |
> the installed file. Is there a way to control this? I tried to put my |
64 |
> own code in src_compile(), but ebuild goes ahead and extracts the |
65 |
> archives before executing my code. |
66 |
Are you talking about unpack or compile stage? When the files are extracted? |
67 |
You might need to provide src_unpack function to do custom stuff. |
68 |
|
69 |
> 7. When the wingide archive is extracted, besides the installation |
70 |
> program there is another tar file extracted which containsall the files. |
71 |
> Another possibility for the installation of the main wingide archive is |
72 |
> to just extract this archive into ${D}/usr/lib. The question is, do I |
73 |
> have to create ${D}/usr/lib if it doesn't exist yet or will ebuild do it |
74 |
> for me? |
75 |
I think you do. I am not totally clear on what are you trying to achieve here |
76 |
though. Besides this is you who tells ebuild what to do and if the dir was |
77 |
not created by the package installation scripts ebuild will not know to |
78 |
create it on itself. |
79 |
BTW, is this a prebuilt package or can it be compiled (the last one is always |
80 |
preferable). Is this a WingIDE by any chance? Is this a (time-limited) demo |
81 |
version? I think the users are required to register on the site when |
82 |
downloading the product (in order to get the license). You will most likely |
83 |
have to do something about it (I am not really sure on the status of this |
84 |
package). At present you can ask users to download the package themselves and |
85 |
put it under /usr/portage/distfiles before proceeding. It may change in |
86 |
(probably already near) future when licensing stuff is handled in portage. |
87 |
|
88 |
George |