2019-04-13 19:15:23 +02:00
|
|
|
#
|
|
|
|
# SPDX-License-Identifier: GPL-2.0
|
|
|
|
#
|
|
|
|
# Copyright (C) 2018-2019 WireGuard LLC. All Rights Reserved.
|
|
|
|
#
|
|
|
|
|
2019-04-18 14:35:51 +02:00
|
|
|
# TODO: Unify version definition with wintun.vcxproj. Migrate from NMAKE to MSBuild?
|
|
|
|
WINTUN_VERSION=0.1
|
2019-04-16 16:10:48 +02:00
|
|
|
|
2019-04-18 12:52:56 +02:00
|
|
|
DIST_DIR=dist
|
2019-04-18 14:00:02 +02:00
|
|
|
MSBUILD_FLAGS=/m /v:minimal /nologo
|
|
|
|
WIX_CANDLE_FLAGS=-nologo -ext WixDifxAppExtension -ext WixIIsExtension -dWINTUN_VERSION="$(WINTUN_VERSION)"
|
|
|
|
WIX_LIGHT_FLAGS=-nologo -ext WixDifxAppExtension -ext WixIIsExtension -sw1103
|
2019-04-13 19:15:23 +02:00
|
|
|
|
2019-04-18 14:00:02 +02:00
|
|
|
build :: \
|
|
|
|
build_x86_Release \
|
|
|
|
build_amd64_Release \
|
|
|
|
build_arm64_Release
|
2019-04-13 19:15:23 +02:00
|
|
|
|
2019-04-18 14:00:02 +02:00
|
|
|
dvl :: "wintun.DVL.XML"
|
2019-04-13 19:15:23 +02:00
|
|
|
|
2019-04-18 14:00:02 +02:00
|
|
|
msm :: \
|
|
|
|
"$(DIST_DIR)" \
|
|
|
|
"$(DIST_DIR)\wintun_$(WINTUN_VERSION)_x86.msm" \
|
|
|
|
"$(DIST_DIR)\wintun_$(WINTUN_VERSION)_amd64.msm"
|
2019-04-13 19:15:23 +02:00
|
|
|
|
2019-04-18 14:00:02 +02:00
|
|
|
"sdv\SDV.DVL.xml" "amd64\Release\vc.nativecodeanalysis.all.xml" :
|
|
|
|
msbuild.exe "wintun.vcxproj" /t:sdv /p:Inputs="/check:*" /p:Configuration="Release" /p:Platform="x64" $(MSBUILD_FLAGS)
|
|
|
|
|
|
|
|
"wintun.DVL.XML" : "sdv\SDV.DVL.xml" "amd64\Release\vc.nativecodeanalysis.all.xml"
|
|
|
|
msbuild.exe "wintun.vcxproj" /t:dvl /p:Configuration="Release" /p:Platform="x64" $(MSBUILD_FLAGS)
|
|
|
|
|
|
|
|
"$(DIST_DIR)" :
|
|
|
|
md $@ > NUL 2>&1
|
2019-04-13 19:15:23 +02:00
|
|
|
|
|
|
|
clean ::
|
2019-04-18 11:24:38 +02:00
|
|
|
-rd /s /q "sdv" > NUL 2>&1
|
2019-04-17 15:09:21 +02:00
|
|
|
-del /f /q "wintun.DVL.XML" > NUL 2>&1
|
2019-04-18 11:25:08 +02:00
|
|
|
-del /f /q "smvbuild.log" > NUL 2>&1
|
2019-04-17 15:09:21 +02:00
|
|
|
-del /f /q "smvstats.txt" > NUL 2>&1
|
2019-04-18 14:00:02 +02:00
|
|
|
-rd /s /q "$(DIST_DIR)" > NUL 2>&1
|
2019-04-13 19:15:23 +02:00
|
|
|
|
2019-04-18 14:00:02 +02:00
|
|
|
CFG=Release
|
|
|
|
PLAT=x86
|
|
|
|
!INCLUDE "Makefile.PlatCfg.mak"
|
|
|
|
PLAT=amd64
|
|
|
|
!INCLUDE "Makefile.PlatCfg.mak"
|
|
|
|
PLAT=arm64
|
|
|
|
!INCLUDE "Makefile.PlatCfg.mak"
|
2019-04-18 12:52:56 +02:00
|
|
|
|
2019-04-18 14:00:02 +02:00
|
|
|
CFG=Debug
|
|
|
|
PLAT=x86
|
|
|
|
!INCLUDE "Makefile.PlatCfg.mak"
|
|
|
|
PLAT=amd64
|
|
|
|
!INCLUDE "Makefile.PlatCfg.mak"
|
|
|
|
PLAT=arm64
|
|
|
|
!INCLUDE "Makefile.PlatCfg.mak"
|