Skip to content

Commit c63c5d2

Browse files
committed
Allow make vcxproj without initializing vcpkg
The idea of the `vcxproj` target is to generate .sln/.vcxproj files and then commit them, to be used elsewhere. Typically, this is done in a VSTS job whenever `master` changes. So there is little use in initializing vcpkg and building all the dependencies: they are not necessary here. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent b02312a commit c63c5d2

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

config.mak.uname

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,12 @@ include compat/vcbuild/MSVC-DEFS-GEN
2525
# See if vcpkg and the vcpkg-build versions of the third-party
2626
# libraries that we use are installed. We include the result
2727
# to get $(vcpkg_*) variables defined for the Makefile.
28+
ifeq (,$(SKIP_VCPKG))
2829
compat/vcbuild/VCPKG-DEFS: compat/vcbuild/vcpkg_install.bat
2930
@"$<"
3031
include compat/vcbuild/VCPKG-DEFS
3132
endif
33+
endif
3234

3335
# We choose to avoid "if .. else if .. else .. endif endif"
3436
# because maintaining the nesting to match is a pain. If
@@ -713,12 +715,12 @@ vcxproj:
713715
git add -f git.sln {*,*/lib,t/helper/*}/*.vcxproj
714716

715717
# Add common-cmds.h
716-
$(MAKE) MSVC=1 prefix=/mingw64 common-cmds.h
718+
$(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 common-cmds.h
717719
git add -f common-cmds.h
718720

719721
# Add scripts
720722
rm -f perl/perl.mak
721-
$(MAKE) MSVC=1 prefix=/mingw64 \
723+
$(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 \
722724
$(SCRIPT_LIB) $(SCRIPT_SH_GEN) $(SCRIPT_PERL_GEN)
723725
# Strip out the sane tool path, needed only for building
724726
sed -i '/^git_broken_path_fix ".*/d' git-sh-setup
@@ -730,7 +732,7 @@ vcxproj:
730732

731733
# Add bin-wrappers, for testing
732734
rm -rf bin-wrappers/
733-
$(MAKE) MSVC=1 prefix=/mingw64 $(test_bindir_programs)
735+
$(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 $(test_bindir_programs)
734736
# Ensure that the GIT_EXEC_PATH is a Unix-y one, and that the absolute
735737
# path of the repository is not hard-coded (GIT_EXEC_PATH will be set
736738
# by test-lib.sh according to the current setup)
@@ -753,7 +755,7 @@ vcxproj:
753755
git add -f templates/boilerplates.made templates/blt/
754756

755757
# Add build options
756-
$(MAKE) MSVC=1 prefix=/mingw64 GIT-BUILD-OPTIONS
758+
$(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 GIT-BUILD-OPTIONS
757759
git add -f GIT-BUILD-OPTIONS
758760

759761
# Commit the whole shebang

contrib/buildsystems/engine.pl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,8 @@ sub showUsage
8282
# Capture the make dry stderr to file for review (will be empty for a release build).
8383

8484
my $ErrsFile = "msvc-build-makedryerrors.txt";
85-
@makedry = `make -C $git_dir -n MSVC=1 V=1 2>$ErrsFile` if !@makedry;
85+
@makedry = `make -C $git_dir -n MSVC=1 SKIP_VCPKG=1 V=1 2>$ErrsFile`
86+
if !@makedry;
8687
# test for an empty Errors file and remove it
8788
unlink $ErrsFile if -f -z $ErrsFile;
8889

0 commit comments

Comments
 (0)