1 |
I like XML as much as the next guy, but one thing you should remember is |
2 |
that ebuilds are not some arbitrary pkg format -- they're bash scripts. |
3 |
They may not look it, since they don't have #!/bin/bash at the top, but |
4 |
they are bash scripts that are sourced with other bash scripts. So, for |
5 |
example, most ebuilds have bash functins like src_unpack, src_install, |
6 |
ect, but others have their own functions that are defined and called by |
7 |
these src_* functions. Converting this to XML would mean that portage |
8 |
would have to convert everything to bash, plus there'd have to be enough |
9 |
flexibility in the XML stylesheet we'd to include the possibility of |
10 |
unknown-ebuild-specific global variables, functions, ect. |
11 |
|
12 |
Just food for thought. |
13 |
|
14 |
-Jared H. |
15 |
|
16 |
Brian Friday wrote: |
17 |
> -- Begin Newbie Rant |
18 |
> |
19 |
> First (as it is my first post), I'd like to say thanks to all the people |
20 |
> who've made gentoo what it is today. I've used lots of linux distributions |
21 |
> but Gentoo was the first to make me feel at home. So thanks for creating |
22 |
> something I have, am and hope to continue enjoying. |
23 |
> |
24 |
> -- End Newbie Rant |
25 |
> |
26 |
> Perhaps I'm totally missing the point but.... |
27 |
> |
28 |
> On the large scale, there will be soon if not already a need to know |
29 |
> when a package was released and/or what version of the distribution it |
30 |
> first occurred in. In addition, making dependency information more |
31 |
> accessible, up to date and more detailed would be helpful as well. These |
32 |
> needs would be in addition to the general information portage currently |
33 |
> stores about a packages (ie category, name, version, size, homepage, and |
34 |
> description). |
35 |
> |
36 |
> For the large scale, a database would seem to be the logical choice for |
37 |
> storing all this information. With a web or similarly easy interface to |
38 |
> allow casual browsing and or administration. You'd want to have primary |
39 |
> servers which would ideally feed mirrors who then in turn feed users. |
40 |
> Though they could feed the end users as well. |
41 |
> |
42 |
> For the individual system, I think the DB idea is overkill but I like |
43 |
> the plugin ability. Maybe a step similar to choosing your cron/syslog but |
44 |
> instead you would be choosing your portage backend. |
45 |
> |
46 |
> One of the key strengths of Gentoo I see as an end user is that most/all |
47 |
> of the files which determine how I can build/configure my system are |
48 |
> directly editable. In practical terms, this openness has encouraged me to |
49 |
> pro-actively attack problems rather than wait for fixes. Ultimately |
50 |
> allowing me to feel a direct part of the Gentoo community, even if I'm |
51 |
> only hacking my system. |
52 |
> |
53 |
> Now what if the portage on end user systems retained a XML text file |
54 |
> format similar to the example below. This would give us the flexibility of |
55 |
> text, as it is readable by the normal human, while at the same time |
56 |
> machine friendly. The example below is just a quick idea how a ebuild file |
57 |
> might look in an XML portage system. |
58 |
> |
59 |
> Example XML file for a package: |
60 |
> |
61 |
> <package> |
62 |
> <name></name> |
63 |
> <version></version> |
64 |
> <size></size> |
65 |
> <homepage></homepage> |
66 |
> <license></license> |
67 |
> <portage_release_date></portage_release_date> |
68 |
> <slot></slot> |
69 |
> <ebuild_comment></ebuild_comment> |
70 |
> <description> |
71 |
> <keywords></keywords> |
72 |
> <abstract>one line info text</abstract> |
73 |
> <full_text>full about text</full_text> |
74 |
> <ebuild_comment></ebuild_comment> |
75 |
> </description> |
76 |
> <dependency> |
77 |
> <name></name> |
78 |
> <version></version> |
79 |
> <mandatory>yes or no</mandatory> |
80 |
> <reason>why it might be good to have this</reason> |
81 |
> </dependency> |
82 |
> <ebuild_commands> |
83 |
> <ebuild_comment></ebuild_comment> |
84 |
> <pkg_setup> |
85 |
> <ebuild_comment></ebuild_comment> |
86 |
> <commands></commands> |
87 |
> </pkg_setup> |
88 |
> <src_unpack></src_unpack> |
89 |
> <src_compile></src_compile> |
90 |
> <src_install></src_install> |
91 |
> <pkg_preinst></pkg_preinst> |
92 |
> <pkg_postinst></pkg_postinst> |
93 |
> <pkg_prerm></pkg_prerm> |
94 |
> <pkg_postrm></pkg_postrm> |
95 |
> <pkg_config></pkg_config> |
96 |
> </ebuild_commands> |
97 |
> </package> |
98 |
> |
99 |
> The nice thing about XML is it could also be used with the plugin idea, |
100 |
> allowing for a intermediate structured format for transfer between the |
101 |
> gentoo servers/mirrors and the end user system. Backends are given the |
102 |
> data in a format they can parse through without to much trouble and you |
103 |
> could also export a ebuild out in a structured format perhaps allowing for |
104 |
> remote submission of ebuilds. |
105 |
> |
106 |
> Now that I'm thinking about it you could have two XML package template |
107 |
> versions, detailed and optimised versions. The detailed version would be |
108 |
> as shown above containing absolutely everything about the ebuild. The |
109 |
> optimised version would contain just minimum elements needed for the |
110 |
> portage system. This would have the secondary effect of having optimised |
111 |
> mirrors which only have those bare bones ebuild files.... |
112 |
> |
113 |
> I'm rambling so I'll end this. Thoughts? Flames? Expressive Grunts? |
114 |
> |
115 |
> |
116 |
> -- |
117 |
> Brian |
118 |
> |
119 |
> |
120 |
> |
121 |
> |
122 |
> |
123 |
> -- |
124 |
> gentoo-dev@g.o mailing list |
125 |
|
126 |
|
127 |
-- |
128 |
gentoo-dev@g.o mailing list |