VirtualBox

Ignore:
Timestamp:
Sep 9, 2008 1:58:29 AM (16 years ago)
Author:
vboxsync
Message:

HostDrivers/Makefiles: Eliminated (most) PATH_TARGET usage and pushed them up to root level (sub-makefile wise).

Location:
trunk/src/VBox/HostDrivers/Support
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/Support/Makefile.kmk

    r12170 r12252  
    2929#
    3030
    31 ifdef VBOX_SINGLE_MAKEFILE
    3231SUB_DEPTH = ../../../..
    33 else
    34 SUB_DEPTH = ..
    35 DEPTH    ?= ../../../..
    36 endif
    3732include $(KBUILD_PATH)/subheader.kmk
    3833
     
    6156        $(if $(VBOX_OSE),,$(PATH_BIN)/src/dkms.conf)
    6257 endif
    63  INSTALLS.linux  += vboxmod-bin vboxmod-sh
     58 INSTALLS.linux   += vboxmod-bin vboxmod-sh
    6459
    6560 #
     
    7368 include $(PATH_SUB_CURRENT)/linux/files_vboxdrv
    7469endif # !VBOX_ONLY_DOCS
    75 
    76 vboxmod-bin_INST    = bin/src/
    77 vboxmod-bin_MODE    = a+r,u+w
    78 vboxmod-bin_SOURCES = $(subst ",,$(FILES_VBOXDRV_NOBIN)) #"
    79 
    80 vboxmod-sh_INST     = bin/src/
    81 vboxmod-sh_MODE     = a+rx,u+w
    82 vboxmod-sh_SOURCES  = $(subst ",,$(FILES_VBOXDRV_BIN)) #"
    83 vboxmod-sh_CLEAN    = $(PATH_TARGET)/vboxmod-sh-1.dep
    84 
    85 # Scripts needed for building the kernel modules
    86 ## @todo generate these else where and move them from OTHERS to vboxmod-bin (which btw installs NOBIN files contrary to its name).
    87 
    88 $(PATH_BIN)/src/build_in_tmp: \
    89                 $(PATH_SUB_CURRENT)/linux/build_in_tmp \
    90                 $(VBOX_VERSION_STAMP)
    91         $(call MSG_TOOL,Creating,,$@)
    92         $(QUIET)$(SED) -e "s;_VERSION_;${VBOX_VERSION_STRING};g; s;_MODULE_;vboxdrv;g" --output $@ $<
    93         $(QUIET)chmod 0755 $@
    94 
    95 $(PATH_BIN)/src/dkms.conf: \
    96                 $(PATH_SUB_CURRENT)/linux/dkms.conf \
    97                 $(VBOX_VERSION_STAMP)
    98         $(call MSG_TOOL,Creating,,$@)
    99         $(QUIET)$(SED) -e "s;_VERSION_;${VBOX_VERSION_STRING};g" --output $@ $<
    100 
    101 -include $(PATH_TARGET)/vboxmod-1.dep
    102 $(PATH_BIN)/src/Makefile: \
    103                 $(PATH_SUB_CURRENT)/linux/Makefile \
    104                 $$(if $$(eq $$(Support/linux/Makefile_VBOX_HARDENED),$$(VBOX_WITH_HARDENING)),,FORCE) \
    105                 | $(call DIRDEP,$(PATH_TARGET))
    106         $(call MSG_TOOL,Creating,,$@)
    107 ifndef VBOX_WITH_HARDENING
    108         $(QUIET)$(SED) -e "s;-DVBOX_WITH_HARDENING;;g" --output $@ $<
    109 else
    110         $(QUIET)$(CP) -f $< $@
    111 endif
    112         %$(QUIET2)$(RM) -f -- $(PATH_TARGET)/vboxmod-1.dep
    113         %$(QUIET2)$(APPEND) '$(PATH_TARGET)/vboxmod-1.dep' 'Support/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)'
    11470
    11571
     
    153109        $(KBUILD_TARGET)/SUPLib-$(KBUILD_TARGET).cpp
    154110
     111ifndef VBOX_ONLY_DOCS
    155112
    156113#
     
    182139endif
    183140ifeq ($(VBOX_LDR_FMT),lx)
    184 SUPR0_SOURCES      += $(PATH_TARGET)/SUPR0.def
    185 $(PATH_TARGET)/SUPR0.def: $(PATH_SUB_CURRENT)/SUPR0.def | $(call DIRDEP,$(PATH_TARGET))
     141SUPR0_SOURCES      += $$(PATH_SUPR0)/SUPR0.def
     142$$(PATH_SUPR0)/SUPR0.def: $(PATH_SUB_CURRENT)/SUPR0.def | $$(dir $$@)
    186143        $(SED) -e 's/^[ \t][ \t]*\([gA-Z]\)/    _\1/' -e 's/[ \t]DATA[ \t]*/ /' $< > [email protected]
    187144        $(MV) -f [email protected] $@
     
    284241        $(KBUILD_TARGET)/SUPDrv-$(KBUILD_TARGET).mod.c
    285242endif
     243
     244
     245#
     246# Targets for installing the linux sources.
     247#
     248vboxmod-bin_INST    = bin/src/
     249vboxmod-bin_MODE    = a+r,u+w
     250vboxmod-bin_SOURCES = $(subst ",,$(FILES_VBOXDRV_NOBIN)) #"
     251
     252vboxmod-sh_INST     = bin/src/
     253vboxmod-sh_MODE     = a+rx,u+w
     254vboxmod-sh_SOURCES  = $(subst ",,$(FILES_VBOXDRV_BIN)) #"
     255vboxmod-sh_CLEAN    = $(PATH_TARGET)/vboxmod-sh-1.dep
     256
     257# Scripts needed for building the kernel modules
     258## @todo generate these else where and move them from OTHERS to vboxmod-bin (which btw installs NOBIN files contrary to its name).
     259
     260$(PATH_BIN)/src/build_in_tmp: \
     261                $(PATH_SUB_CURRENT)/linux/build_in_tmp \
     262                $(VBOX_VERSION_STAMP)
     263        $(call MSG_TOOL,Creating,,$@)
     264        $(QUIET)$(SED) -e "s;_VERSION_;${VBOX_VERSION_STRING};g; s;_MODULE_;vboxdrv;g" --output $@ $<
     265        $(QUIET)chmod 0755 $@
     266
     267$(PATH_BIN)/src/dkms.conf: \
     268                $(PATH_SUB_CURRENT)/linux/dkms.conf \
     269                $(VBOX_VERSION_STAMP)
     270        $(call MSG_TOOL,Creating,,$@)
     271        $(QUIET)$(SED) -e "s;_VERSION_;${VBOX_VERSION_STRING};g" --output $@ $<
     272
     273includedep $(PATH_TARGET)/vboxmod-sh-1.dep
     274$(PATH_BIN)/src/Makefile: \
     275                $(PATH_SUB_CURRENT)/linux/Makefile \
     276                $$(if $$(eq $$(Support/linux/Makefile_VBOX_HARDENED),$$(VBOX_WITH_HARDENING)),,FORCE) \
     277                | $(PATH_TARGET)/
     278        $(call MSG_TOOL,Creating,,$@)
     279 ifndef VBOX_WITH_HARDENING
     280        $(QUIET)$(SED) -e "s;-DVBOX_WITH_HARDENING;;g" --output $@ $<
     281 else
     282        $(QUIET)$(CP) -f $< $@
     283 endif
     284        %$(QUIET2)$(RM) -f -- $(PATH_TARGET)/vboxmod-sh-1.dep
     285        %$(QUIET2)$(APPEND) '$(PATH_TARGET)/vboxmod-sh-1.dep' 'Support/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)'
     286
    286287endif # real linux
     288
     289
    287290
    288291
     
    308311VBoxDrv.kext_INST     = $(INST_VBOXDRV)Contents/
    309312VBoxDrv.kext_SOURCES  = \
    310         $(PATH_TARGET)/VBoxDrv/Info.plist
     313        $(PATH_VBoxDrv.kext)/Info.plist
    311314VBoxDrv.kext_CLEAN    = \
    312         $(PATH_TARGET)/VBoxDrv/Info.plist
    313 
    314 $(PATH_TARGET)/VBoxDrv/Info.plist: $(PATH_SUB_CURRENT)/darwin/Info.plist $(VBOX_VERSION_MK) | $(call DIRDEP,$(PATH_TARGET)/VBoxDrv)
     315        $(PATH_VBoxDrv.kext)/Info.plist
     316
     317$$(PATH_VBoxDrv.kext)/Info.plist: $(PATH_SUB_CURRENT)/darwin/Info.plist $(VBOX_VERSION_MK) | $$(dir $$@)
    315318        $(call MSG_GENERATE,VBoxDrv,$@,$<)
    316319        $(xQUIET)$(RM) -f $@
     
    353356VBoxDrvLib_DEFS       = IN_RT_R0 IN_SUP_R0
    354357VBoxDrvLib_INCS      := \
    355         $(PATH_SUB_CURRENT) \
    356         $(PATH_TARGET) \
     358        . \
    357359        $(PATH_ROOT)/src/VBox/Runtime/include
    358360VBoxDrvLib_SOURCES    = \
     
    404406
    405407
     408endif # !VBOX_ONLY_DOCS
    406409include $(KBUILD_PATH)/subfooter.kmk
    407410
  • trunk/src/VBox/HostDrivers/Support/testcase/Makefile.kmk

    r12170 r12252  
    2929#
    3030
    31 ifdef VBOX_SINGLE_MAKEFILE
    3231SUB_DEPTH = ../../../../..
    33 else
    34 SUB_DEPTH = ../..
    35 DEPTH    ?= ../../../../..
    36 endif
    3732include $(KBUILD_PATH)/subheader.kmk
    3833
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