This commit is contained in:
Simon Rozman 2014-03-14 10:45:19 +00:00
parent a7f9789a96
commit 0244787e26

50
MSM.mak
View File

@ -1,17 +1,21 @@
All :: "$(LANG).$(PLAT).$(CFG).msm" !IFNDEF MSIBUILD_MSM_BASE
MSIBUILD_MSM_BASE=$(LANG).$(PLAT).$(CFG)
!ENDIF
All :: "$(MSIBUILD_MSM_BASE).msm"
Clean :: Clean ::
-if exist "$(LANG).$(PLAT).$(CFG).*-1.idt" del /f /q "$(LANG).$(PLAT).$(CFG).*-1.idt" -if exist "$(MSIBUILD_MSM_BASE).*-1.idt" del /f /q "$(MSIBUILD_MSM_BASE).*-1.idt"
-if exist "$(LANG).$(PLAT).$(CFG).Binary-1\*.*" del /f /q "$(LANG).$(PLAT).$(CFG).Binary-1\*.*" -if exist "$(MSIBUILD_MSM_BASE).Binary-1\*.*" del /f /q "$(MSIBUILD_MSM_BASE).Binary-1\*.*"
-if exist "$(LANG).$(PLAT).$(CFG).Icon-1\*.*" del /f /q "$(LANG).$(PLAT).$(CFG).Icon-1\*.*" -if exist "$(MSIBUILD_MSM_BASE).Icon-1\*.*" del /f /q "$(MSIBUILD_MSM_BASE).Icon-1\*.*"
!IFDEF MSIBUILD_IS_LOCALIZEABLE !IFDEF MSIBUILD_IS_LOCALIZEABLE
-if exist "$(LANG).$(PLAT).$(CFG).*-2.idt" del /f /q "$(LANG).$(PLAT).$(CFG).*-2.idt" -if exist "$(MSIBUILD_MSM_BASE).*-2.idt" del /f /q "$(MSIBUILD_MSM_BASE).*-2.idt"
-if exist "$(LANG).$(PLAT).$(CFG).*-2.idtx" del /f /q "$(LANG).$(PLAT).$(CFG).*-2.idtx" -if exist "$(MSIBUILD_MSM_BASE).*-2.idtx" del /f /q "$(MSIBUILD_MSM_BASE).*-2.idtx"
-if exist "$(LANG).$(PLAT).$(CFG).Binary-2\*.*" del /f /q "$(LANG).$(PLAT).$(CFG).Binary-2\*.*" -if exist "$(MSIBUILD_MSM_BASE).Binary-2\*.*" del /f /q "$(MSIBUILD_MSM_BASE).Binary-2\*.*"
-if exist "$(LANG).$(PLAT).$(CFG).Icon-2\*.*" del /f /q "$(LANG).$(PLAT).$(CFG).Icon-2\*.*" -if exist "$(MSIBUILD_MSM_BASE).Icon-2\*.*" del /f /q "$(MSIBUILD_MSM_BASE).Icon-2\*.*"
!ENDIF !ENDIF
-if exist "$(LANG).$(PLAT).$(CFG).lst" del /f /q "$(LANG).$(PLAT).$(CFG).lst" -if exist "$(MSIBUILD_MSM_BASE).lst" del /f /q "$(MSIBUILD_MSM_BASE).lst"
-if exist "$(LANG).$(PLAT).$(CFG).msm" del /f /q "$(LANG).$(PLAT).$(CFG).msm" -if exist "$(MSIBUILD_MSM_BASE).msm" del /f /q "$(MSIBUILD_MSM_BASE).msm"
###################################################################### ######################################################################
@ -24,12 +28,12 @@ Clean ::
# Since msidb utility doesn't append tables from IDL files to MSM # Since msidb utility doesn't append tables from IDL files to MSM
# module correctly, create separate MSM modules and merge. # module correctly, create separate MSM modules and merge.
"$(LANG).$(PLAT).$(CFG).msm" : $(LANG).$(PLAT).$(CFG).*-1.idt $(LANG).$(PLAT).$(CFG).*-2.idt "$(MSIBUILD_MSM_BASE).msm" : $(MSIBUILD_MSM_BASE).*-1.idt $(MSIBUILD_MSM_BASE).*-2.idt
-if exist $@ del /f /q $@ -if exist $@ del /f /q $@
-if exist "$(@:"=)-1.tmp" del /f /q "$(@:"=)-1.tmp" -if exist "$(@:"=)-1.tmp" del /f /q "$(@:"=)-1.tmp"
-if exist "$(@:"=)-2.tmp" del /f /q "$(@:"=)-2.tmp" -if exist "$(@:"=)-2.tmp" del /f /q "$(@:"=)-2.tmp"
msidb.exe -c -d "$(@:"=)-1.tmp" -f "$(MAKEDIR)" -i $(LANG).$(PLAT).$(CFG).*-1.idt msidb.exe -c -d "$(@:"=)-1.tmp" -f "$(MAKEDIR)" -i $(MSIBUILD_MSM_BASE).*-1.idt
msidb.exe -c -d "$(@:"=)-2.tmp" -f "$(MAKEDIR)" -i $(LANG).$(PLAT).$(CFG).*-2.idt msidb.exe -c -d "$(@:"=)-2.tmp" -f "$(MAKEDIR)" -i $(MSIBUILD_MSM_BASE).*-2.idt
msidb.exe -d "$(@:"=)-1.tmp" -m "$(@:"=)-2.tmp" msidb.exe -d "$(@:"=)-1.tmp" -m "$(@:"=)-2.tmp"
del /f /q "$(@:"=)-2.tmp" del /f /q "$(@:"=)-2.tmp"
move /y "$(@:"=)-1.tmp" $@ > NUL move /y "$(@:"=)-1.tmp" $@ > NUL
@ -39,10 +43,10 @@ Clean ::
###################################################################### ######################################################################
# Module is not localizeable => the compilation is trivial. # Module is not localizeable => the compilation is trivial.
"$(LANG).$(PLAT).$(CFG).msm" : $(LANG).$(PLAT).$(CFG).*-1.idt "$(MSIBUILD_MSM_BASE).msm" : $(MSIBUILD_MSM_BASE).*-1.idt
-if exist $@ del /f /q $@ -if exist $@ del /f /q $@
-if exist "$(@:"=)-1.tmp" del /f /q "$(@:"=)-1.tmp" -if exist "$(@:"=)-1.tmp" del /f /q "$(@:"=)-1.tmp"
msidb.exe -c -d "$(@:"=)-1.tmp" -f "$(MAKEDIR)" -i $(LANG).$(PLAT).$(CFG).*-1.idt msidb.exe -c -d "$(@:"=)-1.tmp" -f "$(MAKEDIR)" -i $(MSIBUILD_MSM_BASE).*-1.idt
move /y "$(@:"=)-1.tmp" $@ > NUL move /y "$(@:"=)-1.tmp" $@ > NUL
!ENDIF !ENDIF
@ -52,31 +56,31 @@ Clean ::
# Dependencies # Dependencies
###################################################################### ######################################################################
"$(LANG).$(PLAT).$(CFG).Binary-1.idt" : $(LANG).$(PLAT).$(CFG).Binary-1\*.* "$(MSIBUILD_MSM_BASE).Binary-1.idt" : $(MSIBUILD_MSM_BASE).Binary-1\*.*
"$(LANG).$(PLAT).$(CFG).Binary-2.idt" : $(LANG).$(PLAT).$(CFG).Binary-2\*.* "$(MSIBUILD_MSM_BASE).Binary-2.idt" : $(MSIBUILD_MSM_BASE).Binary-2\*.*
"$(LANG).$(PLAT).$(CFG).Icon-1.idt" : $(LANG).$(PLAT).$(CFG).Icon-1\*.* "$(MSIBUILD_MSM_BASE).Icon-1.idt" : $(MSIBUILD_MSM_BASE).Icon-1\*.*
"$(LANG).$(PLAT).$(CFG).Icon-2.idt" : $(LANG).$(PLAT).$(CFG).Icon-2\*.* "$(MSIBUILD_MSM_BASE).Icon-2.idt" : $(MSIBUILD_MSM_BASE).Icon-2\*.*
###################################################################### ######################################################################
# Folder creation # Folder creation
###################################################################### ######################################################################
"$(LANG).$(PLAT).$(CFG).Binary-1" : "$(MSIBUILD_MSM_BASE).Binary-1" :
if not exist $@ md $@ if not exist $@ md $@
"$(LANG).$(PLAT).$(CFG).Icon-1" : "$(MSIBUILD_MSM_BASE).Icon-1" :
if not exist $@ md $@ if not exist $@ md $@
!IFDEF MSIBUILD_IS_LOCALIZEABLE !IFDEF MSIBUILD_IS_LOCALIZEABLE
"$(LANG).$(PLAT).$(CFG).Binary-2" : "$(MSIBUILD_MSM_BASE).Binary-2" :
if not exist $@ md $@ if not exist $@ md $@
"$(LANG).$(PLAT).$(CFG).Icon-2" : "$(MSIBUILD_MSM_BASE).Icon-2" :
if not exist $@ md $@ if not exist $@ md $@
!ENDIF !ENDIF