ZRCola/MSILocal.mak
Simon Rozman f8eead6835 MSI building process revised
- Common cabinet file for all language variations
- Same practice applied as with GÉANTLink project
2016-10-11 11:08:36 +02:00

154 lines
12 KiB
Makefile
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#
# Copyright 1991-2016 Amebis
#
# This file is part of ZRCola.
#
# ZRCola is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# ZRCola is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with ZRCola. If not, see <http://www.gnu.org/licenses/>.
#
All ::
Clean ::
cd "MSI\ZRCola"
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=$(LANG) PLAT=Win32 CFG=Release
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=$(LANG) PLAT=Win32 CFG=Debug
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=$(LANG) PLAT=x64 CFG=Release
$(MAKE) /f "Makefile" /$(MAKEFLAGS) Clean LANG=$(LANG) PLAT=x64 CFG=Debug
cd "$(MAKEDIR)"
-if exist "$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)32.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)32.msi"
-if exist "$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)32D.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)32D.msi"
-if exist "$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)64.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)64.msi"
-if exist "$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)64D.msi" del /f /q "$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)64D.msi"
!IFDEF HAS_VERSION
######################################################################
# 2nd Phase
# - The version is known, do the rest.
######################################################################
######################################################################
# File copy
######################################################################
"$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)32.msi" \
"$(PUBLISH_PACKAGE_DIR)\ZRCola$(LANG_OUT)32.msi" : "$(OUTPUT_DIR)\ZRCola.$(LANG).32.3.msi"
copy /y $** $@ > NUL
"$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)32D.msi" : "$(OUTPUT_DIR)\ZRCola.$(LANG).32D.3.msi"
copy /y $** $@ > NUL
"$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)64.msi" \
"$(PUBLISH_PACKAGE_DIR)\ZRCola$(LANG_OUT)64.msi" : "$(OUTPUT_DIR)\ZRCola.$(LANG).64.3.msi"
copy /y $** $@ > NUL
"$(OUTPUT_DIR)\Setup\ZRCola$(LANG_OUT)64D.msi" : "$(OUTPUT_DIR)\ZRCola.$(LANG).64D.3.msi"
copy /y $** $@ > NUL
"$(PUBLISH_DIR)\ZRColaInstall$(LANG_OUT).exe" : "$(OUTPUT_DIR)\Win32.Release\ZRColaInstall$(LANG_OUT).exe"
copy /y $** $@ > NUL
######################################################################
# Building
######################################################################
"$(OUTPUT_DIR)\ZRCola.$(LANG).32.2.msi" :: Localization
"$(OUTPUT_DIR)\ZRCola.$(LANG).32D.2.msi" :: Localization
"$(OUTPUT_DIR)\ZRCola.$(LANG).64.2.msi" :: Localization
"$(OUTPUT_DIR)\ZRCola.$(LANG).64D.2.msi" :: Localization
"$(OUTPUT_DIR)\ZRCola.$(LANG).32.2.msi" ::
devenv.com "ZRCola.sln" /build "Release|Win32"
devenv.com "MSI\MSICA\MSICA.sln" /build "Release|Win32"
devenv.com "Updater\Updater.sln" /build "Release|Win32"
"$(OUTPUT_DIR)\ZRCola.$(LANG).32D.2.msi" ::
devenv.com "ZRCola.sln" /build "Debug|Win32"
devenv.com "MSI\MSICA\MSICA.sln" /build "Debug|Win32"
devenv.com "Updater\Updater.sln" /build "Debug|Win32"
"$(OUTPUT_DIR)\ZRCola.$(LANG).64.2.msi" ::
devenv.com "ZRCola.sln" /build "Release|x64"
devenv.com "MSI\MSICA\MSICA.sln" /build "Release|x64"
devenv.com "Updater\Updater.sln" /build "Release|x64"
"$(OUTPUT_DIR)\ZRCola.$(LANG).64D.2.msi" ::
devenv.com "ZRCola.sln" /build "Debug|x64"
devenv.com "MSI\MSICA\MSICA.sln" /build "Debug|x64"
devenv.com "Updater\Updater.sln" /build "Debug|x64"
"$(OUTPUT_DIR)\Win32.Release\ZRColaInstall$(LANG_OUT).exe" ::
devenv.com "ZRColaUtils.sln" /build "Release|Win32"
"$(OUTPUT_DIR)\Win32.Debug\ZRColaInstall$(LANG_OUT).exe" ::
devenv.com "ZRColaUtils.sln" /build "Debug|Win32"
"$(OUTPUT_DIR)\ZRCola.$(LANG).32.2.msi" ::
cd "MSI\ZRCola"
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=$(LANG) PLAT=Win32 CFG=Release
cd "$(MAKEDIR)"
"$(OUTPUT_DIR)\ZRCola.$(LANG).32D.2.msi" ::
cd "MSI\ZRCola"
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=$(LANG) PLAT=Win32 CFG=Debug
cd "$(MAKEDIR)"
"$(OUTPUT_DIR)\ZRCola.$(LANG).64.2.msi" ::
cd "MSI\ZRCola"
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=$(LANG) PLAT=x64 CFG=Release
cd "$(MAKEDIR)"
"$(OUTPUT_DIR)\ZRCola.$(LANG).64D.2.msi" ::
cd "MSI\ZRCola"
$(MAKE) /f "Makefile" /$(MAKEFLAGS) LANG=$(LANG) PLAT=x64 CFG=Debug
cd "$(MAKEDIR)"
"$(OUTPUT_DIR)\ZRCola.$(LANG).32.3.msi" : \
"$(OUTPUT_DIR)\ZRCola.$(LANG).32.2.msi" \
"$(OUTPUT_DIR)\ZRCola32.inf"
-if exist $@ del /f /q $@
copy /y "$(OUTPUT_DIR)\ZRCola.$(LANG).32.2.msi" "$(@:"=).tmp" > NUL
cscript.exe "MSI\MSIBuild\MSI.wsf" //Job:SetCAB //Nologo "$(@:"=).tmp" "$(OUTPUT_DIR)\ZRCola32.inf"
move /y "$(@:"=).tmp" $@ > NUL
"$(OUTPUT_DIR)\ZRCola.$(LANG).32D.3.msi" : \
"$(OUTPUT_DIR)\ZRCola.$(LANG).32D.2.msi" \
"$(OUTPUT_DIR)\ZRCola32D.inf"
-if exist $@ del /f /q $@
copy /y "$(OUTPUT_DIR)\ZRCola.$(LANG).32D.2.msi" "$(@:"=).tmp" > NUL
cscript.exe "MSI\MSIBuild\MSI.wsf" //Job:SetCAB //Nologo "$(@:"=).tmp" "$(OUTPUT_DIR)\ZRCola32D.inf"
move /y "$(@:"=).tmp" $@ > NUL
"$(OUTPUT_DIR)\ZRCola.$(LANG).64.3.msi" : \
"$(OUTPUT_DIR)\ZRCola.$(LANG).64.2.msi" \
"$(OUTPUT_DIR)\ZRCola64.inf"
-if exist $@ del /f /q $@
copy /y "$(OUTPUT_DIR)\ZRCola.$(LANG).64.2.msi" "$(@:"=).tmp" > NUL
cscript.exe "MSI\MSIBuild\MSI.wsf" //Job:SetCAB //Nologo "$(@:"=).tmp" "$(OUTPUT_DIR)\ZRCola64.inf"
move /y "$(@:"=).tmp" $@ > NUL
"$(OUTPUT_DIR)\ZRCola.$(LANG).64D.3.msi" : \
"$(OUTPUT_DIR)\ZRCola.$(LANG).64D.2.msi" \
"$(OUTPUT_DIR)\ZRCola64D.inf"
-if exist $@ del /f /q $@
copy /y "$(OUTPUT_DIR)\ZRCola.$(LANG).64D.2.msi" "$(@:"=).tmp" > NUL
cscript.exe "MSI\MSIBuild\MSI.wsf" //Job:SetCAB //Nologo "$(@:"=).tmp" "$(OUTPUT_DIR)\ZRCola64D.inf"
move /y "$(@:"=).tmp" $@ > NUL
!ENDIF