/[gentoo-x86]/dev-vcs/git/files/git-1.7.12-optional-cvs.patch
Gentoo

Contents of /dev-vcs/git/files/git-1.7.12-optional-cvs.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download)
Wed Aug 22 04:44:07 2012 UTC (22 months, 2 weeks ago) by robbat2
Branch: MAIN
CVS Tags: HEAD
Finally, a Git that works with SVN 1.7, per bug #418431! 1.7.12-r1 contains backported ms/git-svn-1.7 branch that will be merged into Git 1.7.13. 1.7.12-r0 excludes that backport but is otherwise identical. Thanks to Michael Schwern for the development work!

(Portage version: 2.2.0_alpha121/cvs/Linux x86_64)

1 From eadb20b065c33d46b49c8c95d8cde0c9fe7c62a4 Mon Sep 17 00:00:00 2001
2 From: Robin Johnson <robbat2@gentoo.org>
3 Date: Wed, 22 Aug 2012 04:25:06 +0000
4 Subject: [PATCH] Makefile: Add NO_CVS define to disable all CVS interface
5 utilities
6
7 Forward-ported from 1.7.10.2 to current git.git v1.7.12 tag PLUS fix-svn branch.
8
9 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/Makefile git-1.7.12/Makefile
10 --- git-1.7.12.orig/Makefile 2012-08-20 01:22:48.000000000 +0000
11 +++ git-1.7.12/Makefile 2012-08-22 04:23:48.335032122 +0000
12 @@ -224,6 +224,8 @@
13 #
14 # Define NO_TCLTK if you do not want Tcl/Tk GUI.
15 #
16 +# Define NO_CVS if you do not want any CVS interface utilities.
17 +#
18 # The TCL_PATH variable governs the location of the Tcl interpreter
19 # used to optimize git-gui for your system. Only used if NO_TCLTK
20 # is not set. Defaults to the bare 'tclsh'.
21 @@ -405,6 +407,7 @@
22 PROGRAM_OBJS =
23 PROGRAMS =
24 SCRIPT_PERL =
25 +SCRIPT_PERL_CVS =
26 SCRIPT_PYTHON =
27 SCRIPT_SH =
28 SCRIPT_LIB =
29 @@ -445,18 +448,19 @@
30 SCRIPT_PERL += git-add--interactive.perl
31 SCRIPT_PERL += git-difftool.perl
32 SCRIPT_PERL += git-archimport.perl
33 -SCRIPT_PERL += git-cvsexportcommit.perl
34 -SCRIPT_PERL += git-cvsimport.perl
35 -SCRIPT_PERL += git-cvsserver.perl
36 SCRIPT_PERL += git-relink.perl
37 SCRIPT_PERL += git-send-email.perl
38 SCRIPT_PERL += git-svn.perl
39
40 +SCRIPT_PERL_CVS += git-cvsexportcommit.perl
41 +SCRIPT_PERL_CVS += git-cvsimport.perl
42 +SCRIPT_PERL_CVS += git-cvsserver.perl
43 +
44 SCRIPT_PYTHON += git-remote-testgit.py
45 SCRIPT_PYTHON += git-p4.py
46
47 SCRIPTS = $(patsubst %.sh,%,$(SCRIPT_SH)) \
48 - $(patsubst %.perl,%,$(SCRIPT_PERL)) \
49 + $(patsubst %.perl,%,$(SCRIPT_PERL) $(SCRIPT_PERL_CVS)) \
50 $(patsubst %.py,%,$(SCRIPT_PYTHON)) \
51 git-instaweb
52
53 @@ -2088,8 +2092,18 @@
54 $(QUIET_GEN)$(cmd_munge_script) && \
55 mv $@+ $@
56
57 +_SCRIPT_PERL_BUILD =
58 +_SCRIPT_PERL_NOBUILD =
59 +
60 ifndef NO_PERL
61 -$(patsubst %.perl,%,$(SCRIPT_PERL)): perl/perl.mak
62 +
63 +_SCRIPT_PERL_BUILD += $(SCRIPT_PERL)
64 +
65 +ifndef NO_CVS
66 +_SCRIPT_PERL_BUILD += $(SCRIPT_PERL_CVS)
67 +else # NO_CVS
68 +_SCRIPT_PERL_NOBUILD += $(SCRIPT_PERL_CVS)
69 +endif # NO_CVS
70
71 perl/perl.mak: perl/PM.stamp
72
73 @@ -2101,7 +2115,7 @@
74 perl/perl.mak: GIT-CFLAGS GIT-PREFIX perl/Makefile perl/Makefile.PL
75 $(QUIET_SUBDIR0)perl $(QUIET_SUBDIR1) PERL_PATH='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' $(@F)
76
77 -$(patsubst %.perl,%,$(SCRIPT_PERL)): % : %.perl GIT-VERSION-FILE
78 +$(patsubst %.perl,%,$(_SCRIPT_PERL_BUILD)): % : %.perl GIT-VERSION-FILE
79 $(QUIET_GEN)$(RM) $@ $@+ && \
80 INSTLIBDIR=`MAKEFLAGS= $(MAKE) -C perl -s --no-print-directory instlibdir` && \
81 sed -e '1{' \
82 @@ -2126,14 +2140,17 @@
83 chmod +x $@+ && \
84 mv $@+ $@
85 else # NO_PERL
86 -$(patsubst %.perl,%,$(SCRIPT_PERL)) git-instaweb: % : unimplemented.sh
87 +_SCRIPT_PERL_NOBUILD += $(SCRIPT_PERL) $(SCRIPT_PERL_CVS) git-instaweb
88 +endif # NO_PERL
89 +
90 +# This is any perl scripts that were disabled it might be empty...
91 +$(patsubst %.perl,%,$(_SCRIPT_PERL_NOBUILD)): % : unimplemented.sh
92 $(QUIET_GEN)$(RM) $@ $@+ && \
93 sed -e '1s|#!.*/sh|#!$(SHELL_PATH_SQ)|' \
94 -e 's|@@REASON@@|NO_PERL=$(NO_PERL)|g' \
95 unimplemented.sh >$@+ && \
96 chmod +x $@+ && \
97 mv $@+ $@
98 -endif # NO_PERL
99
100 ifndef NO_PYTHON
101 $(patsubst %.py,%,$(SCRIPT_PYTHON)): GIT-CFLAGS GIT-PREFIX
102 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/t/t9200-git-cvsexportcommit.sh git-1.7.12/t/t9200-git-cvsexportcommit.sh
103 --- git-1.7.12.orig/t/t9200-git-cvsexportcommit.sh 2012-08-20 01:22:48.000000000 +0000
104 +++ git-1.7.12/t/t9200-git-cvsexportcommit.sh 2012-08-22 04:19:23.650741974 +0000
105 @@ -12,6 +12,11 @@
106 test_done
107 fi
108
109 +if ! test_have_prereq CVS; then
110 + skip_all='skipping git cvsexportcommit tests, cvs not available'
111 + test_done
112 +fi
113 +
114 cvs >/dev/null 2>&1
115 if test $? -ne 1
116 then
117 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/t/t9400-git-cvsserver-server.sh git-1.7.12/t/t9400-git-cvsserver-server.sh
118 --- git-1.7.12.orig/t/t9400-git-cvsserver-server.sh 2012-08-20 01:22:48.000000000 +0000
119 +++ git-1.7.12/t/t9400-git-cvsserver-server.sh 2012-08-22 04:19:23.650741974 +0000
120 @@ -11,9 +11,15 @@
121 . ./test-lib.sh
122
123 if ! test_have_prereq PERL; then
124 - skip_all='skipping git cvsserver tests, perl not available'
125 + skip_all='skipping git-cvsserver tests, perl not available'
126 test_done
127 fi
128 +
129 +if ! test_have_prereq CVS; then
130 + skip_all='skipping git-cvsserver tests, cvs not available'
131 + test_done
132 +fi
133 +
134 cvs >/dev/null 2>&1
135 if test $? -ne 1
136 then
137 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/t/t9401-git-cvsserver-crlf.sh git-1.7.12/t/t9401-git-cvsserver-crlf.sh
138 --- git-1.7.12.orig/t/t9401-git-cvsserver-crlf.sh 2012-08-20 01:22:48.000000000 +0000
139 +++ git-1.7.12/t/t9401-git-cvsserver-crlf.sh 2012-08-22 04:19:23.650741974 +0000
140 @@ -38,15 +38,20 @@
141 fi
142 }
143
144 -cvs >/dev/null 2>&1
145 -if test $? -ne 1
146 +if ! test_have_prereq PERL
147 then
148 - skip_all='skipping git-cvsserver tests, cvs not found'
149 + skip_all='skipping git-cvsserver tests, perl not available'
150 test_done
151 fi
152 -if ! test_have_prereq PERL
153 +if ! test_have_prereq CVS
154 then
155 - skip_all='skipping git-cvsserver tests, perl not available'
156 + skip_all='skipping git-cvsserver tests, cvs not available'
157 + test_done
158 +fi
159 +cvs >/dev/null 2>&1
160 +if test $? -ne 1
161 +then
162 + skip_all='skipping git-cvsserver tests, cvs not found'
163 test_done
164 fi
165 "$PERL_PATH" -e 'use DBI; use DBD::SQLite' >/dev/null 2>&1 || {
166 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/t/t9600-cvsimport.sh git-1.7.12/t/t9600-cvsimport.sh
167 --- git-1.7.12.orig/t/t9600-cvsimport.sh 2012-08-20 01:22:48.000000000 +0000
168 +++ git-1.7.12/t/t9600-cvsimport.sh 2012-08-22 04:19:23.650741974 +0000
169 @@ -3,14 +3,25 @@
170 test_description='git cvsimport basic tests'
171 . ./lib-cvs.sh
172
173 -test_expect_success PERL 'setup cvsroot environment' '
174 +if ! test_have_prereq PERL
175 +then
176 + skip_all='skipping git cvsimport tests, perl not available'
177 + test_done
178 +fi
179 +if ! test_have_prereq CVS
180 +then
181 + skip_all='skipping git cvsimport tests, cvs not available'
182 + test_done
183 +fi
184 +
185 +test_expect_success 'setup cvsroot environment' '
186 CVSROOT=$(pwd)/cvsroot &&
187 export CVSROOT
188 '
189
190 -test_expect_success PERL 'setup cvsroot' '$CVS init'
191 +test_expect_success 'setup cvsroot' '$CVS init'
192
193 -test_expect_success PERL 'setup a cvs module' '
194 +test_expect_success 'setup a cvs module' '
195
196 mkdir "$CVSROOT/module" &&
197 $CVS co -d module-cvs module &&
198 @@ -42,23 +53,23 @@
199 )
200 '
201
202 -test_expect_success PERL 'import a trivial module' '
203 +test_expect_success 'import a trivial module' '
204
205 git cvsimport -a -R -z 0 -C module-git module &&
206 test_cmp module-cvs/o_fortuna module-git/o_fortuna
207
208 '
209
210 -test_expect_success PERL 'pack refs' '(cd module-git && git gc)'
211 +test_expect_success 'pack refs' '(cd module-git && git gc)'
212
213 -test_expect_success PERL 'initial import has correct .git/cvs-revisions' '
214 +test_expect_success 'initial import has correct .git/cvs-revisions' '
215
216 (cd module-git &&
217 git log --format="o_fortuna 1.1 %H" -1) > expected &&
218 test_cmp expected module-git/.git/cvs-revisions
219 '
220
221 -test_expect_success PERL 'update cvs module' '
222 +test_expect_success 'update cvs module' '
223 (cd module-cvs &&
224 cat <<EOF >o_fortuna &&
225 O Fortune,
226 @@ -86,7 +97,7 @@
227 )
228 '
229
230 -test_expect_success PERL 'update git module' '
231 +test_expect_success 'update git module' '
232
233 (cd module-git &&
234 git config cvsimport.trackRevisions true &&
235 @@ -97,7 +108,7 @@
236
237 '
238
239 -test_expect_success PERL 'update has correct .git/cvs-revisions' '
240 +test_expect_success 'update has correct .git/cvs-revisions' '
241
242 (cd module-git &&
243 git log --format="o_fortuna 1.1 %H" -1 HEAD^ &&
244 @@ -105,7 +116,7 @@
245 test_cmp expected module-git/.git/cvs-revisions
246 '
247
248 -test_expect_success PERL 'update cvs module' '
249 +test_expect_success 'update cvs module' '
250
251 (cd module-cvs &&
252 echo 1 >tick &&
253 @@ -114,7 +125,7 @@
254 )
255 '
256
257 -test_expect_success PERL 'cvsimport.module config works' '
258 +test_expect_success 'cvsimport.module config works' '
259
260 (cd module-git &&
261 git config cvsimport.module module &&
262 @@ -126,7 +137,7 @@
263
264 '
265
266 -test_expect_success PERL 'second update has correct .git/cvs-revisions' '
267 +test_expect_success 'second update has correct .git/cvs-revisions' '
268
269 (cd module-git &&
270 git log --format="o_fortuna 1.1 %H" -1 HEAD^^ &&
271 @@ -135,7 +146,7 @@
272 test_cmp expected module-git/.git/cvs-revisions
273 '
274
275 -test_expect_success PERL 'import from a CVS working tree' '
276 +test_expect_success 'import from a CVS working tree' '
277
278 $CVS co -d import-from-wt module &&
279 (cd import-from-wt &&
280 @@ -148,12 +159,12 @@
281
282 '
283
284 -test_expect_success PERL 'no .git/cvs-revisions created by default' '
285 +test_expect_success 'no .git/cvs-revisions created by default' '
286
287 ! test -e import-from-wt/.git/cvs-revisions
288
289 '
290
291 -test_expect_success PERL 'test entire HEAD' 'test_cmp_branch_tree master'
292 +test_expect_success 'test entire HEAD' 'test_cmp_branch_tree master'
293
294 test_done
295 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/t/t9601-cvsimport-vendor-branch.sh git-1.7.12/t/t9601-cvsimport-vendor-branch.sh
296 --- git-1.7.12.orig/t/t9601-cvsimport-vendor-branch.sh 2012-08-20 01:22:48.000000000 +0000
297 +++ git-1.7.12/t/t9601-cvsimport-vendor-branch.sh 2012-08-22 04:19:23.650741974 +0000
298 @@ -34,6 +34,17 @@
299 test_description='git cvsimport handling of vendor branches'
300 . ./lib-cvs.sh
301
302 +if ! test_have_prereq PERL
303 +then
304 + skip_all='skipping git cvsimport tests, perl not available'
305 + test_done
306 +fi
307 +if ! test_have_prereq CVS
308 +then
309 + skip_all='skipping git cvsimport tests, cvs not available'
310 + test_done
311 +fi
312 +
313 setup_cvs_test_repository t9601
314
315 test_expect_success PERL 'import a module with a vendor branch' '
316 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/t/t9602-cvsimport-branches-tags.sh git-1.7.12/t/t9602-cvsimport-branches-tags.sh
317 --- git-1.7.12.orig/t/t9602-cvsimport-branches-tags.sh 2012-08-20 01:22:48.000000000 +0000
318 +++ git-1.7.12/t/t9602-cvsimport-branches-tags.sh 2012-08-22 04:19:23.650741974 +0000
319 @@ -6,6 +6,17 @@
320 test_description='git cvsimport handling of branches and tags'
321 . ./lib-cvs.sh
322
323 +if ! test_have_prereq PERL
324 +then
325 + skip_all='skipping git cvsimport tests, perl not available'
326 + test_done
327 +fi
328 +if ! test_have_prereq CVS
329 +then
330 + skip_all='skipping git cvsimport tests, cvs not available'
331 + test_done
332 +fi
333 +
334 setup_cvs_test_repository t9602
335
336 test_expect_success PERL 'import module' '
337 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/t/t9603-cvsimport-patchsets.sh git-1.7.12/t/t9603-cvsimport-patchsets.sh
338 --- git-1.7.12.orig/t/t9603-cvsimport-patchsets.sh 2012-08-20 01:22:48.000000000 +0000
339 +++ git-1.7.12/t/t9603-cvsimport-patchsets.sh 2012-08-22 04:19:23.650741974 +0000
340 @@ -14,6 +14,17 @@
341 test_description='git cvsimport testing for correct patchset estimation'
342 . ./lib-cvs.sh
343
344 +if ! test_have_prereq PERL
345 +then
346 + skip_all='skipping git cvsimport tests, perl not available'
347 + test_done
348 +fi
349 +if ! test_have_prereq CVS
350 +then
351 + skip_all='skipping git cvsimport tests, cvs not available'
352 + test_done
353 +fi
354 +
355 setup_cvs_test_repository t9603
356
357 test_expect_failure 'import with criss cross times on revisions' '
358 diff -Nuar --exclude '*.orig' --exclude '*.rej' git-1.7.12.orig/t/test-lib.sh git-1.7.12/t/test-lib.sh
359 --- git-1.7.12.orig/t/test-lib.sh 2012-08-20 01:22:48.000000000 +0000
360 +++ git-1.7.12/t/test-lib.sh 2012-08-22 04:19:23.650741974 +0000
361 @@ -618,6 +618,7 @@
362 esac
363
364 ( COLUMNS=1 && test $COLUMNS = 1 ) && test_set_prereq COLUMNS_CAN_BE_1
365 +test -z "$NO_CVS" && test_set_prereq CVS
366 test -z "$NO_PERL" && test_set_prereq PERL
367 test -z "$NO_PYTHON" && test_set_prereq PYTHON
368 test -n "$USE_LIBPCRE" && test_set_prereq LIBPCRE

  ViewVC Help
Powered by ViewVC 1.1.20