freedreno: defer flush_queue allocation
[mesa.git] / docs / repository.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2 <html lang="en">
3 <head>
4 <meta http-equiv="content-type" content="text/html; charset=utf-8">
5 <title>Code Repository</title>
6 <link rel="stylesheet" type="text/css" href="mesa.css">
7 </head>
8 <body>
9
10 <div class="header">
11 <h1>The Mesa 3D Graphics Library</h1>
12 </div>
13
14 <iframe src="contents.html"></iframe>
15 <div class="content">
16
17 <h1>Code Repository</h1>
18
19 <p>
20 Mesa uses <a href="http://git-scm.com">git</a>
21 as its source code management system.
22 </p>
23
24 <p>
25 The master git repository is hosted on
26 <a href="http://www.freedesktop.org">freedesktop.org</a>.
27 </p>
28
29 <p>
30 You may access the repository either as an
31 <a href="#anonymous">anonymous user</a> (read-only) or as a
32 <a href="#developer">developer</a>
33 (read/write).
34 </p>
35
36 <p>
37 You may also
38 <a href="http://cgit.freedesktop.org/mesa/mesa/"
39 >browse the main Mesa git repository</a> and the
40 <a href="http://cgit.freedesktop.org/mesa/demos"
41 >Mesa demos and tests git repository</a>.
42 </p>
43
44
45 <h2 id="anonymous">Anonymous git Access</h2>
46
47 <p>
48 To get the Mesa sources anonymously (read-only):
49 </p>
50
51 <ol>
52 <li>Install the git software on your computer if needed.<br><br>
53 <li>Get an initial, local copy of the repository with:
54 <pre>
55 git clone git://anongit.freedesktop.org/git/mesa/mesa
56 </pre>
57 <li>Later, you can update your tree from the master repository with:
58 <pre>
59 git pull origin
60 </pre>
61 <li>If you also want the Mesa demos/tests repository:
62 <pre>
63 git clone git://anongit.freedesktop.org/git/mesa/demos
64 </pre>
65 </ol>
66
67
68 <h2 id="developer">Developer git Access</h2>
69
70 <p>
71 If you wish to become a Mesa developer with git-write privilege, please
72 follow this procedure:
73 </p>
74 <ol>
75 <li>Subscribe to the
76 <a href="http://lists.freedesktop.org/mailman/listinfo/mesa-dev">mesa-dev</a>
77 mailing list.
78 <li>Start contributing to the project by posting patches / review requests to
79 the mesa-dev list. Specifically,
80 <ul>
81 <li>Use <code>git send-mail</code> to post your patches to mesa-dev.
82 <li>Wait for someone to review the code and give you a <code>Reviewed-by</code>
83 statement.
84 <li>You'll have to rely on another Mesa developer to push your initial patches
85 after they've been reviewed.
86 </ul>
87 <li>After you've demonstrated the ability to write good code and have had
88 a dozen or so patches accepted you can apply for an account.
89 <li>Occasionally, but rarely, someone may be given a git account sooner, but
90 only if they're being supervised by another Mesa developer at the same
91 organization and planning to work in a limited area of the code or on a
92 separate branch.
93 <li>To apply for an account, follow
94 <a href="http://www.freedesktop.org/wiki/AccountRequests">these directions</a>.
95 It's also appreciated if you briefly describe what you intend to do (work
96 on a particular driver, add a new extension, etc.) in the bugzilla record.
97 </ol>
98
99 <p>
100 Once your account is established:
101 </p>
102
103 <ol>
104 <li>Get an initial, local copy of the repository with:
105 <pre>
106 git clone git+ssh://username@git.freedesktop.org/git/mesa/mesa
107 </pre>
108 Replace <em>username</em> with your actual login name.<br><br>
109 <li>Later, you can update your tree from the master repository with:
110 <pre>
111 git pull origin
112 </pre>
113 <li>If you also want the Mesa demos/tests repository:
114 <pre>
115 git clone git+ssh://username@git.freedesktop.org/git/mesa/demos
116 </pre>
117 </ol>
118
119
120 <h2>Windows Users</h2>
121
122 <p>
123 If you're <a href="http://git.wiki.kernel.org/index.php/WindowsInstall">
124 using git on Windows</a> you'll want to enable automatic CR/LF conversion in
125 your local copy of the repository:
126 </p>
127 <pre>
128 git config --global core.autocrlf true
129 </pre>
130
131 <p>
132 This will cause git to convert all text files to CR+LF on checkout,
133 and to LF on commit.
134 </p>
135 <p>
136 Unix users don't need to set this option.
137 </p>
138 <br>
139
140
141 <h2>Development Branches</h2>
142
143 <p>
144 At any given time, there may be several active branches in Mesa's
145 repository.
146 Generally, the trunk contains the latest development (unstable)
147 code while a branch has the latest stable code.
148 </p>
149
150 <p>
151 The command <code>git-branch</code> will list all available branches.
152 </p>
153
154 <p>
155 Questions about branch status/activity should be posted to the
156 mesa3d-dev mailing list.
157 </p>
158
159 <h2>Developer Git Tips</h2>
160
161 <ol>
162 <li>Setting up to edit the master branch
163 <p>
164 If you try to do a pull by just saying<code> git pull </code>
165 and git complains that you have not specified a
166 branch, try:
167 <pre>
168 git config branch.master.remote origin
169 git config branch.master.merge master
170 </pre>
171 <p>
172 Otherwise, you have to say<code> git pull origin master </code>
173 each time you do a pull.
174 </p>
175 <li>Small changes to master
176 <p>
177 If you are an experienced git user working on substantial modifications,
178 you are probably
179 working on a separate branch and would rebase your branch prior to
180 merging with master.
181 But for small changes to the master branch itself,
182 you also need to use the rebase feature in order to avoid an
183 unnecessary and distracting branch in master.
184 </p>
185 <p>
186 If it has been awhile since you've done the initial clone, try
187 <pre>
188 git pull
189 </pre>
190 <p>
191 to get the latest files before you start working.
192 </p>
193 <p>
194 Make your changes and use
195 <pre>
196 git add &lt;files to commit&gt;
197 git commit
198 </pre>
199 <p>
200 to get your changes ready to push back into the fd.o repository.
201 </p>
202 <p>
203 It is possible (and likely) that someone has changed master since
204 you did your last pull. Even if your changes do not conflict with
205 their changes, git will make a fast-forward
206 merge branch, branching from the point in time
207 where you did your last pull and merging it to a point after the other changes.
208 </p>
209 <p>
210 To avoid this,
211 <pre>
212 git pull --rebase
213 git push
214 </pre>
215 <p>
216 If you are familiar with CVS or similar system, this is similar to doing a
217 <code> cvs update </code> in order to update your source tree to
218 the current repository state, instead of the time you did the last update.
219 (CVS doesn't work like git in this respect, but this is easiest way
220 to explain it.)
221 <br>
222 In any case, your repository now looks like you made your changes after
223 all the other changes.
224 </p>
225 <p>
226 If the rebase resulted in conflicts or changes that could affect
227 the proper operation of your changes, you'll need to investigate
228 those before doing the push.
229 </p>
230 <p>
231 If you want the rebase action to be the default action, then
232 <pre>
233 git config branch.master.rebase true
234 git config --global branch.autosetuprebase=always
235 </pre>
236 <p>
237 See <a href="http://www.eecs.harvard.edu/~cduan/technical/git/">Understanding Git Conceptually</a> for a fairly clear explanation about all of this.
238 </p>
239 </ol>
240
241 </div>
242 </body>
243 </html>