@@ -450,80 +450,6 @@ endif
450
450
X = .exe
451
451
452
452
compat/msvc.o: compat/msvc.c compat/mingw.c GIT-CFLAGS
453
-
454
- vcxproj:
455
- # Require clean work tree
456
- git update-index -q --refresh && \
457
- git diff-files --quiet && \
458
- git diff-index --cached --quiet HEAD --
459
-
460
- # Make .vcxproj files and add them
461
- unset QUIET_GEN QUIET_BUILT_IN; \
462
- perl contrib/buildsystems/generate -g Vcxproj
463
- git add -f git.sln {*,*/lib,t/helper/*}/*.vcxproj
464
-
465
- # Generate the LinkOrCopyBuiltins.targets file
466
- (echo '<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">' && \
467
- echo ' <Target Name="CopyBuiltins_AfterBuild" AfterTargets="AfterBuild">' && \
468
- for name in $(BUILT_INS);\
469
- do \
470
- echo ' <Copy SourceFiles="$$(OutDir)\git.exe" DestinationFiles="$$(OutDir)\'"$$name"'" SkipUnchangedFiles="true" UseHardlinksIfPossible="true" />'; \
471
- done && \
472
- for name in $(REMOTE_CURL_ALIASES); \
473
- do \
474
- echo ' <Copy SourceFiles="$$(OutDir)\'"$(REMOTE_CURL_PRIMARY)"'" DestinationFiles="$$(OutDir)\'"$$name"'" SkipUnchangedFiles="true" UseHardlinksIfPossible="true" />'; \
475
- done && \
476
- echo ' </Target>' && \
477
- echo '</Project>') >git/LinkOrCopyBuiltins.targets
478
- git add -f git/LinkOrCopyBuiltins.targets
479
-
480
- # Add command-list.h
481
- $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 command-list.h
482
- git add -f command-list.h
483
-
484
- # Add scripts
485
- rm -f perl/perl.mak
486
- $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 \
487
- $(SCRIPT_LIB) $(SCRIPT_SH_GEN) $(SCRIPT_PERL_GEN)
488
- # Strip out the sane tool path, needed only for building
489
- sed -i '/^git_broken_path_fix ".*/d' git-sh-setup
490
- git add -f $(SCRIPT_LIB) $(SCRIPT_SH_GEN) $(SCRIPT_PERL_GEN)
491
-
492
- # Add Perl module
493
- $(MAKE) $(LIB_PERL_GEN)
494
- git add -f perl/build
495
-
496
- # Add bin-wrappers, for testing
497
- rm -rf bin-wrappers/
498
- $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 $(test_bindir_programs)
499
- # Ensure that the GIT_EXEC_PATH is a Unix-y one, and that the absolute
500
- # path of the repository is not hard-coded (GIT_EXEC_PATH will be set
501
- # by test-lib.sh according to the current setup)
502
- sed -i -e 's/^\(GIT_EXEC_PATH\)=.*/test -n "$${\1##*:*}" ||\
503
- \1="$$(cygpath -u "$$\1")"/' \
504
- -e "s|'$$(pwd)|\"\$$GIT_EXEC_PATH\"'|g" bin-wrappers/*
505
- # Ensure that test-* helpers find the .dll files copied to top-level
506
- sed -i 's|^PATH=.*|&:"$$GIT_EXEC_PATH"|' bin-wrappers/test-*
507
- # We do not want to force hard-linking builtins
508
- sed -i 's|\(git\)-\([-a-z]*\)\.exe"|\1.exe" \2|g' \
509
- bin-wrappers/git-{receive-pack,upload-archive}
510
- git add -f $(test_bindir_programs)
511
- # remote-ext is a builtin, but invoked as if it were external
512
- sed 's|receive-pack|remote-ext|g' \
513
- <bin-wrappers/git-receive-pack >bin-wrappers/git-remote-ext
514
- git add -f bin-wrappers/git-remote-ext
515
-
516
- # Add templates
517
- $(MAKE) -C templates
518
- git add -f templates/boilerplates.made templates/blt/
519
-
520
- # Add build options
521
- $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 GIT-BUILD-OPTIONS
522
- git add -f GIT-BUILD-OPTIONS
523
-
524
- # Commit the whole shebang
525
- git commit -m "Generate Visual Studio solution" \
526
- -m "Auto-generated by \`$(MAKE)$(MAKEFLAGS) $@\`"
527
453
endif
528
454
ifeq ($(uname_S),Interix)
529
455
NO_INITGROUPS = YesPlease
@@ -786,3 +712,77 @@ ifeq ($(uname_S),QNX)
786
712
NO_STRCASESTR = YesPlease
787
713
NO_STRLCPY = YesPlease
788
714
endif
715
+
716
+ vcxproj:
717
+ # Require clean work tree
718
+ git update-index -q --refresh && \
719
+ git diff-files --quiet && \
720
+ git diff-index --cached --quiet HEAD --
721
+
722
+ # Make .vcxproj files and add them
723
+ unset QUIET_GEN QUIET_BUILT_IN; \
724
+ perl contrib/buildsystems/generate -g Vcxproj
725
+ git add -f git.sln {*,*/lib,t/helper/*}/*.vcxproj
726
+
727
+ # Generate the LinkOrCopyBuiltins.targets file
728
+ (echo '<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">' && \
729
+ echo ' <Target Name="CopyBuiltins_AfterBuild" AfterTargets="AfterBuild">' && \
730
+ for name in $(BUILT_INS);\
731
+ do \
732
+ echo ' <Copy SourceFiles="$$(OutDir)\git.exe" DestinationFiles="$$(OutDir)\'"$$name"'" SkipUnchangedFiles="true" UseHardlinksIfPossible="true" />'; \
733
+ done && \
734
+ for name in $(REMOTE_CURL_ALIASES); \
735
+ do \
736
+ echo ' <Copy SourceFiles="$$(OutDir)\'"$(REMOTE_CURL_PRIMARY)"'" DestinationFiles="$$(OutDir)\'"$$name"'" SkipUnchangedFiles="true" UseHardlinksIfPossible="true" />'; \
737
+ done && \
738
+ echo ' </Target>' && \
739
+ echo '</Project>') >git/LinkOrCopyBuiltins.targets
740
+ git add -f git/LinkOrCopyBuiltins.targets
741
+
742
+ # Add command-list.h
743
+ $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 command-list.h
744
+ git add -f command-list.h
745
+
746
+ # Add scripts
747
+ rm -f perl/perl.mak
748
+ $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 \
749
+ $(SCRIPT_LIB) $(SCRIPT_SH_GEN) $(SCRIPT_PERL_GEN)
750
+ # Strip out the sane tool path, needed only for building
751
+ sed -i '/^git_broken_path_fix ".*/d' git-sh-setup
752
+ git add -f $(SCRIPT_LIB) $(SCRIPT_SH_GEN) $(SCRIPT_PERL_GEN)
753
+
754
+ # Add Perl module
755
+ $(MAKE) $(LIB_PERL_GEN)
756
+ git add -f perl/build
757
+
758
+ # Add bin-wrappers, for testing
759
+ rm -rf bin-wrappers/
760
+ $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 $(test_bindir_programs)
761
+ # Ensure that the GIT_EXEC_PATH is a Unix-y one, and that the absolute
762
+ # path of the repository is not hard-coded (GIT_EXEC_PATH will be set
763
+ # by test-lib.sh according to the current setup)
764
+ sed -i -e 's/^\(GIT_EXEC_PATH\)=.*/test -n "$${\1##*:*}" ||\
765
+ \1="$$(cygpath -u "$$\1")"/' \
766
+ -e "s|'$$(pwd)|\"\$$GIT_EXEC_PATH\"'|g" bin-wrappers/*
767
+ # Ensure that test-* helpers find the .dll files copied to top-level
768
+ sed -i 's|^PATH=.*|&:"$$GIT_EXEC_PATH"|' bin-wrappers/test-*
769
+ # We do not want to force hard-linking builtins
770
+ sed -i 's|\(git\)-\([-a-z]*\)\.exe"|\1.exe" \2|g' \
771
+ bin-wrappers/git-{receive-pack,upload-archive}
772
+ git add -f $(test_bindir_programs)
773
+ # remote-ext is a builtin, but invoked as if it were external
774
+ sed 's|receive-pack|remote-ext|g' \
775
+ <bin-wrappers/git-receive-pack >bin-wrappers/git-remote-ext
776
+ git add -f bin-wrappers/git-remote-ext
777
+
778
+ # Add templates
779
+ $(MAKE) -C templates
780
+ git add -f templates/boilerplates.made templates/blt/
781
+
782
+ # Add build options
783
+ $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 GIT-BUILD-OPTIONS
784
+ git add -f GIT-BUILD-OPTIONS
785
+
786
+ # Commit the whole shebang
787
+ git commit -m "Generate Visual Studio solution" \
788
+ -m "Auto-generated by \`$(MAKE)$(MAKEFLAGS) $@\`"
0 commit comments