VirtualBox

Changeset 69527 in vbox


Ignore:
Timestamp:
Oct 30, 2017 5:28:06 PM (7 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
118870
Message:

Installer/linux: re-enable use of the variable KERN_DIR for building modules.
bugref:4567: Linux kernel driver maintenance

Using only the environment variable KERN_VER to decide which kernel version
to build against means that we can only use kernel headers in the default
location. This might make some things harder, so re-enable the use of
KERN_DIR in addition.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Installer/linux/Makefile.include.header

    r69500 r69527  
    9494
    9595 # kernel base directory
     96 ifdef KERN_DIR
     97  ifeq ($(filter %/build,$(KERN_DIR)),)
     98   $(error The variable KERN_DIR must be a kernel build folder and end with /build without a trailing slash)
     99  endif
     100 endif
     101
     102 ifndef KERN_VER
     103  ifdef KERN_DIR
     104   KERN_VER = $(notdir $(patsubst %/build,%,$(KERN_DIR)))
     105   ifeq ($(shell expr $(KERN_VER) : '[0-9]*\.[0-9]*.[0-9]*'),0)
     106    $(error The kernel build folder path must end in <version>/build, or the variable KERN_VER must be set)
     107   endif
     108  endif
    96109 KERN_VER ?= $(shell uname -r)
     110 endif
    97111
    98112 # guess kernel major version (24 or later)
Note: See TracChangeset for help on using the changeset viewer.

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