From: Ben Kaduk Date: Sat, 24 Sep 2011 22:05:09 +0000 (-0400) Subject: FBSD: bsd.kmod.mk fallout for debug symbols X-Git-Tag: openafs-stable-1_8_0pre1~3230 X-Git-Url: https://git.openafs.org/?p=openafs.git;a=commitdiff_plain;h=3e191dfd99087ac9408eff5f7f73cc10beb90f79;hp=b6e04fa78ed5793d52caccafe2f5fc46be6a6af9 FBSD: bsd.kmod.mk fallout for debug symbols Now that we no longer control the installation of libafs.ko, debug symbols are always getting stripped. If the user requested kernel debug symbols, define DEBUG_FLAGS for the libafs build and install, so that bsd.kmod.mk will install the .symbols file alongside the kernel module. Change-Id: I0e7f3736666c96c6aaed18c0add98dea37349b83 Reviewed-on: http://gerrit.openafs.org/5503 Tested-by: BuildBot Reviewed-by: Derrick Brashear --- diff --git a/src/cf/osconf.m4 b/src/cf/osconf.m4 index d5f42e8..93b4158 100644 --- a/src/cf/osconf.m4 +++ b/src/cf/osconf.m4 @@ -665,6 +665,12 @@ case $AFS_SYSNAME in AC_SUBST(install_XFS_SIZE_CHECK) AC_SUBST(dest_XFS_SIZE_CHECK) ;; + *_fbsd_*) + if test "x$enable_debug_kernel" = "xyes"; then + DEBUG_FLAGS=-g + AC_SUBST(DEBUG_FLAGS) + fi + ;; esac dnl Disable the default for debugging/optimization if not enabled diff --git a/src/libafs/MakefileProto.FBSD.in b/src/libafs/MakefileProto.FBSD.in index 9ba0954..227fe1b 100644 --- a/src/libafs/MakefileProto.FBSD.in +++ b/src/libafs/MakefileProto.FBSD.in @@ -46,6 +46,9 @@ AFS_OS_NONFSOBJS = \ KSRC = @BSD_KERNEL_PATH@ KBLD = @BSD_KERNEL_BUILD@ +# keep symbols if --enable-debug-kernel +DEBUG_FLAGS = @DEBUG_FLAGS@ + # We are not doing very well (WARNS=2 brings in printf format type checking) WARNS= 1 # We have some sketchy code that redeclares prototypes