]> granicus.if.org Git - zfs/commitdiff
dkms: Enable debuginfo option to be set with zfs sysconfig file
authorNeal Gompa (ニール・ゴンパ) <ngompa13@gmail.com>
Fri, 18 Jan 2019 18:10:24 +0000 (13:10 -0500)
committerTony Hutter <hutter2@llnl.gov>
Fri, 22 Feb 2019 17:47:34 +0000 (09:47 -0800)
On some Linux distributions, the kernel module build will not
default to building with debuginfo symbols, which can make it
difficult for debugging and testing.

For this case, we provide a flag to override the build to force
debuginfo to be produced for the kernel module build.

Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Co-authored-by: Neal Gompa <ngompa@datto.com>
Co-authored-by: Simon Watson <swatson@datto.com>
Signed-off-by: Neal Gompa <ngompa@datto.com>
Signed-off-by: Simon Watson <swatson@datto.com>
Closes #8304

scripts/dkms.mkconf

index 88c289383e676a666e44d3d3cd034798665d37ba..616b7991b03f888ac7c8df16a69793df55d448c1 100755 (executable)
@@ -65,6 +65,10 @@ PRE_BUILD="configure
       then
         echo --enable-debug-dmu-tx
       fi
+      if [[ \${ZFS_DKMS_ENABLE_DEBUGINFO,,} == @(y|yes) ]]
+      then
+        echo --enable-debuginfo
+      fi
     }
   )
 "