VirtualBox

Ignore:
Timestamp:
Feb 20, 2019 4:27:55 PM (6 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
128945
Message:

More linux kernel module Makefile cleansup.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/VBoxNetFlt/linux/Makefile

    r77390 r77394  
    1 #
     1# $Id$
     2## @file
    23# Makefile for the VirtualBox Linux Host Network Filter Driver.
    34#
     
    2425#
    2526
    26 # Linux kbuild sets this to our source directory if we are called from
    27 # there
     27# Find the directory of this makefile.
     28VBOXNETFLT_DIR := $(dir $(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST)))
     29
     30# Linux kbuild sets this to our source directory if we are called from there
    2831obj ?= $(CURDIR)
    2932include $(obj)/Makefile-header.gmk
     
    3639        SUPR0IdcClientComponent.o \
    3740        linux/SUPR0IdcClient-linux.o
    38 
    3941ifeq ($(BUILD_TARGET_ARCH),x86)
    40 MOD_OBJS += math/gcc/divdi3.o \
     42MOD_OBJS += \
     43        math/gcc/divdi3.o \
    4144        math/gcc/moddi3.o \
    4245        math/gcc/qdivrem.o \
    4346        math/gcc/udivdi3.o \
    4447        math/gcc/udivmoddi4.o \
    45         math/gcc/divdi3.o \
     48        math/gcc/divdi3.o \
    4649        math/gcc/umoddi3.o
    4750endif
    48 
    49 MOD_INCL = $(addprefix -I$(KBUILD_EXTMOD),/ /include /r0drv/linux)
    50 MOD_DEFS = -DRT_OS_LINUX -DIN_RING0 -DIN_RT_R0 \
    51         -DIN_SUP_R0 -DVBOX -DRT_WITH_VBOX -DVBOX_WITH_HARDENING \
    52         -Wno-declaration-after-statement
     51MOD_INCL = \
     52        -I$(VBOXNETFLT_DIR) \
     53        -I$(VBOXNETFLT_DIR)include \
     54        -I$(VBOXNETFLT_DIR)r0drv/linux
     55MOD_DEFS = \
     56        -DRT_OS_LINUX \
     57        -DIN_RING0 \
     58        -DIN_RT_R0 \
     59        -DIN_SUP_R0 \
     60        -DVBOX \
     61        -DRT_WITH_VBOX \
     62        -DVBOX_WITH_HARDENING \
     63        -DVBOX_WITH_64_BITS_GUESTS # <-- must be consistent with Config.kmk!
    5364ifeq ($(BUILD_TARGET_ARCH),amd64)
    54  MOD_DEFS += -DRT_ARCH_AMD64
     65MOD_DEFS += -DRT_ARCH_AMD64
    5566else
    56  MOD_DEFS += -DRT_ARCH_X86
     67MOD_DEFS += -DRT_ARCH_X86
    5768endif
    58 # must be consistent with Config.kmk!
    59 MOD_DEFS += -DVBOX_WITH_64_BITS_GUESTS
    60 
    61 # By default we use remap_pfn_range() kernel API to make kernel pages
    62 # visible for userland. Unfortunately, it leads to situation that
    63 # during debug session all structures on that page (such as PVM pointer)
    64 # are not accessible to the debugger (see #3214).
    65 # This code enables experimental support
    66 # for vm_insert_page() kernel API, allowing to export kernel pages
    67 # to the userland in more debugger-friendly way. Due to stability
    68 # concerns, not enabled by default yet.
    69 ifdef VBOX_USE_INSERT_PAGE
    70  KFLAGS  += -DVBOX_USE_INSERT_PAGE
    71 endif
    72 
    73 # build defs
    74 MOD_CFLAGS = -include $(KBUILD_EXTMOD)/include/VBox/SUPDrvMangling.h -fno-pie
     69MOD_CFLAGS = -include $(VBOXNETFLT_DIR)include/VBox/SUPDrvMangling.h -fno-pie -Wno-declaration-after-statement
    7570
    7671include $(obj)/Makefile-footer.gmk
     72
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