VirtualBox

Changeset 16028 in vbox


Ignore:
Timestamp:
Jan 19, 2009 5:11:59 AM (16 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
41712
Message:

Config.kmk: Fixed FreeBSD/amd64 driver linking.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Config.kmk

    r16025 r16028  
    22942294TOOL_FREEBSDKMODLD = FreeBSD kernel module linker.
    22952295# See kBuild/tools/GCC3.kmk for docs.
    2296 TOOL_FREEBSDKMODLD_LINK_SYSMOD_OUTPUT = $(outbase).kld
    22972296TOOL_FREEBSDKMODLD_LINK_SYSMOD_OUTPUT_MAYBE = $(outbase).map
    22982297TOOL_FREEBSDKMODLD_LINK_SYSMOD_DEPEND = $(foreach lib,$(libs),$(if $(findstring $(lib),$(subst /,x,$(lib))),, $(lib)))
    22992298TOOL_FREEBSDKMODLD_LINK_SYSMOD_DEPORD =
     2299 ifeq ($(KBUILD_TARGET_ARCH),amd64)
     2300TOOL_FREEBSDKMODLD_LINK_SYSMOD_OUTPUT =
    23002301define TOOL_FREEBSDKMODLD_LINK_SYSMOD_CMDS
    2301         @# Link intermediate .kld (a relocatable object).
     2302# Link intermediate .kld (a relocatable object).
     2303        ld $(flags) -r -o  $(out) $(objs) \
     2304                $(foreach p,$(libpath), -L$(p))\
     2305                $(foreach lib,$(libs), $(if $(findstring $(lib),$(subst /,x,$(lib))), -l$(patsubst lib%,%,$(basename $(lib))), $(lib)))
     2306# Strip non-exported symbols private and localize the exported ones.
     2307        awk -f $(VBOX_FREEBSD_SRC)/conf/kmod_syms.awk  $(out) $(if $(othersrc), $(othersrc),/dev/null) \
     2308                | xargs -J% objcopy % $(out)
     2309
     2310## Strip debug info (comment out if debugging or something).
     2311#       objcopy --strip-debug $(out)
     2312endef
     2313 else # x86
     2314TOOL_FREEBSDKMODLD_LINK_SYSMOD_OUTPUT = $(outbase).kld
     2315define TOOL_FREEBSDKMODLD_LINK_SYSMOD_CMDS
     2316# Link intermediate .kld (a relocatable object).
    23022317        ld $(flags) -r -o $(outbase).kld $(objs) \
    23032318                $(foreach p,$(libpath), -L$(p))\
    23042319                $(foreach lib,$(libs), $(if $(findstring $(lib),$(subst /,x,$(lib))), -l$(patsubst lib%,%,$(basename $(lib))), $(lib)))
    2305         @# Strip non-exported symbols private and localize the exported ones.
     2320# Strip non-exported symbols private and localize the exported ones.
    23062321        awk -f $(VBOX_FREEBSD_SRC)/conf/kmod_syms.awk $(outbase).kld $(if $(othersrc), $(othersrc),/dev/null) \
    23072322                | xargs -J% objcopy % $(outbase).kld
    2308         @# Link the final .ko (a shared object).
     2323
     2324# Link the final .ko (a shared object).
    23092325        ld $(flags) -Bshareable -o $(out) $(outbase).kld
    23102326endef
     2327 endif # x86
    23112328
    23122329endif # FreeBSD
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