VirtualBox

Changeset 54041 in vbox


Ignore:
Timestamp:
Jan 29, 2015 9:08:50 PM (10 years ago)
Author:
vboxsync
Message:

Installer/win/Makefile.kmk: Redid the dep.sed script using xsltproc and sed. Fixed the DirComponentsAndFiles_DTrace.wxi recipe.

Location:
trunk/src/VBox/Installer/win
Files:
2 added
1 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Installer/win/Makefile.kmk

    r54033 r54041  
    309309        $(call MSG_GENERATE,,$@,$<)
    310310        $(QUIET)$(APPEND) -nt "$@" \
    311                 '<?xml version="1.0" ?> \
     311                '<?xml version="1.0" ?>' \
    312312                '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
    313313ifdef VBOX_WITH_DTRACE
     
    316316                '  <Directory Id="dir_DTrace_lib" Name="lib">' \
    317317                '    <Directory Id="dir_DTrace_lib_arch" Name="$(KBUILD_TARGET_ARCH)">' \
    318                '      <Component Id="cp_dir_DTrace_lib_arch" Guid="7476CDF6-4157-2E17-5CCC-FF92528D2854" WIN64="$$(var.Property_Win64)">' \
     318               '      <Component Id="cp_dir_DTrace_lib_arch" Guid="7476CDF6-4157-2E17-5CCC-FF92528D2854" Win64="$$(var.Property_Win64)">' \
    319319                $(foreach file, $(VBOXINST_DTRACE_LIB_ARCH_FILES) \
    320                         , '        <File Id="file_dtrace_lib_arch_$(file)" Name="$(file)" Vital="yes" ' \
     320                        , '        <File Id="file_dtrace_lib_arch_$(subst -,_,$(file))" Name="$(file)" Vital="yes" ' \
    321321                          '              Source="$(PATH_STAGE_BIN)/dtrace/lib/$(KBUILD_TARGET_ARCH)/$(file)" />' ) \
    322322                '      </Component>' \
     
    325325                '  <Directory Id="dir_DTrace_testcase" Name="testcase">' \
    326326                '    <Directory Id="dir_DTrace_testcase_arch" Name="$(KBUILD_TARGET_ARCH)">' \
    327                '      <Component Id="cp_dir_DTrace_testcase_arch" Guid="45DF7014-4431-6C40-6DB0-35AF7C690EE1" WIN64="$$(var.Property_Win64)">' \
     327               '      <Component Id="cp_dir_DTrace_testcase_arch" Guid="45DF7014-4431-6C40-6DB0-35AF7C690EE1" Win64="$$(var.Property_Win64)">' \
    328328                $(foreach file, $(VBOXINST_DTRACE_TESTCASE_ARCH_FILES) \
    329                         , '        <File Id="file_dtrace_testcase_arch_$(file)" Name="$(file)" Vital="yes" ' \
     329                        , '        <File Id="file_dtrace_testcase_arch_$(subst -,_,$(file))" Name="$(file)" Vital="yes" ' \
    330330                          '              Source="$(PATH_STAGE_BIN)/dtrace/testcase/$(KBUILD_TARGET_ARCH)/$(file)" />' ) \
    331331                '      </Component>' \
     
    333333                '  </Directory>' \
    334334                '  <Directory Id="dir_DTrace_scripts" Name="scripts">' \
    335                '    <Component Id="cp_dir_DTrace_scripts" Guid="AE07F9D5-4FD9-ACC7-C760-E9923CE01E16" WIN64="$$(var.Property_Win64)">' \
     335               '    <Component Id="cp_dir_DTrace_scripts" Guid="AE07F9D5-4FD9-ACC7-C760-E9923CE01E16" Win64="$$(var.Property_Win64)">' \
    336336                $(foreach file, $(VBOXINST_DTRACE_SCRIPTS_FILES) \
    337                         , '      <File Id="file_dtrace_scripts_(file)" Name="$(file)" Vital="yes" ' \
     337                        , '      <File Id="file_dtrace_scripts_$(subst -,_,$(file))" Name="$(file)" Vital="yes" ' \
    338338                          '            Source="$(PATH_STAGE_BIN)/dtrace/scripts/$(file)" />' ) \
    339339                '    </Component>' \
     
    447447                        $(eval $(def_vbox_link_msm)))),)
    448448
    449 #
    450 # Load and adjust the MSI compile step dependencies.
    451 #
    452 -include $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep
    453 
    454 # Filter out some files depending on build type and compiler.
    455 ifeq ($(KBUILD_TYPE),release)
    456  VBOX_MSI_DEPENDENCIES := $(filer-out $(PATH_OUT)/bin/VBoxDbg3.dll, $(VBOX_MSI_DEPENDENCIES))
    457 endif
    458 ifndef VBOX_SIGNING_MODE
    459  VBOX_MSI_DEPENDENCIES := $(filer-out %.cat, $(VBOX_MSI_DEPENDENCIES))
    460 endif
    461 ifdef VBOX_USE_VCC110
    462  VBOX_MSI_DEPENDENCIES := $(filter-out \
    463         $(PATH_OUT)/bin/msvcr100.dll \
    464         $(PATH_OUT)/bin/msvcp100.dll \
    465         , $(VBOX_MSI_DEPENDENCIES))
    466 else # VCC100
    467  VBOX_MSI_DEPENDENCIES := $(filter-out \
    468         $(PATH_OUT)/bin/msvcr110.dll \
    469         $(PATH_OUT)/bin/msvcp110.dll \
    470         , $(VBOX_MSI_DEPENDENCIES))
    471 endif
    472 # TODO: Add filtering out more dependencies here!
    473 ifndef VBOX_WITH_QTGUI
    474  VBOX_MSI_DEPENDENCIES := $(filter-out \
    475         $(PATH_OUT)/bin/VirtualBox.exe \
    476         $(PATH_OUT)/bin/VBoxTestOGL.exe \
    477         $(PATH_OUT)/bin/QtCoreVBox4.dll \
    478         $(PATH_OUT)/bin/QtGuiVBox4.dll \
    479         $(PATH_OUT)/bin/QtNetworkVBox4.dll \
    480         $(PATH_OUT)/bin/QtOpenGLVBox4.dll \
    481         $(PATH_OUT)/bin/accessible/qtaccessiblewidgets4.dll \
    482         , $(VBOX_MSI_DEPENDENCIES))
    483 endif
    484 ifndef VBOX_WITH_PYTHON
    485  VBOX_MSI_DEPENDENCIES := $(filer-out $ \
    486         $(PATH_OUT)/bin/sdk/installer/vboxapisetup.py \
    487         $(PATH_OUT)/bin/sdk/installer/vboxapi/__init__.py \
    488         $(PATH_OUT)/bin/sdk/installer/vboxapi/VirtualBox_constants.py \
    489         , $(VBOX_MSI_DEPENDENCIES))
    490 endif
    491 ifndef VBOX_WITH_CROGL
    492  VBOX_MSI_DEPENDENCIES := $(filer-out $ \
    493         $(PATH_OUT)/bin/VBoxOGLhostcrutil.dll \
    494         $(PATH_OUT)/bin/VBoxOGLhosterrorspu.dll \
    495         $(PATH_OUT)/bin/VBoxOGLrenderspu.dll \
    496         $(PATH_OUT)/bin/VBoxSharedCrOpenGL.dll \
    497         , $(VBOX_MSI_DEPENDENCIES))
    498 endif
    499 ifndef VBOX_WITH_SECURELABEL
    500  VBOX_MSI_DEPENDENCIES := $(filer-out $(PATH_OUT)/bin/SDL_ttf.dll, $(VBOX_MSI_DEPENDENCIES))
    501 endif
    502 ifndef VBOX_WITH_WEBSERVICES
    503  VBOX_MSI_DEPENDENCIES := $(filer-out $(PATH_OUT)/bin/vboxwebsrv.exe, $(VBOX_MSI_DEPENDENCIES))
    504 endif
    505 
    506 ifneq ($(KBUILD_TARGET_ARCH),amd64)
    507  VBOX_MSI_DEPENDENCIES := $(filter-out \
    508         $(PATH_OUT)/bin/VBoxREM2.rel \
    509         , $(VBOX_MSI_DEPENDENCIES))
    510 else
    511  VBOX_MSI_DEPENDENCIES := $(filter-out \
    512         $(PATH_OUT)/bin/VBoxREM32.dll \
    513         $(PATH_OUT)/bin/VBoxREM64.dll \
    514         , $(VBOX_MSI_DEPENDENCIES))
    515 endif
    516 ifdef VBOX_WITH_EXTPACK_PUEL
    517  VBOX_MSI_DEPENDENCIES := $(filter-out $(PATH_OUT)/bin/VBoxVRDP$(VBOX_SUFF_DLL), $(VBOX_MSI_DEPENDENCIES))
    518 endif
    519 
    520 # Add dependencies that makes sure necessary bits gets built since
    521 # VBOX_MSI_DEPENDENCIES will be zero the first time around.
     449
     450#
     451# Add dependencies that makes sure necessary bits gets built.
    522452# For combined packages we always use the .ISO from the amd64 build.
    523 VBOX_MSI_DEPENDENCIES := $(filter-out %/VBoxGuestAdditions.iso, $(VBOX_MSI_DEPENDENCIES))
     453#
    524454ifdef VBOX_WITH_COMBINED_PACKAGE
    525  VBOX_MSI_DEPENDENCIES += \
     455 VBOX_MSI_DEPENDENCIES := \
    526456        $(if $(VBOX_WITH_ADDITIONS_PACKING),$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO)/VBoxGuestAdditions.iso)
    527457else
    528  VBOX_MSI_DEPENDENCIES += \
     458 VBOX_MSI_DEPENDENCIES := \
    529459        $(if $(VBOX_WITH_ADDITIONS_PACKING),$(VBOX_PATH_ADDITIONS_ISO)/VBoxGuestAdditions.iso)
    530460endif
     
    537467        $(PATH_SUB_CURRENT)/VBoxMergeApp.wxi
    538468
    539 $(PATH_SUB_CURRENT)/VBoxMergeApp.wxi: \
     469$(PATH_SUB_CURRENT)/VBoxMergeApp.wxi $(PATH_SUB_CURRENT)/VirtualBox.wxs: \
    540470        $(VBOX_WIN_INST_OUT_DIR)/Files_Doc.wxi \
    541471        $(VBOX_WIN_INST_OUT_DIR)/DirComponentsAndFiles_DTrace.wxi \
     
    544474        $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi \
    545475        $(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi \
    546         $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
     476        $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi
    547477
    548478#
     
    550480#
    551481define def_vbox_compile_wixobj
     482includedep $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_$(lang).wixobj.dep
    552483$(VBOX_WIN_INST_OUT_DIR)/VirtualBox_$(lang).wixobj: \
    553484                        $(PATH_SUB_CURRENT)/VirtualBox.wxs \
     
    566497        $(QUIET)$(RM) -f $@
    567498        $(REDIRECT) \
    568                 -E 'PATH_OUT=$(subst /,\\,$(PATH_OUT))' \
    569                 -E 'PATH_TARGET=$(subst /,\\,$(VBOX_WIN_INST_OUT_DIR))' \
    570                 -E 'PATH_ROOT=$(subst /,\\,$(PATH_ROOT))' \
    571                 -E 'PATH_MULTIARCH_GUEST_ADDITIONS_ISO=$(subst /,\\,$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO))' \
    572                 -E 'VBOX_PATH_WIN_INST_SRC=$(subst /,\\,$(VBOX_PATH_WIN_INST_SRC))' \
    573                 -E 'VBOX_BRAND_WIN_INST_DLGJPG=$(subst /,\\,$(VBOX_BRAND_WIN_INST_DLGJPG))' \
     499                -E 'PATH_OUT=$(subst /,\,$(PATH_OUT))' \
     500                -E 'PATH_TARGET=$(subst /,\,$(VBOX_WIN_INST_OUT_DIR))' \
     501                -E 'PATH_ROOT=$(subst /,\,$(PATH_ROOT))' \
     502                -E 'PATH_MULTIARCH_GUEST_ADDITIONS_ISO=$(subst /,\,$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO))' \
     503                -E 'VBOX_PATH_WIN_INST_SRC=$(subst /,\,$(VBOX_PATH_WIN_INST_SRC))' \
     504                -E 'VBOX_BRAND_WIN_INST_DLGJPG=$(subst /,\,$(VBOX_BRAND_WIN_INST_DLGJPG))' \
    574505                -E 'VBOX_ADD_LANGUAGES=$(VBOX_INSTALLER_ADD_LANGUAGES)' \
    575                 -E 'VBOX_BRAND_LICENSE_RTF=$(subst /,\\,$(VBOX_BRAND_LICENSE_RTF))' \
     506                -E 'VBOX_BRAND_LICENSE_RTF=$(subst /,\,$(VBOX_BRAND_LICENSE_RTF))' \
    576507                $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
    577                         -E 'VBOX_BRAND_$(lang)_LICENSE_RTF=$(subst /,\\,$(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF))') \
     508                        -E 'VBOX_BRAND_$(lang)_LICENSE_RTF=$(subst /,\,$(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF))') \
    578509                -E 'VBOX_BUILD_NR_FOR_INST=$(VBOX_VERSION_BUILD)' \
    579510                -E 'VBOX_VENDOR=$(VBOX_VENDOR)' \
     
    613544                -E 'VBOX_WITH_SERIALNUMBER_INSTALL=$(if $(VBOX_WITH_SERIALNUMBER_INSTALL),yes,no)' \
    614545                -E 'VBOX_WITH_LICENSE_DISPLAY=$(if $(VBOX_WITH_LICENSE_DISPLAY),yes,no)' \
    615                 -E 'VBOX_WINDOWS_ICON_FILE=$(subst /,\\,$(VBOX_WINDOWS_ICON_FILE))' \
     546                -E 'VBOX_WINDOWS_ICON_FILE=$(subst /,\,$(VBOX_WINDOWS_ICON_FILE))' \
    616547                -E 'BUILD_TYPE=$(KBUILD_TYPE)' \
    617548                -E 'BUILD_TARGET_ARCH=$(KBUILD_TARGET_ARCH)' \
     
    622553                        -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
    623554                        -out $$@
    624 ifeq ($(lang),en_US)
    625 #
    626 # Generate dependency file, we share this between all the languages.
    627 #
    628         $(APPEND) -t $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep 'VBOX_MSI_DEPENDENCIES = \'
    629         $(SED) -f $(VBOX_PATH_WIN_INST_SRC)/dep.sed \
    630                 --append $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep \
    631                 $(foreach module,$(VBOX_INSTALLER_MERGE_MODULES), \
    632                         $(VBOX_PATH_WIN_INST_SRC)/VBoxMerge$(module).wxi) \
    633                 $(VBOX_PATH_WIN_INST_SRC)/VirtualBox.wxs \
    634                 $(VBOX_PATH_WIN_INST_SRC)/UserInterface.wxi \
    635                 $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
    636                 $(if $(VBOX_WITH_32_ON_64_MAIN_API),$(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib_x86.wxi,)
    637         $(APPEND) $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep ''
    638 endif
     555# Generate wxi dependencies based on the sourceLineNumber references in the output.
     556        $(QUIET)$(APPEND) -t '[email protected]' '$$@: \'
     557        $(QUIET)$(VBOX_XSLTPROC) $(VBOX_PATH_WIN_INST_SRC)/dep.xsl "$$@" >> "[email protected]"
     558        $(QUIET)$(VBOX_XSLTPROC) $(VBOX_PATH_WIN_INST_SRC)/dep2.xsl "$$@" | sort  | $(SED) '$!N; /^\(.*\)\n\1$$$$/!P; D' >> "[email protected]"
     559        $(QUIET)$(APPEND) -n '[email protected]' '' ''
    639560endef
    640561
     
    646567#
    647568define def_vbox_compile_msm
     569includedep $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wixobj
    648570$(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wixobj: \
    649571                $(PATH_SUB_CURRENT)/VBoxMerge$(module).wxs \
     
    662584        $(QUIET)$(RM) -f $@
    663585        $(REDIRECT) \
    664                 -E 'PATH_OUT=$(subst /,\\,$(PATH_OUT))' \
    665                 -E 'PATH_TARGET=$(subst /,\\,$(VBOX_WIN_INST_OUT_DIR))' \
    666                 -E 'PATH_ROOT=$(subst /,\\,$(PATH_ROOT))' \
    667                 -E 'PATH_MULTIARCH_GUEST_ADDITIONS_ISO=$(subst /,\\,$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO))' \
    668                 -E 'VBOX_PATH_WIN_INST_SRC=$(subst /,\\,$(VBOX_PATH_WIN_INST_SRC))' \
    669                 -E 'VBOX_BRAND_WIN_INST_DLGJPG=$(subst /,\\,$(VBOX_BRAND_WIN_INST_DLGJPG))' \
     586                -E 'PATH_OUT=$(subst /,\,$(PATH_OUT))' \
     587                -E 'PATH_TARGET=$(subst /,\,$(VBOX_WIN_INST_OUT_DIR))' \
     588                -E 'PATH_ROOT=$(subst /,\,$(PATH_ROOT))' \
     589                -E 'PATH_MULTIARCH_GUEST_ADDITIONS_ISO=$(subst /,\,$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO))' \
     590                -E 'VBOX_PATH_WIN_INST_SRC=$(subst /,\,$(VBOX_PATH_WIN_INST_SRC))' \
     591                -E 'VBOX_BRAND_WIN_INST_DLGJPG=$(subst /,\,$(VBOX_BRAND_WIN_INST_DLGJPG))' \
    670592                -E 'VBOX_ADD_LANGUAGES=$(VBOX_INSTALLER_ADD_LANGUAGES)' \
    671                 -E 'VBOX_BRAND_LICENSE_RTF=$(subst /,\\,$(VBOX_BRAND_LICENSE_RTF))' \
     593                -E 'VBOX_BRAND_LICENSE_RTF=$(subst /,\,$(VBOX_BRAND_LICENSE_RTF))' \
    672594                $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
    673                         -E 'VBOX_BRAND_$(lang)_LICENSE_RTF=$(subst /,\\,$(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF))') \
     595                        -E 'VBOX_BRAND_$(lang)_LICENSE_RTF=$(subst /,\,$(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF))') \
    674596                -E 'VBOX_BUILD_NR_FOR_INST=$(VBOX_VERSION_BUILD)' \
    675597                -E 'VBOX_VENDOR=$(VBOX_VENDOR)' \
     
    706628                -E 'VBOX_WITH_SERIALNUMBER_INSTALL=$(if $(VBOX_WITH_SERIALNUMBER_INSTALL),yes,no)' \
    707629                -E 'VBOX_WITH_LICENSE_DISPLAY=$(if $(VBOX_WITH_LICENSE_DISPLAY),yes,no)' \
    708                 -E 'VBOX_WINDOWS_ICON_FILE=$(subst /,\\,$(VBOX_WINDOWS_ICON_FILE))' \
     630                -E 'VBOX_WINDOWS_ICON_FILE=$(subst /,\,$(VBOX_WINDOWS_ICON_FILE))' \
    709631                -E 'BUILD_TYPE=$(KBUILD_TYPE)' \
    710632                -E 'BUILD_TARGET_ARCH=$(KBUILD_TARGET_ARCH)' \
     
    715637                        -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
    716638                        -out $$@
    717 ifeq ($(lang),en_US)
    718 #
    719 # Generate dependency file, we share this between all the languages.
    720 #
    721         $(APPEND) -t $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module).msm.dep 'VBOX_MSI_DEPENDENCIES = \'
    722         $(SED) -f $(VBOX_PATH_WIN_INST_SRC)/dep.sed \
    723                 --append $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module).msm.dep \
    724                 $(VBOX_PATH_WIN_INST_SRC)/VBoxMerge$(module).wxi \
    725                 $(VBOX_PATH_WIN_INST_SRC)/UserInterface.wxi \
    726                 $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
    727                 $(if $(VBOX_WITH_32_ON_64_MAIN_API),$(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib_x86.wxi,)
    728         $(APPEND) $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module).msm.dep ''
    729 endif
     639# Generate wxi dependencies based on the sourceLineNumber references in the output.
     640        $(QUIET)$(APPEND) -t '[email protected]' '$$@: \'
     641        $(QUIET)$(VBOX_XSLTPROC) $(VBOX_PATH_WIN_INST_SRC)/dep.xsl "$$@" >> "[email protected]"
     642        $(QUIET)$(VBOX_XSLTPROC) $(VBOX_PATH_WIN_INST_SRC)/dep2.xsl "$$@" | sort  | $(SED) '$!N; /^\(.*\)\n\1$$$$/!P; D' >> "[email protected]"
     643        $(QUIET)$(APPEND) -n '[email protected]' '' ''
    730644endef
    731645
  • trunk/src/VBox/Installer/win/VBoxMergeApp.wxi

    r54035 r54041  
    7979    <?include $(env.PATH_TARGET)\DirComponentsAndFiles_DTrace.wxi ?>
    8080
     81
    8182    <!--
    8283
     
    187188<?endif ?>
    188189<?if $(env.VBOX_WITH_DTRACE) = "yes" ?>
    189          <File Id="file_VBoxDTrace.exe" Name="VBoxDTrace.exe" Source="$(env.PATH_OUT)\VBoxDTrace.exe" />
     190         <File Id="file_VBoxDTrace.exe" Name="VBoxDTrace.exe" Source="$(env.PATH_OUT)\bin\VBoxDTrace.exe" />
    190191<?endif ?>
    191192        <!-- VBox DLL files -->
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette